# Mining Pool Selection under Block WithHolding Attack +
## 3 Evolutionary Game for Mining Pool Selection
### Expected Payoff
#### 3.2.2 Probability of Wining Mining Competition  
We can see from Section 3.2.1 that the probability \(P_{i}^{win}\) of pool \(i\) wining the mining competition is essential to determine the expected mining revenue of pool \(i\). In the mining competition, each pool aims to mine a block with a valid hash (i.e., an FPoW). Finding such a block is a random event, because the only way is just to try different hash values relentlessly. Since all pools and solo miners join the competition, the probability that pool \(i\) mines a valid block is proportional to the ratio between its _effective_ hash power to the network total _effective_ hash power [34]. By _effective_, we mean the hash power used for mining (excluding those for BWH attack). We use \(P_{i}^{mine}(\mathbf{x},\mathbf{\omega},\mathbf{a})\) to denote the probability of pool \(i\) mining a valid block, which is given by  
\[P_{i}^{mine}(\mathbf{x},\mathbf{\omega},\mathbf{a})=\frac{Nx_{i}\omega_{i}(1-\sum_{j=1}^{ M}a_{ij})}{\sum_{j=1}^{M}Nx_{j}\omega_{j}(1-\sum_{k=1,k\
eq i}^{M}a_{jk})}. \tag{6}\]  
After finding a new block, pool \(i\) broadcasts the block to its adjacent mining pools and solo miners, which will verify the block, append it to their local blockchains and further broadcast it inside the network until the block is received by the majority of the network. This is the situation when other pools and solo miners did not find valid blocks. In this situation, pool \(i\) is the winner of the competition. However, when some other pool or miner also finds valid a block, the block mined by pool \(i\) may be discarded or orphaned by most pools and miners, since the other block may arrive at these pools and miners earlier. In this situation, pool \(i\) will lose the competition. The main cause of orphaning blocks is the propagation time of blocks, which is dependent on the average block propagation delay of network links and average verification time of blocks [24]. According to [24], the propagation delay of a block of size \(s\) can be modeled as \(\tau_{p}(s)=s/(\gamma c)\), where \(\gamma\) is a parameter related to the scale of the network and \(c\) is the average effective channel capacity of each link. The verification time of a block of size \(s\) can be modeled as a linear function \(\tau_{p}(s)=bs\), where \(b\) is a parameter determined by the scale of the network and average verification time of each node [41,42]. Thus, the average propagation time of a block of size \(s\) is given by  
\[\tau(s)=\tau_{p}(s)+\tau_{p}(s)=\frac{s}{\gamma c}+bs. \tag{7}\]  
Suppose that the average block generation interval is a constant \(T\). The occurrence of block orphaning due to the propagation time of blocks can be modeled as a Poisson process with mean rate \(1/T\)[43]. Thus, the probability that the block found by pool \(i\) (i.e., of size \(s_{i}\)) is not orphaned is  
\[P_{i}^{not\ orphan}(s_{i})=e^{-\tau(s_{i})/T}=e^{-(\frac{s_{i}}{\gamma c}+bs_{ i})/T}. \tag{8}\]  
Pool \(i\) wins the competition if and only if it finds a valid block and the block is not orphaned. Thus, the probability of wining the competition for pool \(i\) is  
\[P_{i}^{win}(\mathbf{x},\mathbf{\omega},s_{i},\mathbf{a})=P_{i}^{mine}(\mathbf{x},\mathbf{\omega}, \mathbf{a})P_{i}^{not\ orphan}(s_{i}). \tag{9}\]