IL Formula mAssets

Heyhey,
fairly new to staking and all things Mirror. Could someone ELI5 what happens with IL in price movements of one of the provided assets?
ex:
1.
100 UST
$100 mTSLA

drops

$50 mTSLA

Net result for me?

100 UST
$100 mTSLA

increases

$300 mTSLA

Net result for me?


Much appreciated!

it is impossible to say for sure as pools are dynamic, and it will depend on the ratio of pooled assets in the pool at the moment you deicde to withdraw your liquidity.
here is a reasonable article explaining IL impermanent-loss-explained
this video is also good https://youtu.be/3up4n1_pkQg?t=140
you can also use this tool for rough estimation advanced-impermanent-loss-calculator

estimating your usecases using the tool above:
let’s assume 1 mTSLA at the moment of providing liquidity was $100
so, you provide 1 mTSLA and $100

  • usecase 1

    • price of mTSLA drops to $50
    • pool more or less stabilizes
    • if you withdraw your funds you will have ~1.4 mTSLA and $70, which would be ~$140 total value + MIR rewards for providing liquidity
    • if you just held 2 mTSLA without providing liquidity, total value would be $100
    • if you just held $200 without providing liquidity, total value would be $200 (surprisingly)
  • usecase 2

    • price of mTSLA rises to $300
    • pool more or less stabilizes
    • if you withdraw your funds you will have ~0.6 mTSLA and ~$170, which would be ~$350 total value + MIR rewards for providing liquidity
    • if you just held 2 mTSLA without providing liquidity, total value would be $600
    • if you just held $200 without providing liquidity, total value would be still $200

and of course it is called impermanent because if mTSLA first drops to $50 and then rises back to $100 - you will have your 1 mTSLA and $100 again

with actual price of mTSLA at $640.76 (right now)
you would provide ~0.16 mTSLA and $100

  • usecase 1

    • price of mTSLA drops to $320.38 (-50%)
    • pool more or less stabilizes
    • if you withdraw your funds you will have ~0.22 mTSLA and $70, which would be ~$140 total value + MIR rewards for providing liquidity
    • if you just held ~0.32 mTSLA without providing liquidity, total value would be ~$100
    • if you just held $200 without providing liquidity, total value would be $200 (surprisingly)
  • usecase 2

    • price of mTSLA rises to $1922.28 (+200%)
    • pool more or less stabilizes
    • if you withdraw your funds you will have ~0.09 mTSLA and ~$175, which would be ~$350 total value + MIR rewards for providing liquidity
    • if you just held ~0.32 mTSLA without providing liquidity, total value would be ~$600
    • if you just held $200 without providing liquidity, total value would be still $200