Difficulty calculation of the longest bitcoin chain
Publish: 2021-05-23 23:14:01
1. bitcoin is a consensus network, contributing to a new payment system and a fully digital currency. It is the first decentralized peer-to-peer payment network, which is controlled by its users without a central management organization or middleman. From the user's point of view, bitcoin is much like Internet cash. Bitcoin can also be regarded as the most outstanding three style bookkeeping system
anyone can run software on specialized hardware and become a bitcoin miner. mining software monitors transaction broadcast through P2P network and performs appropriate tasks to process and confirm these transactions. Bitcoin miners can earn transaction fees paid by users to speed up transaction processing and additional bitcoin issued according to fixed formula
new transactions need to be included in a block with mathematical workload proof before they can be confirmed. This kind of proof is hard to generate because it can only be generated by trying billions of calculations per second. Miners need to run these calculations before their blocks are accepted and rewarded. As more people start mining, the difficulty of finding effective blocks will be automatically increased by the network to ensure that the average time to find a block remains at 10 minutes. Therefore, the competition for mining is very fierce, and no indivial miner can control the content contained in the block chain
workload proof is also designed to rely on previous blocks, which forces the time sequence of block chain. This design makes it extremely difficult to cancel previous transactions, because the workload proof of all subsequent blocks needs to be recalculated. When two blocks are found at the same time, the miner will process the first block received, and once the next block is found, it will be transferred to the longest block chain. This ensures that the mining process maintains a global consistency based on processing capacity
bitcoin miners can neither increase their rewards by cheating, nor deal with the fraulent transactions that destroy the bitcoin network, because all bitcoin nodes will reject the blocks containing invalid data that violate the bitcoin protocol rules. Therefore, even if not all bitcoin miners can be trusted, the bitcoin network is still secure
sha256 is an encryption algorithm.
anyone can run software on specialized hardware and become a bitcoin miner. mining software monitors transaction broadcast through P2P network and performs appropriate tasks to process and confirm these transactions. Bitcoin miners can earn transaction fees paid by users to speed up transaction processing and additional bitcoin issued according to fixed formula
new transactions need to be included in a block with mathematical workload proof before they can be confirmed. This kind of proof is hard to generate because it can only be generated by trying billions of calculations per second. Miners need to run these calculations before their blocks are accepted and rewarded. As more people start mining, the difficulty of finding effective blocks will be automatically increased by the network to ensure that the average time to find a block remains at 10 minutes. Therefore, the competition for mining is very fierce, and no indivial miner can control the content contained in the block chain
workload proof is also designed to rely on previous blocks, which forces the time sequence of block chain. This design makes it extremely difficult to cancel previous transactions, because the workload proof of all subsequent blocks needs to be recalculated. When two blocks are found at the same time, the miner will process the first block received, and once the next block is found, it will be transferred to the longest block chain. This ensures that the mining process maintains a global consistency based on processing capacity
bitcoin miners can neither increase their rewards by cheating, nor deal with the fraulent transactions that destroy the bitcoin network, because all bitcoin nodes will reject the blocks containing invalid data that violate the bitcoin protocol rules. Therefore, even if not all bitcoin miners can be trusted, the bitcoin network is still secure
sha256 is an encryption algorithm.
2. Tragically, it should be less than 0.01 yuan
3. In terms of bitcoin, I calculate that it's about 0.13, earning 500 + yuan a day
4. On May 22, 2010, Laszlo hanyecz, a programmer in Jacksonville, Florida, bought $25 worth of pizza with 10000 BTC. Up to now, it's about $2720 a bitcoin. If you want to know more about bitcoin or blockchain, you can follow Youku's "Yangyang interview"
5. The computing power of a single machine. The difficulty is fixed, there is no how to come, just like the human ape purification.
6. Each block contains the information of all recent transactions, a nonce (random number) and the hash value of the previous block. When the SHA-256 hash value of the whole block is lower than the current target value, it is marked as "resolved" (published and verified by multiple nodes). Usually, it is difficult to achieve the goal by hashing once, so nonce must be increased, and blocks must be hashed millions of times to achieve the goal.
7. After 2026 data blocks are generated by bitcoin, the calculation difficulty is updated (each data block includes about 25 bitcoins). It should be updated once today or tomorrow
the later, the longer it takes to calculate each data block, the lower the update frequency of calculation difficulty.
the later, the longer it takes to calculate each data block, the lower the update frequency of calculation difficulty.
8. What is the longest chain? Why the right blockchain
according to the white paper of bitcoin, nodes always think that the longest chain is the right blockchain and will continue to extend on it. All miners are mining on the longest chain, which is concive to the uniqueness of blockchain ledger. If the bitcoin transaction transferred to you is not recorded on the longest chain, you may face property losses
what is the "longest blockchain"? Because the miners all over the world are mining at the same time, it is possible that two miners can work out the correct answer at the same time, then the blockchain will form a fork, and the remaining miners may continue to mine on any fork, extending the blockchain
therefore, we usually require that after the bitcoin transfer is packaged, we need to go through the confirmation of six blocks to ensure that the miners will not go back to the other branch to excavate, then the real transfer is successful.
according to the white paper of bitcoin, nodes always think that the longest chain is the right blockchain and will continue to extend on it. All miners are mining on the longest chain, which is concive to the uniqueness of blockchain ledger. If the bitcoin transaction transferred to you is not recorded on the longest chain, you may face property losses
what is the "longest blockchain"? Because the miners all over the world are mining at the same time, it is possible that two miners can work out the correct answer at the same time, then the blockchain will form a fork, and the remaining miners may continue to mine on any fork, extending the blockchain
therefore, we usually require that after the bitcoin transfer is packaged, we need to go through the confirmation of six blocks to ensure that the miners will not go back to the other branch to excavate, then the real transfer is successful.
Hot content