Blockchain, Ethereum, Simulation.
detailed explanation of how Uniswap works, see this post. Part 2. How to test the security of blockchain systems There are two questions we need to answer to know a system like Uniswap is secure: Correctness. Does the code follow our intended model (written as a specification or otherwise)?