🧪 Blockchain Defi Simulation
Interactive constant-product AMM simulator: trade against a live x*y=k liquidity pool, watch slippage, LP fees and impermanent loss update in real time, and see the reserve curve rendered in 3D exactly as Uniswap-style DEXs work.
This simulation models the constant-product Automated Market Maker at the heart of decentralized exchanges like Uniswap: a liquidity pool holding two token reserves, A and B, that always satisfies x·y = k. Trade against the pool and watch the reserve curve, spot price, execution slippage and pool depth respond exactly as they do on-chain — the larger a trade relative to the pool, the steeper the price impact. A fee slider shows how liquidity-provider revenue accrues into the invariant itself, an "Add/Remove Liquidity" control demonstrates how depth changes slippage without moving price, and an "External Price Shock" button simulates arbitrage forcing the pool back to a moved market price — the exact mechanism that produces impermanent loss for real liquidity providers.
This simulation explores Decentralized Finance (DeFi) applications built on blockchain technology. Users can interact with simulated lending protocols, decentralized exchanges, and other DeFi services to understand the core concepts.
2D · HTML5 Canvas 2D · 60 FPS target · runs fully client-side, no install