Post
Topic
Board Development & Technical Discussion
Re: How to generate public key from private key
by
aplistir
on 17/12/2017, 15:13:47 UTC
i have only one missing part to understand the complete picture.
G is a point on the curve with two coordinates(X,Y), how can you multiply the with a number and end up with a single number(public key) and not with a new point?

What you get is a new point, which is your public key.
There are two possible ways to represent your public key. Either the long one with
04 + x_coordinate + y_coordinate
or (the compressed way) if y is even
02 + x_coordinate
and for odd y
03 + x_coordinate

Your public key is a point in the field. It is just represented in the way I described above. And you can always calculate the x and y coordinates from the compressed format too.

from the public key you can calculate your address, and for that you have to take SHA256 and Ripemod160 hashes. And add a few check bytes to the end...