Basic understanding of The Architecture

To support its dual functionality as a Decentralized Exchange (DEX) and a Money Market, Nitro Finance is built around a unique AMM architecture that integrates a concentrated liquidity pool and an efficient debt management module.

The Liquidity pool

At the core of Nitro Finance’s architecture is the liquidity pool, segmented into bins, with each bin corresponding to a specific price point within a trading pair. These bins collectively form the liquidity pool but operate independently, facilitating trades at their defined price points.

The concentrated liquidity design allows Liquidity Providers (LPs) to allocate their capital to specific price ranges (bins) where they anticipate the most trading activity. This focused allocation enhances capital efficiency and minimizes slippage for traders.

Concentrated Liquidity Outlook

  • Active Bin (A): Represents the bin aligned with the current market price. It contains an active mix of both base and quote assets, enabling seamless swaps at this price point.

  • X-Range: Holds the base asset (e.g., NAD in the USDC/NAD pair), representing liquidity bins positioned above the current active bin.

  • Y-Range: Holds the quote asset (e.g., USDC in the USDC/NAD pair), representing liquidity bins positioned below the current active bin.

Bin-Based Segmentation

The liquidity pool is divided into multiple bins, each functioning as a micro-pool corresponding to a unique price point.

  • Geometric Price Progression: The difference between consecutive bins is determined by the bin step (s), which follows a geometric progression:

P1+bin step=P2,P2+bin step=P3,P_1 + \text{bin step} = P_2, \, P_2 + \text{bin step} = P_3, \, \dots

  • Bin Reserves: Each bin maintains its own set of reserves:

    • Reserve X: Holds the base asset (e.g., NAD in the USDC/NAD pair).

    • Reserve Y: Holds the quote asset (e.g., USDC in the USDC/NAD pair).

Debt Management Module

The debt management module efficiently handles the creation, tracking, and recovery of debt within Nitro Finance. It secures collateral assets, ensures debt accountability, and enforces automated recovery upon debt expiration.

The key components

Debt NFT Contract:

The Debt NFT serves as a verifiable record of the debt, supporting both repayment and recovery processes.

  • Based on the ERC-721 standard, the contract mints a Debt NFT for each borrowing position.

    • Each Debt NFT records:

      • Borrow bin price: The specific bin price at which the borrowing occurred.

      • Borrow type: Whether the debt is positioned above or below the market price.

      • Collateral value: The amount of collateral securing the debt.

Debt Reserve (Z):

The reserve ensures efficient management and quick access to collateral during repayment or auto liquidation.

  • Per-Bin Collateralization: Collateral assets are stored in reserves corresponding to their associated borrow bins.

  • Reserve Types:

    • Zx Reserve: Stores collateralized base assets (e.g., NAD).

    • Zy Reserve: Stores collateralized quote assets (e.g., USDC).

Auto Liquidator

The Auto Liquidator is a user-initiated but protocol-automated infrastructure designed to recover expired debts seamlessly:

  • User-Initiated Execution:

    • A user, referred to as a blacklistoor, triggers the liquidation process by blacklisting an expired debt position.

  • Protocol-Automated Absorption:

    • Once a debt is blacklisted, the auto liquidator automatically absorbs the associated collateral asset into the corresponding bin of the liquidity pool.

The FusedTradeLedger

Last updated