• News
    • Bitcoin
    • Altcoins
    • Blockchain
    • DeFi
    • Regulation
    • Scams
  • NFT
  • Metaverse
  • Analysis
  • Learn
  • Videos
  • Blogs
  • Market Cap
  • Shop
What's Hot

US Treasury sanctions Philippines tech firm over aiding $200 million pig butchering spree

2025-05-30

What Is Asset Tokenization? Types, Why It Matters Now [2025]

2025-05-30

Bitcoin Spammers Working With The CCP?

2025-05-29

Subscribe to Updates

Get the latest creative news from FooBar about art, design and business.

Facebook Twitter Instagram
Crypto Investor News Network
  • News
    • Bitcoin
    • Altcoins
    • Blockchain
    • DeFi
    • Regulation
    • Scams
  • NFT

    All Eyes on Art: Upcoming Collections to Watch the Week of February 4

    2025-02-05

    Creator of rabbit AI assistant has hidden NFT past

    2024-05-02

    Ethereum tops daily NFT sales at US$7 mln, ends weakest month of 2024

    2024-05-02

    Top NFT Airdrops and Giveaways for May 2024

    2024-05-02

    Casio Launches NFT Collection Celebrating 50th Anniversary

    2024-05-01
  • Metaverse

    Shib: The Metaverse – Part of the Expanding Shiba Inu Ecosystem

    2025-01-03

    Experience to Earn: Everdome’s Metaverse Frontier

    2024-12-30

    Beyond Bots: Meta Motivo and the Dawn of Humanlike Digital Life

    2024-12-13

    Exploring NetVRk: What Is Behind This AI-Driven Virtual Universe?

    2024-10-28

    Council of Europe Highlights Metaverse’s Impact on Privacy and Democracy

    2024-09-05
  • Analysis

    Crypto Exchange Coinbase Lists New DeFi Altcoin Project Built on Base Blockchain

    2023-12-13

    Ethereum Price Bears Keep Pushing, Why Decline Isn’t Over Yet

    2023-12-13

    Trader Bullish on Cosmos (ATOM), Says One Dogecoin Rival Setting Up for Next Leg Up – Here’s His Outlook

    2023-12-13

    AVAX Price Pumps 50% and Dumps 15%, Why Uptrend Is Still Strong

    2023-12-13

    Top Trader Predicts Parabolic Rally for Solana Competitor – Here’s His Upside Target

    2023-12-13
  • Learn

    What Is Asset Tokenization? Types, Why It Matters Now [2025]

    2025-05-30

    What Is Crypto Margin Trading? A Beginner-Friendly Guide to Leverage

    2025-05-26

    What Is Circulating Supply in Crypto? A Beginner’s Guide to Token Supply

    2025-05-23

    What Is a DEX? How DEXs Work and Why They Matter

    2025-05-21

    What Is Blockchain? Blockchain Technology Explained for Beginners

    2025-05-21
  • Videos

    Bitcoin Spammers Working With The CCP?

    2025-05-29

    MSTR Financial Jiu-Jitsu: Saylor’s Savage Capital Market Checkmate! 🔥🔥🔥

    2025-05-28

    🟠 Bitcoin Conference 2025 | Top Moments from Day 1 & 2 🧨

    2025-05-28

    🚀 OCTA: Things Are Melting Up Quietly 🔥📈

    2025-05-27

    Guess Who is Buying $2.5B of Bitcoin | Bull Run Continues

    2025-05-27
  • Blogs
  • Market Cap
  • Shop
Facebook Twitter Instagram TikTok
Crypto Investor News Network
Home»DeFi»Differences With V1 and V2
DeFi

Differences With V1 and V2

2023-10-14No Comments6 Mins Read
Facebook Twitter Pinterest LinkedIn Tumblr Email
Share
Facebook Twitter LinkedIn Pinterest Email

  • 1 Uniswap V3 allows to work in bounded ranges lesser than (0,∞)
  • 2 It provides UNI governance in addition to design different fee structures
  • 3 In Uniswap V3, it is possible to create multiple pools for each pair of token that too with different swap fees

An advanced version to Uniswap V1 and Uniswap V2, Uniswap V3 is Automated Market Maker (AMM) which gives liquidity providers higher control over price ranges in which the capital deposited by them is used without significantly affecting liquidity fragmentation and gas efficiency.

Uniswap V3 also works on the similar constant product [x*y=k] with added features. These are:

Concentrated Liquidity: The ability to concentrate liquidity by bounding it within an arbitrary price range is given to liquidity providers. In previous versions, liquidity was distributed along the reserve curve [x*y=k] where, x and y are reserves of the assets X and Y respectively while k is a constant. With the earlier version, liquidity was provided across the entire price range (0, ∞) while with V3 liquidity is provided across the smaller (finite) range than (0, ∞). Liquidity concentrated in a finite range known as Position. A position only needs to maintain liquidity reserve to facilitate trade between this range and therefore acts like constant product pools within larger reserves called virtual reserves within the range.

Uniswap V3 White Paper Summary: Differences With V1 and V2

Figure: Simulation of virtual liquidity

A position needs to hold enough assets in reserve X to cover the price movements to its upper limit because price-rise would lead to depletion of X reserves. And in case of Y, it needs to holds enough Assets in the reserve Y to cover the downward price movement to its lower limit. In the above graph, the relationship is shown for a position on a range [pa,pb] and a current price pcЄ [pa,pb] and xreal and yreal represents the position’s real reserves.

See also  stabble Secures $2.5M to Enhance Solana’s Decentralized Trading and Liquidity Ecosystem

What happens when the price exits the position range? The position’s liquidity is no longer active and does not earn fees. At this point, the reserve is composed of a single Asset as the reserves of the other asset must have been completely depleted. If the price again re-enters in the position, liquidity becomes active again. The real reserve of the position are calculated using

where, L is the amount of liquidity provided and is calculated as √k. The graphical representation of above equation is

Uniswap V3 White Paper Summary: Differences With V1 and V2

Figure: Real Reserves

This lets the market decide where to allocate liquidity and they can create as many as positions as can be fit into the price range. Rational Liquidity Providers can reduce cost of their capital by concentrating their liquidity in a narrow band around the current prices and then keep on adding/ removing tokens as the price moves.

Architectural Changes: Some of the changes that occurred from V1 and V2 to V3 were necessary to support concentrated liquidity positions while some are improvements in general. The improvements include (i) Multiple Pools Per Pair: Uniswap V3 allows multiple pool for each pair of token, with different swap fees while all the pools are created by the same factory contract and allows contract creation with three different fee categories 0.05%, 0.30% and 1% while it was 0.30% only in V1 and V2. In V3, additional fee structures can be implemented. (ii) Non-Fungible Liquidity: In V3, compounding of fees is not possible as fees are stored separately and are held as tokens in which fees are paid.

See also  Vietnamese Web3 coalition Ninety Eight launches $25M ecosystem fund

Governance: In Uniswap V3, UNI governance has more flexibility to change the fraction of the swap fees that is applicable on the protocols and also, it is able to implement additional layer of fee structures. It also has power to transfer ownership to another addresses.

Oracle: V3 does not require users of the oracle to track previous values of accumulator externally. In V3, it is possible to calculate arithmetic mean TWAP (Time-weighted Average Price) and geometric mean TWAP (V3 tracks the sum of log prices). It adds a liquidity accumulator which is tracked alongside the price accumulator that accumulates 1/L for each second.

Geometric mean TWAP can be calculated as between time period t1 and t2,

Implementing Concentrated Liquidity

  • Ticks and Ranges: Ranges are specified as a range of signed integer tick indices: a lower tick (il) and a upper tick (iu). Ticks represent the prices at which the virtual liquidity of the contract can change. There is a tick at every price p, an integer power of 1.0001. Representing ticks by an integer index i, prices are given by,

p(i) = 1.0001i

When liquidity is added to a range, if one or both of the ticks are not already used as the upper or lower limits, in any of the existing positions, then the tick is initialized. Not all the ticks can be initialized. The pool is initialized with a parameter known as tick spacing so all the ticks that could be initialized should be divisible by tick spacing. If tick spacing is smaller than it allows for tighter and more precise ranges.

  • Global State: The Global State of the contract includes seven storage variables relevant to swaps and liquidity positions.
See also  What’s the Truth of the KYC and Whitelist Debate?

Out of Liquidity and Price, only one changes at a time. Price changes when swapping within a tick and liquidity changes when crossing a tick or when minting or burning liquidity. L is calculated as x.y and P is calculated as y/x.

Current tick can be calculated on the basis of P . At any given point of time, the equation should be true is ic=[log1.0001P]

In Uniswap V3, fees are collected in the tokens themselves rather than liquidity. The global state of fees represents the total amount of fees that have been earned per unit of Virtual Liquidity L. The global state tracks the total accumulated uncollected protocol fees in each token and this can be collected by UNI governance.

Swapping in a Single Tick: When swapping one token for the other, the pool contract first compute the new P using formula P= y/L and to compute the amount of token0 or token1 to be send out using either of the two formulas: y=P .L or x=(1/P). L

Tick- Indexed State: Contract needs to store information about each tick in order to track the amount of net liquidity that should be added or removed when the tick is crossed, as well as to track the fees earned above or below that tick.

Position- Indexed State: Each Position structure tracks three values including liquidity, lower tick and upper tick to know the liquidity and uncollected fees position.

Differences
Share. Facebook Twitter Pinterest LinkedIn Tumblr Email

Related Posts

The Main Differences Between Crypto Exchanges

2025-03-03

Bitcoin vs. Altcoins: What Are The Differences?

2025-02-26

Sky Pauses Plan to Offboard Wrapped Bitcoin, After Chat With BitGo’s Belshe

2024-09-24

Aave (AAVE) regains $20B in net deposits

2024-09-24
Add A Comment

Leave A Reply Cancel Reply

Top Posts
Videos

This NEW $4.8B MicroStrategy Copycat JUST Sent A HUGE WARNING To The World

2025-03-27

The new $4.8B MicroStrategy copycat could break the markets — and investors are watching closely.…

Regulation

Judge Denies Kraken’s Request To Dismiss SEC Claims Alleging the Exchange Operated As Unregistered Securities Broker

2024-08-24

A judge shot down Kraken’s request to dismiss claims made by the U.S. Securities and…

Videos

DID YOU GET BONKED! [BTC ETF Approved! means…]

2023-12-20

I will show you how I make significant gains in the crypto market! Act NOW…

Subscribe to Updates

Get the latest news and Update from CINN about Crypto, Metaverse and NFT.

Editors Picks

US Treasury sanctions Philippines tech firm over aiding $200 million pig butchering spree

2025-05-30

What Is Asset Tokenization? Types, Why It Matters Now [2025]

2025-05-30

Bitcoin Spammers Working With The CCP?

2025-05-29

MSTR Financial Jiu-Jitsu: Saylor’s Savage Capital Market Checkmate! 🔥🔥🔥

2025-05-28
Crypto Investor News Network
Facebook Twitter Instagram TikTok
  • Contact
  • Terms & Conditions
  • Privacy Policy
  • DMCA
  • Disclouser
© 2025 - All rights are reserved.

Type above and press Enter to search. Press Esc to cancel.

bitcoin
Bitcoin (BTC) $ 104,724.06
ethereum
Ethereum (ETH) $ 2,541.81
tether
Tether (USDT) $ 1.00
xrp
XRP (XRP) $ 2.20
bnb
BNB (BNB) $ 659.27
solana
Solana (SOL) $ 157.50
usd-coin
USDC (USDC) $ 1.00
dogecoin
Dogecoin (DOGE) $ 0.193425
tron
TRON (TRX) $ 0.266
cardano
Cardano (ADA) $ 0.690677
bitcoin
Bitcoin (BTC) $ 104,724.06
ethereum
Ethereum (ETH) $ 2,541.81
tether
Tether (USDT) $ 1.00
xrp
XRP (XRP) $ 2.20
bnb
BNB (BNB) $ 659.27
solana
Solana (SOL) $ 157.50
usd-coin
USDC (USDC) $ 1.00
dogecoin
Dogecoin (DOGE) $ 0.193425
tron
TRON (TRX) $ 0.266
cardano
Cardano (ADA) $ 0.690677