Last updated 5 months ago
M^0 Project
Legal
Copyright 2024 M^0 Foundation
earnerRateModel.rate()earnerRateModel.rate()earnerRateModel.rate()
Returns current earner rate in basis points: P1∗er1∗t−P1=P2∗er2∗t−P2P1 * e^{r1 * t} - P1 = P2 * e^{r2 *t} - P2P1∗er1∗t−P1=P2∗er2∗t−P2
If totalActiveOwedM<=totalEarningSupplytotalActiveOwedM <= totalEarningSupplytotalActiveOwedM<=totalEarningSupply, r2=minterRate∗totalActiveOwedM/totalEarningSupplyr2 = minterRate * totalActiveOwedM / totalEarningSupplyr2=minterRate∗totalActiveOwedM/totalEarningSupply,
Otherwise, calculates equilibrium rate P1∗er1∗t−P1=P2∗er2∗t−P2P1 * e^{r1 * t} - P1 = P2 * e^{r2 *t} - P2P1∗er1∗t−P1=P2∗er2∗t−P2 r2=ln(1+(P1∗er1∗t−P1)/P2),r2 = ln(1 +( P1 *e^{r1 * t} - P1) / P2), r2=ln(1+(P1∗er1∗t−P1)/P2), P1=totalActiveOwedMP1=totalActiveOwedMP1=totalActiveOwedM, P2=totalEarningSupplyP2=totalEarningSupplyP2=totalEarningSupply, t=confidence intervalt=confidence\;intervalt=confidenceinterval
Returns min(baseEarnerRate,MULTIPLIER∗r2)min(baseEarnerRate,MULTIPLIER * r2)min(baseEarnerRate,MULTIPLIER∗r2), where baseEarnerRatebaseEarnerRatebaseEarnerRate and minterRateminterRateminterRate are APY in basis points.