Search

Refer your friends and get 30% of their trading fees.

Refer your friends and get 30% of their trading fees.

Learn More
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 Crypto Custody?

January 18, 2022

Christina

Consider a $100 bill for a moment. When the bill is in your pocket, it is in your custody, and you are its custodian. If you deposit that bill into a bank, the bank becomes the custodian. The same is true with crypto custody.

Keep up with crypto through EQONEX!


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

What Is The Ethereum Arrow Glacier Upgrade?

January 11, 2022

Christina

The Ethereum Arrow Glacier upgrade recently went live and made another change to the network by delaying Ethereum's "difficulty bomb" until June 2022. How will it effect you?

What Is Double-Spend, and How Does Bitcoin Prevent It?

December 30, 2021

Christina

The “double-spend” problem is one of the many pieces of jargon that often seems confusing to anyone unfamiliar with cryptocurrencies because it doesn’t exist in traditional finance. Understanding the double-spend problem and how Bitcoin solves it is key.

Centralized Exchanges (CEXs) vs. Decentralized Exchanges (DEXs)

December 21, 2021

Christina

What is a CEX? What is a DEX? Centralized Exchanges (CEXs) and Decentralized Exchanges (DEXs) are different types of cryptocurrency exchanges. What's the difference? And which is best for you?