Skip to content

Commit

Permalink
update target rewards calculations
Browse files Browse the repository at this point in the history
  • Loading branch information
cyberphysic4l committed Feb 15, 2024
1 parent 9ddcd13 commit d47dc73
Showing 1 changed file with 9 additions and 15 deletions.
24 changes: 9 additions & 15 deletions tips/TIP-0040/tip-0040.md
Original file line number Diff line number Diff line change
Expand Up @@ -564,17 +564,11 @@ The following section specifies how to convert the slot-level data into epoch-le

#### Parameters needed for calculations:

- `Bootstrapping Duration` = 1154 (approximately 3 years)
- `Mana Share Coefficient` = 2 (relative to the term $\theta/(1-\theta)$ from the _IOTA 2.0 Incentives and Tokenomics
Whitepaper_, with $\theta = 2/3$)
- `Final Reward = (Total Supply * Mana Share Coefficient * Generation Rate) >> (Generation Rate Exponent - Slots Per Epoch Exponent)`.
- `Bootstrapping Duration` = 1154 epochs (approximately 3 years)
- `Reward To Generation Ratio` = 2 (the ratio of final target rewards rate to Mana generation rate)
- `Final Target Rewards Rate = (Total Supply * Reward To Generation Ratio * Generation Rate) >> (Generation Rate Exponent - Slots Per Epoch Exponent)`.
- This is the constant reward per epoch after the bootstrapping phase.
- `Decay Balancing Constant` is an integer approximation of $2^{\text{Decay Balancing Constant Coefficient}}\frac{e
\Delta}{T(1-\exp{(-\beta \Delta)})}$, for $Delta =$ epoch duration in years, $T=$ `Bootstrapping Duration`, and
$\beta=1/3$.
- This is the parameter to calculate the reward per epoch in the bootstrapping phase.
- For `Decay Balancing Constant Coefficient = 8`, `Decay Balancing Constant = 696`.
- `Initial Reward = (Final Reward * Decay Balancing Constant) >> Decay Balancing Constant Coefficient`.
- `Initial Target Rewards Rate = Final Target Rewards Rate / ((Annual Decay Factor Percentage / 100) ^ Bootstrapping Duration In Years)`.
- `Pool Coefficient Exponent = 11`.

#### Input values
Expand All @@ -589,9 +583,9 @@ The following section specifies how to convert the slot-level data into epoch-le

#### Calculations

- The total target reward `Target Reward(n)` for an epoch index `n` is defined as:
- `Initial Reward * Decay(n)` if `n <= Bootstrapping Duration`.
- `Final Reward` if `n > Bootstrapping Duration`.
- The total target rewards rate `Target Rewards Rate(n)` for an epoch index `n` is defined as:
- `Initial Target Rewards Rate * Decay(n)` if `n <= Bootstrapping Duration`.
- `Final Target Rewards Rate` if `n > Bootstrapping Duration`.
- The Pool Reward `Pool Reward` for an epoch index `n`, and pool `i` is calculated as follows:
- Let `Pool Coefficient` be
`((Pool Stake(i) << Pool Coefficient Exponent)/Total Stake) + (Validator Stake(i) << Pool Coefficient Exponent) / Total Validator Stake`.
Expand All @@ -600,8 +594,8 @@ The following section specifies how to convert the slot-level data into epoch-le
`Pool Coefficient Exponent + 1` bits.
- Take the `Epoch Performance Factor` for the whole epoch `n` according to
[Epoch Performance Factor](#epoch-performance-factor).
- Let `Scaled Pool Reward` be `Pool Coefficient * Target Reward(n) * Epoch Performance Factor`.
- Since `Pool Coefficient` uses at most 12 bits, `Target Reward(n)` uses at most 41 bits, and
- Let `Scaled Pool Reward` be `Pool Coefficient * Target Rewards Rate(n) * Epoch Performance Factor`.
- Since `Pool Coefficient` uses at most 12 bits, `Target Rewards Rate(n)` uses at most 41 bits, and
`Epoch Performance Factor` uses at most 8 bits, this multiplication will not overflow using uint64 variables.
- Finally, `Pool Reward` will be
`((Scaled Pool Reward/Validation Blocks Per Slot) >> (Pool Coefficient Exponent + 1))`. Note that if this value is
Expand Down

0 comments on commit d47dc73

Please sign in to comment.