Reserve Index DTFs

Pricing

Pricing of Index DTFs

The Price of a DTF is based on a NAV (Net Asset Value) calculation.

Given a DTF with a basket of n tokens, each with a spot price p , we can calculate the price as:

NAV=i=1ntokeni×piNAV = \sum_{i=1}^{n} token_i \times p_i Price=NAVtotalSharesPrice = \frac{NAV}{totalShares}

Onchain Pricing

The toAssets() function is used to convert a DTF share to its underlying assets. It will return the one:many exchange rate of the DTF.

function toAssets(uint256 shares, Math.Rounding rounding) returns (address[] memory _assets, uint256[] memory _amounts);

Solidity Code: Folio.toAssets()

Inputs

  • shares Amount of shares to quote
  • rounding enum, one of:
    • [0] Floor (Toward negative infinity)
    • [1] Ceil (Toward positive infinity)
    • [2] Trunc (Toward zero)
    • [3] Expand (Away from zero)

Outputs

  • _assets Array of assets in the quote
  • _amounts Array of amounts of assets in the quote

Pricing API

Info about the pricing API here