You will learn, from a high-level perspective, about the underlying mechanics of Bitcoin as a payment network.
The Bitcoin Ledger
- Blockchain – a system of recording information that is difficult or impossible to change, hack, or cheat
- Decentralized – process by which core activities and decision making is delegated away from a central authority
Bitcoin Mining (Proof-of-Work)
Let us suppose the Bitcoin blockchain has started from scratch. No transactions exist. Regardless of the fact that no transactions have taken place, the Bitcoin software mandates that a record of transactions in the network gets officially recorded to the ledger/blockchain with a timestamp. This process occurs about every 10 minutes. So, every 10 minutes, a “block” of confirmed transactions that took place in the network will be added to the end of the blockchain. No transactions in a block would simply lead to an empty block being added.
For this process of adding blocks to occur, the Bitcoin software puts out a bounty to solve a complex math problem that would take your computer approximately 10 minutes to answer. For solving the problem, the underlying code will reward some amount of bitcoin to a digital version of a wallet (aka a digital wallet) held by your computer. This computation-heavy process is called proof-of-work mining. Your computer runs the Bitcoin software and validates blocks of transactions, by solving complex math problems given by the Bitcoin software, in return for bitcoin (the asset) in a digital wallet.
Expanding on this concept, we introduce another network participant. You and another party compete to solve the computation-based problem first. Typically, whoever has the most computation power (aka hash rate) will have a higher probability of winning the race, and thus earn bitcoin from the network. After a winner is determined, you and the other participant will update your version of the blockchain to include the validated block. You both continue to compete for new blocks approximately every 10 minutes. To keep the 10 minute window, the difficulty of the math problem is adjusted automatically as new miners join and leave the network.
Without a single user generated transaction taking place, newly minted bitcoins were rewarded to miners for validating blocks and the blockchain grew; with the ledger becoming more distributed as miners downloaded the existing version of the ledger (with the longest string of blocks) to begin competing in the mining process. The bitcoin held by miners is sold directly to other people, sold on cryptocurrency exchanges (similar to using a brokerage), or held.
It is also possible to run a copy of the Bitcoin blockchain, without contributing to the mining process (called running a Bitcoin node). This further distributes the original copy of the official Bitcoin ledger (increasing the blockchain’s immutability properties). Simply running a node (without specialized mining hardware) will allow you to validate your version of the ledger versus others in the network, but will not allow you to earn bitcoin. The proof-of-work difficulty is currently too high for normal PCs to compete in the mining process.
- Bitcoin Node – any computer that runs a Bitcoin implementation and stores a full record of the blockchain
- Cryptocurrency Exchange – marketplace allowing for the conversion of digital currencies for other assets
- Digital Wallet – software that allows one party to make electronic transactions with another
- Hash Rate – total amount of computation power used in a proof-of-work cryptocurrency network to validate blockchain transactions
- Immutability – not capable or susceptible to change
- Proof-of-Work – cryptographic proof in which one party proves to others that a certain amount of computational power has been expended
Validating Bitcoin Transactions (Mining Cont.)
Suppose Sally Sue wants to buy a moon missile from Jeff. However, Jeff only accepts Bitcoin as payment. Sally would then go and exchange dollars on a cryptocurrency exchange for bitcoin. The bitcoin that Sally purchased would then be transferred to Jeff’s digital bitcoin wallet via a public address. This bitcoin transaction would automatically be broadcast to the network to be included in the next block for validation.
The transaction effectively sits in a queue and waits for miners to find the next valid block to add to the blockchain. As discussed, finding the next valid block is the competition that miners go through to answer the math problem given by the Bitcoin software. A fee is added to this transaction (paid to the miners) as an incentive for miners to prioritize adding Sally’s transaction to a block, as there is a limit to how many transactions can fit into a single block. The more congested the queue, the longer it takes to validate a transaction, and the higher the transaction fee becomes to ensure a transaction is included earlier than others in a block. Remember, it takes 10 minutes for miners to find a valid block.
Once the transaction is confirmed, the bitcoin that Sally sent to Jeff would be available for use and Jeff can then send Sally the moon missile. To ensure a high degree of security of the transaction, it is an industry standard to wait for at least 6 confirmations before declaring a transaction is secure and irreversible. A confirmation is a block being added to the blockchain after a particular transaction has been made. 6 confirmations, in theory, would take an hour to process.
At a high level, this is how transactions are validated and how the blockchain grows within the Bitcoin network. This entire process of keeping nodes in sync through the longest chain selection and validating transactions using proof-of-work is known as consensus or more specifically, in the case of the Bitcoin protocol, Nakamoto Consensus.
- Confirmation – a block being added to the blockchain after a particular transaction has been made
- Consensus – method for ensuring individual nodes in a system agree on a single state of the network
- Protocol (programming) – a set of rules and instructions by which electronic devices must follow in order to communicate between one another
- Public Address – a cryptographic string of text that allows a user to receive cryptocurrencies to their digital wallet or account
Chaudhury, A. (2021, November 8). What is Nakamoto consensus and how does it power bitcoin? Bitcoin Magazine: Bitcoin News, Articles, Charts, and Guides. Retrieved March 22, 2022, from https://bitcoinmagazine.com/guides/what-is-nakamoto-consensus-bitcoin
Dog, D. (2020, November 19). What is the Nakamoto Consensus? CoinMarketCap Alexandria. Retrieved March 22, 2022, from https://coinmarketcap.com/alexandria/article/what-is-the-nakamoto-consensus
Nakamoto, S. (2008). Bitcoin: A Peer-to-Peer Electronic Cash System. Bitcoin.org.