Bitcoin Forum
December 14, 2024, 08:47:21 AM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 [2]  All
  Print  
Author Topic: mining process query  (Read 1748 times)
raresaturn (OP)
Full Member
***
Offline Offline

Activity: 168
Merit: 100


Everyone Is A Bank


View Profile
July 01, 2011, 03:04:23 AM
 #21

No you can't do that... but by using a new nonce you pretty much ensure that you won't get the same hash again.

Why can't you? Is it because it's against the rules?  Not supported by current software?  Or simply not feasible?

thanks.

                 BABB        |[     BANK ACCOUNT BASED BLOCKCHAIN     ]|       Everyone is a bank
▬                       JOIN TOKEN SALE                       ▬
▬▬▬▬▬     JOIN THE COMMUNITY    |    Telegram     ▬▬▬▬▬
compro01
Hero Member
*****
Offline Offline

Activity: 590
Merit: 500



View Profile
July 01, 2011, 10:23:21 PM
 #22



You take the block header, run it through SHA-256 twice, and check whether that hash output is less than the target.  if not, you increment the nonce value (which completely changes the hash value, due to the avalanche effect) and try again, over and over, until someone finds a valid block, then you start it all over again with a new set of transactions, etc.

Ok, so instead of increasing the nonce to randomly genrate a new hash value, is it possible to set your miner to just increment (or decrement) the hash value by one each time and go through them sequentially , thus eliminating re-tries?  It seem to me that that current way of doing it is a bit like playing Battleship without the white pegs.

you appear to be misunderstanding the process.  incrementing the hash is nonsensical, as it is not an input value, it is the result.  mining is working to find the input (the block header) that results in a hash which is less than the target.

you can't just change the output arbitrarily, as the input needs to match with it, and hashing is a one-way function (you can hash something, but it's (practically) impossible to take a hash and determine the input value that resulted in it.).
raresaturn (OP)
Full Member
***
Offline Offline

Activity: 168
Merit: 100


Everyone Is A Bank


View Profile
July 01, 2011, 10:39:14 PM
 #23



You take the block header, run it through SHA-256 twice, and check whether that hash output is less than the target.  if not, you increment the nonce value (which completely changes the hash value, due to the avalanche effect) and try again, over and over, until someone finds a valid block, then you start it all over again with a new set of transactions, etc.

Ok, so instead of increasing the nonce to randomly genrate a new hash value, is it possible to set your miner to just increment (or decrement) the hash value by one each time and go through them sequentially , thus eliminating re-tries?  It seem to me that that current way of doing it is a bit like playing Battleship without the white pegs.

you appear to be misunderstanding the process.  incrementing the hash is nonsensical, as it is not an input value, it is the result.  mining is working to find the input (the block header) that results in a hash which is less than the target.

you can't just change the output arbitrarily, as the input needs to match with it, and hashing is a one-way function (you can hash something, but it's (practically) impossible to take a hash and determine the input value that resulted in it.).

ok thanks that's a bit clearer.

                 BABB        |[     BANK ACCOUNT BASED BLOCKCHAIN     ]|       Everyone is a bank
▬                       JOIN TOKEN SALE                       ▬
▬▬▬▬▬     JOIN THE COMMUNITY    |    Telegram     ▬▬▬▬▬
Pages: « 1 [2]  All
  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!