@angleprotocol/sdk
Version:
SDK for Angle DApps
11 lines (10 loc) • 975 B
TypeScript
import { BigNumber } from 'ethers';
import JSBI from 'jsbi';
export declare function getSqrtRatioAtTick(tick: number): JSBI;
export declare function getTickAtSqrtRatio(sqrtRatioX96: JSBI): number;
export declare const getAmount0ForLiquidity: (lowerTick: number, upperTick: number, liquidity: BigNumber) => BigNumber;
export declare const getAmount1ForLiquidity: (lowerTick: number, upperTick: number, liquidity: BigNumber) => BigNumber;
export declare const getAmountsForLiquidity: (sqrtRatioX96String: string, lowerTick: number, upperTick: number, liquidity: BigNumber) => BigNumber[];
export declare const getLiquidityForAmount0: (lowerTick: number, upperTick: number, amount0: BigNumber) => BigNumber;
export declare const getLiquidityForAmount1: (lowerTick: number, upperTick: number, amount1: BigNumber) => BigNumber;
export declare const getLiquidityForAmounts: (tick: number, lowerTick: number, upperTick: number, amount0: BigNumber, amount1: BigNumber) => BigNumber;