filecoin-project / ec-gpu

OpenCL code generator for finite-field arithmetic over arbitrary prime fields
Other
91 stars 61 forks source link

Subtraction on bls12-381 #40

Closed 20171759 closed 1 year ago

20171759 commented 2 years ago

Given a "G1_affine" type point G (x, y), then - G should be (x, Fq_P - y). A "G1projective" point is marked as P, so G1 sub mixed(P,G) = G1 add_ mixed(P,-G)。 I want to know what is wrong with this understanding? Or can you provide some help for the calculation of "G1_sub_mixed"?