Cryptocurrencies

Difference between Proof of Work and Proof of Stake mining cryptocurrencies

Cryptocurrency mining is not done by just telling teams to start mining and that's it. Given the importance that a decentralized blockchain works controlled by the nodes that compose it and are all aligned, it is imperative to have a mining procedure algorithm to keep the blockchain active and reward those who maintain it. Currently, the two most popular algorithm types are proof-of-work and proof-of-stake. Proof of Work and Proof of Stake respectively.

But… What does each one mean? Which is better? What does house one imply? With Ethereum moving from Proof of Stake to Proof of Work imminent in August, if there are no issues, it is necessary to understand what each of these algorithms does.

Proof of Work, explained in a simplified way

To mine blocks of the blockchain of a cryptocurrency whose algorithm is based on the proof of work, it is sought that the miners of the blockchain, and not its users, perform complex mathematical operations to be able to guarantee the transactions that are done on the blockchain.

One advantage that Proof of Work has for those who want to mine the cryptocurrency in question is that does not require any purchase of the token which is going to be mined. Mining is made up of equipment that uses the calculation capacity, or the hash rate of the components of your PC in order to mine blocks of cryptocurrencies and receive tokens as a reward.

Cryptocurrency mining farm in Greenidge, Finger Lake.

Physical scalability for higher mining profit is inherent in Proof of Work algorithms. This is why large cryptocurrency mining operations are produced in industrial buildings. They are spaces capable of housing meters in length and height with motherboards intended for mining, with many graphics and processors mining cryptocurrencies. These operations seek the highest profit as much as possible.

It is not uncommon for large Proof of Work cryptocurrency mining operations to take place in countries where electricity is very cheap or subsidized. sometimes even have been installed in power plants to devote all their energy to mining. China is one of the countries in the latter case, and for this reason the country has become a mining center in itself, despite the country's restrictions on cryptocurrencies due to their polluting effects due to energy use.

Proof of work, explained in detail

This explanation will focus on such proof of work using the Bitcoin blockchain. The Bitcoin blockchain is a ledger that contains a record of all transactions made from Bitcoin, arranged in sequential blocks. With this, no user can spend their crypto assets twice. To prevent tampering, the ledger is public or "distributed" among multiple nodes or users. ORan altered version would be quickly rejected by other users. Being distributed among many users who have a copy to ensure the integrity of the ledger, manipulation is avoided.

Users detect tampering through hashes, which are long strings of numbers that serve as proof-of-work. If a data set is subjected to a hash function, a hash will be generated. Due to the “avalanche effect“, even a small change to any part of the original data will result in a totally unrecognizable hash.

The hash is a one-way function. It cannot be used to get the original data. It is used to verify that the data that generated the hash coincides with the original data.

Since generating a hash for a set of Vitcoin transactions is a piece of cake, to turn the process into “work“, the Bitcoin blockchain establishes a certain level of “difficulty“. This setting is set to “enamel” a new block to be added to the blockchain and a valid hash is generated, approximately every 10 minutes. Difficulty setting is done by setting a “target” for the hash. The lower the target, the smaller the set of valid hashes and the harder it is to generate one. In practice, this means a hash that starts with a very long string of zeros.

Since a given data set can only generate one hash, miners make sure to generate a hash below the target by altering the input by adding an integer, called a nonce (“number used once”). Once a valid hash is found, it is transmitted to the network and the block is added to the blockchain.

Cryptocurrency mining CMP chip.

Mining is a competitive process, and it qualifies more as a lottery than a race. On average, an acceptable proof of work is generated every ten minutes, but no one knows who it will be. The miners are grouped together to increase your chances of mining blocks. This generates transaction fees and, for a limited time, a reward of newly created bitcoins.

Proof of Work makes it extremely difficult to tamper with any aspect of the blockchain. Requires re-mining all subsequent blocks. It also makes it difficult for one user or group of users to monopolize the computing power of the network, which is called “51% attack“. The machinery and energy required to complete hash functions are expensive. But it is not impossible due to the snowball effect. Is that It rewards more those who have more hash power, which could continue to expand their hashing capacity further than lower-level users can.

In the case of Bitcoin, the hash job is SHA-256 hashing algorithms. He "winner” from a hashing round adds and records the mempool transactions in the next block. Since the "winner” is chosen randomly and proportional to the work done, all members of the network are encouraged to act honestly and only record actual transactions.

Can a part of the blockchain decide to change the mining algorithm?

In the event that part of a mining network begins to accept an alternative proof of work, it is known as a “hard fork”. to happen, creates a split from the original and that new part cannot interact with the original.

For practical purposes, a new cryptocurrency is generated, which is why there are variants of Bitcoin and Ethereum. One of the most recent is the move from Ethereum's Proof of Work to Proof of Stake. Since many users want to continue using Ethereum properties but not switch to Proof of Stake, possibly to avoid parting with their large investments in mining hardware; They made a fork called Ethereum Classic. This Ethereum Classic fork that still uses Proof of Work.

Proof of Stake, explained simply

Proof of Stake is a blockchain transaction validation algorithm for users to stake their tokens as collateral for a transaction. With that show that they have a stake in making the transactions valid. All users must sign a contract and buy collateral tokens to start trading, thus avoiding unwanted agents.

Proof of Stake explained in detail

Proof of Stake is a consensus mechanism that randomly assigns the node that will mine or validate block transactions based on the number of tokens held by that node. The more a wallet has, the more mining power it is given. Some flaws they have are the increased chance of a 51% attack on the altcoins smaller. Also encourages the accumulation of tokens and not use them for use as currency because that would imply losing future mining power.

Ethereum logo.

Proof-of-stake is a type of consensus mechanism used by blockchains to achieve distributed consensus. The big difference of the essence of each algorithm is as follows:

  • In the Proof of Work, miners prove that they have capital at risk by expending energy.
  • In Proof of Stake, validators explicitly stake their capital on a smart contract. These staked tokens act as collateral that can be destroyed if the validator behaves dishonestly or lazily.

The validator is responsible for checking that new blocks being propagated over the network are valid, and occasionally for creating and propagating new blocks themselves.

Proof-of-stake comes with a number of changes from the Proof-of-work system:

  • Higher energy efficiency, so it is not necessary to use a lot of energy in the calculations of the proofs of work
  • Lower barriers to entry having lower hardware requirements. You don't need hardware with a huge CPU and multiple GPUs to have the opportunity to create new blocks.
  • Reduced risk of centralization because proof-of-stake should lead to more nodes securing the network
  • Less ETH issuance required to incentivize participation
  • All the financial penalties for misbehavior they make 51% attacks exponentially more expensive for an attacker compared to proof-of-work, which can fall on those with more money to buy more expensive materials.
  • The community can resort to honest chain social recovery if a 51% attack gets past crypto defenses.

What are Proof of Stake validators?

To participate as a validator, at least as planned for the Ethereum Merge, a user must deposit 32 ETH in the deposit contract and run three different pieces of software. These are an execution client, a consensus client, and a validator. By depositing their token, the user joins an activation queue that limits the rate of new validators joining the network. Once activated, validators receive new blocks from peers on the Ethereum network. Transactions delivered in the block are reexecuted and the block signature is checked to ensure its validity. The validator then sends a vote for that block across the network.

While in Proof of Work, the time of the blocks is determined by the difficulty of the mining; Proof of Stake have a fixed rhythm. For Ethereum, it is divided into 12-second slots and 32-slot epochs, about 384 seconds per epoch, just over six minutes. A validator is randomly selected to be a block proponent in each slot. This validator is responsible for creating a new block and sending it to other nodes on the network. Each slot randomly chooses a committee of validators, whose votes are used to determine the validity of the proposed block.

Purpose of a transaction in Proof of Stake

A transaction has "finality" in distributed networks when it is part of a block that cannot change without burning a significant amount of ether. In Ethereum, this is managed by “checkpoint” blocks. The first block of each epoch is a checkpoint. The validators then vote for the pairs of checkpoints that they consider to be valid.

If a pair of checkpoints attracts votes representing at least two-thirds of the total staked ether, the checkpoints are updated. The newer of the two becomes "justified", while the older of the two is already justified because it was the "target" in the previous epoch. Then it is updated to “finished”.

To revert a completed block, an attacker would commit to forfeiting at least a third of the total staked ether supply. Since it requires a two-thirds majority, an attacker could prevent the network from reaching its intended purpose voting with a third of the total participation.

There is a mechanism to defend against this: the idle leak. is activated as long as the chain does not terminate for more than four epochs. The idle leak diverts staked ether from validators voting against the majority, allowing the majority to win back a two-thirds majority and end the chain. With all this, it is ensured that only those interested in the chain of blocks continuing and being complete want to bet their capital.

What is a 51% attack on a blockchain?

A "51% attack” refers to an attack on a blockchain by a group of miners who control more than 50% of the network's mining hash rate or computing power. Is a digital version of a hostile takeover. When shares of a public company are bought between several shareholders of the same group to take possession of the company. For this to happen on a blockchain, a group of miners must agree to take control of a blockchain for their own interests by massively acquiring mining material to hoard the hash on Proof of Work, or by buying tokens on Proof of Stake.

It is speculated that, if a 51% attack occurs, no new coins could be created or old blocks could be altered, since most would block them. They could also stop payments between some or all users. They could reverse transactions that had been completed while they were in control of the network. This would mean that they could double spend the tokens they had.

Infographic of a blockchain.

With Ethereum's move to Proof of Stake, it is hoped that this possibility will be further limited. The first reason is because by having many more participants, it is more difficult for a group to control 51% of all Ethereum tokens and agree to control the blockchain.

What effects does a 51% attack have?

If a 51% attack occurs, it is inevitable that the token will lose a lot of value and utility not being that interesting for any commercial use. All the participants in that 51% attack must have deposited a considerable amount of tokens. It is about 32 ETH, which is approximately 64.000 US dollars, which would be devalued. Users would lose their deposit and the value of the tokens in their wallets.

With all this, Proof of Stake hopes that Ethereum's validation power will not reside in several massive mining operations. It would not depend on mining in China, Russia, the United States and other countries with cheap electricity, thus harming more casual users who mine with homemade equipment. It is an attempt to democratize the blockchain, because it does not lie in the accessibility of motherboards and GPUs, which depend a lot on having biots and contacts with distributors.

What will Ethereum's move from Proof of Work to Proof of Stake mean?

For the month of August, and if there are no complications, Ethereum will go from Proof of Work to Proof of Stake in an event called The Merge. Then it will lead to Ethereum 2.0. Some implications within the Ethereum network itself is that ETH tokens will be required to be purchased in order to deposit as a guarantee for the contract and then guarantee the blockchain transactions with more tokens. This implies more token sales given their higher utility. This expects to have a higher demand for ETH and thereby maintain or even increase its value.

One of its benefits will be the considerable reduction in energy consumption produced by the Ethereum blockchain. While data on the contamination of Ethereum is difficult to find, regarding Bitcoin, if its blockchain were a country, it would be among the 30 most polluting. It would mean a much lower cost per transaction, since one of the biggest detriments of a Proof of Work blockchain is its “gas fee“, since miners with large crypto mining equipment, which are large ships with GPUs, must be paid a part of the electricity rate.

Ethereum's change to Proof of Stake is a way of trying to secure its future.

By reducing your energy cost by 99%, a blockchain will be made in theory more sustainable, and attractive for users with less purchasing power. A small transaction will not have to see its price go up two or three times the original value solely because of the “gas fee“. This energy cost is what is motivating China and the European Union to request its prohibition. They hope to move to an algorithm with lower energy consumption, to maintain activity in many countries if they decide to regulate cryptocurrencies for their energy cost.

Render of an agreement between peers of a blockchain.

The blockchain not only records coins, but also the tokens themselves can have smart contracts and small bits of information, hence it has been one of the most popular networks in which to award the NFT. The latter made other blockchains such as Cardano, Solana or Tezanos marginally more popular, in order to have less purchase and transaction costs. NFTs are expected to use the Ethrereum network more again having less associated costs.

Will the stock of graphics cards improve when Ethereum goes Proof of Stake?

For users less interested in crypto, Ethereum's move from Proof of Work to Proof of Stake this August should mean more graphics card availability. Ethereum has been the most popular cryptocurrency to mine due to its ease of mining. This would leave Bitcoin alone as the only major cryptocurrency operating with Proof of Work. Being Bitcoin a cryptocurrency with a limited number of tokens, and increasingly difficult to mine, the economic investment of electricity, motherboards, space and graphics cards becomes less and less profitable at any size of operation.

This is why, in theory, the low stock of high-end graphics cards should end high hoarded by crypto miners. Most likely, the miners proceed to try to sell their mining equipment on second-hand markets. But it is difficult since constant Proof of Work mining damages the graphics and many shops will not want to accept them. It is very difficult for the market to sell second-hand graphics in stores, but the new graphics should be more accessible.

Show more

Benjamin Rosa

Madrileño whose publishing career began in 2009. I love investigating curiosities that I later bring to you, readers, in articles. I studied photography, a skill that I use to create humorous photomontages.

Related publications

Leave your comment

Your email address will not be published. Required fields are marked with *

Button back to top
Close

Ad blocker detected

This site is financed through the use of advertising, we always ensure that it is not too intrusive for the reader and we prioritize the reader's experience on the web. But if you block ads, some of our funding will be reduced.