Skip to content

Erroneous claim about equality of PMM curve to AMM curve when K=1 #83

@azaidelson

Description

@azaidelson

In the PMM explanation here[https://dodoex.github.io/docs/docs/pmm] there is a statement that if k=1, the PMM curve actually becomes the same as AMM curve. This seems wrong.

It would be correct if the exponent of (B0/B) equaled one. It is not correct if the exponent is 2 as in your final formula.

Proof:
The AMM formula looks like this (with zero fees): dy = dx*Y / (X+dx). Here, X and Y are amounts of liquidity present in the pool for assets X and Y, dx is the amount of asset x sold, and dy is the amount received.

If we translate this to Dodo nomenclature with k=1, P = dx/dy, and P also equals X/Y * (Y/(Y-dy)).
Indeed, dx/dy equals the actual price (P), X/Y is the initial price i, and Y/(Y-dy) is essentially B0/B.

After algebraic simplification, we bring the expression dx/dy=X/Y*(Y/(Y-dy)) to the exact AMM formula: dy = dx*Y/(X+dx)
Of course, if the exponent of Y/(Y-dy) was 2, we would not get to this result.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions