EOS dPOS (Delegated Proof-of-Stake)
EOS uses the consensus algorithm Delegated Proof of Stake dPOS. EOS implements a system of governance when coming to a consensus for block validation. Under this mechanism, only the token holders of EOS can select “block producers” as delegates through a continuous approval voting system. These token holders have a right to participate in how the network operates. The block producer stakes a portion of their own funds to prove they are honest to the network, because if they don’t they will lose what they staked. The process consists of two parts, namely electing a group of block producers and scheduling production. The block producer has plenty to gain and also to lose, so they must properly perform their duty to validate blocks or else they will lose what they have at stake.
Let’s assume we have 3 block producers, A, B, and C. A consensus in dPOS requires 2⁄3 + 1 to resolve all cases. In this case producer C is the tie breaker. In EOS there would be 21 or more block producers. The block producer who has validated the longest chain wins. Any time an honest peer sees a valid strictly longer chain it will switch from its current fork to the longer one. This was by design to prevent any hard forks or new chain from sprouting up.
A block is produced exactly every 0.5 second. The blocks are produced in rounds of 126, with 6 blocks each for 21 producers. During the start of each round, unique block producers are elected from votes by the token holders. Now the block producers need to be scheduled to produce blocks. Under normal conditions, the block producers take turns producing a block every 3 seconds. Assuming no one misses their turn then this will produce the longest possible chain. It is invalid for a block producer to produce a block at any other time slot than the one they are scheduled for. Every time a new block is produced, new tokens are given as reward to the block producers.
It is a requirement that every transaction must include part of the hash of a recent block header as part of TaPoS (Transaction as Proof of Stake). This hash is used to prevent a replay of a transaction and also signals the network that a particular user and their stake are on a specific fork. At this point if a bad actor tries to create their own chain, they will have to take their claim as the valid block. As the other producers cooperate in an honest manner, the bad actor will have to get more producers to accept their chain, but if not supported by consensus, it will be rejected by the network. The bad actor will just lose more, so this is a deterrent. Of the 21 block producers, 15 are needed for consensus on the network and this will then reward those who helped rather than those who tried to attack the network. Since this uses voting as part of the consensus mechanism, a bad actor can be voted out of the network by token holders.
By design, the smaller number of producers produce a higher throughput through parallelism. To achieve a consensus requires 2/3 of the block producers on the network to establish honesty.
![Screen Shot 2018-05-28 at 1.02.47 AM.png](https://steemitimages.com/640x0/https://cdn.steemitimages.com/DQmXezntofVK7rd4pVpZfW7J6Q39yzGu3xHvH3Y9eG32S37/Screen%20Shot%202018-05-28%20at%201.02.47%20AM.png)
Good explanation of EOS dPOS, thanks for sharing.
Thank you for your feedback.