4

I am trying to understand the block hashing algorithm used to generate block.

One of the points mentioned here is

it is (nearly) impossible for two people to have the same Merkle root because the first transaction in your block is a generation "sent" to one of your unique Bitcoin addresses.

How do I specify my unique address? Does it depend on what kind of miner I use and whether I mine in a pool?

Also what is "generation" and how is it different from other transactions that include transfers of bitcoins? What other transactions are included in the Merkle root?

1 Answer 1

3

How do I specify my unique address?

You don't need to. Bitcoin will add the coinbase transaction automatically.

Does it depend on what kind of miner I use

No.

and whether I mine in a pool?

Yes, because then the pool gives you a block header to mine, which includes their coinbase transaction. If you put in your own coinbase header, then the pool will reject your shares.

Also what is "generation" and how is it different from other transactions that include transfers of bitcoins?

Just like a normal transaction, it specifies how the money can be spent, but unlike normal transactions, it doesn't need to provide any inputs. However, the amount transferred must be equal to the total transaction fees plus the block subsidy.

What other transactions are included in the Merkle root?

Every valid transaction that your bitcoin client knows about is included.

I suppose that the pool gives different headers which include different transactions to pool members. Right?

I'm not sure what you mean by that - the coinbase transaction is different, because the pool doesn't want multiple miners to duplicate work. But in all cases, the coinbase transaction gives the bitcoins to the pool. Actually solving a block is worth just as much to the individual miner as solving a share.

What happens to the transactions that are not included. Are they included in future blocks?

Sometimes. Maybe those transactions are forgotten. It's called the "memory pool" for a reason - it's forgotten on shutdown.

4
  • I suppose that the pool gives different headers which include different transactions to pool members. Right? Maybe that should be a different question but what happens to the transactions that are not included. Are they included in future blocks?
    – kon psych
    Commented Feb 17, 2013 at 18:20
  • @konpsych I edited my answer to add your questions.
    – Nick ODell
    Commented Feb 18, 2013 at 0:23
  • I did not realise that the coinbase transaction is different although it is given by the pool. However, even if the transactions are forgotten by my memory pool are they lost? I thought the purpose of mining is to organise all the transactions into blocks. Am I missing something?
    – kon psych
    Commented Feb 18, 2013 at 10:21
  • @konpsych This is by design. Transactions that don't make it into a block will eventually be forgotten.
    – Nick ODell
    Commented Feb 18, 2013 at 16:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.