Post
Topic
Board Bitcoin Discussion
Re: Bitcoin Talmud (or Order 2.625 Bible)
by
KalOlak
on 29/07/2023, 18:28:23 UTC
32bit binary which starting point is of 5000000000units has a nice easy halving factor that results in a near precise amount with limited rounding when halved every 210k blocks

but explaining the 21 is more ontopic to satoshi

Of course, your answer is incorrect because you are not familiar with programming and the architecture of modern processors.

21 million was chosen in order to simplify calculations and involve floating-point arithmetic.

1. 64-bit IEEE754 double, all integers up to 9007199254740992 == 2^53 can be exactly represented. In the range 2^51 to 2^52, the only non-integer values.
Below 2^51 we also have ".25" and ".75", so comparing a number with its rounded counterpart in order to determine if it may be integer or not starts making some sense.
If you want to test whether a calculated result may be integer, avoid numbers larger than 2251799813685248 == 2^51

Sure, he could choose  2200000000000000, but 22 is not triangular numer.

2. So, for the purpose of optimizing calculations, he had to choose the triangular number closest to 22 from the sequence: 0, 1, 3, 6, 10, 15, 21, 28,...

So it's 21. Basic math, kid.