[Gate.io Academy] Master Perpetual Contract

2021-07-15, 08:12

The contract can be divided into Perpetual Contracts and Delivery Contracts. The main difference is that one has no settlement date and the other has a settlement date. Today’s course is about Perpetual. Once we have fully understood Perpetual Contracts, it will be easy for us to understand Delivery Contracts.


What is a Perpetual Contract

The perpetual contract is an innovative crypto derivative settled in crypto coin such as BTC and USDT. There are some similarities with Spot Margin Trading such as borrowing from other users to amplify the profit and loss. Investors can get the benefits of rising prices by buying long or getting the benefits of falling prices by selling short.

To understand Perpetual Contracts, we have to understand Traditional Futures Contracts first. A futures contract is an agreement between two parties to buy or sell a commodity, currency, or another instrument at a predetermined price at a specified time in the future. One person promises to sell an asset at an agreed price while the other promises to buy it. Unlike a traditional spot market, the trades are not 'settled' instantly in a futures market. At the time the contract is due, both must fulfill their promise regardless of where the price of the item actually is. If the future price is higher than the original agreed price, the seller loses and the buyer wins. The opposite is true if the price goes lower than the original price.

The Perpetual Contract takes on some characteristics of a Futures Contract, but without the delivery of the actual commodity. The price of a Traditional Futures Contract can have prolonged or even permanent differences versus the Spot Price. Perpetual Contracts use a peer-to-peer exchange mechanism in terms of funding. It is a fair price making method to make the price close to the underlying reference Index Price.

Unlike traditional futures, there is no expiration date. Therefore, there are no restrictions on the holding time. Users can choose to hold positions at all times, even when prices move against their position. You are not necessarily stuck with a losing trade as long as you have enough funds to maintain your positions. Suppose you think that the price of Bitcoin will rise, but you don't know when it will rise. If the price of your futures contract has not risen when it expires, then this is a losing trade. However, with a perpetual contract, you can hold your position indefinitely. In this way, you can maximize your chances of success.

Your maximum loss is the whole maintenance margin once your position is liquidated. The fees involved are funding payment and entry/exit commissions.

Mechanics of a Perpetual Contract Market

1) Fair Price Marking: Used to avoid unnecessary liquidations due to market manipulation or lack of liquidity. Perpetual contracts are marked according to Fair Price instead of the Last price. The Mark Price(the estimated true value of the contract comparable to the current trading price) is used in Unrealized PNL(profit & loss) and Liquidation Price. This calculation helps to avoid certain manipulations and ensure that Perpetual Contract price is matched to the Spot Price.

The Fair Price is equal to the underlying Index Price plus a decaying Funding basis rate.

Funding Basis = Funding Rate * (Time Until Funding / Funding Interval)

2) Initial and Maintenance Margin: Initial margin level determines how much leverage one can trade with and the Maintenance Margin level determines at what point liquidation occurs. The auto-liquidation will occur if their liquidation position is below the Maintenance Margin level.

Initial margin

In order to leverage trading benefits or open a leveraged position to trade in Perpetual Futures Contracts, the Initial margin is the minimum amount that a trader must pay at first. It is the value you commit when opening a position.

Maintenance margin

Maintenance margin is the minimum amount of collateral you must hold to keep trading positions open. The value of the Maintenance margin changes according to the market price of the collateral. If your margin balance drops below this level, you will either receive a margin call (asking you to add more funds to your account) or be liquidated.

3) Long & Short positions

The buyer holds the “Long” position which means he commits to buying an asset at a specific price in the future; whereas the seller holds a “Short” position and agrees to sell the asset at a predetermined price.


4) Funding: Long and short position holders exchange payment every 8 hours. Funding is exchanged between buyers and sellers at 0:00, 8:00, 16:00 UTC; You will only pay or receive funding if you hold a position at one of these times.

Funding = Position Value * Funding Rate

The Funding Rate determines which party is the payer and the payee. Your position value is irrespective of leverage. When the Funding Rate is positive, longs pay shorts. When it is negative, shorts pay longs.

The funding rate of the previous period applies to give users more insights in predicting the cost. For example, the settled result calculated from 0:00-8:00 will be used when funding payment takes place at 16:00.

5) Calculation of Funding Rate: The funding rate consists of two parts: the interest rate spread of quote currency and settle currency (Please check course Day 3 for more details). We take it as 0.01%, and the premium or discount of exchange price and external spot prices.


6) Risk: A perpetual contract is highly leveraged. It can amplify profits as well as losses. Make sure you have fully understood the trading rules and risks. Pay attention to reminder messages sent to you via email or SMS from gate.io. Do not trade beyond your financial means and always trade with caution.

Base currency: Also called the transaction currency. The first currency in the Currency Pair against which the Client buys or sells the Quote Currency.

Quote currency: Listed after the base currency in the pair when currency exchange rates are quoted.

Settle currency: Currency settled on to buy or sell the value of a specified amount of a particular base currency.

Due to the combination of different currency types, the contracts can be divided into the 3 kinds:

Ordinary forward contract: The quote currency and settle currency are the same. For example, in the EOS_BTC contract, EOS is the base currency, and BTC is the quote and settled currency. The price is the amount of EOS priced in BTC.


Dual currency contract (Quanto): The so-called dual currency contract means that the quote currency and the settle currency are different. They are two currencies, so it is necessary to define an exchange relationship between the two currencies. Just like the ETH_USD contract, ETH is the base currency, USD is the quote currency, and BTC is the settle currency. The reason for the dual-currency contract is because the user doesn’t want to maintain a wallet with a certain base currency (such as ETH). At the same time, the user can use the currency in their wallet (settle currency, BTC) to conduct transactions and use fiat currency (quote currency, USD) as mark price.

Reverse contract: The base currency and settle currency are the same. Just like BTC_USD. The reason for the reverse contract is that the user doesn’t want to maintain a fiat currency (USD) in their wallet. At the same time, the user can trade the currency in their own wallet (BTC). That is, the relationship between buying and selling BTC in USD is reversed, and USD is still used to mark the price.

PNL (Profit & Loss) Calculation

Unrealized PNL is based on the difference between the average entry price and mark price.

It is a reflection of what profit or loss could be realized if the position were closed at that time. The PNL does not become realized until the position is closed.

Realized PNL is based on the difference between the average entry price and exit price.

Funding exchange payment and trading fees are accounted for through realized PNL. Because the realized PNL refers to the profit or loss that originates from closed positions, it has no direct relation to mark price, but only to the executed price of the orders.

Liquidation

To keep your position, you are required to hold a designated percentage of the position value on your contract account, known as the Maintenance Margin. If you cannot fulfill maintenance requirements, you will be liquidated and your maintenance margin will be lost.

Liquidation process

Step 1: Cancels any open orders in the contract--if there are any

Step 2: If this does not satisfy the maintenance margin requirement then the position will be liquidated at the bankruptcy price.

Auto Deleveraging--ADL

In the event of liquidation, if the liquidation order cannot be filled on the market when the mark price reaches the bankruptcy price, the opposing traders’ positions will be automatically de-leveraged according to the priority rank, at the bankruptcy price of the initial liquidated order.

ADL Priority Deleveraging Ranking

Priority rank is determined by the average entry price. The more favorable the entry price traders get, the more likely they are to be automatically deleveraged in the event of ADL.

Risk Limit

With large sized positions, if they can not be fully liquidated, they may pose risks to others on the exchange. Gate.io uses a Step model to require higher maintenance and initial margin level for large sized positions to minimize the risks.

Insurance Fund

Gate.io uses insurance funds to prevent traders’ positions being taken over by auto-deleveraging. If a “long buyer” is unable to close a trading position due to market price drop or other reasons, then his account will be liquidated as the balance goes below the minimum required amount. The insurance funds will be used to aggress unfilled liquidation orders before it is taken over by ADL. The Insurance Fund gets bigger when users are liquidated before their positions reach break-even or negative value.

Stop Loss and Take profit Orders are auto-trading strategies that will send a preset order to the market when the market reaches a certain Trigger Price.

The validity of the present order will be checked only when the stop order is triggered. If it passes the validity check, the preset order will be sent to the market. If it fails, the order will not be sent to the market and the stop order expires.

Common reasons for failure in validity checks are lack of balance or conflicting with existing orders.


Perpetual Contract Trading Fees

Gate.io uses a Maker-Taker fee schedule, where the taker pays a trading fee and the maker receives a trading fee as a reward. In other words, the trading fee is only charged when you are a taker.

Trading fee

Maker: Pays -0.025%

Taker: Pays 0.075%

If you have points in your contract account, you can use your points to cover part of the taker fee.

The trading fee is charged based on the position value, irrespective of the leverage.



Cartoon: https://www.gate.io/en/help/futures/cartoon/16783/Perpetual-Contract-Trading-in-Gate.io-cartoon


Video: https://www.gate.io/en/help/futures/cartoon/16895/Gate.io-Perpetual-Contract

https://www.gate.io/en/help/futures/perpetual/16716/How-to-trade-with-Perpetual-Contract-Video


TESTNET: https://www.gate.io/en/testnet/futures_trade/USDT/BTC_USDT


Understand Perpetual Contracts: https://www.gate.io/en/help/futures/cartoon/16697/Understand-Perpetual-Contract


About Perpetua Contracts: https://www.gate.io/en/help/futures/perpetual/16695/About-Perpetual-Contract


Fees: https://www.gate.io/en/help/futures/perpetual/16688/Perpetual-Contract-Trading-Fees


分享一下
gate logo
Credit Ranking
Complete Gate Post tasks to upgrade your rank