check if a point lies on the curve in the tests
Signed-off-by: Uncle Fatso <uncle.fatso@ghostchain.io>
This commit is contained in:
parent
901e969877
commit
db373fe486
@ -88,4 +88,8 @@ contract MathTester {
|
|||||||
function toAffineProjective(uint256 x, uint256 y, uint256 z) public pure returns (uint256, uint256) {
|
function toAffineProjective(uint256 x, uint256 y, uint256 z) public pure returns (uint256, uint256) {
|
||||||
return EllipticCurveProjective.toAffine(x, y, z);
|
return EllipticCurveProjective.toAffine(x, y, z);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function isOnCurve(uint256 x, uint256 y) public pure returns (bool) {
|
||||||
|
return EllipticCurveProjective.isOnCurve(x, y);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user