What are Consensus Algorithms?

William Nester
Sep 20, 2018 · 3 min read
Image for post
Image for post

An algorithm is a process or set of rules to be followed in calculations to reach a goal, usually seen in computer systems. New networks (such as cryptocurrency networks) and rudimentary networks (such as those used by financial institutions) of transactions are considered working, valid and valuable only if the network can agree on current balances in a double-spend-proof ledger of transactions — only if they reach consensus.

Networks only work if the computers in the network are able to agree with one another and not have any double-spend or “counterfeit” transactions in their ledgers.

Rudimentary networks achieve this with a trusted third party such as a bank or financial institution, which would be in charge of checking each transactors balance to see if they are only spending money that they own. To check that they are not double-spending.

Cryptocurrency networks on the other hand, can achieve this consensus with a decentralized network of validators who are able to reach agreement in the network using consensus algorithms, such as the Nakamoto Consensus Algorithm.

Reaching a valid network agreement is not easy, especially in cryptocurrency networks that are (presumably) permission-less. Being permission-less means that anyone can be part of the network and can therefore be a validator. The only thing that you have to do to be a part of it is to get your computer or mining equipment ready and plug it into the network.

With the likes of Visa and MasterCard though, they know that their computers will be checking the right balances and validating only transactions with sufficient funds, because they own the network. They are the validators. With great power comes great responsibility — but also susceptibility to fraud, hacking, malpractice and error.

To maintain consensus in a decentralized environment, permission-less networks have to implement several mechanisms because of the possibility of having malicious actors on the network. Such mechanisms include computational puzzles that make participants put resources at stake, incentives mechanisms which pay participants in the form of rewards, and rules, such as ‘the longest chain prevails’ . These elements in combination with a Blockchain or Directed Acyclic Graph architecture, form consensus algorithms.

When you put all of these components in the right place, you are left with an algorithm that will allow participants to develop and support a single decision in everyone’s best interest. The agreement can be achieved because the personal interest of the participant and the interest of the whole network are one, and therefore, the probabilities of having an individual going against their personal interest is minimal.

Decentralised consensus is the result, and once we begin to apply that concept to the world around us, things become very interesting, very quickly.

Image for post
Image for post

Enjoyed this post? We’d love to hear your thoughts on it. Complete the nakamo.to survey for a chance to win nakamo.to merchandise!


Picking up where Satoshi left off.

Medium is an open platform where 170 million readers come to find insightful and dynamic thinking. Here, expert and undiscovered voices alike dive into the heart of any topic and bring new ideas to the surface. Learn more

Follow the writers, publications, and topics that matter to you, and you’ll see them on your homepage and in your inbox. Explore

If you have a story to tell, knowledge to share, or a perspective to offer — welcome home. It’s easy and free to post your thinking on any topic. Write on Medium

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store