Borrowing

This section will show an example of a a user borrowing DAI with a 50% LTV and $2000 worth of ETH as collateral. The user will borrow ~1000 DAI from three different liquidity pools.

Each liquidity pool has a different maturity. One is a 1-year pool (fDAI maturing in one year), one is a 6-month pool (fDAI maturing in 0.5 years), and the last is a 3-month pool (fDAI maturing in 0.25 years).

Here is what the pools look like before the user borrows.

Before borrowing

In order to borrow, a user must provide collateral and mint an fDAI pair (+fDAI and -fDAI). Then the borrower needs to swap +fDAI for DAI. Here's what the borrower's portfolio looks like once they mint the fDAI pair.

Notice that the borrower needs to mint more fDAI in order to borrow for one year then he needs to mint if he wants to borrow for six months or three months. This represents the extra interest the borrower will pay over the longer time period.

Borrowing

Now the borrower needs to swap the +fDAI for DAI on the liquidity pool. Here are the details of the swap that the borrower will get on each liquidity pool.

Note that once the borrower swaps his +fDAI for DAI, he will have a -fDAI position in his portfolio.

After borrowing

Here is what the liquidity pools look like after the user has borrowed and swapped fDAI for DAI.