2

I know that miners have freedom to choose transactions from memory pool,

Let say there are 5 transactions Tx1 Tx2 Tx3 Tx4 and Tx5 in memory pool,

There are 3 miners M1 M2 and M3

M1 has created block with Tx1 Tx2 and Tx3

M2 has created block with Tx2 Tx3 and Tx4

M3 has created block with Tx2 and Tx5

==

M1 successfully solves the block and get reward in terms of bitcoin and transaction fee

at same time M2 and M3 successfully solves the block, In this case, will M2 and M3 gets reward and transaction fee? as Tx2 was already part of M1's block which was already confirmed.

2

No, the blocks from M2 and M3 will most likely end up being discarded. The reason being that as soon as M1 broadcasts its block most miners will drop their current block and start trying to solve the next one.

There's nothing to stop M2 and M3 broadcasting their blocks after M1 in the hope that they will also be able to generate the next block and take over the longest chain. The problem is that these days the cost of generating a block is in the 10's of thousands of dollars in electricity so it's an expensive gamble to try and solve two blocks in a row.

And in answer to your main question if a transaction that's already included in a block appears in a subsequent block then the new block will be rejected as invalid by full nodes and other miners.

  • What will happen to Tx4 and Tx5 in this case ? as blocks by M2 and M3 are rejected. – Rizstien Mar 8 at 8:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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