Determining which ticks to borrow from
When a user seeks to obtain leverage in Limitless, the system selects specific ticks from which to borrow. This selection via our indexing algorithm is designed to ensure LPs' solvency in any market conditions. Limitless's innovative approach to utilizing discretized ticks and an indexing algorithm allows a streamlined process for one to obtain leverage from order books like AMMs.
Necessity of Discretization
The discretization of liquidity positions is pivotal for two key reasons:
Efficient Indexing: The system must efficiently identify tick ranges that fulfill solvency criteria,
Computational Efficiency: Discretizing tick ranges streamlines the process of tracking, managing, and adjusting borrowed and repaid liquidity.
Example Scenario
A trader wants a 20x long position on ETH, at the current price of 2000 USD/ETH. In this case, the indexing algorithm says the trader should ideally be borrowing from the 1900-1910 and 1910-1920 USD bins.
If liquidity is available across a broader range, say 1800-2200 USD, the lending process would involve: a. Withdrawing liquidity from 1800-2200 USD. b. Lending liquidity within the 1900-1910 and 1910-1920 USD ticks. c. Reproviding liquidity in segmented positions (1800-1900, 1900-1910, 1910-1920, 1920-2200 USD), since liquidity is no longer uniform in 1800-2200.
This naive approach is more computationally demanding than just withdrawing and lending from the 1900-1910 and 1910-1920 ticks
Indexing Algorithm
Therefore Limitless uses an algorithm that, given a collateral amount and a desired leverage, will output one or more ticks that
ensure LPs' solvency(more information below)
cumulatively equate to the borrowed amount while satisfying the solvency criterion.
minimizes the premiums quoted to borrowers(more information below)
The indexing algorithm determines which discretized tick ranges(bins) to borrow from, given desired leverage and collateral amount.
Ensuring LP Solvency
Every debt originated in Limitless begins overcollateralized. However, as price fluctuates, the system needs to ensure the LPs are always made whole, or that the LP's loss is capped by his impermanent loss. This is achieved by enforcing the collateral amount to be greater than or equal to what the LP would expect for his liquidity to be converted to.
For all borrowed ticks i, this is represented via enforcing the invariant below;
Borrowing token y with token x as collateral, the system necessitates collateralAmount_x
when debt amount in token y is
Borrowing token x with token y as collateral, the system necessitates collateralAmount_y
when debt amount in token x is
and where L_i denotes the liquidity borrowed and reduced in tick i.
Minimizing Premiums Quoted
When determining which ticks to borrow from, the indexing algorithm is designed to
skip the highly utilized ticks
borrow from ticks the farthest possible tick ranges from current prices(since premiums quoted are proportional to the distance to current price from the borrowed price), subject to the solvency condition above.
Last updated