ELI5: Bitcoin Mining Explained
Friday, November 9th, 2018Things I learned about bitcoin mining today:
- All bitcoin transactions are recorded via a system called Blockchain. The “mining” process you hear about is something you must do in order to add new blockchain entries (blocks) to record the transactions. This cannot be done by the casual user—adding an entry is very, very computationally intensive. So there are dedicated bitcoin miners who do it for you.
- Successful miners are rewarded with a number of bitcoins in addition to any transaction fees they charge. Currently, however, the bitcoin reward is so lucrative that transaction fees are typically less than a dollar.
- About every 4 years the number of bitcoins you get from mining a block is cut in half. Right now it’s 12.5. It’s been at that level for about 2 years and is expected to drop to 6.25 in the 2020-2021 timeframe.
- Eventually the system will get to the point where mining bitcoins won’t provide enough of them to be cost-effective, and the miners will get their profit solely from charging transaction fees.
- The maximum number of bitcoins that will ever exist is about 21 million. Currently about 17.5 million have been mined (~ 85% of the total).
- The difficulty level of the bitcoin mining calculations is adjusted approximately every two weeks to account for changes to the amount of processing power applied to the system. The goal is to make it average 10 minutes per block. So the system adjusts for advances in hardware or increases in the number of computers used, and the problem is just as time-consuming today as it was 5 year ago, and will be the same 5 years from now.
- Note: For the technically inclined, the mining computations just require you to generate a hash code that, when interpreted as a number, is less than a specified value. So the hash must have a bunch of leading zeroes. Normally you will have to run the hash algorithm many times before you get a value that meets the criteria. The adjustment that occurs is to simply change the target number.
- In December 2017, a miner using poorly-written custom mining software had a situation where his software neglected to tell the blockchain system to give him the reward. He mined the block, inserted it into the blockchain, and got nothing in return. At the time, the 12.5 bitcoin he lost was worth about $200,000. These bitcoins are lost forever, as effectively as if they’d been physically destroyed.