I came across hugeblack's reply
https://bitcointalksearch.org/topic/m.64132796 on a thread yesterday, where he used a photo of Bitcoin halving formula as an illustration based on the question that was asked. I instantly got attracted to the formula, and was eager to perform the mathematical calculation of Bitcoin halving approximately every four years. It also turns out that this formula can also give the total supply value.
The image you see below is not different from what hugeblack shared in his reply yesterday. I will explain the key points in the formula below before moving further.
- The value 2 represent the decreasing factor for every halving.
- The value 10^8 represents the smallest unit of Bitcoin also known as Satoshi. E.g 0.0000012.
- 210K is simply the number of blocks that needs to be mined before halving is triggered
- 50 is the first amount of reward
- the letter i below the sigma sign represents each halving. It must start with a value of 0 to 32, making the total halving to occur 33 times.
My aim was to get the
total number of Bitcoin supply, but Inorder to achieve that, I will have to perform the calculation 33 times before arriving at my answer. For example, first trial will require me to replace
i with
1, which will result to a value of 10500000 Bitcoin been mined for first halving year. Second trial, replacing
i with
2, will result to 5249999.998 Bitcoin been mined for second halving year. I can continue to do this till my last trial which is by replacing
i with
32, which will give 2.444721758×10^-3.
Trying to calculate all 33 values one after the other was so stressful and unhealthy, though I tried it. I had a thought to use other methods in carrying out the calculation, and my calculator came to mind. The images below are two different calculators that i used, which gave me an estimated value. I was able to compute the
sigma sign, and also use
x in place of
i because my calculator does not have
i.
https://www.talkimg.com/images/2024/05/27/LIwpP.jpeghttps://www.talkimg.com/images/2024/05/27/LIS3j.jpegI then challenged myself to perform the calculation on a paper, rather than inputting all values into the calculator to get a straight answer. The image below show my three steps.
- Step 1 was just to evaluate by multiplying the number of blocks by the number of first reward, and then dividing both units of Bitcoin (10^8).
- Step 2, I had to get rid of the sigma sign Since I already know that it is use to sum multiple terms. Sum of a geometric progression was used to replace the sigma sign, with a formula containing it's first term, common ratio and nth term.
- Step 3, I finalized by getting my answer.
The image below is not that different from the one above. I had to draft this when I noticed that another solution can come from the one above. If you observe the image below, you noticed that I break down the
Sum of a GP formula into two, which one part happens to be the formula for
Sum to Infinity. If you compute your first term and common ratio, you will still get same 21M value as the one above, but I think this can only happen when
32 at the top of the sigma sign is changed to infinity
∞. Unluckily for me, my calculator does not have an infinity sign, which makes it difficult to confirm.
I need to also share this. The 21M total supply is actually a calculator estimated value, and don't really follow the principles that governs the real formula itself. But that does not mean that the calculator is totally wrong. I discovered this when I decided to stress myself out, by calculating the entire halving values 33 times just by increasing my count by a factor of 1.
The image above was my
rough work for each values of every halving. After taking my time to perform this calculation, I discovered that the total value does not amount to 21M, but rather 20999999.92.
Each values represents the total amounts that can be mined for a particular mining period before another halving occurs.
Please note that after you've used the halving formula to get the first number of Bitcoins to be mined (10500000), any attempt to start dividing by a factor of 2 without using the proper formula, will give you a wrong value. You can try this by dividing 10500000/2, and also try it for others.
My Question:
1. What do you think about the part where I applied
sum to infinity ?.
My calculations on this post are for fun purposes, but might be educational to someone. I am not certain 100% accurate, but I think racking my brain all day for Bitcoin math is quite interesting to me.