Understanding the Concept of Automated Market Maker (AMM)

Uniswap was the first blockchain network to effectively use an automated market maker mechanism when it was introduced.

The automated market maker (AMM) protocol is the backbone of all decentralized exchanges (DEXs). Briefly described, these are automated market systems that do away with the necessity for controlled systems and associated marketplace procedures.

What is a Market Maker?

A regulated exchange supervises investors and offers an automated method to balance trading orders. In other words, if Trader A wants to purchase one bitcoin for $34,000, the exchange finds Trader B ready to sell one Bitcoin at Trader A’s desired rate. De facto, the regulated exchange acts as a go-between. It has to speed up the procedure and connect clients’ purchase and sale requests.

What tends to happen if the marketplace doesn’t instantly match buyers and sellers?

In this case, the commodities’ liquidity is poor. In trade, liquidity denotes the ease of buying and selling an item. High liquidity indicates a busy exchange with many traders buying and selling an item. In contrast, low liquidity means less engagement and difficulty selling a commodity. Slippages occur when liquidity is inferior.

In other terms, the value of the asset at the time of deal execution varies significantly. As in the cryptocurrency world, this is common. Platforms avoid this by guaranteeing that transactions are performed instantly.

Controlled exchanges depend on professional investors or financial firms for liquidity. They generate numerous proposal orders to meet retail traders’ requests. The deal can therefore assure that counterparties are constantly accessible. Liquidity providers act as market makers in this system. Thus, market-making is in the process of providing liquidity for trading pairs.

What is an Automated Market Maker?

Unlike regulated markets, DEXs aim to eliminate all trade intermediaries.

They don’t facilitate custodial or order matching systems. So DEXs encourage autonomy by allowing users to trade straight from non-custodial wallets.

AMMs substitute order finding algorithms and transaction journals in DEXs. A self-executing computer program, known as a “smart contract,” is used to establish digital assets’ value and provide liquidity. In this case, the protocol uses smart contracts to pool liquidity. Instead of trading against counterparties, users are trading against the liquidity trapped within smart contracts.

The term “liquidity pool” is used to describe these smart contracts.

In conventional exchanges, only high-net-worth individuals or businesses may act as liquidity providers. For AMMs, any company that fulfills the intelligent agreement’s conditions may become a liquidity source. Uniswap, Balancer, and Curve are AMMs.

How Does AMM Work?

First, two facts concerning AMMs:

AMMs have distinct “liquidity pools” for exchanging pairings, similar to regulated exchanges. Locate an ETH/USDT liquidity group to exchange ethereum for tether.

Rather than utilizing market makers, anybody may offer liquidity to such pools by loading both assets. Depositing an equal amount of ETH and USDT is required to be a liquidity source for an Ethereum/USDT pool.

AMMs utilize complex computations to maintain a consistent proportion of liquidity pool resources and prevent price inconsistencies. DeFi exchange mechanisms like Uniswap employ the x*y=k equation to establish the numerical connection between the resources maintained in the liquidity pools.

In this case, x represents Asset A, y represents Asset B, and k is a fixed value.

In short, the Uniswap liquidity pools always keep the value of Resource a multiplied by the value of Resource B equal.

Let’s look at an ETH/USDT liquidity group as an example. Traders buying ETH add USDT to the pool and remove ETH. As a result, the quantity of ETH in the pool decreases, causing the value of ETH to rise. However, when more USDT is introduced to the pool, the value of USDT falls. When buying USDT, the price of ETH decreases in the pool while USDT increases.

Excessive transactions in AMMs may produce significant disparities among both the pool pricing and the market pricing. AMM eliminates some other token; for example, somebody contributed significantly of ETH to a pool, making the market price $3,000 but the pool price $2,850.

The pool would then trade ETH at a price reduction, presenting an arbitrage opportunity. Arbitrage trading is purchasing an asset at a lower rate and reselling it at a premium cost on several exchanges.

AMMs are financially motivated to locate assets selling at discounts in liquidity pools and purchase them up until the investment’s value recovers to market. An arbitrage broker may profit by purchasing ETH in a liquidity pool at a cheaper deal and selling it at a premium value on other exchanges. With each transaction, the pooled ETH’s price progressively recovers to the market rate.

Uniswap’s x*y=k is merely one of today’s AMM mathematical formulae. For example, Balancer leverages a sophisticated statistical connection to allow individuals to pool up to 8 virtual currencies. Curve, on the contrary, uses a mathematical method for combining assets.

Impermanent Loss

Impermanent loss is one of the dangers connected with liquidity pools. This arises as a result of fluctuations in the value ratio of consolidated assets. When the value ratio of the combined investment detracts from the value at which the LP deposited money, the LP will automatically suffer losses. The greater the price movement, the greater the failure.

Impermanent failures are a frequent occurrence in pools that hold unstable virtual currencies. This setback, nevertheless, is temporary since there is a chance that the value ratio may return. The loss becomes irreversible only when the LP withdraws the money before the value ratio reverting. Additionally, consider that future revenue from transaction cost and LP token staking might sometimes compensate for such losses.

--

--

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
DEFIX SOLUTIONS

DEFIX SOLUTIONS

DeFiX Solutions is an open-source P2P protocol that wants to build a decentralized trading platform that is secured by escrow.