# LP TOKENS

**LP Tokens** will be given to **L**iquidity **P**roviders when they add liquidity to tAsset-nYUSD or NEPT-nYUSD NEPRIswap pools. Each pool will have a unique LP token associated with it and cannot be combined with LP tokens from other pools. They serve primarily as a unit of account, representing the liquidity provider's share in the pool in order to reclaim assets when they remove liquidity.

Although LP tokens exist independently as a yield-generation feature of NEPRIswap, they are central to NEPRI TFA's market infrastructure. As such, the protocol will provide NEPT rewards to users who stake LP tokens as an incentive to help maintain liquid markets on NEPRIswap for tAssets and NEPT.

## LP Token Supply

{% hint style="info" %}
There will be a different LP token for each tAsset-nYUSD's NEPRIswap pool, as well as the NEPT-nYUSD pool. The descriptions below refer to each individual pool's supply of LP tokens.
{% endhint %}

### Minting

A user can provide liquidity by depositing tokens to both sides of a NEPRI TFA-related NEPRIswap pool. This results in the creation of LP tokens for that pool, which they can use to retrieve assets from the pool.

#### Creating a new pool

For a new pool with starting quantities of nYUSD and tAsset / NEPT $$x\_0,y\_0$$, the number of LP tokens is:

$$
LP=
\sqrt{x\_0,y\_0
}

​
$$

#### Adding to an existing pool

Given quantities of nYUSD and tAsset/NEPT being deposited$$A\_{\text{in}},B\_{\text{in}}$$, and currently in the pool prior to deposit$$X,Y$$, and the current supply of LP tokens $$\text{LP}\_{\text{total}}$$, the amount of newly minted LP tokens is:

$$
LP
\_{new}
​
​
\=min(

\frac{A
\_{in}
​	}{X}
​

​
LP\_{total}
​
,

​ \frac{B
\_{in}
​	}{Y}

​
LP\_{total}
​
)
$$

Although liquidity providers can deposit any amount for both tokens, they are incentivized to put in quantities where value is equal on both sides, taking into consideration the tAsset or NEPT's market price. Doing otherwise would cause them to incur losses as it would create arbitrage opportunities against the pool, and the LP tokens they received would be insufficient to recover their liquidity.

### Burning

{% hint style="info" %}
It is very probable that the amounts of assets recovered by burning LP tokens will be different from the quantities deposited. This comes from a variety of reasons such as price movement of tAsset / NEPT, changes in your relative share of the liquidity pool, etc.
{% endhint %}

A user can burn their LP tokens to recover their deposited liquidity. The pool will send back amounts of nYUSD and tAssets (or NEPT), depending on the amount of LP tokens they burn, determined by the formulas shown below.

$$
A\_{out}
​ =  \frac{LP
\_{burn} }{LP
\_{total}}  X
$$

$$
B\_{out}
​ =  \frac{LP
\_{burn} }{LP
\_{total}}  X
$$

### ​LP Commission Rewards

Holders of LP tokens will receive a portion of rewards generated by the pool's trading fees, divided out in proportion to the total share of LP token pool. A portion of either tAsset/NEPT or nYUSD (depending on the direction of the trade) gets added back into the pool as the **LP Commission.**

This functionality will not be implemented in the NEPRI TFA Protocol contracts, and come purely due to NEPRIswap's incentive structure for liquidity providers. Because the trading fee rewards will be returned to the pool, they can only be withdrawn by burning LP tokens and withdrawing liquidity.

{% hint style="info" %}
This section discusses staking rewards for LP tokens, which come from the new NEPT tokens minted per block by the protocol as inflation. Staking NEPT also generates NEPT rewards, which come from trading fees rather than inflation.&#x20;
{% endhint %}

NEPRI TFA  will allow users to additionally profit from LP tokens by staking them to receive NEPRI TFA Token (NEPT) rewards. The LP tokens can be unstaked at any time, and then burned to retrieve the corresponding deposited liquidity and LP Commission rewards.

At each block, the protocol introduces into circulation an amount of NEPT tokens (which had been locked by the protocol), by distributing them across all stakers of LP tokens in proportion to their total weighted stake.

NEPRI TFA Protocol will reward stakers of LP tokens for each of the tAsset-nYUSD pools as well as the NEPT-nYUSD pool. All tAsset-nYUSD staking pools will receive a weight of 1, while the NEPT-nYUSD pool will receive a weight of 3. Therefore, there will be a stronger reward incentive to stake NEPT-nYUSD LP tokens as they confer 3 times the reward when staked relative to tAssets.

The block reward, $$R\_{t *{k}}$$ for a specific staking pool corresponding to asset $$t*{k}$$with weight $$w\_{k}$$and quantity$$I$$of NEPT introduced into circulation per block, is given by:

$$
R
*{t*{k}}
​

​
\=   \frac{w
*{t*{k}}
​

​}{\sum\_{i}{w\_{t\_{i} }}}

I
$$


---

# 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://nepri.gitbook.io/neprifinance/lp-tokens.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.
