# Trading Basics

**On-Chain Perpetual Futures**

**Perpetual Futures** enables traders to engage in perpetual futures—derivatives contracts with no expiry date. It allows speculation on price movements or hedging against risk without requiring physical delivery of assets. Instead, profits or losses are realized through cash settlements, influenced by leverage and price changes between the trade's opening and closing.

With no expiration, traders can maintain positions indefinitely. However, profitability requires active monitoring of asset prices and funding rates, as these factors fluctuate over time.

***

**Efficient Collateral and Account Management**

Trading begins by depositing collateral, such as USDC, into a pooled margin account. This system aggregates unrealized profits and losses across positions, reducing the risk of liquidation while improving liquidity.

While this pooled approach offers flexibility, leverage amplifies both potential gains and losses. Active risk management is essential to avoid significant losses during rapid market changes.

Future updates will support isolated margin accounts, allowing traders to manage risks more granularly. Until then, sub-accounts can be used to separate positions.

***

**Funding Rates**

To maintain perpetual contracts' alignment with the spot price of the underlying asset, a funding model is used. Funding rates are periodic payments between long and short position holders, designed to correct price deviations:

* **Positive funding rates:** Longs pay shorts.
* **Negative funding rates:** Shorts pay longs.

This mechanism ensures that the perpetual market stays balanced.

***

**Key Metrics and Definitions**

* **Unrealized Profit and Loss (UPNL):** Reflects potential gains or losses if a position were closed at the current market price.\
  Formula: `UPNL = (Average Entry Price - Current Index Price) × Position Size`
* **Open Interest (OI):** Represents the total value of active contracts. High OI indicates increased market activity.\
  When OI reaches its maximum, new trades cannot be opened until existing positions are closed.
* **Account Health:** Measures position stability as a percentage.\
  Formula: `(Equity Balance - Maintenance Margin) / Equity Balance`\
  Falling below the Maintenance Margin triggers liquidation
* **Equity Balance:** The total balance available, combining account funds and UPNL.\
  Formula: `Equity Balance = Allocated Balance + UPNL`
* **Maintenance Margin (CVA):** The minimum amount needed to keep a position open. If the Equity Balance falls to this level, liquidation is triggered.
* **Allocated Balance:** Funds set aside in a margin sub-account, usable for trades or transferable back to the main account after a verification period.

***

**Liquidity Management and Withdrawal**

All deposits are subject to a fraud-proof verification process to ensure secure transactions. Withdrawals are finalized after a brief evaluation period.

***

The Intent-based system offers a secure, capital-efficient system for managing on-chain perpetual futures. Key features like margin pooling, funding rate mechanisms, and a robust risk management system ensure a seamless and scalable trading experience. The intent-based system is positioned to meet the needs of modern traders while maintaining the transparency and decentralization of blockchain technology.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.xpanse.trade/intent-based-system/trading-on-intent-based-system/trading-basics.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
