Implement mining slow start with a linear ramp
This commit is contained in:
@@ -14,6 +14,20 @@ namespace Consensus {
|
||||
*/
|
||||
struct Params {
|
||||
uint256 hashGenesisBlock;
|
||||
/** Needs to evenly divide MAX_SUBSIDY to avoid rounding errors. */
|
||||
int nSubsidySlowStartInterval;
|
||||
/**
|
||||
* Shift based on a linear ramp for slow start:
|
||||
*
|
||||
* MAX_SUBSIDY*(t_s/2 + t/r) = MAX_SUBSIDY*t_h Coin balance
|
||||
* t_s + t_r = t_h + t_c Block balance
|
||||
*
|
||||
* t_s = nSubsidySlowStartInterval
|
||||
* t_r = number of blocks between end of slow start and first halving
|
||||
* t_h = nSubsidyHalvingInterval
|
||||
* t_c = SubsidySlowStartShift()
|
||||
*/
|
||||
int SubsidySlowStartShift() const { return nSubsidySlowStartInterval / 2; }
|
||||
int nSubsidyHalvingInterval;
|
||||
/** Used to check majorities for block version upgrade */
|
||||
int nMajorityEnforceBlockUpgrade;
|
||||
|
||||
Reference in New Issue
Block a user