by bbosh · 12y ago · 0 comments
Not if the current network speed is higher than the difficulty level due to more mining power having come online since the last difficulty change.
You could estimate this by examining the block times over the last 120 (or some N) blocks, estimating the difficulty for that solve rate, and using the ratio of current network difficulty over the the estimated difficulty times 10 minutes.
I think the best solution is to remove the expected next block time counter altogether. One of the reasons UX wise I went for such an expected point in the future was that after reading it you are aware a new block will come again (just like when you first load the project) and that might keep you waiting for it.
Testing a block header is just a binary (yes/no) test with a given probability (target/max_target). Finding a block is repeating this test again and again, i.e. a binomial distribution, right?
Finding a block averages 10 minutes, which means that, after 10 minutes trying hashes randomly, the expectation of finding a block is high, i.e. the CDF of the binomial distribution approaches 1.
The result will deviate from the expected result? Of course! After all, it's a distribution... but this doesn't contradict the fact that as you try again a again, the probability of AT LEAST ONE hitting the target gets higher.
So, yes, it doesn't change the individual probability of each outcome, but it sure does mean that more hashes have been tried, i.e. there's a greater probability of a hash being found simply because we've tried more guesses as time passes, i.e. we're measuring the CDF with a high N.
To put it another way: the more coins you flip, the higher the expectation of AT LEAST ONE yielding tails (even if the previous attempts don't change the outcome probability).
Think about it: even if each coin outcome is always 1/2, we're not assessing whether it's going to be tails or not in flip N, but whether after N flips we'll see at least one flipping tails, whose probability is (1 - (1/2)^N).
Flipping a coin 7 times yields a 99% probability of flipping tails (or heads) at least once, regardless of previous outcomes.
And I'll stop here, I think I'm repeating myself :P
Just like when you flip 10 coins they likely won't result in: head - tail - head - tail - (...). Though on average you end up with 5 tails and 5 heads.
That's why it says expected! To be 100% correct you could plot the cumulative density function as time progresses, but I think just printing the expected time is fine.