2

Reading about the proof of work, I got to the data generation part (mainly the DAG) and found it in:

~/.ethash/full-R23-0000000000000000

In the ethash it is mentioned that the DAG is generated from a seed, then a 16 MB cache and finally a 1 GB data set. When I ran geth and pyethapp as part o f a private network a new DAG was not generated meaning that the one that the one in the home directory has been used.

Why? Isn't the DAG supposed to be uniquely generated from a seed and then based on block header data, namely the nonce and the mixhash which in this case would be the ones in the custom genesis block?

  • I have the idea that the DAG generates a dataset that only depends on the blockNumber (the part that is in ~/.ethash) and doesn't depend on the network. But the actual calculation of the POW does require network information and the dataset. – Ismael Jun 13 '16 at 18:28
  • But then this implies that there is no information in any custom genesis block so that a DAG corresponding from it differs to another corresponding to a genesis block that's different in at least one field from the first, no? So the DAG is the same for all blocks. What I understood from the algorithm is that you take a seed and hash it recursively to a given length. From there you rehash it a few times (no. of rounds), but this time you hash chunks of the first hash set at random (the index of the chunk is part of the chunk which is uniformly random) – Sebi Jun 13 '16 at 19:01

Your Answer

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

Browse other questions tagged or ask your own question.