Skip to main content

FP12

FP12​

Kind: global class
this: {"{"}FP12{"}"}

new FP12()​

Creates an instance of FP12.

fP12.reduce()​

Reduces all components of possibly unreduced FP12 mod Modulus

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.norm()​

Normalises the components of an FP12

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.iszilch()​

Tests for FP12 equal to zero

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.isunity()​

Tests for FP12 equal to unity

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.cmove(g, d)​

Conditional copy of FP12 number

Kind: instance method of FP12
this: {"{"}FP12{"}"}

ParamDescription
gFP12 instance
dcopy depends on this value

fP12.select()​

Constant time select from pre-computed table

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.geta()​

extract a from this

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.getb()​

extract b from this

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.getc()​

extract c from this

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.equals(x)​

Tests for equality of two FP12s

Kind: instance method of FP12
this: {"{"}FP12{"}"}

ParamDescription
xFP12 instance to compare

fP12.copy(x)​

Copy FP12 to another FP12

Kind: instance method of FP12
this: {"{"}FP12{"}"}

ParamDescription
xFP12 instance to be copied

fP12.one(x)​

Set FP12 to unity

Kind: instance method of FP12
this: {"{"}FP12{"}"}

ParamDescription
xFP12 instance to be set to one

fP12.zero()​

Set FP12 to zero

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.conj()​

Conjugation of FP12

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.set(d, e, f)​

Set FP12 from three FP4 values

Kind: instance method of FP12
this: {"{"}FP12{"}"}

ParamDescription
dFP4 instance
eFP4 instance
fFP4 instance

fP12.seta(d)​

Set FP12 from one FP4 value

Kind: instance method of FP12
this: {"{"}FP12{"}"}

ParamDescription
dFP4 instance

fP12.usqr()​

Fast Squaring of an FP12 in "unitary" form

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.sqr()​

Fast Squaring of an FP12

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.mul(y)​

Full unconditional Multiplication of two FP12s

Kind: instance method of FP12
this: {"{"}FP12{"}"}

ParamDescription
yFP12 instance, the multiplier

fP12.smul(y)​

Fast multiplication of two sparse FP12s that arises from ATE pairing line functions

Kind: instance method of FP12
this: {"{"}FP12{"}"}

ParamDescription
yFP12 instance, the multiplier

fP12.ssmul(y)​

Fast multiplication of what may be sparse multiplicands

Kind: instance method of FP12
this: {"{"}FP12{"}"}

ParamDescription
yFP12 instance, the multiplier

fP12.inverse()​

Inverting an FP12

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.frob(f)​

Raises an FP12 to the power of the internal modulus p, using the Frobenius

Kind: instance method of FP12
this: {"{"}FP12{"}"}

ParamDescription
fModulus

fP12.trace()​

Calculate the trace of an FP12

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.toString()​

convert this to hex string

Kind: instance method of FP12
this: {"{"}FP12{"}"}

fP12.toBytes(w)​

convert this to byte array

Kind: instance method of FP12
this: {"{"}FP12{"}"}

ParamDescription
wByte array

fP12.pow(e)​

Raises an FP12 to the power of a BIG

Kind: instance method of FP12
this: {"{"}FP12{"}"}

ParamDescription
eBIG instance exponent

fP12.pinpow(e, bts)​

Raises an FP12 instance x to a small integer power, side-channel resistant

Kind: instance method of FP12
this: {"{"}FP12{"}"}

ParamDescription
esmall integer exponent
btsmaximum number of bits in exponent

fP12.compow(e, r)​

Raises an FP12 instance to a BIG power, compressed to FP4

Kind: instance method of FP12
this: {"{"}FP12{"}"}

ParamDescription
eBIG exponent
rBIG group order

FP12.fromBytes(w)​

convert from byte array to FP12

Kind: static method of FP12
this: {"{"}FP12{"}"}

ParamDescription
wByte array

FP12.teq()​

return 1 if b==c, no branching

Kind: static method of FP12
this: {"{"}FP12{"}"}

FP12.pow4()​

p=q0^u0.q1^u1.q2^u2.q3^u3

Kind: static method of FP12
this: {"{"}FP12{"}"}