BW6G2Affine
State Variables
INFINITY_FLAG
INFINITY_FLAG
bytes1 private constant INFINITY_FLAG = bytes1(0x40);
Y_IS_NEGATIVE
Y_IS_NEGATIVE
bytes1 private constant Y_IS_NEGATIVE = bytes1(0x80);
Functions
zero
Returns the additive identity element of Bw6G2.
function zero() internal pure returns (Bw6G2 memory);
Returns
Name | Type | Description |
---|---|---|
<none> | Bw6G2 | Bw6G2(BW6FP.zero(), BW6FP.zero()) |
is_zero
Returns true
if self
is equal to the additive identity.
function is_zero(Bw6G2 memory self) internal pure returns (bool);
Parameters
Name | Type | Description |
---|---|---|
self | Bw6G2 | Bw6G2. |
Returns
Name | Type | Description |
---|---|---|
<none> | bool | Result of zero check. |
is_infinity
Returns true
if self
is infinity point.
function is_infinity(Bw6G2 memory self) internal pure returns (bool);
Parameters
Name | Type | Description |
---|---|---|
self | Bw6G2 | Bw6G2. |
Returns
Name | Type | Description |
---|---|---|
<none> | bool | Result of infinity check. |
serialize
Serialize Bw6G2.
function serialize(Bw6G2 memory g2) internal pure returns (bytes memory r);
Parameters
Name | Type | Description |
---|---|---|
g2 | Bw6G2 | Bw6G2. |
Returns
Name | Type | Description |
---|---|---|
r | bytes | Compressed serialized bytes of Bw6G2. |