<p>Actually, it is not related to the difficulty at all, rather just related to the expected time until the next block is found.</p>

<p>Block finding is a <a href="https://en.wikipedia.org/wiki/Poisson_process" rel="noreferrer">Poisson process</a>.</p>

<p>The probability of <code>x</code> blocks occuring in the amount of time we'd expect <code>λ</code> blocks occuring therefore is:  </p>

<blockquote>
  <p><a href="https://i.sstatic.net/60tgi.gif" rel="noreferrer"><img src="https://i.sstatic.net/60tgi.gif" alt="enter image description here"></a></p>
</blockquote>

<p>In ideal conditions, we expect one block per ten minutes, i.e. 600 seconds. Therefore in 2 seconds we'd expect 1/300 blocks occuring.</p>

<p><code>p(2|1/300)</code> evaluates to approximately 5.54*10<sup>-6</sup> which is about 0.000554%, i.e. <strong>we'd expect two blocks to occur within two seconds once every 180k blocks or every ~3.4 years</strong>.</p>

<p>More exciting are ten seconds which has a probability of about 0.00014, i.e. we'd expect two blocks within ten seconds to happen once every 7000 blocks, i.e. roughly every seven weeks.</p>

CC BY-SA 3.0
2016-01-29T22:25:03.593Z
Nice! Now I'm wondering how much time a block discovery takes to be propagated to the entire network.
Henrique Barcelos
CC BY-SA 3.0
2016-01-30T07:24:10.737Z
@HenriqueBarcelos: Have a look at [How long does it take to propagate a newly created block to the entire Bitcoin network and why?](http://bitcoin.stackexchange.com/q/10821/5406)
Murch
CC BY-SA 3.0
2016-01-29T14:15:06.890Z
2016-01-30T08:11:52.280Z
2016-01-30T08:11:52.280Z
Murch
<p>Is there any general formula that allows someone to calculate what is the current probability of having a chain fork?</p>

<p>I know that the probability of finding a new block is proportional to the difficulty target. Given that it's possible to have <code>2^256</code> different hashes (for simplification), finding a <code>nonce</code> that will yield a hash lower than <code>target</code> has probability of approximately <code>P(m) = (2^256 - target)/2^256</code>.</p>

<p>Given that a block will be mined within 10 minutes and considering that a delay of 2 seconds would be small enough for the newtwork propagation not being complete, that is, if two nodes find a block 2 seconds appart, there would be no time to notify the full network.</p>

<p>Here is when it gets complicated to me (statistics is not strong with me). What is the probability of the situation described above occur?</p>

<p>I think this is something related with a normal distribution, but I'm not sure.</p>

<p>My rational to find the probability of forking would be:</p>

<pre><code>P(fork) = P(m1) * P(m2) * P(tdse)
</code></pre>

<p>Where <code>P(m1)</code> is the probability of node 1 to find a new block, <code>P(m2)</code> the same for node 2 and <code>P(tdse)</code> is the probability of both mining occur with a <strong>t</strong>ime <strong>d</strong>ifference <strong>s</strong>mall <strong>e</strong>nough to not be propagated to the entire network.</p>

<blockchain-fork>
What is the probability of forking in blockchain?
Henrique Barcelos
# What is the probability of forking in blockchain?

(Asked by: username_0 on 2016-01-29)

Is there any general formula that allows someone to calculate what is the current probability of having a chain fork?
I know that the probability of finding a new block is proportional to the difficulty target. Given that it's possible to have 2^256 different hashes (for simplification), finding a nonce that will yield a hash lower than target has probability of approximately P(m) = (2^256 - target)/2^256.
Given that a block will be mined within 10 minutes and considering that a delay of 2 seconds would be small enough for the newtwork propagation not being complete, that is, if two nodes find a block 2 seconds appart, there would be no time to notify the full network.
Here is when it gets complicated to me (statistics is not strong with me). What is the probability of the situation described above occur?
I think this is something related with a normal distribution, but I'm not sure.
My rational to find the probability of forking would be:
P(fork) = P(m1) * P(m2) * P(tdse)

Where P(m1) is the probability of node 1 to find a new block, P(m2) the same for node 2 and P(tdse) is the probability of both mining occur with a time difference small enough to not be propagated to the entire network.

**Tags:** blockchain-fork


---

## 1 answers

### Answer by username_1 on 2016-01-29. Score: 7 | Accepted answer

Actually, it is not related to the difficulty at all, rather just related to the expected time until the next block is found.

Block finding is a [Poisson process](https://en.wikipedia.org/wiki/Poisson_process).

The probability of `x` blocks occuring in the amount of time we'd expect `λ` blocks occuring therefore is:

> [![enter image description here](https://i.sstatic.net/60tgi.gif)](https://i.sstatic.net/60tgi.gif)

In ideal conditions, we expect one block per ten minutes, i.e. 600 seconds. Therefore in 2 seconds we'd expect 1/300 blocks occuring.

`p(2|1/300)` evaluates to approximately 5.54\*10-6 which is about 0.000554%, i.e. **we'd expect two blocks to occur within two seconds once every 180k blocks or every ~3.4 years**.

More exciting are ten seconds which has a probability of about 0.00014, i.e. we'd expect two blocks within ten seconds to happen once every 7000 blocks, i.e. roughly every seven weeks.

> **Comments:**
> **username_0**: Nice! Now I'm wondering how much time a block discovery takes to be propagated to the entire network.  
> **username_1**: @HenriqueBarcelos: Have a look at [How long does it take to propagate a newly created block to the entire Bitcoin network and why?](http://bitcoin.stackexchange.com/q/10821/5406)  

---

