Search

Crypto Explained

Digital Assets Decoded: What are Consensus Algorithms?

November 19, 2020
This is the second article of our Digital Assets Decoded series which aims to give you a fundamental understanding of the cryptocurrency space. In our previous article, “What is Blockchain?”, we discussed what a blockchain is and how it stores data as a series of events.

Defining Consensus Algorithms

The overall meaning of the phrase consensus algorithm may be understood by understanding the meaning of both words in this phrase. The first word, consensus, means a general agreement between members of a group, whereas the second word, algorithm, denotes a sequence of steps that a computer follows in a program.

Taking the definition of these words together, we can rephrase consensus algorithm as, “a set of rules which are followed to coordinate and arrive at an agreement between members of a group.

At its core, a consensus algorithm is used for multiple parties or computers to agree on a system’s state. This decision will be added onto the blockchain and can then be considered as an irrefutable Single Source of Truth. Consensus algorithms are based on Distributed Computing concepts, in which multiple machines aim to achieve a reliable network by deriving results following a decision-making process through consensus.

An example Consensus Algorithm

A very simplified analogy of a Consensus Algorithm is a simple majority voting process.

For example, you’d like someone to represent your community in a particular yearly event, and would like to hold a very distributed voting process. There are two candidates, Alice and Bob, as well as 500 people in your community. Each community member can be thought of as a machine on the system. Not all community members know each other, but they do know that they have to vote for 1 of 2 candidates, and a simple majority is required to declare the winner. In addition, in this set-up, voters are also the people who are counting the votes. Thus, the overall rules of this voting process will be as follows:

1. Two candidates are identified: Alice and Bob

2. 500 eligible voters are identified, and agree to participate in the vote and the rules associated with the process

3. Should a voter not agree with the rules, they may feel free to drop out of the process

4. Once a voter has sent in their vote, they will know how many people have voted for each party and the current state of the votes

5. If there is a simple majority (e.g. 251 out of 500 votes if there are no dropouts) for a specific candidate, a winner will be declared

At the end of this process, if at least half of the votes count towards a specific candidate, it is then known and agreed upon by all parties that this candidate is the winner. The decision on who is the winner may then be added to a list or record of winners. However, because we love blockchains, this can be done in a blockchain which shows both a timestamp and a result, as represented in Figure 2. 

Comparison with Cryptocurrencies

A direct comparison of this analogy is in cryptocurrencies, where the blockchain will show a timestamp and a list of transactions. Miners will select which transactions will be eligible to be in the next block in their blockchain, and this process is done in a distributed fashion.

The above shows a very simplified analogy of consensus algorithms, and do not take into account topics such as fault-tolerance and consistency. These are deeper topics which we may choose to explore in future articles.

There are many variants and applications of consensus algorithms. However, in the cryptocurrency space, the most popular ones are Proof-of-Work and Proof-of-Stake, which we will discuss in future articles in these series.

Related Articles

What Is a Cryptocurrency Halving?

June 11, 2021

Halvings are strongly associated with price cycles in cryptocurrencies and form an intriguing part of Bitcoin’s economic model. But what are they, and why do they happen?

Keep up with crypto through EQUOS!


This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

What is a Bitcoin node?

May 28, 2021

The beginner's guide to Bitcoin nodes: To fulfill and validate Bitcoin transactions, it’s also necessary to broadcast messages across a network using nodes. Here's how it works.

What is Proof of Work (Pow)?

May 25, 2021

Proof of Work uses hashes to verify a blockchain contains all previous transactions in a sequential line of blocks.

What Is an ERC-20 token?

May 13, 2021

The most important issue that ERC-20 addresses is standardization. In the early days of the Ethereum blockchain, developers worked on their own tokens with different functions and rules, which led to compatibility issues.