Bitcoin Forum
May 04, 2024, 01:18:52 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Where can I learn in more detail exactly what the computers are doing to mine?  (Read 1088 times)
yordan (OP)
Newbie
*
Offline Offline

Activity: 14
Merit: 0


View Profile
March 25, 2013, 04:21:08 PM
 #1

I keep seeing over and over that "to mine bitcoins your computer has to solve mathematical puzzels".  OK that's a little vague.  Where can I learn more about what exactly is required to generate a block and how the difficulty changes?  I wouldn't understand the code itself but a technical paper with some diagrams would be interesting.
1714828732
Hero Member
*
Offline Offline

Posts: 1714828732

View Profile Personal Message (Offline)

Ignore
1714828732
Reply with quote  #2

1714828732
Report to moderator
The grue lurks in the darkest places of the earth. Its favorite diet is adventurers, but its insatiable appetite is tempered by its fear of light. No grue has ever been seen by the light of day, and few have survived its fearsome jaws to tell the tale.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1714828732
Hero Member
*
Offline Offline

Posts: 1714828732

View Profile Personal Message (Offline)

Ignore
1714828732
Reply with quote  #2

1714828732
Report to moderator
1714828732
Hero Member
*
Offline Offline

Posts: 1714828732

View Profile Personal Message (Offline)

Ignore
1714828732
Reply with quote  #2

1714828732
Report to moderator
1714828732
Hero Member
*
Offline Offline

Posts: 1714828732

View Profile Personal Message (Offline)

Ignore
1714828732
Reply with quote  #2

1714828732
Report to moderator
misterbigg
Legendary
*
Offline Offline

Activity: 1064
Merit: 1001



View Profile
March 25, 2013, 04:24:35 PM
 #2

You would probably get the most bang for your buck by first studying Hash Functions to understand what they are.
alir
Member
**
Offline Offline

Activity: 215
Merit: 11



View Profile
March 25, 2013, 06:05:16 PM
 #3

I've been doing some reading on this myself, if you understand the fundamentals of programming: https://en.bitcoin.it/wiki/Getblocktemplate is a treasure trove of information.
MysteryMiner
Legendary
*
Offline Offline

Activity: 1470
Merit: 1029


Show middle finger to system and then destroy it!


View Profile
March 25, 2013, 10:24:36 PM
 #4

It searches for such combination of block header hash and random number that when hashed two times by SHA256 will give hash that starts with equal or greater number of zeroes than required by difficulty level. Hope I got it all right and did not miss anything.

bc1q59y5jp2rrwgxuekc8kjk6s8k2es73uawprre4j
mokahless
Sr. Member
****
Offline Offline

Activity: 471
Merit: 256



View Profile
March 25, 2013, 10:38:20 PM
 #5

I keep seeing over and over that "to mine bitcoins your computer has to solve mathematical puzzels".  OK that's a little vague.  Where can I learn more about what exactly is required to generate a block and how the difficulty changes?  I wouldn't understand the code itself but a technical paper with some diagrams would be interesting.
Start with this picture:
http://spectrum.ieee.org/img/06Bitcoin-1338412974774.jpg

Then read up on the topics that interest you the most.

The-Real-Link
Hero Member
*****
Offline Offline

Activity: 533
Merit: 500


View Profile
March 26, 2013, 02:00:59 AM
 #6

Great image.  Thanks!

Oh Loaded, who art up in Mt. Gox, hallowed be thy name!  Thy dollars rain, thy will be done, on BTCUSD.  Give us this day our daily 10% 30%, and forgive the bears, as we have bought their bitcoins.  And lead us into quadruple digits
yordan (OP)
Newbie
*
Offline Offline

Activity: 14
Merit: 0


View Profile
March 26, 2013, 03:40:37 AM
 #7

I keep seeing over and over that "to mine bitcoins your computer has to solve mathematical puzzels".  OK that's a little vague.  Where can I learn more about what exactly is required to generate a block and how the difficulty changes?  I wouldn't understand the code itself but a technical paper with some diagrams would be interesting.
Start with this picture:
http://spectrum.ieee.org/img/06Bitcoin-1338412974774.jpg

Then read up on the topics that interest you the most.

That's exactly what I'm looking for but I got lost on 'nonces' and what data it's being added to to change the hash value and why.  Moving right a long though to way over simply is this the problem that's being solved:

1.) There is some existing data based on all passed transactions.

2.) Everyone collectively in the network is taking that existing data, adding a nonce to it and creating a hash - completely at random.

3.) They're looking for the hash that starts with X 0's that's created by a set of existing data plus a random nonce.  I can't tell what the character combination is exactly but looks like upper case, lower case and numbers - 62 combinations?  This means that each difficulty step can be accomplished by adding more leading 0's.  Each success leading zero is an exponential (or is it logarithmic?) step up in difficulty because it becomes 0 - 62 possible combinations 00 - 62 * 62 possible combinations 000 - 62 * 62 * 62 possible combinations and so on.

Is that right?
Nancarrow
Hero Member
*****
Offline Offline

Activity: 492
Merit: 500


View Profile
March 26, 2013, 01:33:16 PM
 #8

Kind of, but don't confuse the hash that a miner needs to find, with a bitcoin address.

A bitcoin address is the thing that looks like a string of uppercase/lowercase letters and numbers (frinstance, the one in my sig). It always starts with a 1, has (I think) 33 or 34 characters, and each character is one of 58 (not 62). 26 uppercase letters + 26 lowercase + 10 digits = 62, but four are disallowed (I think 0, O, 1 and l) and you can probably see why.

The hash is a 256-bit number, which must start with a certain number of zeroes. The more zeroes it must start with, the harder it'll be to find. Back when the difficulty level was 1, the first 32 bits had to be zero. That meant that on average you'd have to make 4 billion hashes (actually 2^32) to find a valid block header. Now the difficulty is six-million-and-change, which means the upper limit for what's a valid hash, is six million times lower than it was back in the day. So your miner has to do six million times as much work as back then.

For more info on what's actually being hashed, check out https://en.bitcoin.it/wiki/Block_hashing_algorithm

If I've said anything amusing and/or informative and you're feeling generous:
1GNJq39NYtf7cn2QFZZuP5vmC1mTs63rEW
kjj
Legendary
*
Offline Offline

Activity: 1302
Merit: 1024



View Profile
March 26, 2013, 01:39:20 PM
 #9

I keep seeing over and over that "to mine bitcoins your computer has to solve mathematical puzzels".  OK that's a little vague.  Where can I learn more about what exactly is required to generate a block and how the difficulty changes?  I wouldn't understand the code itself but a technical paper with some diagrams would be interesting.
Start with this picture:
http://spectrum.ieee.org/img/06Bitcoin-1338412974774.jpg

Then read up on the topics that interest you the most.

That's exactly what I'm looking for but I got lost on 'nonces' and what data it's being added to to change the hash value and why.  Moving right a long though to way over simply is this the problem that's being solved:

1.) There is some existing data based on all passed transactions.

2.) Everyone collectively in the network is taking that existing data, adding a nonce to it and creating a hash - completely at random.

3.) They're looking for the hash that starts with X 0's that's created by a set of existing data plus a random nonce.  I can't tell what the character combination is exactly but looks like upper case, lower case and numbers - 62 combinations?  This means that each difficulty step can be accomplished by adding more leading 0's.  Each success leading zero is an exponential (or is it logarithmic?) step up in difficulty because it becomes 0 - 62 possible combinations 00 - 62 * 62 possible combinations 000 - 62 * 62 * 62 possible combinations and so on.

Is that right?

Close.

The output of the hash is 256 bits, not an ASCII string.  Basically, the hash is a number between 0 and 115792089237316195423570985008687907853269984665640564039457584007913129639936.

The leading zero part is just because the hash must be below the target.  The target is related to the difficulty in a way that target is roughly equal to 2256-(difficulty*232).  Right now, the target is 4026319404534786334009451711043898716884778820756489262596096.

See these two pages:

https://en.bitcoin.it/wiki/Difficulty
https://en.bitcoin.it/wiki/Target

17Np17BSrpnHCZ2pgtiMNnhjnsWJ2TMqq8
I routinely ignore posters with paid advertising in their sigs.  You should too.
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!