
Being LP with Iotabee — Part II: Impermanent Loss explained
Being LP with Iotabee — Part II: Impermanent Loss explained
Disclaimer: this article is part of the Iotabee DeFi Honeypot column. It aims at providing entry-level knowledge on Decentralized Finance (DeFi) topics for information only. It is not intended, and should not be understood or constructed as financial advice. All investment activities should be carried out with caution and at your own risk.
Hi guys, it’s Iotabee DeFi honeypot again! Today we will continue with the topic we started last time: Being LP with Iotabee. In this article, we’ll review the basic concepts around the Impermanent Loss, and provide a few alternative calculations and considerations that you may not find in other materials yet.
If you have not yet read our previously article on APR, check it out here.
Ready? Let’s go!
Impermanent Loss — Basics
In our previous article, we have explained what Impermanant Loss is, and provided a very simple calculation based on the USDT/MIOTA trading pair. Back then, we also discussed the mechanism of AMM, especially the formula x*y = k. As a result, when exiting the pool ( earned fees excluded), you are likely not exiting with the exact same amount of tokens, which is your impermanent loss.
With he example of USDT/MIOTA, it may be more obvious to calculate, as you can easily translate your token values to USDT, where USDT value is stable and close to that of USD so that it is straightforward to understand.
However, believe it or not, you do not actually need to know your tokens’ real-time market value to calculate your impermanent loss. The only important factor is the price change, i.e. how the ratio of token amounts has changed.
Let’s use MIOTA/SMR as an example and enter an advanced version of understanding the impermanent loss!
Impermanent Loss — Advanced: how exactly is it calculated?
The formula for the impermanent loss of a given price change δ is:
IL (δ) = 2(√δ)/ (δ+1) — 1
where, δ = price change = new price (as a ratio of the amount of token A vs token B)/ initial price (as a ratio of the amount of token A vs token B) for example, if you deposited with a price 1 MIOTA = 4 SMR, and withdraw with a price 1 MIOTA = 2 SMR, then δ= (1/2)) / (1/4) = 2
The above formula IL (δ) = 2(√δ)/ (δ+1) — 1 shows that only when δ = 1, then that the IL(δ) = 0, meaning no impermanent loss occurred. In all the other cases, whether δ > 1 ( meaning price increases) or δ< 1 ( meaning price decreases), IL (δ) is always a negative number, i.e the impermanent loss occurs.
The exact calculating process can be a bit long ( and boring), but if you’re interested, we can show the whole calculation in a separate article next time.
Based on this formula, you can easily calculate what your impermanent loss will be for a given price change δ.
For example, in the case mentioned above,
when SMR price doubled compared to MIOTA, δ= 2,
IL (0.5) = -5.72%, meaning 5.72% of loss in your asset value by providing liquidity.
What can we know from this?
- Find out the curve of the impermanent loss:
- With the curve you can identify the zone where the Impermanent loss is relatively small. From there, you can combine it with your own estimation on the price change, then have a pretty good prediction of your impermanent loss while exiting the pool. Smaller impermanent loss can be covered by your gain in fees with time while significant ones can be hard to recover from.
- Understand how the volatility of the tokens in a trading pair can impact your IL.
- From the formula, you have understood that the price change δ is the key. Hence to reduce risks, you may want to prioritize more stable trading pairs such as trading with MIOTA.
- For example, if, for the pair SMR/MIOTA, SMR price goes up to twice, δ=2, IL(δ)= -5.72%;
- and for the pair MIOTA/ A Project token, the project token goes down to 1/2, δ = 2, IL(δ = -5.72%;
- then for the pair SMR / Project token, δ = 4, impermanent loss = -20%
- The difference in impermanent loss is significant. Since MIOTA is more stable, trading pairs with MIOTA typically suffer less from impermanent loss.
An alternative calculation based on your token amounts
As MIOTA is the base currency in our ecosystem, we also consider that many people are actually seeing things based on their MIOTA asset. This is a different way of calculating your gain and loss than the classical Impermanent Loss calculation. If you’re in this category, we also have something for you.
Conclusion first: if you are taking this approach, then you need to have your own judgement on the price trend, then adjust your operations accordingly.
Let’s take the trading pair SMR/MIOTA again as an example.
Say, when you deposit, the price is 1 MIOTA = 3 SMR,
—
If SMR price has increased at withdrawal,
for example, to 1 MIOTA = 2 SMR.
Then after the calculation based on AMM principles, you can withdraw 1.225 MIOTA and 2.45 SMR.
If you calculate your asset value based on the number of MIOTA tokens, then:
When you deposit, you have 2 MIOTA tokens ( 1MIOTA + 3SMR),
When you withdraw, you have 2.45 MIOTA tokens ( 1.225 MIOTA + 2.45 SMR),
Your MIOTA assets have increased by 22.5% ( (2.45–2)/2 = 22.5%)
—
If SMR price has decreased at withdrawal
When SMR price decreases, on the contrary, after providing liquidity, your MIOTA assets will decrease
Now you have the calculations. How can you adjust your operations then?
The calculations actually indicate that,
—
When you believe that the actual SMR price is underestimated ( i.e. the price will increase compared to MIOTA), then you could use your MIOTA to buy some SMR tokens to provide liquidity because:
1) in this way, providing LP is more like a consistent sell higher strategy
2) you can earn trading fees by providing liquidity;
—
When you believe that the actual SMR price is overestimated (i.e. the price will decrease compared to MIOTA), then you could sell some SMR at the current price to buy MIOTA to provide liquidity because:
1) with time, the eventual SMR amount in your deposited assets will actually increase ( being bought back at a lower price in the pool)
2) you can earn trading fees by providing liquidity.
Conclusion
Alright, let’s summarize the key leanings and tips from today’s content:
- The formula to calculate your impermanent loss for a given price change δ: IL (δ) = 2(√δ)/ (δ+1) — 1
- Tips from this are:
1) impermanent loss is only relevant to the price change;
2) prioritize stable trading pairs such as trading with MIOTA to better reduce risk
2. If you calculate your loss and gain based on the amount of your MIOTA tokens, then:
Having your own judgement for the token price is crucial for your operations.
- Tips from this are:
1) if you believe that one token will increase in price compared to MIOTA, then use your MIOTA to buy this token to provide liqudity;
2) if you believe that one token will decrease in price compared to MIOTA, then sell some at the current price to buy MIOTA to provide liquidity.
Reminder:
Again, please bear in mind that the above calculations are only our own thoughts and perceptions. They shall not be considered as financial advice by any means. You are responsible for your own investment activities. Think twice and act cautiously!
Happy trading and we’ll see you next time in our Iotabee DeFi Honeypot!

