Blocks in Bitcoin Blockchain

Hi Everyone

i was so confused about how the blocks work and Function in Bitcoin blockchain i’ve many questions and i want if someone here has a good knowledge in blockchain to answer my questions ?

:slightly_smiling_face:

1- is the blocks can only contains one transaction or more ?

2- we know that the miners doing calculation through POW ? is it the same calculation of the hash tx ?

3- is the block that is created by a miner doesn’t valide untill it is validated by all the miners in the network ? is that correct ? and how it is considered as a valide block ?

4- is every miner considered as Node in Bitcoin Network ?

No One wants to answer my questions :neutral_face::face_with_raised_eyebrow::thinking: ?

Hi,

Hopefully this video will be useful to you.
This is a starting point but should hopefully clarify a few things.

1 Like

Hey @ansdb,

I am a newbie too so please take all of this with a grain of salt!

  1. Blocks can contain more than 1 transaction.

  2. My understanding is that miners are spending electricity to essentially guess a number (which is very difficult to guess, much like a lottery) to decide who gets to create the next block; whereas the hash tx is a form of id for the block (a string of transactions).

  3. A block is valid after a certain point, on exchanges there is a minimum amount of excepted confirmations before it will be accepted, due to the unlikelihood of it being reversed after the aforementioned point.

  4. Miners and nodes are not the same thing at all. Miners are there for cryptographic protection through POW and receive mining rewards and transaction fees from the network as a reward for there efforts and energy spent, whereas nodes are responsible for sharing and amending the entire blockchain in a way that maintains consensus throughout.

I hope this helps! Good luck.

1 Like

thanks a lot @Kakurat for your help i really appreciate it :grinning: :slightly_smiling_face:

1 Like

You’re welcome! :smile:

1 Like

1- is the blocks can only contains one transaction or more ?
Blocks can contain as many transactions as the 1MB block size allows. Usually Miners will add transactions to the proposed block until the 1MB size is filled, in order to collect the maximum transaction fees possible.

2- we know that the miners doing calculation through POW ? is it the same calculation of the hash tx ?
No, it is not the same. What miners do within the POW is following:

  1. They hash all the transactions they have added to the proposed block obtaining a No.
  2. Then they generate a random no also called a nonce. This nonce is then hashed together with the above obtained hash. They repeat step 2 until the obtained hash is smaller or equal to the network difficulty target. As the hasing process is non deterministic they literally try as many combinations as they can. (brute force). That’s why the miners computing power is measured as Hashes/second. (actually TH/s - terahash per second).
    The network aims at an average block generation time of 10min. So it will adjust the difficulty target , up (means easier to guess) or down (harder to guess) depending on how the miners perform

3- is the block that is created by a miner doesn’t valide untill it is validated by all the miners in the network ? is that correct ? and how it is considered as a valide block ?
Once a new valid block has been created by a miner it is distributed in the network by the nodes. As the network is a world wide network and it takes some time for all nodes to be in sync it can happen that more miners manage to propose valid blocks and there are several proposed blockchain ledgers passed around. In this case there is a “temporary network split”. As more blocks are being produced on version of the blockchain ledger will be mined faster and therefore will be longer than the others. The network takes this into consideration and will always accept the longest chain and discard all the others. Usually it is considered that a transaction is valid (permanent) when it is hashed in to a block that has other 3-4 blocks already stacked upon it and the risk of this chain being discard in favor of a longer one is considered to be minimal.

4- is every miner considered as Node in Bitcoin Network ?
No. Miners and nodes are different. Miners are responsible for block creation, though POW and thus adding the valid transactions to the blockchain ledger making them permanent. Nodes are responsible for maintaining the network. They validate the created blocks, they store the entire ledger and distribute it throughout the network, they acknowledge transactions and create a list of all pending valid transactions for the miners to get.

I hope this helps.

1 Like