“Bitcoin”, “blockchain”, and “mining”. Three words that go together like strawberries and cream. Indeed, if you’ve heard of one, you’ve heard of the other two. In this article, we’ll discuss bitcoin mining: why you should care, what it is, and how the industry is doing in 2018.
Buckle your seatbelts, let’s go.
Why should you care about bitcoin mining?
If you care about bitcoin then you have to care about mining.
Without it, the bitcoin blockchain would not be able to validate transactions, allowing double-spending, and therefore eradicating the integrity of the network.
More specifically, bitcoin is a decentralized alternative to the banking system that operates independently of any central authority. This is achieved by recording network transactions in blocks on the publicly visible blockchain.
In order to operate in a decentralized manner, the bitcoin protocol enforces rules, which ensure that all actors in the network behave in the best interest of both themselves and the community as a whole.
A huge part is played by bitcoin miners, who work within these rules to process and encrypt valid transactions and reject fraudulent ones.
What is bitcoin mining?
In really simple terms, bitcoin mining works by guessing a random number that solves an equation generated by bitcoin’s protocol. Naturally, the guessing isn’t done by you, but instead by your computer. The better your computer, the easier it will be to guess the number. Simply because good computers can make more guesses per second.
With the emergence of ASIC miners and mining pools (more on both later), successfully guessing the number before anyone else, using nothing but your laptop, has become close to impossible in 2018 – for bitcoin at least.
If you do manage to guess the number, new bitcoins are generated and paid out to you as a reward. The amount bitcoin miners receive halves at predesignated intervals, with another ~80,000 blocks to go until the next halving. Today (October 2018) the reward is 12.5 BTC or ~$80,000.
A more detailed look at bitcoin mining
Depending on why you’re reading this article, you might need a more or less detailed explanation of how bitcoin mining actually works. This section is for those of you who want the inside scoop.
As with all complicated matters, bitcoin mining is best discussed as a series of steps. First, the bitcoin mining computers collect hundreds of pending transactions and perform a mathematical algorithm that creates a hash. A hash is perfect for this use case, because it maps data to a bit string, using SHA 256, creating a 32 byte string in the process.
As an example, this is the hash for the first bitcoin block:
The first miner to produce this hash, announces it to the network, which then checks if all transactions are valid. This is done by checking if the sender of the funds has provided the correct signature. If the sender had the required amount of bitcoin in his wallet at the time of the transaction, the correct signature will have been applied.
Blocks containing transactions with missing signatures are thrown out as invalid and replaced with other blocks. Once all transactions are proven to be valid, and the resultant hash is verified, the miner receives 12.5 bitcoin as a reward. Crucially, the Bitcoin protocol demands that a new block is mined every 10 minutes. This is achieved by adjusting the mining difficulty in accordance with the total computing (hash) power of the bitcoin network.
By employing this approach, Bitcoin ensures that miners are incentivized to process transactions. Blocks which contain invalid transactions are thrown out by the network, meaning a miner only receive his reward when his block is accepted as valid by the network. This stroke of genius ensures the integrity of the blockchain.
To store an invalid transaction, hackers and malicious actors would have to rewrite the blockchain’s transaction history. In order to do this, they would have to gain control over more than half the networks computing (hash) power. Considering that this figure is currently 13,000 times more powerful than the world’s 500 biggest supercomputers, this seems like an impossible task.
The bitcoin mining industry in 2018
So far we have discussed the brilliance of bitcoin mining, but the system is far from perfect.
As bitcoin’s consensus algorithm (Proof-of-Work) requires so much computing power to generate the required encryption, a moneyed elite has emerged with the financial muscle to outperform regular users.
In 2009, computer geeks could mine thousands of bitcoins using mainstream graphics cards built into off-the-shelf laptops. Today, Bitmain and others are creating highly specialized ASIC chips specifically designed to mine bitcoin.
As you can see from the screenshot above, these typically cost around $1,000 and do not guarantee profitability. Indeed, depending on your electricity costs you might even lose money mining bitcoin.
As an example, this calculator estimates that the Antminer S9 with a maximum hashrate of 14Th/s and a power consumption of 1372W, generates a loss of $384 per year.
The reason why even specialized mining rigs are generating negative returns is the increasing bitcoin difficulty of the network. As the moneyed bitcoin mining elite grow their ASIC farms in locations with cheap electricity, smaller miners are being pushed out.
Worryingly this has resulted in exactly what bitcoin was meant to oppose: centralization.
Since 2017, bitcoin mining has become increasingly centralized. As can be seen from the pie chart below, several companies and mining pools dominate the industry.
Mining pools like ViaBTC, AntPool, and SlushPool are groups of miners “pooling” their resources to increase their chances of mining a block. When a block is successfully mined by the pool, the bitcoin reward is generated and split between the pool members.
This presents a potentially cataclysmic problem for bitcoin. For one thing, the chance of a 51% hack no longer seems outlandish. A small number of pools already own the majority of the networks hashing power. All it would take would be an alliance between these pools for the whole network to be compromised.
Additionally, these pools do not operate in a vacuum. AntPool, for example, is based in China and is run by Bitmain. Bitmain recently filed for an IPO and will soon go public. Once it does, Bitmain will be solely accountable to its shareholders, rather than the network. As a result, we might find ourselves in a position where the incentives of the network and of the company are no longer aligned, and bitcoin suffers as a result.
It’s a strange time for bitcoin miners.
An activity which started off as a way for computer nerds to support a cool new form of digital cash, has generated over $5 billion dollars in revenue in 2018. This is the finding of an eye-opening report published by research firm Diar.
Astonishingly, the report concludes that despite the vast sums of revenue, bitcoin mining is no longer profitable for most miners.
Instead, only miners located in countries with cheap electricity prices will be able to compete. China for example, currently provides electricity at around $0.08 kw/h, compared to ~$0.18 in the UK.
The result has been a clustering of hashing power in China, giving one region an inordinate amount of power over the network – posing significant problems for the future of bitcoin.
Unfortunately, solutions are hard to come by. The centralization of mining power can only be battled by changing the bitcoin protocol. This would most likely involve a shift away from the power intensive Proof-of-Work to a far more efficient Proof-of-Stake (POS or dPOS) consensus algorithm. By employing POS, bitcoin would effectively eradicate miners, and break up the centralization of its network. Unfortunately, making the shift to POS is no mean feat.
Ethereum for example, has been trying to shift to Casper – its own iteration of POS – for years. Despite the impressive brain power behind the project, the switch has been dogged by problems, and seems no closer to completion.
This does not bode well for bitcoin, especially considering how much moneyed interest is behind keeping POW as an integral part of the network. Nevertheless, it seems that changing bitcoin’s consensus algorithm is the only way of achieving the decentralization Satoshi aspired to in his whitepaper.