MultiversX Tracker is Live!

Bonding Curve Algorithms for Autonomous Market Makers (DEX)

Etherum Reddit

More / Etherum Reddit 261 Views

We provide over 100+ FREE crypto articles on our SubStack! :D (Link on our profile). This is not financial advice.

TLDR:

Instead of bonding curves showing the relationship between token price and token supply, in AMM, bonding curves shows the relationship between token A and token B. It is done via math, specifically using a variable called invariant. Also, you can use more than just 2 tokens in your AMM algorithm!

General Conclusion

Oh boy, we are covering a lot in this episode. Buckle up. It's fun, I promise you.

In Part 1, we covered the basics of token bonding curves and understand how the shape of the curve affects the incentive mechanism. We used a 2D graph to visualise the understanding of incentives.

In this episode, we look into the application of token bonding curve in decentralised exchanges (DEX). Specifically, the use case of Autonomous Market Maker (AMM).

We dive into 4 case studies, of how token bonding curve adds real economic value to the ecosystem.

Projects in this episode: Bancor, Uniswap, Balancer, Curve

The concept of token bonding curve in the 4 DEXes are the same. But the application of how the token bonding curve algorithm is built is different. So we uncover the 4 various algorithms used in the 4 different token bonding curves.

1. In Pegged Tokens

This is the most straight forward and basic method. Bonding curves don't add much economic value, but we still use them.

Basically, 1 token into the smart contract = minting 1 new token.

Where do we see it? Aave. When you deposit 1 USDT in Aave, they mint 1 aUSD.

2. In Autonomous Market Maker (AMM)

This is probably the most popular use-case of bonding curves now, thanks to Bancor. Bancor is arguably the leader of using bonding curves in AMM.

Instead of bonding curves showing the relationship between token price and token supply, it shows the relationship between token A and token B.

How is it done? Via math formulas. Previous episode, we talked about the shape of curve, but in AMM, all the shapes are pretty much the same (concave shape). But the math formulas differ very much. The similarity in the math formulas is that they use this thing called invariant. It follows a physics formula in energy conservation principle.

Also, previously, we only talked about 2D graph visualisation. But with AMM, we can explore 3D, 4D, even nth-dimension graphs!

We use AMM in DEX because it facilitates transparent price discovery.

Where do we see it? Bancor, Uniswap, Balancer, Curve. You use these protocols to change Token A (e.g. MKR) for Token B (e.g. USDT).

If I can summarise, we are looking at 2 different types of models here.

One model is looking only at AMM with 2 tokens interacting with each other via a constant (aka invariant) in the model.

The other model is looking at more than 2 tokens interacting with each other via a constant (aka invariant) in the model.

Given the constraint of the constant, there is still a bunch of really fun variables to play around and change. For example, changing various token weightage, allowing for information via oracles, etc.

So if you are starting up a DEX or a protocol that requires AMM, take note of the following:

  1. Your invariant in your math model
  2. Number of tokens to consider
  3. What variables can you relax in your model (e.g. token weightage, tokens chosen)
submitted by /u/economicsdesign
[link] [comments]
Get BONUS $200 for FREE!

You can get bonuses upto $100 FREE BONUS when you:
πŸ’° Install these recommended apps:
πŸ’² SocialGood - 100% Crypto Back on Everyday Shopping
πŸ’² xPortal - The DeFi For The Next Billion
πŸ’² CryptoTab Browser - Lightweight, fast, and ready to mine!
πŸ’° Register on these recommended exchanges:
🟑 Binance🟑 Bitfinex🟑 Bitmart🟑 Bittrex🟑 Bitget
🟑 CoinEx🟑 Crypto.com🟑 Gate.io🟑 Huobi🟑 Kucoin.



Comments