Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix formula #720

Merged
merged 1 commit into from
May 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions 56_DEX/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ tags:

![](./img/56-1.png)

接下来,我们以可乐($COLA)和美元($USD)的市场为例,给大家介绍 AMM。为了方便,我们规定一下符号: $x$ 和 $y$ 分别表示市场中可乐和美元的总量,$\Delta x$ 和 $\Delta y$ 分别表示一笔交易中可乐和美元的变化量,$L$ 和 $\Delta L$ 表示总流动性和流动性的变化量。
接下来,我们以可乐($COLA)和美元($USD)的市场为例,给大家介绍 AMM。为了方便,我们规定一下符号: $x$ 和 $y$ 分别表示市场中可乐和美元的总量, $\Delta x$ 和 $\Delta y$ 分别表示一笔交易中可乐和美元的变化量,$L$ 和 $\Delta L$ 表示总流动性和流动性的变化量。

### 恒定总和自动做市商

Expand Down Expand Up @@ -442,4 +442,4 @@ contract SimpleSwap is ERC20 {

## 总结

这一讲,我们介绍了恒定乘积自动做市商,并写了一个极简的去中心化交易所。在极简Swap合约中,我们有很多没有考虑的部分,例如交易费用以及治理部分。如果你对去中心化交易所感兴趣,推荐你阅读 [Programming DeFi: Uniswap V2](https://jeiwan.net/posts/programming-defi-uniswapv2-1/) 和 [Uniswap v3 book](https://y1cunhui.github.io/uniswapV3-book-zh-cn/) ,更深入的学习。
这一讲,我们介绍了恒定乘积自动做市商,并写了一个极简的去中心化交易所。在极简Swap合约中,我们有很多没有考虑的部分,例如交易费用以及治理部分。如果你对去中心化交易所感兴趣,推荐你阅读 [Programming DeFi: Uniswap V2](https://jeiwan.net/posts/programming-defi-uniswapv2-1/) 和 [Uniswap v3 book](https://y1cunhui.github.io/uniswapV3-book-zh-cn/) ,更深入的学习。