Steembottracker.com (by ) has a wonderful tool where we can calculate the curation rewards. This tool shows us how much we will receive if we already voted a post or if we are attempting to vote right now. Additionally, it includes a slider to define hypothetical post payouts, which also influences the curation rewards.
The heart of this calcultor is the following formula:

where P0 is the payout before you vote, P1 is the payout after you vote, v is the value of the vote, PT is the payout after 7 days, and t is a value between 0 and 1 in function to the rule of 30 minutes.
This formula works very well in most cases, however, it is not perfect, it has 3 problems that I describe below:
The best way to calculate the curation rewards is following the same steps that the blockchain uses. Every vote contributes with an amount of r-shares (shares in the reward pool), and the total payout represents the STEEM reserved for the sum of all r-shares of the votes (including negative votes).
Let
where f(x) is the approximated square root used in Steem. Additionally, if the curator votes within the first 30 minutes of publication part of his earnings go to the author and it is proportional to the remaining time to complete the 30 minutes.
25% of the total payout goes to curators. Each curator receives a percentage of this amount regarding his contribution with respect all curation contributions:
where
Then, the above formula is the correct calculation for each curation, and the one I have implemented in the code
(Note that if we assume that there are no downvotes or changes on votes, and that f(x) is the exact square root, then we get the formula shown at the beginning of the post).
As I mentioned before, the root square used in the Steem Blockchain uses simple bit to bit operations to approximate it. These operations are: OR, AND, SWIFTLEFT, and SWIFTRIGHT. However, it is based on 64-bit numbers and JavaScript only supports bit operations on 32-bit numbers.
For this reason, I coded a set of functions for bit operations on 64-bit numbers in order to implement the same square root used in Steem.
The pull request of this new code was accepted and merged by the owner .
| Name | Link |
|---|---|
| Github repository | https://github.com/MattyIce/bottracker |
| Commit | 9077ef6aef39359dc02b2166adf7a4663ddb42ed |
| Pull Request and Merge | https://github.com/MattyIce/bottracker/pull/35 |
| Web | https://steembottracker.com/curation_calculator.html |