Author

Topic: Clarification on Bitcoin Developer Guide: Proof of Work (Read 671 times)

copper member
Activity: 2562
Merit: 2504
Spear the bees
No, they were saying that 2256-1 is the biggest possible number which a hash could be, indicating that the hash is a 256-bit hash. The target is 2255.

In that case, would this be the error?

"For example, if the maximum possible hash value is 2256 − 1, you can prove that you tried up to two combinations by producing a hash value less than 2255."

Up to two combinations doesn't make sense considering how you can produce up to 2255-1 different hashes that would be higher than the target value (correct me on my math if I'm wrong)
.

I've got it now! Thanks for the clarification: it didn't make too much sense to me.

(You produce up to two combinations since one is successful and the other is unsuccessful)



Truly, the folly of man lies in his ability to communicate.



[Locked. In case there are extra comments to be made about PoW process; please PM me - I'd love to learn more]
staff
Activity: 3374
Merit: 6530
Just writing some code
I see what you're saying, but the problem is that AFAICT they were making the target value 2256-1 in the example and attempting to use 2255 in the second without stating it, which is incorrect when you're speaking about having a successful hash every other attempt.
No, they were saying that 2256-1 is the biggest possible number which a hash could be, indicating that the hash is a 256-bit hash. The target is 2255.

So is this just simply an error in their paragraph?
It's just a weird way of saying that the hash is a 256-bit hash.
copper member
Activity: 2562
Merit: 2504
Spear the bees
It says on average, so given a big number of tries, half of them would be greater than 2255 and half would be less. I don't think saying "every other try" is the right wording for this.

I see what you're saying, but the problem is that AFAICT they were making the target value 2256-1 in the example and attempting to use 2255 in the second without stating it, which is incorrect when you're speaking about having a successful hash every other attempt.

I understand the maths of statistically succeeding every other attempt, which occur when the target value is 2255.



So is this just simply an error in their paragraph?
staff
Activity: 3374
Merit: 6530
Just writing some code
I don't quite understand this. Is there not a huge gap between 2255 and 2256-1? If you tried up to only two combinations (I'm assuming this is a hash value of 2256 and 2256-1) then how would you be able to produce a successful hash every other try?
It says on average, so given a big number of tries, half of them would be greater than 2255 and half would be less. I don't think saying "every other try" is the right wording for this.
copper member
Activity: 2562
Merit: 2504
Spear the bees
Note: I realize that there is a disclaimer that states the possibility of errors, and thus have come here to ask for an explanation.



On the segment of Proof Of Work, it is stated

Quote
To prove you did some extra work to create a block, you must create a hash of the block header which does not exceed a certain value. For example, if the maximum possible hash value is 2256 − 1, you can prove that you tried up to two combinations by producing a hash value less than 2255.

In the example given above, you will produce a successful hash on average every other try.

I don't quite understand this. Is there not a huge gap between 2255 and 2256-1? If you tried up to only two combinations (I'm assuming this is a hash value of 2256 and 2256-1) then how would you be able to produce a successful hash every other try?



I'm not too huge on hashing so a layman explanation for that including this would also help. My thought so far on how it would work is that you're given a random value <=2256.

The only other logical explanation I might have is that they mean that you would produce a successful hash on average every other try if the target was 2255.
Jump to: