Oracles
The first component of a vault is its
Last updated
The first component of a vault is its
Last updated
The first component of a vault is its oracle. The oracle is used to compute initial shares minting. When a deposit and burn event, it is also use to get the current price of the market and have an up to date price.
These oracles are adapters from existing oracles like chainlink.
An oracle just contains a single definition which is its tick (in a base/quote market). Here is a quick definition of the mangrove .
If the market in question was WETH/USDC, with p being the price and t being the tick, assuming the current price of ETH is 2500 USDC, WETH has 18 decimals, USDC has 6 decimals, we would have the following:
This formula is such that same decimals and price makes a tick of 0, in the market USDC/USDT for example.
By reversing the formula, computing the price from the tick is as follows for the same market.