Skip to content

Get X coordinate from Y ??? #1432

Closed Answered by sipa
rs78GT asked this question in Q&A
Oct 22, 2023 · 3 comments · 1 reply
Discussion options

You must be logged in to vote

I'm not sure what you're trying to do, but computing Y from X is a lot simpler than X from Y. That is what the compressed public key format is based on, which is supported by libsecp256k1.

For that, the relation is just y = +- sqrt(x^3 + 7) mod p.

Replies: 3 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@sipa
Comment options

Answer selected by rs78GT
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants