So I’ve been reading about how the nonce is calculated. There is one part that I don’t get. So there is a mempool, and each node (or mining node) takes a part (or the whole part) of that mempool, computes a merkle root and combines it with a nonce to get a hash that has a certain difficulty level.

Is the mempool (or part of it) is first converted to a hash by the mining software, then enters the nonce calculation?

Are there requirements on how the transactions are ordered when mining a block?

Can nodes choose the order of transactions in a block? Is a node free to choose any order of the transactions that it wants or must it be chosen chronologically?

(feel free to edit the question, I tried to explain it the best I could)

Recent Questions – Bitcoin Stack Exchange