Token Balance at Liquidity Thresholds

I think it would be helpful and/or illustrative of how DLMM works if when building the position the UI shows how much of each token you would be left with if the pool moves out of your range. Maybe it could be called high/low threshold positioning or something, as in when you move out of range these are the tokens you will be holding. I think for people new to DLMM as well it would be a concrete data point to help understand how it works.

It would be helpful especially when placing one sided liquidity to try and sell or purchase at a certain price to see your cost weighted average price you are targeting.

I don’t think it would be too difficult to implement as it is a summation of all of the bins at the two extremes, but a question of whether others think this would also be helpful.

Cheers,
Timothy

3 Likes

I agree that something like this would be useful. I proposed an Impermanent / Divergence Loss Simulator Mode in the discord proposals channel, that would be similar to what you’re proposing, and would provide some additional functionality. I will repost here for posterity:

There could be a toggle button to enable simulator mode when in the Add Liquidity form or in the Add Position form. When the simulation mode button is clicked, the UI highlights to indicate it is in simulation mode and the button can be clicked again to toggle back to normal mode. The Add Liquidity button disappears when in simulation mode.

In simulation mode, the Curent Price changes to Simulated Price . The deposit amounts are still enabled, and if a deposit amount has been entered in one or both fields, when the user clicks and drags the simulated price, the UI will update to show the original starting values, the new values at the new price, and the difference in the balances. It could also calculate the starting value in the quote symbol, the new value in the quote symbol, and the difference (i.e. P&L) in the quote symbol. The existing current pool price toggle at the top would flip the quote symbol.

If the user is in the Add Liquidity form when enabling the simulator mode, the calculations above will occur for the additional position, the existing position, and combined.

2 Likes

That sounds good to me! You get way more information to play with in your suggestion and the visualization would help a lot I think. At the same time you could easily get the two data points I am talking about or the one you were interested in if you for example think that one token will go up.

2 Likes