Skip to content

Validator Economy

Michael Kong edited this page May 4, 2022 · 3 revisions

Validator - Economy

In this wiki, we may use event and event block interchangeably. Do not confuse event block and block - those are different terms.

Economy scores

A validator's reward is weighted by 2 independent numbers: transactions reward weight and base reward weight.

  • transactions reward weight: share of transaction fees that the validator will receive at the end of epoch.
  • base reward weight: share of base reward (newly minted coins) that validator will receive at the end of epoch.

Reward weights are calculated at the end of each epoch using the formulas below:

  • transactions reward weight = originated fee * uptime
  • base reward weight = stake * (uptime ^ 2)

where:

  • stake is the sum of delegations to validator (including validator's self-delegation)
  • uptime is the total number of nanoseconds the validator was online in the epoch (i.e. was creating events). It's also called validation score.
  • originated fee is the total fees of transactions that the validator originated in the epoch ("originated" means "included into event"). It's also called origination score.

A list of properties which may be concluded from formulas:

  • originated fee may be roughly estimated as stake share * uptime * network fee per nanosecond. If we substitute estimation into transactions reward weight formula, then we'll get (stake share * uptime * network fee per nanosecond) * uptime.
  • Uptime influences reward non-linearly. If a validator has 50% uptime in epoch, then he'll receive ~4 times smaller rewards in that epoch.
  • stake influences base reward linearly, and influences transactions reward weight linearly on average.

Rewards distribution

Rewards distribution is fully controlled by the SFC contract. It's worth to mention that the SFC contract can be upgraded by the governance contract at any time without hardfork.

30% of transaction fees are burned. All transaction fees get burnt inside block processing, but the amount of fees for an epoch is sent to the SFC contract. The SFC contract adds 70% of burnt fees to rewards. The remaining 70% of transaction fees are distributed between validators proportional to their transactions reward weight.

Note that all transaction fees get burnt inside block processing, but the amount of fees for an epoch is sent to the SFC contract. The SFC contract adds 70% of burnt fees to rewards. While settling a reward, SFC contract mints the rewards(it has an authority to do so via NodeDriver) which is equal to 70% of the original transaction fee.

Base rewards = epoch duration in second * base reward per second. Base reward per second is controlled by the SFC contract.

Base rewards are distributed between validators proportional to their base reward weight.

Reward between validator and his delegators is distributed proportional to their stake, with exception that delegator pays 15% of his rewards to validator (as a validator commission).

Downtime

Downtime is calculated as a difference time of last block-time of last block where validator had at least 1 event.

Downtime has 2 numbers: number of missed blocks and time of missed blocks. If validator missed not more than 50 blocks, then downtime should be interpreted as 0, because it may be possible that validator has a right to emit events slower than other validators.

Uptime in an epoch is calculated differently. It's reset to 0 every epoch, and during processing of i'th block, uptime is incremented by block[i].time-block[i - min(number of missed blocks, 50)].time.

According to the formulas above, missing of no more than 50 blocks in a raw doesn't affect uptime.

If validator has downtime >= 72 hours (but not less than 1000 blocks), then he's permanently pruned from validators list. In this case, validator and delegators have to withdraw their stake via SFC contract using the withdrawal procedure.