Each pair is configured to change interest rates as a function of Utilization. Utilization is the total amount of deposited assets which have been lent to borrowers. Fraxlend currently has two interest rate models available for use:
- 1.The Linear Rate
- 2.Time-Weighted Variable Rate
- 3.Variable Rate V2
The Linear rate is a configurable function that allows for two linear functions of the form
y = mx +b. The function takes parameters which are defined at the time the Pair is created.
Minimum Rate: Rate when Utilization is 0% Vertex Rate: Rate when utilization is equal to vertex utilization (i.e when the two slopes meet) Vertex Utilization: The Utilization % where the two slopes meet Maximum Rate: Rate when Utilization is 100%
These configuration values are immutable and fixed at time of Pair creation.
The Interest Rate is calculated using the following formulae:
If Utilization Rate is equal to Vertex Utilization then:
If Utilization Rate is less than Vertex Utilization then:
If Utilization Rate is greater than Vertex Utilization then:
The Time-Weighted Variable Interest Rate adjusts the current rate over time. The variable interest rate is configured with a half-life value, given in seconds, which determines how quickly the interest rate adjusts.
Minimum Rate: Minimum Rate to which interest can fall Target Utilization Range: The Utilization Range where the interest rate does not adjust, it is considered in equilibrium with the market expectations. Maximum Rate: Maximum Rate to which interest can rise Interest Rate Half-Life: The time it takes for the interest to halve when Utilization is 0%. This is the speed at which the interest rate adjusts. In the currently available Rate Calculator, the Interest Rate Half-Life is 12 hours.
The Time-Weighted Variable Interest Rate allows the market to signal the appropriate interest rate.
When Utilization is below the target range, the interest rate lowers, this encourages more borrowing and lenders to pull their capital, both of which push the Utilization Rate back into the target range.
When Utilization is above the target range, the interest rate increases which encourages more lending and less borrowing, bringing the Utilization back towards the target range. Encouraging participants to borrow or lend as a function of both time and utilization.
The following graph shows how the interest rate changes when the Interest Rate Half-Life is 4 hours, with a Target Utilization Range of 75% - 85%:
This allows the market, not the pair creator, to decide the appropriate interest rate of a given asset-collateral pair, the pair creator only needs to provide a target utilization.
The Variable Rate V2 Interest Rate combines the concepts from the Linear Interest Rate and the Time-Weighted Variable Interest Rate. Specifically, it utilizes the linear function from the Linear Interest Rate to determine the current rate, but adjusts the vertex and max rate utilizing the formula from the Time-Weighted Variable Interest Rate.
Just like the Time-Weighted Variable Interest Rate, the Variable Rate V2 takes a half-life and target utilization parameters. When utilization is low, the Vertex and Max Rate will decrease. If utilization is high, the Vertex and Max Rate will increase. The rate of the decrease/increase is determined by both the utilization and half-life. If utilization is 0% the Vertex and Max Rates will decrease by 50% each half-life. If the utilization is 100%, the increase will be 100% per half-life. This means that interest rates will immediately respond to changes in utilization along the linear rate curve while at the same time adjusting to market conditions over the long term by scaling the slope of the linear rate curve.