Empty Set Dollar Cheat sheet
Epoch duration
8 hours following PIP-2 implementation.
Supply and Market Cap
Supply is the total amount of ESD tokens available (not including coupons). It is sometime identified to Market Capitalization (MC) that should in fact be the dollar value of Supply:
For clarity purpose, debt and supply will be counted in ESD tokens in this article.
TWAP
Time Weighted Average Price.
It is calculated by averaging over one epoch (8h) the time the token held a given price resulting from exchanges in the ESD/USDC Uniswap pool.
Example:
- ESD price from 0:00:00 to 2:30:00 = 1.2$
- ESD price from 2:30:00 to 6:30:00 = 1.3$
- ESD price from 6:30:00 to 8:00:00 = 1.1$
- TWAP = [(1.2$ x 2.5h) + (1.3$ x 4h) + (1.1$ x 1.5h)] / 8h = 1.23125$
Token supply expansion
If 1$ ≤ TWAP ≤ 1.03$ at the end of an epoch, the amount of tokens issued at the beginning of the next epoch for expansion is calculated as follow:
Supply expansion is currently capped at 3% of Supply per epoch if TWAP > 1.3$ following PIP-7 implementation.
Supply expansion is updated at the beginning of an epoch using Supply and TWAP at the end of the previous epoch.
Expansion rewards
Bonded ESD tokens: 80% of new ESD tokens minted at the beginning of an epoch
Bonded LP tokens (UNIv2 ESD/USDC): 20% of new ESD tokens minted at the beginning of an epoch
Debt generation
If 0.97$ ≤ TWAP ≤ 1$ at the end of an epoch, debt issued at the beginning of the next epoch is:
New debt generated is currently capped at 3% of Supply per epoch if TWAP < 0.97$ following PIP-7 implementation
Debt is updated at the beginning of an epoch using Supply and TWAP at the end of the previous epoch.
Debt cap
Debt is capped at 35% of Supply following PIP3 implementation.
Debt clearing
Debt can only be cleared in two ways
- TWAP < 1$ at the end of the previous epoch: debt can be cleared through burning ESD tokens to purchase coupons.
- TWAP ≥ 1$ at the end of the previous epoch: all residual debt is cleared as per PIP8 / EIP1
Redeeming coupons
Coupons can be redeemed 1:1 for ESD tokens once the system enters an expansion period (TWAP > 1$ at the end of the previous period).
When TWAP > 1$ at the end of the previous period, if some coupons are not redeemed, new ESD tokens emitted for expansion are sent to a debt clearing bucket. This bucket will keep accruing new ESD tokens to reach the sum of unredeemed coupons before flowing as rewards to bonded ESD and LP tokens.
Coupons expiration
Coupons expire 90 epochs after being purchased and cannot be redeemed after expiration, leading to loss of capital.
The countdown starts from the epoch of purchase (e.g. if you burn ESD tokens for coupons on epoch 180, your coupons can be redeemed until epoch 269 included).
Coupons bought at different epochs would have different expiration dates related to the respective epoch of purchase.
Premium calculation for coupon purchase
Coupons purchases follow a bonding curve for a premium according to the following formula:
where R is the current Debt ratio:
The premium bonding curve is an incentive for ESD holders to clear debt accumulated by the system by burning their ESD tokens, hence decreasing the Supply.
It is important to note that Premium is not directly related to TWAP but to Debt accumulated by the system.
Premium and coupons calculations
If a user burns n ESD tokens to clear debt for coupons, the system reach a new debt ratio R’ such as:
The average premium the user would get for burning n ESD tokens can be calculated as follow:
One can estimate the amount of coupons obtained through burning n ESD tokens as follow: