Giter Club home page Giter Club logo

uniswapv3's Introduction

The solution of the task

In this example we use the Polygon blockchain.

To calculate the amount of assets we can buy without changing the price of the pair, we need to find the Liquidity
that is in the range of lowerTick and upperTick based on the current Slot0.Tick and TickSpacing.

Knowing the current tick and also the upper and lower ticks, we should calculate the corresponding root of the price (√pa, √pb, √P)
to use further in the Equations.

Now use the Equations from chapter 3.3.3 of the document https://atiselsts.github.io/pdfs/uniswap-v3-liquidity-math.pdf
to calculate the amount for the each asset of the assets in a ticks range

We use library github.com/daoleno/uniswapv3-sdk to make requests to smartcontract and make different Uniswap v3 mathematical operations

uniswapv3's People

Watchers

 avatar

Forkers

justldq

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.