This article explains how constant function markets operate under concentrated liquidity, detailing pricing mechanics, liquidity depth, fee distribution, and theThis article explains how constant function markets operate under concentrated liquidity, detailing pricing mechanics, liquidity depth, fee distribution, and the

How Constant Function Markets Price Trades Under Concentrated Liquidity

Abstract

1. Introduction

2. Constant function markets and concentrated liquidity

  • Constant function markets
  • Concentrated liquidity market

3. The wealth of liquidity providers in CL pools

  • Position value
  • Fee income
  • Fee income: pool fee rate
  • Fee income: spread and concentration risk
  • Fee income: drift and asymmetry
  • Rebalancing costs and gas fees

4. Optimal liquidity provision in CL pools

  • The problem
  • The optimal strategy
  • Discussion: profitability, PL, and concentration risk
  • Discussion: drift and position skew

5. Performance of strategy

  • Methodology
  • Benchmark
  • Performance results

6. Discussion: modelling assumptions

  • Discussion: related work

7. Conclusions And References

Constant function markets and concentrated liquidity

2.1. Constant function markets

Consider a reference asset X and a risky asset Y which is valued in units of X. Assume there is a pool that makes liquidity for the pair of assets X and Y , and denote by Z the marginal exchange rate of asset Y in units of asset X in the pool. In a CFM that charges a fee τ proportional to trade size, the trading function f q X, qY = κ 2 links the state of the pool before and after a trade is executed, where q X and q Y are the quantities of asset X and Y that constitute the reserves in the pool, κ is the depth of the pool, and f is increasing in both arguments.

\ We write f q X, qY = κ 2 as q X = φκ q Y for an appropriate decreasing level function φκ. We denote the execution rate for a traded quantity ±y by Z˜ (±y), where y ≥ 0. When an LT buys y of asset Y , she pays x = y × Z˜ (y) of asset X, where

f (q X + (1 − τ ) x, qY − y ) = κ 2 =⇒ Z˜(y) = φκ (q Y − y ) − φκ(q Y ) (1 − τ ) y . (1)

Similarly, when an LT sells y of asset Y , she receives x = y × Z˜ (−y) of asset X, where

f (q X + x, qY + (1 − τ ) y ) = κ 2 =⇒ Z˜(−y) = φκ (q Y ) − φκ (q Y + (1 − τ ) y ) y . (2)

\ In CL markets, the marginal exchange rate is Z = −φ ′ κ (q Y ), which is the price of an infinitesimal trade when fees are zero, i.e., when y → 0 and τ = 0. 2 In traditional CPMs such as Uniswap v2, the trading function is f(q X, qY ) = q X ×q Y , so the level function is φκ(q Y ) = κ 2/qY and the marginal exchange rate is Z = q X/qY . Liquidity provision operations in CPMs do not impact the marginal rate, so when an LP deposits the quantities x and y of assets X and Y , the condition Z = q X/qY = (q X + x)/(q Y + y) must be satisfied; see Cartea et al. (2022, 23b).

\ 2.2. Concentrated liquidity market

This paper focuses on liquidity provision in CPMs with CL. In CPMs with CL, LPs specify a range of rates (Z ℓ , Zu ] in which their assets can be counterparty to liquidity taking trades. Here, Z ℓ and Z u take values in a finite set {Z 1 , . . . , ZN }, the elements of the set are called ticks, and the range (Z i , Zi+1] between two consecutive ticks is a tick range which represents the smallest possible liquidity range; see Drissi (2023) for a description of the mechanics of CL.3

\ The assets that the LP deposits in a range (Z ℓ , Zu ] provide the liquidity that supports marginal rate movements between Z ℓ and Z u . The quantities x and y that the LP provides verify the key formulae

   x = 0 and y = ˜κ Z ℓ −1/2 − (Z u ) −1/2 if Z ≤ Z ℓ , x = ˜κ Z 1/2 − Z ℓ 1/2

and y = ˜κ Z −1/2 − (Z u ) −1/2 if Z ℓ < Z ≤ Z u , x = ˜κ (Z u ) 1/2 − Z ℓ 1/2 and y = 0 if Z > Z u (3)

\ where κ˜ is the depth of the LP’s liquidity in the pool. The depth κ˜ is specified by the LP and it remains constant unless the LP provides additional liquidity or withdraws her liquidity. When the rate Z changes, the equations in (3) and the prevailing marginal rate Z determine the holdings of the LP in the pool, in particular, they determine the quantities of each asset received by the LP when she withdraws her liquidity.

\ Within each tick range, the constant product formulae (1)–(2) determine the dynamics of the marginal rate, where the depth κ is the total depth of liquidity in that tick range. To obtain the total depth in a tick range, one sums the depths of the individual liquidity positions in the same tick range; see Drissi (2023). When a liquidity taking trade is large, so the marginal rate crosses the boundary of a tick range, the pool executes two separate trades with potentially different depths for the constant product formula.

\ In CPMs with CL, the proportional fee τ charged by the pool to LTs is distributed among LPs. More precisely, if an LP’s liquidity position with depth κ˜ is in a tick range where the total depth of liquidity is κ, then for every liquidity taking trade that pays an amount p of fees,4 the LP with liquidity κ˜ earns the amount

p˜ = κ˜ κ p 1Zℓ (4)

Thus, the larger is the position depth κ˜, the higher is the proportion of fees that the LP earns.5 The equations in (3) imply that for equal wealth, narrow liquidity ranges increase the value of κ. ˜ However, as the liquidity range of the LP decreases, the concentration risk increases.

:::info Authors:

  1. Alvaro Cartea ´
  2. Fayc¸al Drissia
  3. Marcello Monga

:::

:::info This paper is available on arxiv under CC0 1.0 Universal license.

:::

\

Disclaimer: The articles reposted on this site are sourced from public platforms and are provided for informational purposes only. They do not necessarily reflect the views of MEXC. All rights remain with the original authors. If you believe any content infringes on third-party rights, please contact [email protected] for removal. MEXC makes no guarantees regarding the accuracy, completeness, or timeliness of the content and is not responsible for any actions taken based on the information provided. The content does not constitute financial, legal, or other professional advice, nor should it be considered a recommendation or endorsement by MEXC.