Bitcoin in a Nutshell
Dr. Daniel K.C. Chan
September, 2021
Contents
◦ What is Bitcoin?
◦ Which Bitcoin networks to transact on?
◦ Where to keep your bitcoins?
◦ Ways to pay more securely
◦ How to buy and sell bitcoins?
◦ Transaction fees are optional but …
◦ What does Bitcoin have to do with
blockchain?
◦ How is consensus reached?
◦ What is Bitcoin mining?
September, 2021 Bitcoin in a Nutshell 2
What is Bitcoin?
September, 2020 Bitcoin in a Nutshell 3
Introduction to Bitcoin
▪ First cryptocurrency (created and stored digitally) introduced in 2009
and is the most popular cryptocurrency
▪ The number of bitcoins is capped to 21 million by design
▪ It is operated by a decentralised authority
▪ No centralised authority is responsible for verification of the validity of bitcoin
transactions and decides its value - it does this on its own
▪ Acceptable to some businesses as a form of payment
▪ Advantages include low transaction fees, faster transfer of payments,
participants stay anonymous, exemption of transaction taxes, …
September, 2021 Bitcoin in a Nutshell 4
The Controlled Supply of Bitcoin
https://en.bitcoin.it/w/images/en/4/42/Controlled_supply-supply_over_block_height.png
September, 2021 Bitcoin in a Nutshell 5
Needs & Goals of Beneficiaries & Stakeholders
Insurers
September, 2021 Bitcoin in a Nutshell 6
The Genesis of Bitcoin
▪ The idea behind bitcoin began in 2008 when
the name Bitcoin.org was registered
▪ On October 31, 2008 (Halloween), Satoshi
Nakamoto published a paper that dictates
how bitcoin operates
▪ No one knows the true identity of Satoshi
Nakamoto, the name associated with the person
that released the bitcoin whitepaper in 2008
▪ The identity of Satoshi Nakamoto has not been
Bitcoin: A Peer-to-Peer Electronic Cash
revealed to date
System, Satoshi Nakamoto, 2008
(https://bitcoin.org/bitcoin.pdf)
September, 2021 Bitcoin in a Nutshell 7
Distributed Ledgers
September, 2021 Bitcoin in a Nutshell 8
Blockchain Behind Bitcoin
a chain of blocks
September, 2021 Bitcoin in a Nutshell 9
September, 2021 The Genesis Block / Block 0 Bitcoin in a Nutshell 10
https://btc.com/000000000019d6689c085ae165831e934ff763ae46a2a6c172b3f1b60a8ce26f
▪ The coinbase message
“04ffff001d0104455468652054696d657320
30332f4a616e2f32303039204368616e6365
6c6c6f72206f6e206272696e6b206f662073
65636f6e64206261696c6f757420666f7220
62616e6b73” captures the heading “The
Times 03/Jan/2009 Chancellor on brink of
second bailout for banks” in The Times
▪ This was probably intended as proof that
the block was created on or after January 3,
2009
September, 2021 Bitcoin in a Nutshell 11
Users can pay for
their bookings
with more than 30
cryptocurrencies,
including bitcoin,
in addition to
traditional
payments
https://news.bitcoin.com/700000-expedia-travala-hotels-cryptocurrencies/
September, 2021 Bitcoin in a Nutshell 12
Which Bitcoin networks to
transact on?
September, 2020 Bitcoin in a Nutshell 13
Types of Bitcoin Networks
Main Network Global Testing Local Regression
(mainnet) Network (testnet) Testing Network
Real and mined coins with real Real and mined coins with no Let you instantly create a
associated value are traded in associated value are traded in brand-new private blockchain
the live blockchains. the live blockchain for testing with the same basic rules as
purposes. testnet.
Coins on the main network are
traded for goods and services. Testnet coins are given away Coins are created instantly
for free to anyone that wants under your complete control.
Wallet addresses start with a them.
“1” or “3”
Wallet addresses start with a
“m” or “n”
Coins mined in one network stay in that network, thus coins
cannot be transferred between networks
September, 2021 Bitcoin in a Nutshell 14
Where do the Testnet bitcoins come from?
▪ Coins for the Testnet are given out for free from what are called Faucet
Websites (e.g. http://bitcoinfaucet.uo1.net/, https://testnet-
faucet.mempool.co/)
▪ These websites are set up by miners or other users with a surplus of Testnet
coins
▪ They send coins to anyone who requests them and kindly asks for their return
when the user is finished with them What is total supply of
▪ Testnet requires no separate installation bitcoin on a testnet?
▪ Bitcoin wallets that have the ability to connect to the Testnet can be started
with a special flag that will direct the software to connect to the Testnet
blockchain instead of the main network blockchain
September, 2021 Bitcoin in a Nutshell 15
September, 2021 Bitcoin in a Nutshell 16
http://bitcoinfaucet.uo1.net/ https://testnet-faucet.mempool.co/
Where to keep your bitcoins?
September, 2020 Bitcoin in a Nutshell 17
Bitcoin Wallets
▪ A bitcoin wallet is a
program / app / device /
way that helps send and
receive bitcoin payments
▪ It keeps history of
transactions made
through all wallet
addresses
▪ It reveals the balance of
the wallet containing
bitcoins associated to one
or more bitcoin addresses
September, 2021 Bitcoin in a Nutshell 18
What is kept in a wallet?
▪ Multiple addresses
▪ Multiple private & public keys
▪ Does not store any currency nor wallet balance
▪ In fact, currencies do not get stored in any single location or exist anywhere in any
physical form
▪ All that exists are records of transactions stored on the blockchain
▪ A facility to manage cryptocurrencies (bitcoin and altcoins)
▪ A medium to interact with the cryptocurrency blockchains
▪ An address can be seen as a safe deposit box that has a glass front – everybody is aware of
what is contained inside, but only the private key can be used to unlock it and put things in or
take things out
September, 2021 Bitcoin in a Nutshell 19
What can you see through the glass front?
https://bitinfocharts.com/top-100-richest-bitcoin-addresses.html
September, 2021 Bitcoin in a Nutshell 20
Types of Bitcoin Wallets
https://bitcoin.org/en/choose-your-wallet
September, 2021 Bitcoin in a Nutshell 21
Creating a Desktop Wallet
▪ Open www.bitcoin.com
▪ Create a new “Personal Wallet”
▪ Enable “testnet” within “advanced options”
if you want to play with simulated currency;
otherwise, do not enable it
September, 2021 Bitcoin in a Nutshell 22
Seed / Mnemonic / Recovery Phrase
▪ If “testnet” is not enabled, a seed phrase
will be generated for you
▪ The seed phrase must be securely stored
as it serves as a superuser password for
your wallet
▪ The seed phrase needs to be provided
when trying to recover a wallet
September, 2021 Bitcoin in a Nutshell 23
Wallet Addresses
▪ Typically, multiple addresses can be mapped
to a wallet
▪ Some wallets have a limit on the number of
addresses and some do not
▪ Each address is associated to the
public/private keypair of the wallet
▪ The public key goes through several rounds
of hashing, a checksum added, and is
converted into a base58 string to produce the
bitcoin address
▪ An address is a string of 30 characters
September, 2021 Bitcoin in a Nutshell 24
Private Key
▪ Private keys are needed to sign
transactions
▪ If a public key was an account number, a
private key would be like an ATM pin
▪ Provide and confirm a password before
exporting the private key as a file
▪ The private key can be shown as a QR
code to allow another device to capture it
▪ The private key can also be recovered
using the seed phrase
September, 2021 Bitcoin in a Nutshell 25
Online Wallets
▪ Stores your bitcoin online
▪ These use an external
service that usually has control of
your money
▪ Besides those online wallets
listed on bitcoin.org, most places
where you can exchange bitcoins,
also let you store your money on
their servers, e.g. coinbase.com
https://www.coinbase.com/ and blockchain.com
September, 2021 Bitcoin in a Nutshell 26
https://wallet.mycelium.com/
Mobile Wallets
▪ Mobile wallets are not full bitcoin
clients
▪ A full bitcoin client has to download the
whole bitcoin blockchain, which is large
and grows constantly
▪ A mobile device memory may not be
capable of storing this
▪ Mobile clients only download a small
subset of a blockchain then rely on the
trusted nodes on the network in a bid
to ensure the information they have is
correct
September, 2021 Bitcoin in a Nutshell 27
https://paperwalletbitcoin.com/
Paper Wallets
▪ Paper wallets are bitcoin seed written on paper
▪ When generating a paper wallet from a website, an image of two QR codes will be generated
▪ One will be a public address that you can use to receive bitcoins
▪ The other will be a private key that you can use to authorize payments
▪ The private key is not stored anywhere by digital means, meaning that they are not prone to hardware
failure or cyber attacks
September, 2021 Bitcoin in a Nutshell 28
Paper Wallets
▪ Also known as cold storage
▪ Download the wallet keys
generator by saving the webpage
(Ctrl-S)
https://paperwallet.bitcoin.com/
▪ Disconnect the computer
▪ Load the downloaded webpage
(without Internet connection) and
move the mouse around to
generate the keys completely
offline
https://paperwallet.bitcoin.com/
September, 2021 Bitcoin in a Nutshell 29
Hardware Wallets
▪ Dedicated hardware wallets
▪ These vary quite a bit in
features, security, and interface
▪ They are not widely
used, although possibly worth
investigating if you become a
serious bitcoin enthusiast
September, 2021 Bitcoin in a Nutshell 30
https://www.exodus.io/desktop/
https://www.youtube.com/watch?reload=9&time_continue=237&v=35k3PONYTlg&feature=emb_logo
Let's try
downloading &
installing it to you
laptop & mobile EXODUS WALLET
phone, and discuss
in the next class.
September, 2021 Bitcoin in a Nutshell 31
Top 5 Wallets in 2020: https://www.youtube.com/watch?v=Eod04JEyOV8
Ways to pay more securely
September, 2020 Bitcoin in a Nutshell 32
Multi-Signature Wallets & Payment Transactions
▪ Multi-signature (multisig) refers to requiring multiple private keys to authorize a
bitcoin transaction, rather than a single signature from one private key
▪ It has a number of applications
• Dividing up responsibility for possession of bitcoins among multiple people
• Avoiding a single-point of failure, making it substantially more difficult for the wallet to be
compromised
• M-of-N backup (M & N are agreed upon when the address was created) where loss of a single seed
does not lead to loss of the wallet
September, 2021 Bitcoin in a Nutshell 33
How to buy and sell bitcoins?
September, 2020 Bitcoin in a Nutshell 34
Bitcoin is a Tradable Currency https://bitinfocharts.com
September, 2021 Bitcoin in a Nutshell 35
Bitcoin’s Historical High at US$18.334k on 16-Dec-2017
https://www.blockchain.com/charts/market-price?timespan=all
September, 2021 Bitcoin in a Nutshell 36
Buying Bitcoins through Exchanges
▪ Bitcoin exchanges allows you to trade
bitcoin or fiat currency
▪ You can buy bitcoins from a bitcoin
exchange after signing up for an account
▪ You will be allowed to pay from a credit
card or a bank account
▪ The private key will be used to authorize
any payments
September, 2021 Bitcoin in a Nutshell 37
Selling Bitcoins
▪ The process of selling bitcoins is
not as easy as buying bitcoins
▪ You must decide on whether to sell
bitcoin online or in person
▪ Online
▪ Direct trades
▪ Exchange trades
▪ Peer-to-Peer Marketplaces
▪ In Person
September, 2021 Bitcoin in a Nutshell 38
Exchange Trades - Bitcoin ATM Locations
https://coinatmradar.com/country/96/bitcoin-atm-hong-kong/ https://coinmap.org/#/world/33.72433966/14.94140625/2/atm
September, 2021 Bitcoin in a Nutshell 39
Exchange Trades – Using Bitcoin ATMs
▪ Can buy and sell bitcoins without
verification under a specified amount
▪ Need a bitcoin wallet
▪ QR code scanning with mobile phone
▪ On-site Wi-Fi is often provided
▪ Often only accepts/dispenses large
denomination notes
▪ Transaction fee (7~10%) is required
▪ Transaction receipt is provided
September, 2021 Bitcoin in a Nutshell 40
Transaction fees are optional
but …
September, 2020 Bitcoin in a Nutshell 41
Bitcoin Transaction Fees
▪ When receiving bitcoins, one is not expected to pay any fee
▪ When spending bitcoins, you can specify the amount of fee that you are
prepared to pay
▪ The amount of fee is not determined by the amount of bitcoins that you are
transacting
▪ So the amount of fee for transferring 10,000 BTC and 1 BTC may be similar
▪ A higher transaction fee may lead to a faster transaction confirmation
▪ The fee will only affect the time you have to wait until the first confirmation
▪ For example, Next Block Fee gets the transaction mined on the next block (~10
mins), 3 Blocks Fee within 3 blocks (~30 mins), and 6 Blocks Fee within 6 blocks (~1
hour)
September, 2021 Bitcoin in a Nutshell 42
The Genesis Block
September, 2021 Bitcoin in a Nutshell 43
Bitcoin Transfer Carries a Transaction Fee
https://bitinfocharts.com/comparison/bitcoin-transactionfees.html
September, 2021 Bitcoin in a Nutshell 44
Specifying Bitcoin Transaction Fees
▪ Transaction fees are a form of compensation to the bitcoin miners for
the computational work they invested in confirming a bitcoin block
▪ When a transaction has a higher total denomination in its inputs than in
is outputs, the difference will go to the miner as a transaction fee
September, 2021 Bitcoin in a Nutshell 45
The 500kth Block
Total inputs = 0.20333199 BTC
Total outputs = 0.20097975 BTC
Transaction fee
= total inputs – total outputs
= 0.00235224
September, 2021 Bitcoin in a Nutshell 46
https://bitcoinfees.earn.com/
Predicting Transaction Fees
September, 2021 Bitcoin in a Nutshell 47
Bitcoin Fee Calculator
▪ bitcoinfees.earn.com provides a
useful statistic: the median byte
size is the most commonly seen
byte size of transactions in the
last several blocks
▪ Also provided in the same page is
a recommended fee for fast
confirmation
▪ Multiplying these two values will
https://www.buybitcoinworldwide.com/fee-calculator/ get the total fee to pay
September, 2021 Bitcoin in a Nutshell 48
What does Bitcoin have to do
with blockchain?
September, 2020 Bitcoin in a Nutshell 49
What is Bitcoin again?
▪ A protocol that supports a decentralized, pseudo-anonymous, peer-to-
peer digital currency
▪ A publicly disclosed linked ledger of transactions stored in a blockchain
▪ A reward driven system for achieving consensus (mining) based on
Proof of Work (POW) for helping to secure the network
September, 2021 Bitcoin in a Nutshell 50
Blockchain as a Network of Nodes
▪ The blockchain is made of a network of nodes
▪ Each node in the network is an administrator and nodes are allowed to
join the network voluntarily
▪ Anything that happens is a function of the whole network
▪ The network operation is done on a peer-to-peer basis
September, 2021 Bitcoin in a Nutshell 51
Decentralisation in the Blockchain
▪ Blockchain technology is decentralised by design
▪ Information is in the form of shared and reconciled databases
▪ The blockchain does not keep records in a single location but at nodes
on the bitcoin network
▪ The records are available to the public to verify easily
▪ A hacker is not provided with a centralised version of records which they
can corrupt
▪ With identical blocks of information stored on the different nodes of the
network, there is no single point of failure
September, 2021 Bitcoin in a Nutshell 52
Bitcoin nodes found in countries around the world
https://bitnodes.io/nodes/live-map/
September, 2021 Bitcoin in a Nutshell 53
Activities Leading to Confirmation
▪ Must have the sender’s private key and receiver’s wallet address
▪ The private key is used to sign the transaction which has the input, the
amount, and the output
▪ The “involved” bitcoins are sent from the bitcoin wallet to the bitcoin
network
▪ Bitcoin miners then verify the transaction, put it into a transaction block,
and finally solve the computational puzzle against the block
▪ Solved puzzle must be verified by other miners through confirmation
and this is why sometimes one may have to wait for them to finish
September, 2021 Bitcoin in a Nutshell 54
Transaction Confirmation
▪ The bitcoin blockchain is designed in such a way that each block takes
on average about 10 minutes to mine
▪ Some merchants will make you wait for the transaction to be confirmed
▪ Meaning that it may take some time before you are allowed to download the
digital goods or enjoy using the paid service
▪ Some merchants will not make you wait for the transaction to be confirmed
▪ This is mostly in cases where the value of a transaction is low, meaning that the risk
of fraud is low
▪ A transaction is often considered confirmed after having six or more
transaction confirmations from various miners
September, 2021 Bitcoin in a Nutshell 55
YouTube: https://anders.com/blockchain/
September, 2021 Bitcoin in a Nutshell 56
How is consensus reached?
September, 2020 Bitcoin in a Nutshell 57
The network has a unified perspective of the blockchain,
with the blue block as the tip of the main chain
September, 2021 Bitcoin in a Nutshell 58
Two miners mine two different blocks almost simultaneously,
both are children of the blue block
September, 2021 Bitcoin in a Nutshell 59
The network splits into two different perspectives, one side
topped with a red block, the other with a green block
September, 2021 Bitcoin in a Nutshell 60
The miners building on top of the green block find a new
pink block and extends the blockchain
September, 2021 Bitcoin in a Nutshell 61
The blue-green-pink chain representing more effort spent
becomes the main chain & the red block becomes an orphan
What is going to happen
with the red block?
September, 2021 Bitcoin in a Nutshell 62
Chain Selection
Once a node has validated a new block, it will then
assemble the new block into the existing blockchain
▪ Nodes maintain three sets of
blocks
▪ blocks connected to the main
blockchain
▪ blocks that form branches off the
main blockchain (secondary chains)
▪ blocks that do not have a known
parent in the known chains
(orphans)
▪ The main chain at any time is ▪ Under most circumstances this is also the chain
whichever valid chain of blocks with the most blocks in it, unless there are two
has the most cumulative Proof-of- equal-length chains and one has more Proof-of-
Work associated with it Work
September, 2021 Bitcoin in a Nutshell 64
Once a node has validated a new block, it will then
assemble the new block into the existing blockchain
▪ The main chain will also have
branches with blocks that are
siblings to the blocks on the main
chain
▪ These blocks are valid but not part
of the main chain (not confirmed)
▪ They are kept for future reference, in
The Block Tree case one of those chains is
extended to exceed the main chain
in work
September, 2021 Bitcoin in a Nutshell 65
Secondary chains occur as a result of an almost
simultaneous mining of blocks at the same height
▪ Sometimes, the new block extends a chain that is not the main chain
▪ In that case, the node will attach the new block to the secondary chain it
extends and then compare the work of the secondary chain to the main
chain
▪ If the secondary chain has more cumulative work than the main chain,
the node will reconverge on the secondary chain
▪ Meaning it will select the secondary chain as its new main chain, making the
old main chain a secondary chain
▪ If the node is a miner, it will now construct a block extending this new,
longer, chain
September, 2021 Bitcoin in a Nutshell 66
By selecting the greatest-cumulative-work valid chain, all
nodes eventually achieve network-wide consensus
▪ Temporary discrepancies between chains are resolved eventually as
more work is added, extending one of the possible chains
▪ Mining nodes vote with their mining power by choosing which chain to
extend by mining the next block
▪ When they mine a new block and extend the chain, the new block itself
represents their vote
September, 2021 Bitcoin in a Nutshell 67
If all nodes select the greatest-cumulative-work chain, the
network will eventually converge to a consistent state
▪ Bockchain is a decentralized data structure and different copies of it are
not always consistent
▪ Blocks might arrive at different nodes at different times, causing the nodes to
have different perspectives of the blockchain
▪ To resolve this, each node always selects and attempts to extend the
chain of blocks that represents the most Proof-of-Work
▪ Also known as the longest chain or greatest cumulative work chain
▪ By summing the work recorded in each block in a chain, a node can
calculate the total amount of work that has been expended to create
that chain
September, 2021 Bitcoin in a Nutshell 68
What is Bitcoin mining?
September, 2020 Bitcoin in a Nutshell 69
What is Bitcoin mining?
▪ Bitcoin mining is the process of verifying transactions and adding them
to the public ledger which is a blockchain
▪ In the mining process, recent transactions are combined into blocks and
computationally difficult puzzles are solved
▪ The computational difficulty is elevated every 2,106 blocks
▪ After the “discovery” of a particular block, the discoverer is allowed to
itself a number of bitcoins as award
▪ Bitcoin mining is also the means through which new bitcoins are
released into circulation
September, 2021 Bitcoin in a Nutshell 70
Mining reward is halved every 210,000 blocks
https://www.coindesk.com/bitcoin-halving-arrives-mining-rewards-drop-for-third-time-in-history
September, 2021 Bitcoin in a Nutshell 71
Block height is at 650,490 as of 29th Sept, 2020
https://www.blockchain.com/btc/blocks
September, 2021 Bitcoin in a Nutshell 72
The Bitmain mine in Ordos, Inner Mongolia, has eight buildings containing
mining machines. One of them is dedicated to Litecoin and seven mine
bitcoins.
https://qz.com/1055126/photos-china-has-one-of-worlds-largest-bitcoin-mines/
September, 2021 Bitcoin in a Nutshell 73
September, 2021 Bitcoin in a Nutshell 74
September, 2021 Bitcoin in a Nutshell 75
September, 2021 Bitcoin in a Nutshell 76
September, 2021 Bitcoin in a Nutshell 77
The Cheapest and the Most Expensive
September, 2021 Bitcoin in a Nutshell 78
University of
Cambridge
estimates that
Bitcoin uses 61.76
terawatt-hours
(TWh) of electricity
per year, more than
many countries and
around 0.28%
of worldwide
electricity
consumption.
https://www.statista.com/chart/18632/estimated-annual-electricity-consumption-of-bitcoin/
September, 2021 Bitcoin in a Nutshell 79
Power of Work (PoW)
September, 2020 Bitcoin in a Nutshell 80
The Computational Puzzle
Find a value for the nonce field such that the block header hash value is smaller than the specified difficulty target?
The SHA-256 values of the different
Using the 500th block as an example configurations of the block header
Magic Number (4) 0xD9B4BEF9 ffffffff….
….
Block Size (4) 632
….
Version (4) 1 af658d45….
….
Possible block header hash values
corresponding to possible values
Block Header (80)
Previous Block Header Hash (32) 0000… assigned to the nonce field
Merkle Root Hash (32) d7c3….
Timestamp (4) 2010-11-08 15:34:22 ….
00000001….
Difficulty Target (4) 1.00000000
….
Nonce (4) What value to assign?
Nonce
000000004ff..
….
✓ Block header hash values are valid
Transaction Counter (1-9) 3 only if they are below the specified
= 2063568441 ….
000000002….
difficulty target, often interpreted as
Transactions (< 1,000,000) 1Htz....(50) the number of leading zeros required
1K3d….(50) > 1Lgs….(50) 000000001….
1E7o….(50) > 12Qy….(10), …. 000000000….
In the case of the 500th block, the winning miner assigned 2063568441 to the nonce field.
September, 2021 Bitcoin in a Nutshell 81
Mining makes Bitcoin special, a decentralized security
mechanism that is the basis for P2P digital cash
▪ The primary purpose of mining is neither the reward for the
miners nor the generation of new coins
▪ Mining is the mechanism that underpins the decentralized
clearing house, by which transactions are validated and
cleared
▪ Mining secures the bitcoin system and enables the
emergence of network-wide consensus without a central
authority
▪ The reward of newly minted coins and transaction fees is
an incentive scheme that aligns actions of the miners with
the security of the network, while simultaneously
implementing the monetary supply
September, 2021 Bitcoin in a Nutshell 82
Miners receive two types of rewards in return for the
security provided by mining
▪ Miners are rewarded new coins created with each
new block and transaction fees from all the
transactions included in the block
▪ To earn this reward, miners compete to solve a
difficult mathematical problem based on a
cryptographic hash algorithm
▪ The solution to the problem, called the Proof-of-Work
(POW), is included in the new block and acts as proof
that the miner expended significant computing effort
▪ The competition to solve the POW algorithm to earn
the reward and the right to record transactions on the
blockchain is the basis for Bitcoin’s security model
September, 2021 Bitcoin in a Nutshell 83
The process is called mining because the reward (new coin
generation) is designed to simulate diminishing returns
▪ Bitcoin’s money supply is created through mining
▪ Similar to how a central bank issues new money by
printing bank notes
▪ The maximum amount of newly created bitcoins a
miner can add to a block decreases approximately
every four years (or precisely every 210,000 blocks)
▪ It started at 50BTC per block in January of 2009
and halved to 25BTC per block in November of
2012, and down to 12.5BTC for now
▪ Mining rewards decrease exponentially until
approximately the year 2140, when all bitcoin
(20.99999998 million) will have been issued
September, 2021 Bitcoin in a Nutshell 84
Bitcoin miners also earn fees from transactions
▪ Every transaction may include a transaction fee, in the
form of a surplus of bitcoin between the transaction’s
inputs and outputs
▪ The winning miner gets to keep the change on the
transactions included in the winning block
▪ As the reward decreases over time and the number of
transactions per block increases, a greater proportion
of bitcoin mining earnings will come from fees
▪ Gradually, transaction fees will form the primary incentive for
miners
▪ After 2140, the amount of new bitcoin in each block
drops to zero and bitcoin mining will be incentivized
only by transaction fees
September, 2021 Bitcoin in a Nutshell 85
The total value of all transaction fees paid to miners
excluding the coinbase value of block rewards
https://www.blockchain.com/charts/transaction-fees?timespan=all
September, 2021 Bitcoin in a Nutshell 86
Satoshi Nakamoto’s main invention is the decentralized
mechanism for emergent consensus
▪ Emergent, because consensus is not
achieved explicitly—there is no election
or fixed moment when consensus
occurs
▪ Instead, consensus is an emergent
artifact of the asynchronous interaction
of thousands of independent nodes, all
following simple rules
▪ All the properties of bitcoin, including
currency, transactions, payments, and the
security model that does not depend on
September, 2021
central authority or trust, derive from this
Bitcoin in a Nutshell 87
invention
References
September, 2020 Bitcoin in a Nutshell 88
References
Bitcoin: A Peer-to-Peer Electronic Cash Mastering Bitcoin: Programming the Open
System, Satoshi Nakamoto, 2008 Blockchain, 2nd edition, Andreas M.
(https://bitcoin.org/bitcoin.pdf) Antonopoulos, 2017
(https://github.com/bitcoinbook/bitcoinbook)
September, 2021 Bitcoin in a Nutshell 89
Thank you