You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The function CollateralRegistry._getUpdatedBaseRateFromRedemption calculates the base rate from the share of bold tokens that are redeemed.
// get the fraction of total supply that was redeemed
uint256 redeemedBoldFraction = _redeemAmount * DECIMAL_PRECISION / _totalBoldSupply;
As the redeemedBoldFraction is rounded down, splitting a redemption into multiple smaller ones can reduce the fee paid. The most extreme case are redemptions with redeemAmount < totalBoldSupply / 1e18, which will have their fraction rounded to zero, meaning they will not increase the base rate at all. However, multiple redemptions will incur higher gas costs.
The text was updated successfully, but these errors were encountered:
For “the most extreme case”, assuming a total supply of 10B (1e10 * 1e18), the redeem amount would be 1e10 wei, i.e. 1e-8 BOLD. It doesn’t make sense to redeem such amount, as the amount paid in gas would be much higher.
The function
CollateralRegistry._getUpdatedBaseRateFromRedemption
calculates the base rate from the share of bold tokens that are redeemed.As the redeemedBoldFraction is rounded down, splitting a redemption into multiple smaller ones can reduce the fee paid. The most extreme case are redemptions with
redeemAmount < totalBoldSupply / 1e18
, which will have their fraction rounded to zero, meaning they will not increase the base rate at all. However, multiple redemptions will incur higher gas costs.The text was updated successfully, but these errors were encountered: