The liquidation price formula for the Contract 1 of Perpetual futures contracts is as below:
Definitions:
WB: Wallet Balance
TMM1: Maintenance Margin of all other contracts, excluding Contract 1
UPNL1: Unrealized PNL of all other contracts, excluding Contract 1
cumB: Maintenance Amount of BOTH position (one-way mode)
cumL: Maintenance amount of LONG position (hedge mode)
cumS: Maintenance amount of SHORT position (hedge mode)
Side1BOTH: Direction of BOTH position, 1 as long position, -1 as short position
Position1BOTH: Absolute value of BOTH position size (one-way mode)
EP1BOTH: Entry Price of BOTH position (one-way mode)
Position1LONG: Absolute value of LONG position size (hedge mode)
EP1LONG: Entry Price of LONG position (hedge mode)
Position1SHORT: Absolute value of SHORT position size (hedge mode)
EP1SHORT: Entry Price of SHORT position (hedge mode)
MMR B: Maintenance margin rate of BOTH position (one-way mode)
MMR L: Maintenance margin rate of LONG position (hedge mode)
MMR S: Maintenance margin rate of SHORT position (hedge mode)
One-way position mode:
In Cross margin mode,
- Position1LONG and Position1SHORT both = 0.
- The calculation of TMM excludes the maintenance margin of those positions in Isolated margin mode.
- The calculation of UPNL excludes the Unrealised PNL of those positions in Isolated margin mode.
- WB refers to crossWalletBalance.
In Isolated margin mode,
- Position1LONG and Position1SHORT both = 0.
- TMM = 0
- UPNL = 0
- WB refers to isolatedWalletBalance.
Hedge position mode:
In Cross margin mode,
- Position1BOTH = 0
- The calculation of TMM excludes the maintenance margin of those positions in Isolated margin mode.
- The calculation of UPNL excludes the Unrealised PNL of those positions in Isolated margin mode.
- WB refers to crossWalletBalance.
In Isolated margin mode,
- Position1BOTH = 0
- If calculating open long position, Position1SHORT = 0; If calculating open short position, Position1SHORT = 0.
- TMM = 0
- UPNL = 0
- WB refers to isolatedWalletBalance.
Note:
- Under the cross margin mode, both long and short position of one contract share the same liquidation price. Under the isolated mode, each isolated position will have different liquidation prices.
- If the liquidation price is less than 0, then will display as “--”.
Maintenance Margin Rate & Maintenance Amount
- Maintenance Margin Rate
Users can refer to table below to find the “Maintenance Margin Rate” with the position value.
Note: If your position (calculated at the liquidation price) and the current position (calculated at the opening price) are of different levels, then you must substitute (i.e. to calculate at the liquidation price) the maintenance margin rate and the maintenance margin amount of the position level, to recalculate the liquidation price. - Maintenance Amount
Users can refer to table below to find the “Maintenance Amount” with the position value.
Maintenance Amount formula= [ Floor of Position Bracket on Level n * (difference between Maintenance Margin Rate on Level n and Maintenance Margin Rate on Level n-1) ] + Maintenance Amount on Level n-1
Maintenance margin = Notional Value * Maintenance Margin Rate-Maintenance Amount
Notional Value = Price * Size
*Disclaimer: The numbers in this article are subject to change without further notice.