Title: Does it really require more hashing to find a hash with more zero ? Post by: BitcoinExchangeIndia.com on November 30, 2014, 04:58:43 PM I used to know there is no formula to find a hash with more or less zero at left !!!
Title: Re: Does it really require more hashing to find a hash with more zero ? Post by: hexafraction on November 30, 2014, 05:17:40 PM Yes, it does take more time, probabilistically. Drawing hashes is like playing the lottery, as in each nonce (attempt by a mining device) represents a single drawn ticket. For the purposes of our knowledge today, each hash result is effectively random (but determined by the nonce and coinbase). The more zeros need to be at the beginning of the hash, the more tries it generally takes (since a winning result is less likely if more zeros are needed).
You can try this by picking a number from 0 to 999,999 on a calculator a bunch of times. A number that has at least one zero is between 0 and 99,999, chance roughly 1/10. A number with two zeros is between 0 and 9,999 (chance roughly 1/100). A number with 3 zeros is between 0 and 999 (chance roughly 1/1000). And so on... Title: Re: Does it really require more hashing to find a hash with more zero ? Post by: BitCoinDream on November 30, 2014, 10:38:20 PM Yes, it does take more time, probabilistically. Drawing hashes is like playing the lottery, as in each nonce (attempt by a mining device) represents a single drawn ticket. For the purposes of our knowledge today, each hash result is effectively random (but determined by the nonce and coinbase). The more zeros need to be at the beginning of the hash, the more tries it generally takes (since a winning result is less likely if more zeros are needed). You can try this by picking a number from 0 to 999,999 on a calculator a bunch of times. A number that has at least one zero is between 0 and 99,999, chance roughly 1/10. A number with two zeros is between 0 and 9,999 (chance roughly 1/100). A number with 3 zeros is between 0 and 999 (chance roughly 1/1000). And so on... The example u have given are linear natural number, where the probability is calculable. How come we are determining the probability of hash generation where we neither know the hashes nor know any formula to predict them !!! Title: Re: Does it really require more hashing to find a hash with more zero ? Post by: hhanh00 on November 30, 2014, 10:55:50 PM A cryptographic hash like SHA-256 produces hashes that are indistinguishable from a uniform distribution. This is why there is no bias in the 'lottery'. It can act as a pseudo random number generator (even though there are subtleties related to sizes and it is not recommended to do so).
Title: Re: Does it really require more hashing to find a hash with more zero ? Post by: hexafraction on November 30, 2014, 11:02:22 PM Yes, it does take more time, probabilistically. Drawing hashes is like playing the lottery, as in each nonce (attempt by a mining device) represents a single drawn ticket. For the purposes of our knowledge today, each hash result is effectively random (but determined by the nonce and coinbase). The more zeros need to be at the beginning of the hash, the more tries it generally takes (since a winning result is less likely if more zeros are needed). You can try this by picking a number from 0 to 999,999 on a calculator a bunch of times. A number that has at least one zero is between 0 and 99,999, chance roughly 1/10. A number with two zeros is between 0 and 9,999 (chance roughly 1/100). A number with 3 zeros is between 0 and 999 (chance roughly 1/1000). And so on... The example u have given are linear natural number, where the probability is calculable. How come we are determining the probability of hash generation where we neither know the hashes nor know any formula to predict them !!! Well, since you can't predict them, they are random. It's empirically observed (and intended in the design) that the hashes are uniformly spread (so any 256-bit integer is likely as the next). The probability is thus still calculable (though you need to consider that a goal of leading zeros in binary make the probability powers of 1/2, and a goal of leading zeros in hexadecimal make the probability powers of 1/16. |