4 ms·
> Unfortunately this means the chance of a collision in a year is 99.999999999998% which isn't great! How was this computed? My intuition begs to differ.
by doersino 6y ago
> Unfortunately this means the chance of a collision in a year is 99.999999999998% which isn't great!
How was this computed? My intuition begs to differ.
- jychang 6y agoThere are 31,536,000,000 milliseconds in a year. If you do (1-1E-9)^3.1536E10, you get a 2E-14 chance of no collision in a year.
- hoseja 6y agoI think the presumption is you will not be generating 50 million of them each millisecond.
- alpaca128 6y agoWhich is a pretty safe assumption, considering just generating those 128bits 50 million times a millisecond results in over 20 million TB of data in a year. I think it's safe to say this is not a common scenario.
- onetoo 6y agoProbability of no collision in a single millisecond: p_1 = 999999999/1000000000 Milliseconds in a year: t = 1000 * 60 * 60 * 24 * 365 Probability of no collision happening for every millisecond of a year: p_2 = p_1^t Probability of a collision happening for at least one millisecond of a year: p_3 = 1 - p_2 https://www.wolframalpha.com/input/?i=1+-+%28999999999%2F1000000000%29%5E%281000+*+60+*+60+*+24+*+365%29 https://www.wolframalpha.com/input/?i=1+-+%28999999999%2F100...
- mytailorisrich 6y agoThere are close to 32 billion millisecond in a year. If the chance of a collision happening within a millisecond is 1 in a billion then my intuition is that the probability of a collision happening at least once a year is quite high, indeed. It's like a dice: You have 1 in 6 chance of getting a 6 every time your roll the dice. Now, if you roll the dice 100 times the chance that you'll get a 6 at least once is then pretty high.