Bitcoin Gold claimed to have per-block difficulty adjustment, how does it work? I find this https://github.com/BTCGPU/BTCGPU/pull/151, but still don't understand how it work by change some parameters.


It's just a simple moving average with a window of 30 blocks:

next_D = sum(past 30 D) / sum(past 30 solvetimes) * 600

This isn't exactly what it's doing, but it's darn close.

| improve this answer | |
  • Thank you. Is this fomula calculated every blocks? And why is 600? – Anderson Nov 19 '17 at 7:31
  • Time is calculated in terms of millisecond i believe – VforVendetta Sep 20 '18 at 12:47

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.