I know a little bit about the Uniswap, providing liquidity, bonding curves...

But I'm still struggling to perform the actual math - what is the actual formula?

Real-life example (easier to operate on real numbers)

enter image description here


Round numbers:

  • 300 ETH
  • 300k GET

Say I'm a whale and I add 60 ETH and 60k GET to the bonding curve.

The bonding curve now:

  • 360 ETH
  • 360k GET

I have 20% of the liquidity pool.


What will happen in cases 1 and 2?

  1. Someone sends 10 ETH into the bonding curve?

  2. Someone sends 10k GET into the bonding curve?

My understanding is that I will still own 20% of the liquidity pool but what about the actual numbers of ETH and GET?

1 Answer 1


As a liquidity provider, you cannot send money on either side of the pool, they need to be added in the same proportions.

However, someone is free to buy ETH/GET or buy GET/ETH from the pool. In this case the number of tokens left in the pool changes and the price moves using the following formula:

ETH/GET price before = 360/360k = 1000

For the case (1): bought 1000 GET with 10 ETH

ETH/GET new price = 350k/370 = 945

For the sake of simplification, I left of liquidity provider fees from the calculations.

  • Correct. When you add liquidity you must add both pairs in the same proportions as initially specified. When someone buys or sells is when the price changes according to the formula. Sep 14, 2020 at 16:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.