Rabbit Finance's leveraged yield farming and margin trading are based on the lending and borrowing functions of Rabbit Finance Bank. Relying on the lending and lending system and leverage function, the Bank, leveraged yield farming and margin trading together constitute the entire ecology of Rabbit Finance, continuously improving the the funds utilization.
At present, a total of 15 kinds assets are supported by Rabbit Finance Bank to deposit and obtain interest, including BNB, BUSD, USDT, BTCB and ETH, etc.
Depositors (Lender) can get 2 kinds of gains, namely:
Interest income generated from the borrowing interest payment from the borrowers (automatic reinvestment)
RABBIT reward allocated to ibTokens staked in the RABBIT reward pool
Borrowers (Farmer & Trader) can farm or trade on margin with lower cost and more funds from Rabbit Finance Bank, while paying a certain amount of borrowing interest to Rabbit Finance Bank.
What are ibTokens?
When a user supplies their assets to Rabbit Finance's lending pools, ibTokens (interest-bearing Tokens) are used to keep track of the funds they have deposited as well as any interest earned.
Each time a user supplies funds to the lending pool, they are issued a corresponding balance in ibTokens. This balance of the ibTokens is directly proportional to the stake they have in the lending pool, which accrues interest every block.
Each lending pool has its own ibToken, for example, if a user lends BNB to the protocol, they will receive a corresponding balance of ibBNB.
How do ibTokens earn interest?
Each deposit vault earns interest. However, the interest isn't distributed. Instead, simply by holding ibTokens, you'll earn the interest.
ibTokens accumulate interest through their exchange rate; over time, each ibToken's value increases, becoming convertible into a larger amount of its underlying asset with every block, even while the number of ibTokens in your wallet stays the same.
Each deposit pool has its own utilization which will also reflect how much the corresponding ibTokens will appreciate over time.
The longer a user holds ibTokens, the higher the value of those tokens appreciates. This is the accumulation of interest.
You do not need to stake ibTokens to enjoy this price appreciation, although you will still earn it while your tokens are staked.
Do I need to calculate the ibTokens exchange rate?
When Rabbit Finance was launched, the ibToken exchange ratio (ie. how many BNB one ibBNB was worth) began at 1:1. Since the launch of leveraged yield farming though, it has continued to increase at a rate equal to the compounding market interest rate. This represents the accrual of the lending fees to lenders' tokens.
For instance, if the lending APY for a year was an average of 50%, the value of the ibToken at the end of the year would be ~1.5.
Each user has the same ibToken exchange rate; there’s nothing unique to your wallet that you have to worry about.
Let's say you deposit 1,000 BNB in our vault when each ibBNB is worth 1.05 BNB, you would receive 952.38 ibBNB (1,000 / 1.05)
A few months later, you decide it’s time to withdraw your ibBNB from the vault, when the exchange rate is 1.10. The following will occur:
Your 952.38 ibBNB is now equal to 1,047.618 BNB (952.38 * 1.10)
You could withdraw 1,047.618 BNB, which would exchange all 952.38 ibBNB
Or, you could withdraw a portion, such as your original 1,000 BNB, which would redeem 909.09 ibBNB (keeping 43.29 ibBNB in your wallet)