# Execution of Trades

A purchase of LP-B in exchange for LP-A will be executed by the following actions:

#### On the LP-A/ETH pool:

* Calculate the Oracle market value of LP-A tokens.
* Fetch the Oracle market price of ETH.
* Calculate the LP-A/ETH exchange rate using Flype's IMM mechansim.
* Add LP-A tokens to the LP-A/ETH Pool.
* Remove the equivalent ETH value in US Dollar terms from the LP-A/ETH Pool.

#### On the LP-B/ETH pool:

* Calculate the Oracle market price of LP-B.
* Calculate the LP-B/ETH exchange rate using Flype's IMM mechansim.
* Add the ETH to the LP-B/ETH Pool.
* Transfer equivalent LP-B tokens value in US Dollar terms from the LP-B/ETH Pool to your wallet.
