Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Q4. Mining (18 points] The hash target is used in mining. It is a number that a block hash must be below for the block
Q4. Mining (18 points] The hash target is used in mining. It is a number that a block hash must be below for the block to be valid in order for it to be added on to the blockchain. Assume that the hash target is 256=249. In other words, each block hash has to start with 8 zeros (as the most significant bits). To hash a block, the fields are concatenated in the same order. For example, the "Current Block Hash" for the block with ID=1 is the hash of the value "1002262 Ahmad". a. [6 points Fill replace "???" by appropriate values to make the blockchain a valid one. Head Hash: 297 Head Pointer: 4 Pres: ID Prey Hash Nonce ??? ??? Hessa ??? Data Current Block Hash Pues ID Prey: Hash Nonce 001ecdf2e0b2b7b7c51701385d99d58eaeccbabea16061a0ef2cfb91f6308336 ??? Islam ??? Data Current Block Hash ID A null Pres: ID Pres: Hash Nonce Data Current Block Hash 2261 Ahmad 001ecdf2e0b2b7b7c51701385d99d58eaeccbabea16061a0ef2cfb91fb308336 b. [6 points) Find the average time for mining a block for each of the following hash targets. Measure the time in terms of both the number of hash computations as well as in seconds on your machine. Report your results as an average for mining 10 different blocks. Fill the table below. 1. Hash target = 28 2. Hash target = 212 3. Hash target = 216 Hash Target Average number of hash computations to mine a block (average over 10 blocks) Average time in seconds to mine a block (average over 10 blocks) 28 = 256 212 = 4,096 216 = 65,536 Q4. Mining (18 points] The hash target is used in mining. It is a number that a block hash must be below for the block to be valid in order for it to be added on to the blockchain. Assume that the hash target is 256=249. In other words, each block hash has to start with 8 zeros (as the most significant bits). To hash a block, the fields are concatenated in the same order. For example, the "Current Block Hash" for the block with ID=1 is the hash of the value "1002262 Ahmad". a. [6 points Fill replace "???" by appropriate values to make the blockchain a valid one. Head Hash: 297 Head Pointer: 4 Pres: ID Prey Hash Nonce ??? ??? Hessa ??? Data Current Block Hash Pues ID Prey: Hash Nonce 001ecdf2e0b2b7b7c51701385d99d58eaeccbabea16061a0ef2cfb91f6308336 ??? Islam ??? Data Current Block Hash ID A null Pres: ID Pres: Hash Nonce Data Current Block Hash 2261 Ahmad 001ecdf2e0b2b7b7c51701385d99d58eaeccbabea16061a0ef2cfb91fb308336 b. [6 points) Find the average time for mining a block for each of the following hash targets. Measure the time in terms of both the number of hash computations as well as in seconds on your machine. Report your results as an average for mining 10 different blocks. Fill the table below. 1. Hash target = 28 2. Hash target = 212 3. Hash target = 216 Hash Target Average number of hash computations to mine a block (average over 10 blocks) Average time in seconds to mine a block (average over 10 blocks) 28 = 256 212 = 4,096 216 = 65,536
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started