Basics of the Blockchain and Cryptocurrencies - Part II

in #cryptocurrency7 years ago (edited)

Note
In the last post I talked about what a blockchain is:
https://steemit.com/blockchain/@gordon-cryptoman/basics-of-the-blockchain-and-cryptocurrencies-part-i
This time I will be talking about how this chain is built, more specifically about consensus algorithms.

What is a consensus algorithm?
The blockchain as a registry is distributed through its network, all the nodes have a copy of all the entries in the database (all the blocks in the chain), and its the nodes themselves that contribute to adding new blocks. Every time a node adds a block to the blockchain it is given a certain reward for it. But they have to be organized, otherwise all the nodes will try to add its own blocks and that would be chaotic and unusable. So they have to find a way to agree between each other which of the nodes will add the next block to the blockchain. And that is basically what a consensus algorithm is for. Its a way for the nodes to decide when and when not to add blocks to the blockchain.

11.jpg

Types of consensus algorithms
There are many ways of making this thing work, the most known one is the Proof-of-Work (used by the bitcoin network), and the second is the Proof-of-Stake (used by neo and dash for example, and it will also be adopted by ethereum soon).
So, lets try to explain how these ones work.
Proof-of-Work : to choose the next node to add a block to the blockchain there will be a challenge, the first one to get the solution to the challenge gets to add the next block to the blockchain and gets rewarded for it. Now, this challenge is a very complicated one and needs lots of computing power to be solved, this means the more computing power you have, the higher the chances that you will be the one to get the reward. So it is very common for people to join forces, dividing the work needed to solve the problem, increasing their odds of "winning" the challenge, and dividing the rewards according to each one's computing power, these kind of group is called a pool. These networks usually consume an insane amount of power, and there are possibilities of a big pool monopolizing the network, those being its main concerns.

Proof-of-Stake: these networks are much more energy saving, being so that there is no challenge that requires lots of computing power, but it brings its own disadvantages too. To choose the node in this kind of network there is a kind of "lottery" that chooses what node will do the job. But there is a catch, the more coins you have in your wallet the more likely you are to win that lottery, this amount you have is known as weight, the more weight the more chances, this is usually a point of complaint because that makes it so that the richer will have more opportunity of becoming even richer.

Conclusion
As you can see all the algorithms have its ups and downs, the challenge right now is coming up with a way to make these networks scalable and as distributed as possible, and making an as fair as possible algorithm.

As in the other post remember that this is a basic explanation of how the blockchain works and I might make some advanced posts in the future after I finish this basics series. The next post will be about how transactions work so stay tuned for that.
If you see any error or typo please tell me. And ask anything you want in the comments.

Coin Marketplace

STEEM 0.26
TRX 0.25
JST 0.040
BTC 92903.81
ETH 3331.70
USDT 1.00
SBD 3.29