Proof of work and proof of stake are two different algorithms employed by cryptocurrencies to verify transactions. Chances are you are hearing these terms over and over again because of Ethereum.
Ethereum has finally decided to switch from PoW to PoS.
So in this article, I am going to talk about both PoS and PoW, and how the Ethereum mining scene is going to change forever as well.
The concept of cryptocurrency can be alien to a lot of people let alone these two verification processes. So before you get to know what proof of work and proof of stake really are, you need to have a clear idea about the whole cryptocurrency system.
- 1 What Is A Cryptocurrency?
- 2 Cryptocurrency Vs Fiat Currencies
- 3 Trustless Transactions And Distributed Consensus
- 4 Proof of Work – Extremely Simplified
- 5 Problems With Proof of Work
- 6 Proof of Stake – Overly Simplified Version
- 7 Proof of Work Vs Proof of Stake
- 8 Problems With The Proof of Stake Algorithm
- 9 Why Is Ethereum Switching to PoS?
- 10 Conclusion
What Is A Cryptocurrency?
You can view cryptocurrency as an alternate currency that resides in the digital world. They are digital assets that users can trade between them digitally. Cryptocurrencies are generated using a system and at a rate that is publicly known.
Whereas government bodies and corporate boards control the supply of fiat currencies. The first decentralized cryptocurrency was Bitcoin and since then numerous cryptocurrencies (or altcoins) have been created.
But still to this day, Bitcoin remains the king of cryptocurrencies.
Cryptocurrency Vs Fiat Currencies
One of the main differences between cryptocurrencies and traditional currencies is how they are controlled. Fiat currencies are dependent on a centralized system and you have to trust that centralized system. This centralized system knows your bank balance and even little details like your shopping habits!
Whenever you send or receive money the transaction goes through the centralized server. The server then accepts or rejects the transaction. If the server accepts the transaction, the details are added to a centralized ledger system.
Whereas in cryptocurrencies there is no centralized server to take care of transactions. Instead, the whole system is distributed and decentralized network. In this network, every node is as powerful as the next one. But still, there has to be some sort of ledger to hold the transaction details right?
Yes, there is a ledger and it is public. This public ledger is called blockchain and it is easily accessible by all the nodes. This brings us to our next topic of discussion, trustless and distributed consensus.
Trustless Transactions And Distributed Consensus
The real essence of cryptocurrencies is their decentralized and distributed nature. In a traditional currency system, we put a lot of trust in third-party services. We need them for verifying transactions for us and keep a track of our account balance.
Suppose you want to buy a Ledger Nano S for you. Now you use PayPal, Visa, MasterCard or any other payment gateways to complete the transaction. The amount is debited from our account and is credited to the seller buy the gateway. These gateways keep a private ledger on their servers and they do the tiresome work of verifying transactions.
But in case of cryptocurrencies, we don’t have to put our trust in some third party. Anyone can easily access the public ledger or blockchain anytime they like and verify the transactions themselves.
The verification of transactions, depending upon the underlying platform, can be done in two ways – Proof of Work and Proof of Stake.
Proof of Work – Extremely Simplified
Whenever you do a transaction in a cryptocurrency platform the system does a whole lot of work under the hood. First of all, it groups your transaction and a lot of other transactions into a block in real time.
The system secures the block using some cryptography problems. Some of the most used cryptographies in the field of blockchain are – SHA256, scrypt, CryptoNight, X11 etc.
Now we need some nodes which will verify these blocks for us and check whether all the transactions are legitimate. But to do that they will have to solve a ridiculously complex yet useless mathematical puzzle at first.
The process of solving this cryptographic puzzles are called proof of work. And the nodes which perform this task are called miners.
The system gives a reward to the first miner who solves the block and adds the block to the blockchain. The reward amount is preset and it is publicly known. The miners not only help in verifying transactions they also create new currencies in a proof of work environment.
In technical terms, mining can be called inverse hashing. A miner determines a number that can be used only once. This number is called nonce. Based on this nonce the block data results in less than a given threshold. This threshold is called difficulty and it determines how competitive the mining process will be.
When the difficulty increases the cost of mining also increases and the reward decreases. In its inception, the supply rate of Bitcoin was 50 units per 10 minutes but currently, it is at 12.5 Bitcoins.
Problems With Proof of Work
Bitcoin and a whole lot of other altcoins use proof of work. But the proof of work is not an efficient solution let alone the ultimate. The cryptographic puzzles, also called CPU cost functions are resource heavy. And these puzzles are getting tough, day by day. So the network is demanding more computing power and more efficient miner.
Usually, graphics cards are used to mine proof of work cryptocurrencies. But in professional mining farms, ASICs are used. ASICs or Application Specific Integrated Circuits are extremely powerful and highly efficient systems. They can be used to mine Bitcoin and many other altcoins.
Use of this specialized hardware requires a lot of electricity and other resources. And in my opinion, this is a waste of energy. In a proof of work system, we are wasting energy by solving technically useless computational puzzles. Although mining farms are trying their best to become efficient by building farms in Iceland and whatnot, it is not really the solution.
According to a study conducted by Motherboard in 2015, a single Bitcoin transaction used up the same amount of electricity that could power 1.57 American households for a day. This is simply unacceptable and unsustainable.
Cryptocurrencies have the potential to become alternatives to fiat currencies. But if a single transaction is 6000 times more energy intensive then it is a tough choice. This where the concept of Proof of Stake comes into play.
Proof of Stake – Overly Simplified Version
In Proof of Stake, there are no miners. Instead, there are validators or forgers. The system has the same end goal as PoW – to verify transactions and put them on the blockchain. But the algorithm of PoS is entirely different. As discussed above in proof of work the miners solve useless cryptographic puzzles to verify the block.
But in a proof of stake system, the forgers do this task. The system deterministically chooses a validator based on their stake in the cryptocurrency. The stake value is directly related to the total wealth of the validator and the total amount of time the wealth has been in his possession.
In PoS every node places a bet on its block. If the block turns out to be legitimate then it might get added to the blockchain. On the contrary, if the block turns out to be invalid then the forger gets penalized and the bet amount is debited from their balance.
There are no rewards for the validators in the proof of stake system. Instead, the validators receive the transaction charge as compensation. So in proof of stake validators don’t generate new coins like miners in a proof of work system.
This algorithm was at first suggested on the bitcointalk forum in 2011. In 2012 PeerCoin implemented it for the first time. Since then it has been used by several other altcoins like Nxt, BlackCoin, ShadowCash, NuShares etc.
Proof of Work Vs Proof of Stake
I hope after all these explanations the difference between them is quite apparent. But allow me to summarize it for you. Proof of work requires mining, which results in wastage of unreasonable amount of energy. There is no concept of mining in proof of stake, so bye bye energy wastage.
As the difficulty increases more powerful and efficient hardware is needed for PoW mining. In case of PoW, anyone with the right amount of stake can participate in the bidding regardless of the computational power of their systems. In PoW the system doesn’t punish the fraudsters.
But in PoS dishonesty is discouraged and heavily penalized whereas honesty is incentivized. In proof of work, the miner doesn’t have to be a loyal user of that cryptocurrency. But in proof of work, a validator is always a loyal user.
So right now you might be thinking, proof of stake is the real deal as there are no real drawbacks. But you are wrong!
Problems With The Proof of Stake Algorithm
The main concern people have with the proof of stake system is that rich will get richer while the poor ones will stay poor. You need to have a significant amount of tokens in your wallet as well as you have to keep it locked in for a reasonable amount of time to become a validator.
Consider Ethereum – it is the world’s largest distributed computing network. If it gets controlled by a very few then it is kind of alarming.
Ethereum has started developing their version of PoS named Casper and the hard fork is going to happen very soon.
Why Is Ethereum Switching to PoS?
Ethereum has decided to switch from PoW to PoS to address a few issues. Ethereum’s founder and main scientist Vitalik Buterin wants to adopt PoS because it is scalable than PoW. Currently, Ethereum can handle anywhere between 10 to 20 transactions per second. But with PoS the number is expected to increase significantly.
Plus PoS is considered to be more secure than PoW. To influence over the network in PoW someone or some group has to have 51% of the total computing power of the network. This way they can double spend or even block transactions.
This type of attack is called 51% attack. But it is simply not possible in PoS system since supplying invalid blocks is heavily penalized. So even if an attack takes place it will appreciate the currency instead of depreciating its value.
The Ethereum Foundation is also concerned with the effect of mining on nature and natural resources. With all these reasons in mind, Ethereum Foundation decided to make the switch.
How The Switch Is Planned to Happen
The switch from PoW to PoS of Ethereum consensus is planned to happen in stages. Before the Casper protocol can be implemented, a new network needs to be rolled out in place of the old one.
This new network is being called Metropolis, and it will be hard forked in two stages as well – Byzantine and Constantinople. The Byzantine hard fork has already been carried out on 16th of October and it is performing smoothly till date.
Casper is going to be a hybrid platform, employing both PoS and PoW. Where miners will be able to mine using PoW method and every 100th block will be checked with PoS.
Ethereum Foundation’s Vlad Zamfir is also working on his version of Casper. As per him, while Vitalik is looking for an immediate solution he is more into finding the theoretically optimal PoS solution.
Proof of stake is still in its infancy. At this moment we can only say that PoS looks promising and has a lot of potentials. It is undoubtedly safer and more efficient than proof of work. Also, it is scalable – a problem every cryptocurrency is entitled to face if it gets popular.
Instead of wasting the computing power on mining this distributed network of computers can be used in creating more powerful decentralized applications and smart contracts.
So in my opinion proof of stake really is the way to go.