Paper: arXiv 2601.03799

Authors: Bastien Baude, Damien Challet, Ioane Muni Toke

Abstract

We study the optimal liquidation of a large position on Uniswap v2 and Uniswap v3 in discrete time. The instantaneous price impact is derived from the AMM pricing rule. Transient impact is modeled to capture either exponential or approximately power-law decay, together with a permanent component. In the Uniswap v2 setting, we obtain optimal strategies in closed-form under general price dynamics. For Uniswap v3, we consider a two-layer liquidity framework, which naturally extends to multiple layers. We address the problem using dynamic programming under geometric Brownian motion dynamics and approximate the solution numerically using a discretization scheme. We obtain optimal strategies akin to classical ones in the LOB literature, with features specific to Uniswap. In particular, we show how the liquidity profile influences them.

Complexity vs Empirical Score

  • Math Complexity: 7.5/10
  • Empirical Rigor: 3.5/10
  • Quadrant: Lab Rats — theoretically deep, empirically untested

Why this score: The paper provides a rigorous mathematical framework for optimal liquidation on AMMs (Uniswap v2 and v3) under transient price impact, extending classical LOB execution models to DeFi. It achieves closed-form solutions for CPAMMs and a dynamic programming scheme for CLAMMs, though it lacks extensive empirical validation or backtesting on historical DEX transaction data.

Research Flowchart

  flowchart TD
    A[Research Goal: Optimal Large-Position Liquidation on Uniswap v2 & v3] --> B[Model Formulation: AMM Impact & Decay Models]
    B --> C[Inputs: AMM Rules, Transient/Permanent Decay, GBM Dynamics]
    C --> D1[Uniswap v2: Closed-Form Solution]
    C --> D2[Uniswap v3: Multi-Layer Liquidity & Dynamic Programming]
    D1 --> E[Numerical Discretization & Strategy Execution]
    D2 --> E
    E --> F[Outcomes: LOB-like Optimal Strategies Shaped by AMM Liquidity Profiles]

Cited References (33)

  1. D ecentralized finance: P rotocols, risks, and governance (2023)
  2. V alue under liquidation (1999)
  3. O ptimal execution of portfolio transactions (2001)
  4. O ptimal execution with nonlinear impact functions and trading-enhanced risk (2003)
  5. T he financial mathematics of market liquidity: F rom optimal execution to market making (2016)
  6. A lgorithmic and high-frequency trading (2015)
  7. O ptimal trading strategy and supply/demand dynamics (2013)
  8. C onstrained portfolio liquidation in a limit order book model (2008)
and 25 more
  1. O ptimal execution strategies in limit order books with general shape functions (2010)
  2. T ransient linear price impact and F redholm integral equations (2012)
  3. O ptimal execution with non-linear transient market impact (2017)
  4. T rades, quotes and prices: F inancial markets under the microscope (2018)
  5. C alibration of optimal execution of financial transactions in the presence of transient market impact (2012)
  6. F luctuations and response in financial markets: T he subtle nature of `random’ price changes (2003)
  7. O ptimal approximations of power laws with exponentials: A pplication to volatility models with long memory (2007)
  8. U niswap v2 core (2020)
  9. U niswap v3 core (2021)
  10. U niswap v4 core (2023)
  11. S table S wap - efficient mechanism for stablecoin liquidity (2019)
  12. A non-custodial portfolio manager, liquidity provider, and price sensor (2019)
  13. G lobal order routing on exchange networks (2021)
  14. O ptimal routing for constant function market makers (2022)
  15. A n efficient algorithm for optimal routing through constant function market makers (2023)
  16. O ptimal routing in the presence of hooks: T hree case studies (2025) — link
  17. O n-chain optimal aggregation of U niswap v3 clones (2024)
  18. D ecentralised finance and automated market making: E xecution and speculation (2025)
  19. E xecution and statistical arbitrage with signals in multiple automated market makers (2023)
  20. O ptimal trading in automatic market makers with deep learning — → 2304.02180
  21. Optimal control theory: A n introduction (2004)
  22. Order book inspired automated market making (2024)
  23. Matrix analysis (2013)
  24. Hadamard powers of rank two, doubly nonnegative matrices (2020)
  25. Jensen’s Inequality (2021)

1 of 33 cited works are in the corpus; resolved via arXiv source bundles, Semantic Scholar and OpenAlex. Corpus-wide: 2518 linked papers.