changing the mod in secp256k1

134 views Asked by At

Guys not very great at math, but i am trying to achieve something, well firstly i understand that secp256k1 has a large prime modulo. now i have figured out a way to perform a division like operation on the ecc

hex(0x7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20e2 * 131  % 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141

i understand the divisions on Elliptic curve is not like the traditionally known form of division. In reality it is a multiplication for the inverse of the Dividend modulo N what this mean

Lets think in the division of 2/2 = 1 right? Well in elliptic curve we need to find a X number that 2*X = 1 mod N

N = 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141

That X is the inverse value of 2

in this case: 0x7fffffffffffffffffffffffffffffff5d576e7357a4501ddfe92f46681b20a1

so if a number is not even for example 131/2 = 65.5 right? but here its rounded up and 66 is added to the multiplicative inverse.. now the question is how can i make it warp around a certain mod and not change anything ? what i mean is i want the multiplicative inverse within a certain range and and N in a certain range and not disturb how ecc works is it possible ?

0

There are 0 answers