Occupied with validating algorithm for calculating hashrate from stratum messages.
From my understanding following knowledge is required:start_timeĀ , time when miner began calculatingend_time, time when share from miner was discoveredproblem, set by the mining pool
System for calculating hashrate(discovered on-line) is:hashrate = problem * 2**32 / (end_time - start_time)
Instance:problem is 131072 from {"id":null,"methodology":"mining.set_difficulty","params":[131072]}(end_time - start_time) is 8.844114780426025 from one actual take a look at instance
Calculation:131072 * 2**32 / 8.844114780426025131072 * 4294967296 / 8.844114780426025562949953421312 / 8.844114780426025
Hashrate: 63652492917351.58 or round 63 Th/s
Questions:
- Is that this right ?
- What’s 2**32 ? (suspect that it’s related to nonce in block header)