Function hydra_dx_math::stableswap::calculate_shares_removed
source · pub fn calculate_shares_removed<const N: u8>(
initial_reserves: &[Balance],
idx_out: usize,
amount_out: Balance,
amplification: Balance,
share_issuance: Balance,
withdraw_fee: Permill
) -> Option<Balance>
Expand description
Calculate amount of shares to burn if amount is removed from pool