Post
Topic
Board Development & Technical Discussion
Re: Secp256k1 returning half of 3G?
by
NotATether
on 17/12/2024, 16:59:00 UTC
Quote
But if you're using libsecp256k1 then you don't actually have to worry about constructing an N or a P for modulus. The library will reduce the values automatically.
How does the library "know" when to do regular inverse double 16G-->8G and when to do 7G---->SomethingG...
I am asking because every dot looks like any other dot. You do not know if multiplier*G is odd or even

(I was going to write a longer reply, but my iPhone screen glitches and I had to force restart. Sorry.)

Basically the types it use are large enough to carry some overflow before it eventually runs out of bits.

BTW: the library is for point operations, so it only does mod P. There's another library, piggypiggy/fp256 on Github, for modular arithmetic with arbitrary modulus.