🧠Atlas DEX Litepaper

v1.0

Executive Summary

Decentralized Finance (DeFi) has experienced tremendous growth in the past year. While the growth in new DeFi protocols has spurred innovation and attracted huge inflows of users and capital, it has also introduced several pain points to the market.

Significant price discrepancies between two AMMs are commonplace. Or very often, tokens are only listed on one AMM and have no liquidity on the others. Users must typically search through several AMMs to find the “best price” or simply to find an AMM that has the desired token listed. It is not possible to swap assets between multiple chains, which means that each blockchain is a silo with its own local liquidity.

ATLAS is a cross-chain DEX built on the Solana blockchain with the main purpose of providing users with aggregated liquidity through a single user-friendly UI. The goal is to provide DEX traders with the deepest liquidity available for all swaps of any tokens on supported chains.

Current State of Decentralized Finance ecosystem

As of April 2021, there are at least 8 Decentralized Exchanges (DEX) in development on Solana and more than a dozen others across Binance Smart Chain and Ethereum. There are over 10,000 cryptocurrencies and tokens in existence today, each operating on a limited, isolated infrastructure. This results in liquidity and functionality silos, where one platform is unable to access liquidity and features from another chain.

Liquidity pools on the market are fragmented, making it vital to create the infrastructure that bridges these gaps. With an increasing number of institutional

investors entering the crypto space, the need for an aggregated liquidity platform and support for interoperability will certainly grow.

Why we chose Solana?

Solana is the most performant permissionless blockchain in the world. It is natively scalable and designed to withstand billions of users and devices, while maintaining both decentralization and security. Solana can process up to 50,000 transactions per second with a block time of approx. 400ms.

Because smart contracts in Atlas are complex, it is crucial for them to be executed in parallel so that the user experience is excellent, but at the same time the execution cost should be kept low. Solana’s average transaction fee is ~0.00025$ and by leveraging the state-of-the-art parallel smart contract execution runtime “Sealevel,” Atlas is able to provide super-fast swaps at an extremely low cost.

Challenge and Solution

Automated Market Maker

AMM as an idea was first proposed in 2016. However, it took two years to turn this idea into a usable product when Uniswap released the first implementation of this protocol in late 2018 as a constant function market maker.

The simple mathematical principle at the core of such an AMM is constant product function. It forms a hyperbola when plotting two assets; theoretically to always provide liquidity as prices approach infinity on both sides of the spectrum. Constant product function can be graphically represented as shown below where Qα is the quantity of asset α and Qβ is the quantity of an asset β.

Assuming asset α and β with corresponding total quantity Qα and Qβ respectively, AMM will maintain the pool using the following equation:

Where k is a nonnegative constant.

To explain further if we write the trading function of an AMM as:

With total quantity such that

When a trader tries to swap one type of an asset to another in this pool, we can write the output trade as

The output trade’s ith entry Λi, specifies how much of an asset ‘I’ the trader wishes to receive. We can also define the input trade in a similar fashion:

Which is a vector whose ith entry ∆i specifies how much of asset ‘I’ is to be swapped.

The resulting function is then called a complete trade that is to be validated by the pool.

The AMM validation protocol will only consider this trade valid if:

If the trading function can be kept constant, the trade will be considered a valid trade and asset quantities will be updated after a successful swap.

Due to this built-in constant function validation within an AMM, there exists a slippage. Let’s call it 𝛿.

If we introduce a time function such that at an arbitrary time t, the quoted price of assets ‘α’ and ‘β’ is:

Let p be the current quoted price and p’ be the next quoted price; then slippage 𝛿 can be calculated as:

Slippage can increase exponentially if one or more of the following conditions are present:

  • Liquidity pool where swap takes place does not have enough liquidity.

  • If a trader wishes to execute a large enough trade that can potentially drain a big chunk of liquidity from the single pool.

  • If there is no direct route available for the swap for example, if an AMM supports two pools α <-> β and β <-> 𝜏 but there is no pool for α and 𝜏 the swaps will take place as following:

α -> β -> 𝜏

Atlas’s “guiding light” algorithm addresses these problems by splitting single trade into multiple smaller trades across different protocols to find the most efficient route with minimal slippage.

A rather simple swap taking place at Atlas where token a is to be swapped to token z can be graphically represented as following:

Cross-chain liquidity fragmentation

Exchange of assets between multiple blockchains creates a liquidity problem. Since these are usually wrapped tokens that are used to transfer value across blockchains, it is vital to build a reliable framework to lock, mint, burn, and release assets across multiple blockchains in atomic, durable, and consistent transactions. There has been a rather centralized solution to this problem. For example, some centralized exchanges operate bridges to transfer value between the blockchains. However, the crypto ecosystem was built on the premise that traditional finance is fragmented and centralized, and there is a need to replace that with a better, less fragmented, and truly decentralized system.

Centralized bridges also expose the end user to the custodial and serious counterparty risk. These custodians assume the risks of private key loss or theft either by external or internal malicious actors. In the event of a wallet compromise, the exchange may refuse or be unable to transfer the coins from their storage to the user's wallet. There is a single point of failure, and these custodians must be trusted just as it is in traditional finance.

In the first phase, Atlas intends to integrate “wormhole”, a bidirectional, decentralized ERC-20 ⇄ SPL token bridge between Ethereum and Solana to enable cross-chain swaps. It is a leaderless, decentralized framework that relies on the consensus of the chains it bridges and will be expanded to support other chains in futures.

Following diagrams shows the function of wormhole guardians(validators) and how the value can be transferred from Ethereum to Solana.

The burn and release process is shown below:

After the expansion and integration of wormhole, a swap may take shape like the following on Atlas:

Atlas – In a nutshell

Atlas is a cross-chain DEX built on the Solana blockchain with the main purpose of providing users with aggregated liquidity through a single user-friendly UI. It plans to be a DEX trader’s go-to platform to trade any token available through a list of supported exchanges. With Solana’s fast transactions and low fees, Atlas is able to provide several key features that makes it an attractive choice for traders by providing the best user experience and prices possible.

Key Features of Atlas include:

Liquidity Aggregation

Atlas will provide aggregated liquidity to its users. Unlike the traditional AMM which only allows users to trade from its own liquidity pools, ATLAS will provide users with

access to liquidity across all supported DEXs and blockchains.

Simultaneous Trade Execution on multiple DEXs

On CEXs, traders often have to execute their trades on multiple exchanges simultaneously for the best execution. This is especially true when dealing with big position sizes or when trading illiquid tokens.

For example, if a trader wants to buy $10M in Ethereum, he might choose to buy $5M on Coinbase, $3M on Binance and another $2M on FTX to reduce slippage.

Atlas automatically carries out this process for the user seamlessly by considering the amount of liquidity available from different AMMs to calculate the most efficient way to execute a trade.

Cross-chain Support

Atlas will launch with support for AMMs that are on Solana. In the future, it will be interoperable with other Layer 1s, including Ethereum and Binance Smart Chain.

Liquidity Pools, Farming & Token Listing

Atlas will have support for its own liquidity pools like any other AMM DEX. Traders will be able to access ATLAS’s liquidity pools and new trading pairs can be listed through creation of a liquidity pool on Atlas. LPs on ATLAS will receive rewards in trading fees as well as ATLAS’S native governance token, $ATS.

Development Roadmap and milestones

Atlas started the development phase in Q2 2021 and has since assembled a team of 9 developers to date with a combined 22 years of blockchain development experience. The team members have designed, architected, and developed several complex solutions on Ethereum and Binance Smart chain in the past and have laid out a detailed development plan for Atlas. The following timeline summarizes the deliverable and milestone plan:

For more details

Web: https://www.atlasdex.finance

Email: team@atlasdex.finance

Twitter: https://twitter.com/atlas_dex

Medium: https://atlasdex.medium.com/

Source: https://github.com/atlasdex

Last updated