#Binance

#bitcoin

ASSEMBLING AND SELECTING CHAINS OF BLOCK

(B)

Sometimes, as we will see in “Blockchain Forks” the new block extends a

chain that is not the main chain. In that case, the node will attach the new block to

the secondary chain it extends and then compare the work of the secondary chain to

the main chain. If the secondary chain has more cumulative work than the main

chain, the node will reconverge on the secondary chain, meaning it will select the sec‐

ondary chain as its new main chain, making the old main chain a secondary chain. If

the node is a miner, it will now construct a block extending this new, longer, chain.

If a valid block is received and no parent is found in the existing chains, that block is

considered an “orphan.” Orphan blocks are saved in the orphan block pool where

they will stay until their parent is received. Once the parent is received and linked

into the existing chains, the orphan can be pulled out of the orphan pool and linked

to the parent, making it part of a chain. Orphan blocks usually occur when two

blocks that were mined within a short time of each other are received in reverse order

(child before parent).

By selecting the greatest-cumulative-work valid chain, all nodes eventually achieve

network-wide consensus. Temporary discrepancies between chains are resolved even‐

tually as more work is added, extending one of the possible chains. Mining nodes

“vote” with their mining power by choosing which chain to extend by mining the

next block. When they mine a new block and extend the chain, the new block itself

represents their vote.

In the next section we will look at how discrepancies between competing chains

(forks) are resolved by the independent selection of the greatest-cumulative-work

chain.

$BTC