Bitcoin Forum
May 22, 2024, 01:42:47 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Difficulty and zeroes?  (Read 730 times)
tkbx (OP)
Sr. Member
****
Offline Offline

Activity: 350
Merit: 251



View Profile
October 24, 2013, 01:03:18 AM
 #1

If Bitcoin uses the number of preceding zeroes in a block (000000000000000a14da313e33fe2012b95c82ae03c58739888a440a845642f3) to set the difficulty, how is it possible for the difficulty to double or triple? Wouldn't it need to get 16 times harder because of an extra zero?
gmaxwell
Moderator
Legendary
*
expert
Offline Offline

Activity: 4186
Merit: 8424



View Profile WWW
October 24, 2013, 02:13:02 AM
 #2

If Bitcoin uses the number of preceding zeroes in a block (000000000000000a14da313e33fe2012b95c82ae03c58739888a440a845642f3) to set the difficulty, how is it possible for the difficulty to double or triple? Wouldn't it need to get 16 times harder because of an extra zero?
Perceptive. It doesn't.

Bitcoin doesn't use the number of zeros. Instead it converts the hash into a single big integer and requires that the value be less than a target value. The target value is adjusted every 2016 blocks as required to control the block rate and the "difficulty" number is just the ratio of the current hardness of the problem to the initial hardness.
Dabs
Legendary
*
Offline Offline

Activity: 3416
Merit: 1912


The Concierge of Crypto


View Profile
October 24, 2013, 04:59:29 AM
 #3

Okay. So bitcoin does not use zeros. I thought it used zeros in binary or something. Therefore, difficulty can be any number between zero and 2^256. It's not from 1 zero to 256 zeros in 256 bits.

gmaxwell
Moderator
Legendary
*
expert
Offline Offline

Activity: 4186
Merit: 8424



View Profile WWW
October 24, 2013, 06:45:16 AM
 #4

Okay. So bitcoin does not use zeros. I thought it used zeros in binary or something.
No, if it did that difficulty could only change by factors of 2.
Dabs
Legendary
*
Offline Offline

Activity: 3416
Merit: 1912


The Concierge of Crypto


View Profile
October 24, 2013, 07:39:00 AM
 #5

I get it now. Difficulty is currently at around 267731249.48242110, but this is derived from a 256 bit number. So the small numbers actually mean something.

Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!