iZUMi's DL-AMM: An Improvement Based on the Concept of UniSwap V3

Biteye
2023-05-22 18:12:58
Collection
The DL-AMM model originates from iZiswap in the iZUMi product matrix, and its design concept was first proposed in a paper published by two co-founders of iZUMi in November 2021.

Author: Biteye Core Contributor JoJonas
Editor: Biteye Core Contributor Crush

The full text is about 3000 words, with an estimated reading time of 6 minutes.
Since the launch of Uniswap V3 over a year and a half ago, the concept of "concentrated liquidity" it proposed has become commonplace for users.

Currently, the analysis data provided on the Uniswap official website shows that the TVL of V3 is more than 3 times that of V2, and the daily trading volume is over 10 times.
Image https://info.uniswap.org/#/

Concentrated liquidity allows users to actively choose the price range for providing liquidity, significantly improving the capital efficiency of LPs in V3. However, it does not change the constant product formula that defines LPs, meaning impermanent loss still exists and is relatively amplified as capital efficiency increases.

User transactions still experience slippage and are susceptible to sandwich attacks. From the user's perspective, limit orders are a more familiar and advantageous trading method, but V3 has not achieved this.

Uniswap V3 has actually introduced the concept of price ranges, where the liquidity definition for each range varies based on its upper and lower price limits, as shown below:
image

Since LPs cannot track market price changes in real-time, once the price exceeds the selected range, the LP will turn into a single asset liquidity, resulting in a loss relative to the current market price.

In tracking market prices, institutions and professional investors clearly have an advantage; a recent data analysis indicated that investors providing liquidity for Uniswap V3 are generally in a losing position, with fees not exceeding impermanent losses.
Image https://twitter.com/thiccythot_/status/1589022227437039616

Does AMM really have to stick to xy=k? The author has recently noticed a new design approach for AMMs and would like to share it.

01 iZUMi's DL-AMM Model

The DL-AMM model originates from iZUMi's product matrix, specifically iZiswap, and its design concept was first proposed in a paper published by two co-founders of iZUMi in November 2021.
https://assets.izumi.finance/paper/dswap.pdf
This paper presents an innovative algorithm addressing the shortcomings of Uniswap V3, featuring the following characteristics: 1. Discretized Concentrated Liquidity

DL-AMM does not use the constant product formula but instead places liquidity at discrete price points, with each price point following a constant sum formula (x + y = L).

Countless discrete price points are connected, forming a complete AMM price curve similar to Uniswap. Additionally, when placing range liquidity, DL-AMM uses a new "liquidity" quantification definition (L = x*√p + y/√p), transforming the integral summation of Uniswap V3 into a geometric summation, efficiently completed in constant time.
2. Grouped Limited Liquidity

In DL-AMM, liquidity is divided into two categories: LP liquidity and limit order liquidity. The former is similar to V3, while the latter is one-way; once the target price is exceeded, the tokens will not be swapped back and will be retained until the user "claims" them.

If the liquidity within the group does not fully exceed the target price, "claims" follow a first-come, first-served principle. Traditional trading matching engines need to poll all orders at a price point, but through innovative algorithm design, DL-AMM can complete matching in constant time for the first time, ensuring time correctness, fairness, and complete non-custodial security of funds.

Compared to Uniswap V3, the DL-AMM proposed by iZUMi avoids slippage at each price point by applying the constant sum formula at different discrete price points, and combines discrete price points (and the liquidity depth based on this) to achieve on-chain order book functionality. Subsequent projects like Trader Joe's liquidity Bin are derived from the DL-AMM design.

image

Overview of the DL-AMM model, source: https://izumi.finance/paper/dswap.pdf

The image shows the constant sum formula used by DL-AMM, where different discrete price points correspond to different (p, L), and the LP curve (yellow line) differs from the blue line used by Uniswap (constant product formula, xy=k) as seen in the left image.

It can be observed that if the price range is dense enough, the yellow line can approach the blue line infinitely, at which point there is no difference in actual trading experience and operational experience between the two.

The right image illustrates DL-AMM's support for limit orders. Limit orders will act as a special LP (single asset) and provide liquidity alongside regular LPs, bringing the Limit order functionality to iZiswap, which is unattainable by Uniswap.

Through these clever improvements, DL-AMM expands the potential of Uniswap V3 in limit order functionality, providing a complete on-chain order book feature; the on-chain order book based on iZiswap DL-AMM can perfectly avoid the technical challenges encountered by traditional approaches, providing a new direction for development.

iZiswap was launched on May 20, 2021, and the product has undergone continuous iterations, with the current total TVL across all chains being approximately $94.7 million.

iZUMi's iZiSwap Pro features an on-chain order book functionality for point-to-pool matching (AMM mode); at the same time, the zero slippage and anti-MEV decentralized limit orders are also refreshing.
https://twitter.com/izumi_Finance/status/1603215989227032576
iZiswap has successively launched on multiple chains such as BNB Chain and Arbitrum, and after going live on ZkSync on April 21, it quickly became the DEX with the largest TVL on ZkSync in just three weeks.
image

Data of iZiSwap on ZkSync

Currently, Ref Finance on Near and Arctic on Aurora both adopt iZiswap's unique DL-AMM solution, with the former being the largest DEX in the Near ecosystem, reaching a peak TVL of $270 million.

02 Trader Joe's Liquidity Book

Trader Joe follows the DL-AMM approach by setting multiple discrete price bins (Liquidity Bins) for LPs, with the liquidity within each price bin also defined by the constant sum formula (as shown in the left image below).
Image

The liquidity within each price bin is provided by multiple users. Let c represent the proportion of token Y within the price bin; it can be easily deduced that only the price bin c where the current market price lies is between (0, 1).

For price bins with prices greater than the market price, their liquidity consists of token Y (c=0); for price bins with prices lower than the market price, their liquidity consists of token X (c=1).

At this point, the design of the Liquidity Bin is essentially identical to that of DL-AMM, meaning it can also achieve lower slippage.

On its official website, it also provides users with some liquidity addition strategies based on this, allowing users to freely combine liquidity bins to achieve their strategy combinations.
https://help.traderjoexyz.com/en/trader-joe/liquidity-book/liquidity-strategies
For example, the "Bid-Ask" strategy shown in the image below:
image

To further reduce impermanent loss, Liquidity Bin has designed a trading fee mechanism associated with price volatility.

Its trading fee, in addition to the basic fee portion similar to traditional mechanisms, also includes a variable fee portion (as shown in the formula below).

This variable fee is quadratically related to the volatility accumulator (va) (s is the length of the price bin). va is used to measure the intensity of price fluctuations; if the price fluctuates too rapidly in a short period, the variable fee will increase accordingly to reduce IL through smoother fluctuations, and attract liquidity when volatility is too low.
image

The Liquidity Book can be seen as a combination of iZUMi's DL-AMM approach and dynamic fee rates, with its core still being the replacement of the global constant product formula by the constant sum formula at discrete price points, but it currently does not support the Limit Order functionality.

Since the advent of Uniswap, xy=k has seemingly been the "bible" of the AMM field due to its simplicity and effectiveness.

Due to the shortcomings of the xy=k formula, many teams have gradually begun to explore new possibilities, and the DL-AMM model proposed by iZUMi is one of the sufficiently practical and elegant options.

It can support the trading depth and experience of the original xy=k model while reducing slippage and MEV, as well as introducing new functionalities such as on-chain order books.

I believe there will be more innovations based on DL-AMM in the future, laying the technical foundation for richer liquidity addition strategies and the emergence of new applications (such as user-friendly on-chain order books).

Will DL-AMM be the future? Let us wait and see.

ChainCatcher reminds readers to view blockchain rationally, enhance risk awareness, and be cautious of various virtual token issuances and speculations. All content on this site is solely market information or related party opinions, and does not constitute any form of investment advice. If you find sensitive information in the content, please click "Report", and we will handle it promptly.
banner
ChainCatcher Building the Web3 world with innovators