MondrianSwap
  • Welcome to Mondrian Swap
  • PRODUCTS
    • Mondrian Swap Pools
      • Weighted Pools
      • Stable Pools
    • Liquidity Providers
    • Smart Order Router
    • Protocol Fees
    • Security
  • Token
    • Tokenomics
    • Token Emissions
  • About us
    • Roadmap
    • Smart Contracts Overview
    • Abstract Bridge
  • Developers
    • Subgraphs
  • SOCIALS
    • Socials
Powered by GitBook
On this page
  • Overview
  • How Stable Pools Work
  • The Constant Price Model
  • The StableSwap Invariant
  • Amplification Factor A
  • Advantages of Stable Pools
  1. PRODUCTS
  2. Mondrian Swap Pools

Stable Pools

PreviousWeighted PoolsNextLiquidity Providers

Last updated 4 months ago

Overview

Stable Pools, first introduced by Andre Cronje’s Curve Finance, revolutionized Decentralized Exchange (DEX) technology by enabling low-slippage swaps between assets that maintain near-parity pricing. These pools are particularly suited for stablecoins and pegged assets, as they provide greater capital efficiency and reduced impermanent loss compared to traditional AMMs.

Unlike Weighted Pools, which rely on flexible asset ratios, Stable Pools use a modified invariant function designed to preserve price stability while maximizing liquidity efficiency.


How Stable Pools Work

The Constant Price Model

Consider a liquidity provider holding assets X and Y at a constant price. In an ideal scenario:

−dy=dx−dy=dx−dy=dx

This implies that if you sell dx of coin X, you receive dy=dx of coin Y in return. However, this linear invariant assumes that the exchange rate is always exactly 1:1, which does not hold in fluctuating markets.

A potential fix is using price oracles, but they introduce centralization risks and increase system complexity. Instead, Stable Pools use an improved StableSwap invariant to maintain an efficient liquidity balance dynamically.

The StableSwap Invariant

To ensure liquidity is efficiently allocated without relying on external oracles, Stable Pools use a product-based model similar to Uniswap but with an amplification factor A to reduce slippage:

xy=kxy=kxy=k

Where:

  • x and y are the quantities of two tokens in the pool.

  • k is a constant, maintaining liquidity balance.

This StableSwap model keeps the exchange rate close to 1:1, only deviating slightly when liquidity imbalances occur. The amplification factor A determines how close the pool behaves to a constant price model.

Amplification Factor A

The StableSwap invariant introduces an amplification coefficient A that adjusts liquidity behavior:

  • Lower A values make the pool behave similarly to Uniswap’s constant-product model.

  • Higher A values make the pool behave closer to a fixed price invariant, reducing price slippage.

For practical implementations, A=100 is a commonly used benchmark, comparable to using Uniswap with 100x leverage.

📌 Key Takeaway: When the price deviates slightly from equilibrium (1.0), the StableSwap invariant efficiently maintains liquidity, outperforming constant-product AMMs in low-volatility asset pairs.


Advantages of Stable Pools

1. Low Price Impact

  • Traders experience tighter spreads and reduced slippage, making Stable Pools ideal for large trades.

  • Assets remain near parity, ensuring high capital efficiency.

2. Stable Swaps & Arbitrage Efficiency

  • Stablecoin arbitrage opportunities arise when different pools contain multiple stablecoins.

  • Mondrian Swap integrates Stable Pools with Batch Swaps, enabling gas-efficient transactions.

  • Multi-hop trades between stablecoins and volatile assets remain seamless and cost-effective.

Comparison of StableSwap invariant with Uniswap (constant-product) and constant price invariants. The portfolio consists of coins X and Y, which have the "ideal" price of 1.0. There are x = 5 and y = 5 coins loaded up initially. As x decreases, y increases, and the price is the derivative dy/dx.
Price slippage: Uniswap invariant (dashed line) vs Stableswap (solid line)