Skip to main content

What Is the Concept of ‘K’ in the $x Y = K$ Formula, and How Does It Change?

'k' represents the constant product of the reserves ($x$ and $y$) in the pool. It is a mathematical invariant that ensures the pool remains balanced after every trade.

'k' is not a fixed number forever. It increases when new liquidity is added to the pool and decreases when liquidity is removed.

Trades alone do not change 'k'; only changes in total liquidity reserves alter its value.

How Do Hybrid AMM Models, like Curve’s StableSwap Invariant, Improve upon the Constant Product Formula for Stablecoin Trading?
How Does the ‘Constant Sum’ Formula Differ from the ‘Constant Product’ Formula in AMMs?
How Does a Constant Sum Market Maker ($x+y=k$) Differ from a Constant Product AMM?
What Is the Significance of the “Invariant” in Curve Finance’s StableSwap AMM?