Wire Sysio Wire Sysion 1.0.0
Loading...
Searching...
No Matches
Fp12 Class Reference

#include <bn254_if.hpp>

Public Member Functions

 Fp12 ()
 
 Fp12 (const Fp12 &x)
 
 Fp12 (int x)
 
void set (const std::string &str) throw (std::exception)
 
std::string toString () const throw (std::exception)
 
bool equals (const Fp12 &rhs) const
 
void add (const Fp12 &rhs) throw (std::exception)
 
void sub (const Fp12 &rhs) throw (std::exception)
 
void mul (const Fp12 &rhs) throw (std::exception)
 
void pairing (const Ec2 &ec2, const Ec1 &ec1)
 
void power (const Mpz &x)
 

Detailed Description

Definition at line 123 of file bn254_if.hpp.

Constructor & Destructor Documentation

◆ Fp12() [1/3]

Fp12::Fp12 ( )
inline

Definition at line 126 of file bn254_if.hpp.

126{}

◆ Fp12() [2/3]

Fp12::Fp12 ( const Fp12 & x)
inline

Definition at line 127 of file bn254_if.hpp.

127: self_(x.self_) {}

◆ Fp12() [3/3]

Fp12::Fp12 ( int x)
inline

Definition at line 128 of file bn254_if.hpp.

128: self_(x) {}

Member Function Documentation

◆ add()

void Fp12::add ( const Fp12 & rhs)
throw (std::exception )
inline

Definition at line 141 of file bn254_if.hpp.

141{ self_ += rhs.self_; }

◆ equals()

bool Fp12::equals ( const Fp12 & rhs) const
inline

Definition at line 140 of file bn254_if.hpp.

140{ return self_ == rhs.self_; }

◆ mul()

void Fp12::mul ( const Fp12 & rhs)
throw (std::exception )
inline

Definition at line 143 of file bn254_if.hpp.

143{ self_ *= rhs.self_; }
Here is the caller graph for this function:

◆ pairing()

void Fp12::pairing ( const Ec2 & ec2,
const Ec1 & ec1 )

Definition at line 245 of file bn254_if.hpp.

246{
247 ::bn::opt_atePairing(self_, ec2.self_, ec1.self_);
248}
void opt_atePairing(Fp12T< Fp6T< Fp2T< Fp > > > &f, const Fp2T< Fp > Q[2], const Fp P[2])
Definition bn.h:2720
Here is the call graph for this function:
Here is the caller graph for this function:

◆ power()

void Fp12::power ( const Mpz & x)
inline

Definition at line 145 of file bn254_if.hpp.

146 {
147 self_ = mie::power(self_, x.self_);
148 }
T power(const T &x, const S &y)
Definition zm.h:1389
Here is the call graph for this function:
Here is the caller graph for this function:

◆ set()

void Fp12::set ( const std::string & str)
throw (std::exception )
inline

Definition at line 129 of file bn254_if.hpp.

130 {
131 std::istringstream iss(str);
132 iss >> self_;
133 }

◆ sub()

void Fp12::sub ( const Fp12 & rhs)
throw (std::exception )
inline

Definition at line 142 of file bn254_if.hpp.

142{ self_ -= rhs.self_; }

◆ toString()

std::string Fp12::toString ( ) const
throw (std::exception )
inline

Definition at line 134 of file bn254_if.hpp.

135 {
136 std::ostringstream oss;
137 oss << self_;
138 return oss.str();
139 }

The documentation for this class was generated from the following file: