Constant Product Market Maker

Formula

The Constant Product Market Maker (CPMM) is an automated market maker (AMM) algorithm defined by the invariant function x y = k, where x and y represent the quantities of two assets in a liquidity pool, and k is a constant product. This formula dictates that a trade must always maintain the constant product, causing the price of one asset to rise proportionally as the other asset’s quantity increases in the pool. The CPMM design facilitates liquidity provision for trading pairs without relying on a traditional order book structure.