On vAMM’s unnecessity for a liquidity pool

1 Why vAMM does not need a liquidity pool?

Perpetual Protocol’s vAMM uses the same 𝑥∗𝑦=𝑘 constant product formula as Uniswap. One of the very differences between vAMM and AMM is that vAMM does not require a physical liquidity pool. Although the price is still discovered by the AMM curve, traders indeed store their collateral in a smart contract vault. Such a mechanism arouses concerns about whether the vault is capable to meet the solvency demands at any time when traders are allowed to long and short in the protocol. Can vAMM still keep its path independence? This literature aims to simplify the solvency problem into several circumstances and prove that vAMM is capable of doing so.

2 Solvency Model

This literature simplifies the market model with only two components, A and B. Both A and B would either long or short the underlying asset. The chronological order of entering or clearing their position always follows that A goes first and B goes second.

In the real world, the solvency of vAMM can be regarded as a multiplication of trading pairs. So if this model can be proved valid in a dual-system, then vAMM can ensure solvency in the real market. The solvency procedure is classified into several categories. This literature will then prove the solvency of vAMM under each circumstance.

3 Notation

Before deriving the model, it is essential to clarify the notation used in this literature:

  • x: the base asset, e.g ETH
  • y: the quote currency, e.g USDC
  • Δ𝐴: the notional amount of investor A
  • Δ𝐵: the notional amount of investor B
  • xᵢ: the ith step of 𝑥x during the solvency
  • yᵢ: the ith step of 𝑦y during the solvency
  • Δxᵢ: the absolute change of x after the ith step is launched
  • Δyᵢ: the absolute change of y after the ith step is launched
  • gA: A’s capital gain after clearing his position
  • gB: B’s capital gain after clearing his position

4 Derivation

4.1 A long, B long (ΔA<ΔB)

Procedure:

  • The creator can set an initial amount of 𝑥 and 𝑦 on vAMM, respectively with volume 𝑥0 and 𝑦0.
  • Investor A wants to long the underlying asset 𝑥x with a certain ratio of leverage. The protocol thus credits Δ𝐴 from Investor A to the vAMM. In the meantime, we can calculate the amount of 𝑥 that Investor A receives from the protocol. In this step, 𝑥0 moves to 𝑥1.
  • Investor B also wants to long the underlying asset 𝑥. The protocol thus credits Δ𝐵 from Investor B to the vAMM. In the meantime, the amount of 𝑥 that Investor B receives could be discovered. In this step, 𝑥1 moves to 𝑥2.
  • Investor A decides to clear his position and receives 𝑔𝐴 from the protocol. So 𝑥2 moves to 𝑥3.
  • Finally, Investor B clears his position and receives 𝑔𝐵 from the protocol. 𝑥3 moves to 𝑥4 and the trading ends.

Conclusion:

  • From the plot, it is easy to find 𝑔𝐴+𝑔𝐵=Δ𝐴+Δ𝐵g. Thus, 𝑔𝐴−Δ𝐴=Δ𝐵−𝑔𝐵. A’s gain covers B’s loss. So the vault always has enough collateral to pay back every trader under this circumstance.
  • And so forth, it’s easy to deduce that one trader’s gain will cancel out another trader’s loss when A short and B short, no matter the size of their notional.

4.2 A long, B short (Δ𝐴>Δ𝐵)

Procedure:

  • The creator can set an initial amount of 𝑥 and 𝑦 on vAMM, respectively with volume 𝑥0 and 𝑦0.
  • Investor A wants to long the underlying asset 𝑥 with a certain ratio of leverage. The protocol thus credits Δ𝐴 from Investor A to the vAMM. In the meantime, we can calculate the amount of 𝑥x that Investor A receives from the protocol. In this step, 𝑥0 moves to 𝑥1.
  • Investor B wants to short the underlying asset 𝑥. The protocol thus credits −Δ𝐵 from Investor B to the vAMM. In the meantime, the amount of 𝑥 that Investor B shorts could be discovered. In this step, 𝑥1 moves to 𝑥2.
  • Investor A decides to clear his position and receives 𝑔𝐴 from the protocol. So 𝑥2 moves to 𝑥3.
  • Finally, Investor B clears his position and redelivers Δ𝑥2 unit of 𝑥 to the protocol. 𝑥3 moves to 𝑥4 and the trading ends.

Conclusion:

  • From the plot, it is easy to find 𝑔𝐴−Δ𝐴=Δ𝐵−𝑔𝐵. A’s loss is covered by B’s profit. So the vault always has enough collateral to pay back every trader under this circumstance.
  • And so forth, it’s easy to deduce that one trader’s gain will cancel out another trader’s loss when Δ𝐴<Δ𝐵.

4.3 A short, B long(Δ𝐴>Δ𝐵)

Procedure:

  • The creator can set an initial amount of 𝑥 and 𝑦 on vAMM, respectively with volume 𝑥0 and 𝑦0.
  • Investor A wants to short the underlying asset 𝑥x with a certain ratio of leverage. The protocol thus credits −Δ𝐴from Investor A to the vAMM. In the meantime, we can calculate the amount of 𝑥 that Investor A shorts from the protocol. In this step, 𝑥0 moves to 𝑥1.
  • Investor B wants to long the underlying asset 𝑥. The protocol thus credits Δ𝐵 from Investor B to the vAMM. In the meantime, the amount of 𝑥 that Investor B receives could be discovered. In this step, 𝑥1 moves to 𝑥2.
  • Investor A decides to clear his position and redelivers Δ𝑥1 unit of 𝑥 to the protocol. So 𝑥2 moves to 𝑥3.
  • Finally, Investor B clears his position and receives 𝑔𝐵 from the protocol. 𝑥3 moves to 𝑥4 and the trading ends.

Conclusion:

  • From the plot, it is easy to find 𝑔𝐴−Δ𝐴=Δ𝐵−𝑔𝐵. A’s loss is covered by B’s profit. So the vault always has enough collateral to pay back every trader under this circumstance.
  • And so forth, it’s easy to deduce that one trader’s gain will cancel out another trader’s loss when Δ𝐴<Δ𝐵.

5 Benefits & Risks of LP

5.1 Benefits

  • Provide Initial Liquidity The DeFi protocol needs to initialize the liquidity pool in order to provide services with a larger amount of funds (thus it can attract more demanders), so the liquidity pool just plays this role and distributes the potential benefits to the early-stage liquidity provider.
  • Attract Users For the DeFi protocol itself, the liquidity pool can attract more users to participate in the use of the protocol to earn yields. Specifically, a soaring TVL could boost engagement in social media and accelerate the convergence of consensus, which attracts more users to the protocol in return. Besides, yield farming also attracts a number of long-term cryptocurrency investors since the liquidity pool could offer substantial profits during their holding period. In a word, the liquidity pool is a recycling system for the protocol’s promotion and recycling.
  • Promote Decentralized Governance The protocol can allocate its governance authority to its long-term investors and solid believers, rather than speculators or the development team, in order to realize a true decentralized autonomous organization.

5.2 Risks

  • Impermanent Loss Impermanent loss is an inevitable topic when coming to the liquidity pool of AMM. It refers to the difference between holding the tokens directly and injecting the tokens into an AMM liquidity pool. As long as the price changes with respect to your deposit price, an impermanent loss will be incurred.
  • Market Risk If you use a Deposits & Borrow platform, like Compound or Aave, when your collateral is no longer sufficient to cover your loan amount due to the volatility of the borrowed assets or collateral, the automatic liquidation of the collateral will be triggered. You will be also imposed on a liquidation fee.
  • Smart Contract Risk The smart contract code is immutable and operates exactly as specified. However, for this reason, if a smart contract has man-made or non-man-made loopholes, it can be exploited without recourse. The contract cannot be guaranteed to be 100% safe even if the contract code is audited. Such risks must be taken into account when considering investments in yield farming.

--

--

--

Love podcasts or audiobooks? Learn on the go with our new app.

Translate OneDrive Documents with DeepL and Power Automate

Getting off to a Running Start — RunIO Hackathon

Community AMA Transcript

Visualization testing with BDD — using Applitools

Python program to find square root of the number using Newton’s method.

Migrating from IBM-DB2 on AS400 to SQL Server 2017

How to Choose the Right Type of Database for your Enterprise? — Aalpha

Let’s Build A Web App! Week 19 of my 30 week web dev journey

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Alex

Alex

More from Medium

👨‍🌾 DFSocial launches a new Farming Vault on BSC! 👩‍🌾

United DAO Protocol and UTD-Uniswap Initial Liquidity Pool Launch Announcement

Niob Finance Announces Successful Certik Audit

How to trade on forbitspace on BNB Chain