When we hear the word ‘mining’, the first thing that comes to our mind is ‘digging’ something precious out of the ground. But when it comes to mining Bitcoin, the concept is a little different. Bitcoin has no physical form, then why is currency generation used synonymously with the word ‘mining’?
Well, this is because it is just like excavating or churning out gold, except the fact that BTC exists in the algorithmic design (in contrast to the gold that remains underground). As per the protocol, only 21 million coins can be generated in total. Miners get rewarded with a share of Bitcoin for generating blocks of authenticated transactions and then adding them up in the blockchain.
Nodes are basically powerful computers which control Bitcoin's software and support the system by taking part in the dissemination of data. Each and every individual can run the node. All one has to do is download and install the Bitcoin software for free and then keep a certain port unlocked.
A few nodes are basically mining nodes (typically called ‘miners’). These gather all the outstanding transactions in blocks and then include them in the blockchain. This is done by solving complex algorithmic equations and incorporating the appropriate answer in the respective block.
How would they locate this number? By simply speculating. The hashing work makes it difficult to foresee what the result will be. In this way, miners figure the riddle and apply the hash capacity to the arrangement of that speculated number and the information stored in the block. The subsequent hash needs to begin with a pre-built up number of zeroes. It is not possible to know which number will work, since two successive numbers will give varying outcomes. Additionally, there might be a few ‘nonces’ that deliver the desirable outcome, or there might be none (in which case the miners continue with their attempts, yet with an alternate block configuration).
The principal miner to get a subsequent hash within the expected range declares victory to others in the network. The various miners promptly stop working on that particular block and begin to solve the following one. As a reward for the contribution, the winner gets some new Bitcoin.
Currently, the mining reward is 12.5 BTC. However, it is not as easy as it seems. There are a number of miners competing for the block reward and it is all a matter of luck as well as computing power. The mining difficulty is frequently adjusted so that it takes an average of 10 minutes to process 1 block.