# Lend

Lending in the Neptune Protocol offers a way for users to earn yield on crypto assets which is generated by borrowers. Lending deposits in Neptune are represented by nTokens, a liquid receipt token which can be transferred, used as collateral and utilized in third party protocols. A users lending deposits can be redeemed by returning nTokens to the protocol.&#x20;

## How Lending Works

Lending in the Neptune Protocol allows users to deposit their digital assets into a lending pool. In return, they receive nTokens, which represent their share of the pool. These nTokens automatically accumulate interest over time.

### Steps to Lend

1. **Deposit Assets**: Users deposit their assets into the Neptune lending pool.
2. **Receive nTokens**: In exchange, users receive nTokens, which are CW20-compliant tokens representing their share of the pool.
3. **Accumulate Interest**: As the pool generates interest, the value of nTokens increases, allowing users to redeem more of the underlying asset than they initially deposited.

### Lending Equation

The value of nTokens increases as interest accrues. The relationship can be expressed as:

$$
\text{nToken Value} = \text{Initial Deposit} \times (1 + \text{Interest Rate})^t
$$

Where:

* `Initial Deposit` is the amount of assets initially deposited.
* `Interest Rate` is the rate at which interest is accrued.
* `t` is the time period over which interest is calculated.

## Understanding nTokens

nTokens are a crucial component of the Neptune Protocol. They serve as proof of a user's lending position and can be used as collateral for borrowing.

### Key Features of nTokens

* **Interest Accumulation**: nTokens automatically accumulate interest, increasing in value over time.
* **Transferability**: nTokens can be transferred between users, maintaining the underlying lending position.
* **Collateral Use**: nTokens can be used as collateral in Neptune markets, allowing users to borrow against their lending positions.

## Redeeming Assets

Redeeming is the process of exchanging nTokens back for the underlying assets. As nTokens accumulate interest, users can redeem them for more assets than they initially deposited.

### Steps to Redeem

1. **Burn nTokens**: Users initiate the redemption process by burning their nTokens.
2. **Receive Assets**: In return, users receive the underlying assets plus any accrued interest.

### Redemption Equation

The amount of assets received upon redemption is calculated as:

$$
\text{Redeemed Assets} = \text{nTokens Burned} \times \text{Current nToken Value}
$$
