Bitcoin Forum
June 20, 2024, 06:15:02 AM *
News: Voting for pizza day contest
 
  Home Help Search Login Register More  
  Show Posts
Pages: [1]
1  Bitcoin / Development & Technical Discussion / Difference between Public key P and target R in Jimmy Song book on: September 01, 2022, 03:48:57 PM
Hi there,

I'm going through the book of Jimmy Song: Programming Bitcoin: Learn How to Program Bitcoin from Scratch.
Peek here: https://books.google.nl/books?id=QWaHDwAAQBAJ&pg=PA66&lpg=PA66&dq=bitcoin+uG%2BvP+%3DR&source=bl&ots=6iNPaefGNc&sig=ACfU3U1nrwO6y8-O_BdpUf-GaRC_JeiX8w&hl=nl&sa=X&ved=2ahUKEwjXka7X8fP5AhVE2qQKHau0BVUQ6AF6BAgfEAM#v=onepage&q=bitcoin%20uG%2BvP%20%3DR&f=false

On p63, a variable R is introduced as 'the target that is aimed for...', referring to the story of the archer on p62.

It is calculated by R = k*G where k is a secret random number and G is the starting point in the group of the btc-curve.

On the  same page, e*G = P is mentioned, where e is the private key and P is the public key.

I just can't figure out what the difference between P and R is, or better: what is the meaning/function of R, when already P is the result of point multiplication of e and G.

Is it perhaps this:
1. With k*G = R you do point multiplication of k and G to find a new point R (x,y)  'r' is defined as the x-coordinate of R and that x-coordinate 'r' is used in the signature (r,s) with s  = (z+re)/k.
2. With  e*G = P you do point multiplication of e and G to find e new point P (x,y) that is the public key.
So there are two different point multiplications: one with the goal to get a number 'r' for the signature and one with the goal to get a private key.

If this is true, I don't understand why mr Song is calling R the target. In my perception, P is the target. So I can't see yet how to image/explain the R.

Thanks in advance!


















 
Pages: [1]
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!