TIL - How Much Witnesses and Miners Make Per Block

Prior to HF 16, the witness pay was simple. Each block mined = 1 STEEM. After HF 16, it got a lot more complicated..

HF 16 made the following changes to the witness pay:

  • The block production pay was reduced.
  • The payout per block became different depending on if you were a top-19 witness, backup witness, or miner.
  • The payout per block became a dynamic calculation based on the current inflation rate and (virtual) supply of STEEM.

Since the amount was no longer easy to determine, GitHub issue 832 was opened to make the witnesses payouts visible. This would be useful, but in the meantime I decided to calculate it by hand.

This is how much STEEM is paid per block, given the current inflation rate and virtual supply of STEEM:

Disclaimer: These numbers were calculated by hand and are subject to error. I did my best to ensure their accuracy, but please double check everything if you plan to use these numbers for anything important. Also, these calculations are made based on the current inflation rate and virtual supply of STEEM. The numbers will change over time as the supply of STEEM and the inflation rate change.

A few other notes:

  • A new block is produced every 3 seconds.
  • Every 21 blocks, each of the top 19 witnesses, one backup witness, and one miner will produce a block.
  • Payments are made as Steem Power.

Ok, now for the nerdy part. Here is all the code/math.

Code:

uint8_t top19_weight = 1;
uint8_t timeshare_weight = 5;
uint8_t miner_weight = 1;

_wso.witness_pay_normalization_factor =
   _wso.top19_weight * num_elected
 + _wso.miner_weight * num_miners
 + _wso.timeshare_weight * num_timeshare;

/**
* At block 7,000,000 have a 9.5% instantaneous inflation rate, decreasing to 0.95% at a rate of 0.01%
* every 250k blocks. This narrowing will take approximately 20.5 years and will complete on block 220,750,000
*/
int64_t start_inflation_rate = int64_t( STEEMIT_INFLATION_RATE_START_PERCENT );
int64_t inflation_rate_adjustment = int64_t( head_block_num() / STEEMIT_INFLATION_NARROWING_PERIOD );
int64_t inflation_rate_floor = int64_t( STEEMIT_INFLATION_RATE_STOP_PERCENT );

// below subtraction cannot underflow int64_t because inflation_rate_adjustment is <2^32
int64_t current_inflation_rate = std::max( start_inflation_rate - inflation_rate_adjustment, inflation_rate_floor );

auto new_steem = ( props.virtual_supply.amount * current_inflation_rate ) / ( int64_t( STEEMIT_100_PERCENT ) * int64_t( STEEMIT_BLOCKS_PER_YEAR ) );
auto content_reward = ( new_steem * STEEMIT_CONTENT_REWARD_PERCENT ) / STEEMIT_100_PERCENT; /// 75% to content creator
auto vesting_reward = ( new_steem * STEEMIT_VESTING_FUND_PERCENT ) / STEEMIT_100_PERCENT; /// 15% to vesting fund
auto witness_reward = new_steem - content_reward - vesting_reward; /// Remaining 10% to witness pay

const auto& cwit = get_witness( props.current_witness );
witness_reward *= STEEMIT_MAX_WITNESSES;

if( cwit.schedule == witness_object::timeshare )
    witness_reward *= wso.timeshare_weight;
else if( cwit.schedule == witness_object::miner )
    witness_reward *= wso.miner_weight;
else if( cwit.schedule == witness_object::top19 )
    witness_reward *= wso.top19_weight;

witness_reward /= wso.witness_pay_normalization_factor;

Based on the code above, here are the calculations:

Pre-weighted per block witness pay:

STEEMIT_BLOCKS_PER_YEAR = 365*24*60*60/3 = 10,512,000
current_virtual_supply = 248,954,830 STEEM
current_inflation_rate = .0942
new_steem = 248,954,830 * .0942 / 10,512,000 = 2.2309
witness_reward = .1 * 2.2309 = .22309

[Edit] Thanks to @abit for pointing out that the current inflation is 9.42% (not 9.5%).

Weighted per block witness pay:

witness_pay_normalization_factor = (1 * 19) + (1 * 1) + (5 * 1) = 25
backup = .22309 * 5 * 21 / 25 = .9370 STEEM
miner = .22309 * 1 * 21 / 25 = .1874 STEEM
top19 = .22309 * 1 * 21 / 25 = .1874 STEEM

Here are the results:

  • Top 19 Witnesses: 0.1874 STEEM per block
  • Backup Witnesses: 0.9370 STEEM per block
  • Miners: 0.1874 STEEM per block

Reminder to read the disclaimer above if you plan to use these numbers for anything important.


Reminder to vote for witnesses!
https://steemit.com/~witnesses
If you aren't sure who to vote for, check out this Witness Voting Guide.

H2
H3
H4
3 columns
2 columns
1 column
27 Comments