Bitcoin Forum
June 19, 2024, 10:31:17 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: What is proofOfWorkLimit?  (Read 401 times)
Green Lantern (OP)
Newbie
*
Offline Offline

Activity: 322
Merit: 0


View Profile
April 18, 2014, 11:24:30 AM
 #1

Look at the code below from android bitcoin wallet:
Code:
proofOfWorkLimit = Utils.decodeCompactBits(0x1d00ffffL);
And look at the code from bitcoin qt wallet:
Code:
static CBigNum bnProofOfWorkLimit(~uint256(0) >> 32);
I assume that in second case ProofOfWorkLimit consists of 32 "0" and 224 "1" (000000...000000000011111111111111111111....11111111)?
So I don't have an idea how to get first case "0x1d00ffffL" from second case? In binary "0x1d00ffffL" is 11101000000001111111111111111.
P.S. I have looked in uint256.h. It wasn't helpful.
P.S.S. Can anyone answer for sample what exactly should I put here "Utils.decodeCompactBits(0x1d00ffffL);" in case "~uint256(0) >> 27" ?
mriou
Newbie
*
Offline Offline

Activity: 26
Merit: 0


View Profile
April 18, 2014, 10:47:25 PM
 #2

This should help:

https://en.bitcoin.it/wiki/Difficulty
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!