Pages:
Author

Topic: Is there a maximum difficulty? Or can it just go up forever? (Read 2328 times)

member
Activity: 111
Merit: 10
Thank you theymos and MoonShadow for the detailed explanations!!  One more thing I cross off my list of things to wonder about Smiley
legendary
Activity: 1708
Merit: 1010
Difficulty is a made up metric to help humans understand the system better.  It is literally the number of times more difficult that the present target is to achieve than the minimum difficulty of 1, which is (and always has been) defined as the maximum target that the client was hardcoded to permit.  That maximum target is (roughly) 32 leading zeros in a 256 bit hash.  With each extra leading zero (target cuts in half, it's binary) the difficulty literally doubles; so as the target approaches zero, the difficulty metric would approach infinity.  The difficulty, however, is not actually used by the bitcoin system at all, the target is.  And since the target is a bounded 256 bit number, the system has no trouble storing the integer.
hero member
Activity: 1148
Merit: 501
Will difficulty go up further whenever the blocks become 25btc instead of 50?  or will difficulty halve itself and the block quantity will not have any effect?
newbie
Activity: 31
Merit: 0
The difficulty is very limited...

By AMD's limited production facilities.
administrator
Activity: 5222
Merit: 13032
The target is stored in a fixed-size form that basically says, "This many zeroes followed by these bytes, followed by enough zeroes to fill 256 bits". It can handle any number, with lower precision for higher numbers.

"Difficulty" isn't used for anything except display, so it doesn't matter how that is stored.
full member
Activity: 126
Merit: 100
who cares?

when it gets to the point where a miner has to consider n-1=0 (where n=difficulty and 0=generated coin), it doesn't matter, does it?

Well if the client reaches a maximum storage limit before bitcoin hits THE mining peak, then we will all care, but thankfully that seems a non issue.

edit: btw, your math requires that difficulty = 1

oops - you're right, i was wrong.  but we're both wrong:

Quote
n-1=0 (where n=infinite difficulty...)
legendary
Activity: 1246
Merit: 1016
Strength in numbers
Target is what matters and difficulty is it's inverse. I think difficulty is stored somewhere, but the precise meaning has actually changed over versions. For actual block checking you look to see if it's hash is below target, difficulty is not used for that.
member
Activity: 111
Merit: 10
Quote
The client appears to contain BigNum classes which can store arbitrarily large numbers.


This is a beautiful sentence.
* Dirt Rider nods
member
Activity: 111
Merit: 10
who cares?

when it gets to the point where a miner has to consider n-1=0 (where n=difficulty and 0=generated coin), it doesn't matter, does it?

Well if the client reaches a maximum storage limit before bitcoin hits THE mining peak, then we will all care, but thankfully that seems a non issue.

edit: btw, your math requires that difficulty = 1
hero member
Activity: 616
Merit: 500
Quote
The client appears to contain BigNum classes which can store arbitrarily large numbers.


This is a beautiful sentence.
full member
Activity: 126
Merit: 100
who cares?

when it gets to the point where a miner has to consider n-1=0 (where n=difficulty and 0=generated coin), it doesn't matter, does it?
member
Activity: 111
Merit: 10
The client appears to contain BigNum classes which can store arbitrarily large numbers.

Ah ok cool, so this is a non issue then I guess Smiley
full member
Activity: 238
Merit: 100
Hehe all of that is beyond my comprehension I just remembered seeing it in the wiki so copy + pasted.
full member
Activity: 196
Merit: 100
The maximum difficulty is roughly: maximum_target / 1, which is a ridiculously huge number (about 2^224).

And what variable type can hold a number that large?

To clarify...  I am just thinking how a standard win32 integer type can only hold about 4.3 billion different values.  I know in theory that difficulty can grow up to at least 2^224 (ty demonefelru) but if the client tried to store that in a standard integer variable...

The client appears to contain BigNum classes which can store arbitrarily large numbers.
member
Activity: 111
Merit: 10
The maximum difficulty is roughly: maximum_target / 1, which is a ridiculously huge number (about 2^224).

And what variable type can hold a number that large?

To clarify...  I am just thinking how a standard win32 integer type can only hold about 4.3 billion different values.  I know in theory that difficulty can grow up to at least 2^224 (ty demonefelru) but if the client tried to store that in a standard integer variable...

edit: What would the client do if difficulty was 9876543210000000000000000000000000000000000000000000000000000000000000000000000 00000000000000
member
Activity: 111
Merit: 10
The maximum difficulty is roughly: maximum_target / 1, which is a ridiculously huge number (about 2^224).

And what variable type can hold a number that large?
full member
Activity: 237
Merit: 100
maximum difficulty can be calculated starting with the total energy from the sun.  Wink
full member
Activity: 238
Merit: 100
From the wiki
What is the maximum difficulty?
The maximum difficulty is roughly: maximum_target / 1, which is a ridiculously huge number (about 2^224).
The actual maximum difficulty is when current_target=0, but we would not be able to calculate the difficulty if that happened. (fortunately it never will, so we're ok.)
member
Activity: 111
Merit: 10
Well, the client stores the difficulty in some variable - what are it's extents?  I mean that variable probably has a limit as to how many digits there can be - but maybe that is so high that it's not of concern in our lifetimes lol

edit: or maybe it will reach the the point where just one single hash can solve each block long before the highest physically allowed diff is reached?
sr. member
Activity: 308
Merit: 250
Well I suppose theoretically it can keep going up until you're looking for a nonce that leads to a specific hash, but I would imagine by the time we reach that point SHA-256 will have been replaced with something beefier, because I gather that's a pretty fuckin' long ways off.
Pages:
Jump to: