private static long fakeBlockNum(final long parentNum, final long fakeBlockOffset) {
    final long fakeBlockNumber;
    if (Long.compareUnsigned(parentNum, fakeBlockOffset) >= 0) {
      fakeBlockNumber = parentNum - fakeBlockOffset;
    } else {
      fakeBlockNumber = 0L;
    }
    return fakeBlockNumber;
  }
Provides the various difficultly calculates used on mainnet hard forks.
ethereum/core/src/main/java/org/hyperledger/besu/ethereum/mainnet/MainnetDifficultyCalculators.java