Module hydra_dx_math::omnipool
source · Modules
Functions
Calculate delta changes of add liqudiity given current asset state
Calculate delta changes of a buy trade where asset_in is Hub Asset
Calculate delta changes of a buy trade given current state of asset in and out
Calculate delta imbalance given delta hub reserve to be added to pool
Calculate delta changes of remove liqudiity given current asset state and position from which liquidity should be removed.
Calculate delta changes of a sell where asset_in is Hub Asset
Calculate delta changes of a sell trade given current state of asset in and out.
Calculate withdrawal fee given current spot price and oracle price.
Verify if cap does or does exceed asset’s weight cap.