Eliminating impermanent loss by leveraged liquidity

The AMM system addresses impermanent loss in cryptocurrency transactions by dynamically re-leveraging assets with smart contracts and price oracles, stabilizing returns and fees in volatile markets.

WO2026244050A1PCT designated stage Publication Date: 2026-11-26SCIENTIA SPECTRA AG
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
PCT/EP2026/065004
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2025-05-21
Filing Date
2026-05-21
Publication Date
2026-11-26

AI Technical Summary

Technical Problem

Impermanent loss in cryptocurrency transactions due to price fluctuations in automated market makers (AMMs) is a significant challenge, as maintaining constant leverage manually is inefficient and results in high variations in returns.

Method used

An automated market maker (AMM) system that dynamically re-leverages cryptocurrency assets using a smart contract and price oracle to maintain a constant leverage, minimizing impermanent loss through automated adjustments.

Benefits of technology

The system effectively reduces impermanent loss by maintaining stable leverage, ensuring consistent returns and fee earnings from liquidity pools, even in volatile markets.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure EP2026065004_26112026_PF_FP_ABST
    Figure EP2026065004_26112026_PF_FP_ABST
Patent Text Reader

Abstract

A method, computer system, and computer readable storage medium for eliminating impermanent loss in cryptocurrency transactions are provided according to one or more embodiments. The eliminating impermanent loss method may include maintaining a liquidity pool of a plurality of cryptocurrency assets comprising, at least, a first cryptocurrency. A transaction request for the first cryptocurrency is received, and in response to the transaction request, a given leverage of the liquidity pool is maintained by re-leveraging the first cryptocurrency based on a stablecoin. A smart contract corresponding to the re-leveraging of the first cryptocurrency is generated. The generated smart contract is broadcast onto a blockchain and executed.
Need to check novelty before this filing date? Find Prior Art

Description

ELIMINATING IMPERMANENT LOSS BY LEVERAGED LIQUIDITYCROSS-REFERENCE TO RELATED APPLICATIONS

[0001] This application claims the benefit of U. S. Provisional Patent Application Ser. No.63 / 809,669, filed May 21, 2025, the entirety of which is incorporated by reference herein.COMPUTER PROGRAM LISTING APPENDIX

[0002] The application includes a Computer Program Listing Appendix, the entirety of which is incorporated by reference herein. The Computer Program Listing Appendix is an ASCII plaintext file named “520557. PK336US_ComputerProgramListingAppendix.txt” created on April 3, 2026, with a size of 55,345 bytes.FIELD

[0003] This disclosure relates generally to a field of cryptocurrency, and more particularly to eliminating impermanent loss in cryptocurrency.SUMMARY

[0004] Embodiments relate to a method, system, and computer-readable storage medium for eliminating impermanent loss in cryptocurrency transactions through leveraging liquidity. According to one aspect, a computer-implemented method for eliminating impermanent loss in cryptocurrency transactions through leveraging liquidity is provided. The method may include one or more processors maintaining a liquidity pool of a plurality of cryptocurrency assets comprising, at least, a first cryptocurrency; receiving a transaction request for the first cryptocurrency; and in response to the transaction request, maintaining a given leverage of the liquidity pool by re-leveraging the first cryptocurrency based on a stablecoin. Further, theone or more processors generate a smart contract corresponding to the re-leveraging of the first cryptocurrency; broadcast the generated smart contract onto a blockchain; and execute the broadcast smart contract.

[0005] According to another aspect, a computer system for eliminating impermanent loss in cryptocurrency transactions through leveraging liquidity is provided. The computer system may include one or more processors, one or more computer-readable memories, one or more computer-readable tangible storage devices, and program instructions stored on at least one of the one or more storage devices for execution by at least one of the one or more processors via at least one of the one or more memories. When executed by the one or more processors, the program instructions cause the one or more processors to be configured to: maintain a liquidity pool of a plurality of cryptocurrency assets comprising, at least, a first cryptocurrency; receive a transaction request for the first cryptocurrency; and in response to the transaction request, maintain a given leverage of the liquidity pool by re-leveraging the first cryptocurrency based on a stablecoin. Executing the program instructions further cause the one or more processors to be configured to generate a smart contract corresponding to the re-leveraging of the first cryptocurrency; broadcast the generated smart contract onto a blockchain; and execute the broadcast smart contract.

[0006] According to yet another aspect, a computer-readable storage medium storing a computer program for eliminating impermanent loss in cryptocurrency transactions through leveraging liquidity is provided, the computer program, when executed by the one or more processors, cause the processor to perform acts of: maintaining a liquidity pool of a plurality of cryptocurrency assets comprising, at least, a first cryptocurrency; receiving a transaction request for the first cryptocurrency; and in response to the transaction request, maintaining a given leverage of the liquidity pool by re-leveraging the first cryptocurrency based on a stablecoin. When executed by the one or more processor, the program product further causesthe one or more processors to perform acts of generating a smart contract corresponding to decentralized trade of the re-leveraged first cryptocurrency for a second cryptocurrency; and executing the broadcast smart contract.BRIEF DESCRIPTION OF THE DRAWINGS

[0007] These and other objects, features, and advantages will become apparent from the following detailed description of illustrative embodiments, which is to be read in connection with the accompanying drawings. The various features of the drawings are not to scale as the illustrations are for clarity in facilitating the understanding of one skilled in the art in conjunction with the detailed description. In the drawings:FIG. 1 illustrates a networked computer environment according to one or more embodiments;FIG. 2 is a block diagram of a system for eliminating impermanent loss in cryptocurrency transactions through leveraging liquidity, according to one or more embodiments;FIG. 3 is an operational flowchart illustrating the steps carried out by a program that eliminates impermanent loss in cryptocurrency transactions through leveraging liquidity, according to one or more embodiments;FIG. 4 is a block diagram of internal and external components of computers and servers depicted in FIG. 1 according to one or more embodiments.DETAILED DESCRIPTION

[0008] Detailed embodiments of the claimed structures and methods are disclosed herein; however, it can be understood that the disclosed embodiments are merely illustrative of the claimed structures and methods that may be embodied in various forms. Those structures andmethods may, however, be embodied in many different forms and should not be construed as limited to the exemplary embodiments set forth herein. Rather, these exemplary embodiments are provided so that this disclosure will be thorough and complete and will fully convey the scope to those skilled in the art. In the description, details of well-known features and techniques may be omitted to avoid unnecessarily obscuring the presented embodiments.

[0009] Embodiments relate generally to the field of field of cryptocurrency, and more particularly to eliminating impermanent loss in cryptocurrency. The following described exemplary embodiments provide a system, method, and computer-readable storage medium to — among other things — eliminate impermanent loss in cryptocurrency transactions through leveraging liquidity. Therefore, some embodiments have the capacity to improve the field of computing by allowing a computer to facilitate availability of cryptocurrency assets in liquidity pools by allowing such assets to earn fees and other yield. For example, the system, method, and computer-readable storage medium described herein may automatically re-leverage the cryptocurrency assets in the liquidity pool through an automated market maker without human intervention, a solution rooted in computer technology in order to overcome a problem specifically arising in the realm of computer networks.

[0010] In an automated market maker (AMM), the value of liquidity (excluding earned trading fees) may be approximately calculated similarly to that in classic xy = k invariant PLP = where p is price of the token y (e.g., bitcoin) in terms of token x (for example, US dollars). Impermanent loss may occur because< - + - for all p 1 may mean that holding an asset with initial price of 1 and equal amount of USD would outperform always-rebalanced liquidity if trading fee is set to zero.

[0011] For leverage L, if one borrows against any token with a price p' to buy even moreof that token so that the value of the loan is always kept to be equal to d = Vc1 —, whereVcis value of collateral, then the position may be leveraged with the leverage L at all times, and the price of the whole position p* may be proportional to (p')LFor example, a small change in the price p* of a token with price p' leveraged with the leverage L may satisfy the cZu durelationship: — - = L—. Integrating this value may give the equation: logp* = L logp' + p* pconst. Exponentiation of both sides may then yield: p* oc (p')L. Therefore, if L=2 andPLP=p, leveraging liquidity would give p* oc (^ / p) = p. This may equate to the price ofthe token y, while the position may also earn exchange fees.

[0012] However, this approach may not work with xy = k invariant for the liquidity because losses on rebalancing to keep the leverage constant (or re-leverage losses) may simply be not lower than the earnings of the pool. Additionally, for L = 2, the size of the loan may be equal to half of the size of liquidity leveraged on average. However, the US dollar portion of the liquidity may also be equal to half of its size in value. Therefore, if leverage is kept constant and equal to 2, liquidity will on average have enough US dollars to close the position. The APR of the resulting position can be expressed as: APR = 2rpooi—

[0013] Such an approach, therefore, may work when the rate pool (multiplied by leverage) is significantly higher than the total of borrow rate and losses introduced by releverage of the position. Additionally, while maintaining a constant amount of leverage manually may not be efficient. For example, with a manual approach, the threshold price change at which re-leverage should occur is relatively high (e.g., 10%), which may make variations in the returns very high (i.e., returns can go negative very often). It may beadvantageous, therefore, to use an automated market maker (AMM) dedicated to releveraging.

[0014] Aspects are described herein with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer readable media according to the various embodiments. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer readable program instructions.

[0015] The following described exemplary embodiments provide a system, method and computer-readable storage medium for eliminating impermanent loss in cryptocurrency transactions through leveraging liquidity. Referring now to FIG. 1, a functional block diagram of a networked computer environment illustrating an impermanent loss elimination system 100 (hereinafter “system”) for eliminating impermanent loss in cryptocurrency transactions through leveraging liquidity. It should be appreciated that FIG. 1 provides only an illustration of one implementation and does not imply any limitations with regard to the environments in which different embodiments may be implemented. Many modifications to the depicted environments may be made based on design and implementation requirements. For example, while the embodiments disclosed herein are described with respect to cryptocurrency, it may be appreciated that embodiments and techniques disclosed herein may be used for substantially any form of volatile asset.

[0016] The system 100 may include a computer 102 and a server computer 114. The computer 102 may communicate with the server computer 114 via a communication network 110 (hereinafter “network”). The computer 102 may include one or more processors 104, a user interface 105, and a software program 108 that includes processorexecutable instructions that is stored on a data storage device 106, such as memory or other non-transitory computer readable storage medium. The computer 102 is enabled to interfacewith a user and communicate with the server computer 114. As will be discussed below with reference to FIG. 4 the computer 102 may include internal components 800 A and external components 900 A, respectively, and the server computer 114 may include internal components 800B and external components 900B, respectively. The computer 102 may be, for example, a mobile device, a telephone, a personal digital assistant, a netbook, a laptop computer, a tablet computer, a desktop computer, or any type of computing devices capable of running a program, accessing a network, and accessing a database.

[0017] The server computer 114, which may be used for eliminating impermanent loss in cryptocurrency transactions through leveraging liquidity is enabled to run a Liquidity Leveraging Program 116 (hereinafter “program”) that may interact with a database 112. The Liquidity Leveraging Program method is explained in more detail below with respect to FIG. 3. The server computer 114 may include one or more processors and one or more storage media. In one or more embodiments, the computer 102 may operate as an input device including the user interface 105, while the program 116 may run primarily on server computer 114. In one or more embodiments, the program 116 may alternatively run primarily on one or more computers 102 while the server computer 114 may be used for processing and storage of data used by the program 116. It should be noted that the program 116 may be a standalone program or may be integrated into a larger liquidity leveraging program.

[0018] It should be noted, however, that processing for the program 116 may, in some instances, be shared amongst the computers 102 and the server computers 114 in any ratio, including, for example, completely running on only the computer 102 or only the server computer 114. In one or more embodiments, the program 116 may operate on processors on more than one computer, more than one server computer, or some combination of computers and server computers. In one example, the program 116 may operate on one or moreprocessors on a plurality of computers 102 communicating across the network 110 with a single server computer 114. In another example, the program 116 may operate on one or more processors on a plurality of server computers 114 communicating across the network 110 with a plurality of computers 102. In yet another example, the program 116 may operate on one or more processors on a network server communicating across the network with a server 114 and a plurality of computers 102.

[0019] The network 110 may include wired connections, wireless connections, fiber optic connections, or some combination thereof. In general, the network 110 can be any combination of connections and protocols that will support communications between the computer 102 and the server computer 114. The network 110 may include various types of networks, such as, for example, a local area network (LAN), a wide area network (WAN) such as the Internet, a telecommunication network such as the Public Switched Telephone Network (PSTN), a wireless network, a public switched network, a satellite network, a cellular network (e.g., a fifth generation (5G) network, a long-term evolution (LTE) network, a third generation (3G) network, a code division multiple access (CDMA) network, etc.), a public land mobile network (PLMN), a metropolitan area network (MAN), a private network, an ad hoc network, an intranet, a fiber optic-based network, or the like, and / or a combination of these or other types of networks.

[0020] The number and arrangement of devices and networks shown in FIG. 1 are provided as an example. In practice, there may be additional devices and / or networks, fewer devices and / or networks, different devices and / or networks, or differently arranged devices and / or networks than those shown in FIG. 1. Furthermore, two or more devices shown inFIG. 1 may be implemented within a single device, or a single device shown in FIG. 1 may be implemented as multiple, distributed devices. Additionally, or alternatively, a set ofdevices (e.g., one or more devices) of system 100 may perform one or more functions described as being performed by another set of devices of system 100.

[0021] Referring now to FIG. 2, a block diagram of an automated market maker (AMM) system 200 for eliminating impermanent loss through re-leveraging liquidity is depicted according to one or more embodiments. The AMM system 200 may include, among other things, a liquidity pool 202, a price oracle 204, a re-leverage module 206 including an analysis module 208 and a token generation module 210, and a smart contract generation module 212. It may be appreciated that the modules described herein may be implemented in hardware, software, firmware, or a combination thereof. For example, the modules described herein may represent processors of the computer 102 (FIG. 1) and / or server computer 114 (FIG. 1) executing instructions and / or programs.

[0022] Suppose the value of collateral Vcchanges by a small amount 5VC. Compounding leverage may be split into three steps: growth of collateral price, changing the debt to maintain the d / Vc ratio, and adjusting the collateral amount. The collateral amount during the first step and the collateral price during the second step may be taken as constant. At equilibrium, if the collateral amount is y and its price is p’:

[0023] Consider now the first step; in it, the value of leverage position V* changes as follows:For constant d, this equals:(7C+ 8VC) — d = (Vc— d) + 8VC= + 8VC= VC+ y8p'with:where the latter equality holds because the amount of collateral is constant in the first step, and Vc= yp'.

[0024] Consider now the other way whereby the value of the position can be changed, namely, the change in the amount of collateral. When the collateral is changed with the price and the debt kept fixed, the value of leverage position V* would change as:+ p' yAnd, likewise,It may be appreciated, therefore, that for any way of changing the value of the collateral, the change in the value of the leveraged position obeys the relationship:

[0025] It may further be appreciated that the second step may not lead to a degradation of value. As the debt is changed in such a way as to be constrained by a linear relationship with Vc, consider a combination of second and third steps taken together. By definition:

[0026] Then the change in the value of the leveraged position will be given as:and

[0027] It follows that in such a combined step, the value of the leveraged position behaves exactly like the value of the collateral, and, therefore, the total rate of the change in the value will be given by the preceding step. Intuitively, this result corresponds to the observation that this smooth change in the amount of collateral is purely begotten by and commensurate to the change in the debt. Should the first and the second steps have been performed together instead of the first and the third, the results will have been the same, as demonstrated by the above study in the relative rate of change of the leveraged position value. It follows, then, that one of the steps produces a nontrivial result for the rates of change of the collateral and position values.

[0028] As previously discussed, a dedicated AMM may be used for re-leveraging. Thus, the AMM system 200 may use the price oracle 204 to obtain a price p0for the asset in the liquidity pool 202 which is being re-leveraged. The AMM system 200 may keep a reserve of collateral y in the liquidity pool 202. Instead of keeping reserves of stablecoins, the releverage module 206 of the AMM system 200 may borrow stablecoins having a debt d. When the market price p is equal to p0, in order to keep the leverage L, ideal debt should be equal to:where values with ~ may be taken at the time when the market price is equal to the pricegiven by the price oracle 204. For example, for L = 2, d =

[0029] The re-leverage module 206 may keep leverage constant via a variant of xy = k with x being represented as a function of the price given by the price oracle 204 and the debtas:(xo(Po)—d~)y = / (p0), where invariant / is constant at the same p0,x = x0po~) — d.

[0030] In order to find the x0(Po) function, ideal values for p = p0and the property of xy = k invariant that p = x / y. When p = p0, then:Substituting for d̃ yields the equation:For example, at y = 2, p0= 1, L = 2, and d = 1, then it may be determined that xo = 3, which may satisfy x0— d = poy.

[0031] Since y, d, and p0may fully define the state of the AMM system 200, the function x0(Po) may be found for any current values of y and d. For a known o, an “ideal” y may be expressed as:kxoy~ 2L - lp0At constant p0, the value of invariant I may be conserved and the same as at “ideal” parameters (e.g., y and d):

[0032] It may be assumed that x0= x0po~). Substituting for y yields a quadratic equation for xo:The larger root of the quadratic equation may be chosen as the solution for xo:This expression may define the state of the AMM system 200. Before any exchange, the analysis module 208 may calculate xo for the current state, which may stay the same while on the same bonding curve and p0is unchanged.

[0033] The analysis module 206 may also calculate value in the liquidity pool 202 of theAMM system 200. In order to reduce noise, the analysis module 206 may base the calculation on setting p equal to p0:It may be appreciated, for example, that by setting p equal to po, the value obtained on the blockchain may be less susceptible to sandwich attacks. The value of invariant / when p equals p0is given as:The value V in the liquidity pool 202 may be given as:V = 2√Ip₀ − x₀.The analysis module 208 may use this value of V when calculating shares for deposits and withdrawals. It may be seen that x₀ is proportional to √I at a given p₀.

[0034] In one or more implementations, deposits into the liquidity pool 202 can be made. When an amount Cinof a cryptocurrency is deposited into the liquidity pool 202, the releverage module 206 may borrow an amount d stablecoins against liquidity pool (LP) tokens created by the token generation module 210. Specifically, a user may deposit Cinof the cryptocurrency and may specify a debt Ad that may have a value equal to the value of cryptocurrency or can be calculated proportionally to balances in pool. The re-leveragemodule 206 may borrow Ad stablecoins and deposits both the Ad stablecoins and the Cinof the cryptocurrency into the liquidity pool 202, yielding an amount I LP tokens created by the token generation module 210. The analysis module 208 of the re-leverage module 206 may calculate a value in the liquidity pool 202 and a solution for xo calculated using equations described above for states before deposit (d, y) and after the deposit (d + Ad, y + 1). The analysis module 208 may also calculate an amount of yield basis (YB) tokens for the token generation module 210 to mint for the deposit, proportional to the value increase into the liquidity pool 202 from the deposit.

[0035] In one or more implementations, withdrawals from the liquidity pool 202 can also be made. When a user withdraws a fraction of liquidity from the liquidity pool 202, in order to not have any unfair disadvantage for liquidity providers, the user may be prevented from specifying an arbitrary value of the debt. Instead, both the collateral and the debt may be reduced by a same fraction equal to fraction of overall LP tokens being withdrawn.Specifically, the user may wish to withdraw, from the liquidity pool 202, a value equal to t LP tokens. If the supply of LP tokens is s, then the liquidity of the liquidity pool 202 may be reduced by a value of t / s. The collateral c may be reduced by 5c = ct / s, and the debt d may be reduced by 5d = dt / s. Since the collateral may be LP tokens of the liquidity pool 202, 5c LP tokens may be withdrawn in such a way that the amount of stablecoin withdrawn is exactly 5d, and the amount of the cryptocurrency may be kept varied as a function of 5c and 5d, given by a withdraw fixed out function of a smart contract 214 generated by the smart contract generation module 212 and broadcast onto a blockchain for execution. Part of debt 5d may be repaid from the withdrawn stablecoins, and cryptocurrency withdrawn from the pool may be passed to the user.

[0036] In one or more implementations, revenue may be split between staked and unstaked liquidity. For example, for yield basis, real yields may only be given to those userswho did not opt in to earn YB tokens (e.g., stake). If users did not stake, then they may earn real yield from fees. If users did stake, then they may not earn any yield from fees but may earn governance tokens from emissions. The re-leverage module 206 may give an administration (admin) fee that may be taken from the fees earned and given to the YB token stakers. The fee portion going to YB token stakers may dynamically depend on how much cryptocurrency is staked. In one or more implementations, S may be an amount of LP tokens staked to earn YB tokens, T may be a total amount of LP tokens, fmin may be a minimal value of the admin fee, r may be a natural return rate corresponding to how much the liquidity pool 202 may have earned if no token system, staking, or unstaking were present. The admin fee may be calculated as:

[0037] If no cryptocurrency is staked (S / T = 0), then the system admin fee may be equal to fmin (e.g., 10%), and the rest (90%) goes to positions in the liquidity pool 202. If all cryptocurrency is staked (i.e., S / T = 100%), then the system admin fee may be equal to 100% because all assets in the liquidity pool 202 may be earning YB tokens. For an unstaked portion rus, returns may be considered to approach a limit. For example, as s approaches 0, fa fmin and rus-> (1 - fmin)r. Additionally, as s approaches T, fa100% and rusoo. The total liquidity of the liquidity pool may be expressed as:

[0038] In one or more implementations, v-i may be a previous total value of liquidity, v+i may be a new total value of liquidity before the admin fee is taken, vs may be a value assigned to staked liquidity that may earn no fees, vusmay be a value assigned to unstaked liquidity that may earn fees, vs* may be an “ideal” value of staked liquidity if there were no losses, and a may be a running value of collected admin fees. When the value v is justchanged due to trades (i.e., not deposits or withdrawals), then the running value of the admin fees may increase by Δa = (v₁ − v₋₁)fₐ, and value to be split between vsand vusmay beΔvuse = (v₁ − v₋₁)(1 − fₐ). After the admin fee is taken, the new total value of liquidity may be v'₁ = v₋₁ + Δvuse. In the event there were no losses, the staked liquidity value usmay be equal to its upper limit (i.e., vs = vs*). However, should losses be experienced (e.g.Avuse < 0), the loss may be shared between staked and unstaked liquidity as Δvs = Δvuse · S / T,Avuse< 0. In the event that profit is made after previous losses, then vs < vs*, and value is added to vs until it reaches vs*, as given by:max(vs* − vs, 0)), Δvuse > 0

[0039] The amount of unstaked LP tokens does not change if no deposits or withdrawals occur, so one LP token represents a value-accruing cryptocurrency. Without deposits or withdrawals, T - S = constant. The value of “staked” tokens, however, may experience negative rebases. If a reduction of number of staked LP tokens is given as 5s, then the total and staked tokens after such a rebase may accordingly be given as S' = S — 8S and T' = T — 8S. The ratio between these values may be the same as ratio between new staked and total values:S − δS v'ST − δS v'₁from whichmay be derived.

[0040] When leveraging liquidity, the AMM may exchange stablecoins for the LP token of the liquidity pool, or vice versa. However, an arbitrage trader may want to exchange between real cryptocurrency and stablecoin, not LP tokens. Therefore, a “virtual pool”smart contract may be used to combine leverage AMM, liquidity pool, and stablecoin (crvUSD) flash loans to facilitate this process.

[0041] Changing from a cryptocurrency asset to a stablecoin in a virtual pool may include using a flash loan to borrow exact amount of crvUSD needed to add both cryptoasset and crvUSD as balanced liquidity in the cryptopool without changing the spot price in cryptopool. The LP token may be exchanged for crvUSD in the leverage AMM, and the flash loan may be repaid from the crvUSD obtained in leverage AMM. Any remaining crvUSD may be returned to the user.

[0042] Changing from stablecoin to a cryptocurrency asset may include flash-borrowing an additional amount of crvUSD (the exact amount will be calculated below). All the crvUSD acquired (i.e., provided by user and through the flash loan) may be exchanged to cryptopool LP in the leverage AMM. Liquidity may be removed from the liquidity pool symmetrically (i.e., without changing crypto-to-stablecoin ratio and price) to yield the exact amount of stablecoins to repay the flash loan. Therefore, this amount may be calculated before executing the transaction. If the leverage AMM fee is f debt is d, the collateral amount in AMM isy; xo is known; and the whole cryptopool has xcstablecoins, ycamount of crypto, and total LP supply of Sc, then the required flash amount (p can be determined from the input amount of stablecoins x by solving the quadratic equation:For r = — (1 — ), it may be seen that:ScD = b2+ 4yxrb = x0— d + x — ry

[0043] Referring now to FIG. 3, an operational flowchart illustrating the steps of a method 300 carried out by one or more processors performing a computer-implemented method that eliminates impermanent loss in cryptocurrency transactions through leveraging liquidity is depicted.

[0044] At 302, the method 300 may include maintaining a liquidity pool of a plurality of cryptocurrency assets comprising, at least, a first cryptocurrency. A user is provided with one or more fees in response to the user placing an amount of the first cryptocurrency in the liquidity pool. The one or more fees include, at least, an administration fee fa= 1 — / s(1 — fmtn) 1, where S corresponds to an amount of liquidity pool tokens staked to earnyield basis tokens, T corresponds to a total amount of liquidity pool tokens, and fmin corresponds to a minimal value of the administration fee. In operation, the AMM system 200 (FIG. 2) may maintain a liquidity pool 202 (FIG. 2) of one or more cryptocurrencies. The assets in the liquidity pool 202 may be added by one or more users of one or more computers 102 (FIG. 1) through the software program 108 (FIG. 1) which communicates with the Liquidity Leveraing Program 116 (FIG. 1) on one or more server computers 114 (FIG. 1) via the communication network 110 (FIG. 1). The liquidity pool may be maintained in one or more databases 114 (FIG. 1) on the one or more server computers 114 and may allow the AMM system 200 liquid cryptocurrency assets with which it may perform transactions.

[0045] At 304, the method 300 may include receiving a transaction request for the first cryptocurrency. The transaction request is a deposit request or a withdrawal request. The deposit request may include receiving data corresponding to a specified debt amount Ad, depositing the first cryptocurrency in the liquidity pool, borrowing an amount Ad of the stablecoin, depositing the borrowed Ad of the stablecoin, generating liquidity pool tokens, calculating a yield basis value based on a value of the liquidity pool before and afterdepositing the first cryptocurrency and the Ad of the stablecoin and generating yield basis tokens proportional to the calculated yield basis value. The withdrawal request may include receiving a request to withdraw an amount equal to t liquidity pool tokens from the liquidity pool. Prior to the request the liquidity pool has a collateral c and a debt d. A value of a liquidity of the liquidity pool is reduced by t / s, the collateral is reduced by an number of LP tokens 5c equal to (c x t) s, and a value of the debt is reduced by an amount 5d equal to (d x t) s, where s corresponds to a total supply of liquidity pool tokens. 5c liquidity pool tokens are withdrawn from the liquidity pool, and the first cryptocurrency varies as a function of δc and δd by the smart contract. At least a portion of the amount 5d is repaid from withdrawn stablecoins, and a user is provided with withdrawn first cryptocurrency from the liquidity pool. In operation, a user of a computer 102 (FIG. 1) may use the software program 108 (FIG. 1) to deposit their cryptocurrency into the liquidity pool 202 (FIG. 2) to allow it to be leveraged or to withdraw their cryptocurrency from the liquidity pool 202.

[0046] At 306, the method 300 may include in response to the transaction request, maintaining a given leverage of the liquidity pool by re-leveraging the first cryptocurrency based on a stablecoin. Maintaining the given leverage of the liquidity pool includes maintaining reserves of a collateral y, and establishing communication with a price oracle configured to provide a price p0of the first cryptocurrency. A stablecoin with a debt d is borrowed, and based on a market price p of the first cryptocurrency being equal to p0, an ~ L— 1 ~ideal debt value is equal to d̃ = (L−1) / L · pₒỹ for a given leverage amount L, where d and y correspond to market prices of d and y being equal to a price given by the price oracle. In operation, the re-leverage module 206 (FIG. 2) of the AMM system 200 (FIG. 2) may receive price information of the user’s cryptocurrency from a price oracle 204 (FIG. 2). The releverage module 206 may keep leverage of the liquidity pool 202 (FIG. 2) constant via a variant of xy = k with x being represented as a function of the price given by the price oracle204 and the debt as: (x0(p0) — d)y = / (p0), where invariant I is constant at the same p0,x = x0(Po) - d.

[0047] At 308, the method 300 may include generating a smart contract corresponding to decentralized trade of the re-leveraged first cryptocurrency for a second cryptocurrency. Based on the re-leveraging of the first cryptocurrency, an impermanent loss associated with price fluctuations of the first cryptocurrency is eliminated. In operation, the smart contract generation module 212 (FIG. 2) may generate a smart contract 214 (FIG. 2) buying or selling a cryptocurrency in exchange for the cryptocurrencies maintained in the liquidity pool 202 (FIG. 2). The smart contract may be, for example, a program or set of instructions that carry out the transaction upon predetermined conditions being met.

[0048] At 310, the method 300 may include broadcasting the generated smart contract onto a blockchain. In operation, the AMM system 200 (FIG. 2) of the Liquidity Leveraing Program 116 (FIG. 1) may broadcast the smart contract 214 (FIG. 2) via the communication network 110 (FIG. 1) to a blockchain maintained in one or more databases 112 (FIG. 1) in one or more server computers 114 (FIG. 1).

[0049] At 312, the method 300 may include executing the broadcast smart contract. In operation, the smart contract 214 (FIG. 2) may interact with other smart contracts on the blockchain maintained in the one or more databases 112 (FIG. 1) of the one or more server computers 114 (FIG. 1) to carry out the transaction defined in the smart contract 214. The smart contract 214 may allow the AMM system 200 (FIG. 2) to transact with the cryptocurrencies in the liquidity pool 202 (FIG. 2) without user intervention on the part of the AMM system 200.

[0050] It may be appreciated that FIG. 3 provides only an illustration of one implementation and does not imply any limitations with regard to how different embodimentsmay be implemented. Many modifications to the depicted environments may be made based on design and implementation requirements.

[0051] FIG. 4 is a block diagram 400 of internal and external components of computers depicted in FIG. 1 in accordance with one or more embodiments. It should be appreciated that FIG. 4 provides only an illustration of one implementation and does not imply any limitations with regard to the environments in which different embodiments may be implemented. Many modifications to the depicted environments may be made based on design and implementation requirements.

[0052] Computer 102 (FIG. 1) and server computer 114 (FIG. 1) may include respective sets of internal components 800A, B and external components 900A, B illustrated in FIG. 4.Each of the sets of internal components 800 include one or more processors 820, one or more computer-readable RAMs 822 and one or more computer-readable ROMs 824 on one or more buses 826, one or more operating systems 828, and one or more computer-readable tangible storage devices 830.

[0053] Processor 820 is implemented in hardware, firmware, or a combination of hardware and software. Processor 820 is a central processing unit (CPU), a graphics processing unit (GPU), an accelerated processing unit (APU), a microprocessor, a microcontroller, a digital signal processor (DSP), a field-programmable gate array (FPGA), an application-specific integrated circuit (ASIC), or another type of processing component. In some implementations, processor 820 includes one or more processors capable of being programmed to perform a function. Bus 826 includes a component that permits communication among the internal components 800 A, B.

[0054] The one or more operating systems 828, the software program 108 (FIG. 1) and the Liquidity Leveraging Program 116 (FIG. 1) on server computer 114 (FIG. 1) are storedon one or more of the respective computer-readable tangible storage devices 830 for execution by one or more of the respective processors 820 via one or more of the respective RAMs 822 (which typically include cache memory). In the one or more embodiments illustrated in FIG. 4, each of the computer-readable tangible storage devices 830 is a magnetic disk storage device of an internal hard drive. Alternatively, each of the computer-readable tangible storage devices 830 is a semiconductor storage device such as ROM 824, EPROM, flash memory, an optical disk, a magneto-optic disk, a solid state disk, a compact disc (CD), a digital versatile disc (DVD), a floppy disk, a cartridge, a magnetic tape, and / or another type of non-transitory computer-readable tangible storage device that can store a computer program and digital information.

[0055] Each set of internal components 800A, B also includes a R / W drive or interface 832 to read from and write to one or more portable computer-readable tangible storage devices 936 such as a CD-ROM, DVD, memory stick, magnetic tape, magnetic disk, optical disk or semiconductor storage device. A software program, such as the software program 108 (FIG. 1) and the Liquidity Leveraging Program 116 (FIG. 1) can be stored on one or more of the respective portable computer-readable tangible storage devices 936, read via the respective R / W drive or interface 832 and loaded into the respective computer-readable tangible storage device 830.

[0056] Each set of internal components 800A, B also includes network adapters or interfaces 836 such as a TCP / IP adapter cards; wireless Wi-Fi interface cards; or 3G, 4G, or 5G wireless interface cards or other wired or wireless communication links. The software program 108 (FIG. 1) and the Liquidity Leveraging Program 116 (FIG. 1) on the server computer 114 (FIG. 1) can be downloaded to the computer 102 (FIG. 1) and server computer 114 from an external computer via a network (for example, the Internet, a local area network or other, wide area network) and respective network adapters or interfaces 836.From the network adapters or interfaces 836, the software program 108 and the Liquidity Leveraging Program 116 on the server computer 114 are loaded into the respective computer-readable tangible storage device 830. The network may comprise copper wires, optical fibers, wireless transmission, routers, firewalls, switches, gateway computers and / or edge servers.

[0057] Each of the sets of external components 900 A, B can include a computer display monitor 920, a keyboard 930, and a computer mouse 934. External components 900A, B can also include touch screens, virtual keyboards, touch pads, pointing devices, and other human interface devices. Each of the sets of internal components 800A, B also includes device drivers 840 to interface to computer display monitor 920, keyboard 930 and computer mouse 934. The device drivers 840, R / W drive or interface 832 and network adapter or interface 836 comprise hardware and software (stored in computer-readable tangible storage devices 830 and / or ROM 824).

[0058] Some embodiments may relate to a system, a method, and / or a computer-readable storage medium at any possible technical detail level of integration. The computer-readable storage medium may include a computer-readable non-transitory storage medium (or media) having computer readable program instructions thereon for causing a processor to carry out operations.

[0059] The computer readable storage medium can be a tangible device that can retain and store instructions for use by an instruction execution device. The computer readable storage medium may be, for example, but is not limited to, an electronic storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination of the foregoing. A non-exhaustive list of more specific examples of the computer readable storage medium includes the following: a portable computer diskette, a hard disk, a random access memory (RAM), aread-only memory (ROM), an erasable programmable read-only memory (EPROM or Flash memory), a static random access memory (SRAM), a portable compact disc read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanically encoded device such as punch-cards or raised structures in a groove having instructions recorded thereon, and any suitable combination of the foregoing. A computer readable storage medium, as used herein, is not to be construed as being transitory signals per se, such as radio waves or other freely propagating electromagnetic waves, electromagnetic waves propagating through a waveguide or other transmission media (e.g., light pulses passing through a fiber-optic cable), or electrical signals transmitted through a wire.

[0060] Computer readable program instructions described herein can be downloaded to respective computing / processing devices from a computer readable storage medium or to an external computer or external storage device via a network, for example, the Internet, a local area network, a wide area network and / or a wireless network. The network may comprise copper transmission cables, optical transmission fibers, wireless transmission, routers, firewalls, switches, gateway computers and / or edge servers. A network adapter card or network interface in each computing / processing device receives computer readable program instructions from the network and forwards the computer readable program instructions for storage in a computer readable storage medium within the respective computing / processing device.

[0061] Computer readable program code / instructions for carrying out operations may be assembler instructions, instruction-set-architecture (ISA) instructions, machine instructions, machine dependent instructions, microcode, firmware instructions, state-setting data, configuration data for integrated circuitry, or either source code or object code written in any combination of one or more programming languages, including an object oriented programming language such as Smalltalk, C++, or the like, and procedural programminglanguages, such as the “C” programming language or similar programming languages. The computer readable program instructions may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the latter scenario, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet Service Provider). In some embodiments, electronic circuitry including, for example, programmable logic circuitry, field-programmable gate arrays (FPGA), or programmable logic arrays (PLA) may execute the computer readable program instructions by utilizing state information of the computer readable program instructions to personalize the electronic circuitry, in order to perform aspects or operations.

[0062] These computer readable program instructions may be provided to a processor of a general-purpose computer, special purpose computer, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions / acts specified in the flowchart and / or block diagram block or blocks. These computer readable program instructions may also be stored in a computer readable storage medium that can direct a computer, a programmable data processing apparatus, and / or other devices to function in a particular manner, such that the computer readable storage medium having instructions stored therein comprises an article of manufacture including instructions which implement aspects of the function / act specified in the flowchart and / or block diagram block or blocks.

[0063] The computer readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other device to cause a series ofoperational steps to be performed on the computer, other programmable apparatus, or other device to produce a computer implemented process, such that the instructions which execute on the computer, other programmable apparatus, or other device implement the functions / acts specified in the flowchart and / or block diagram block or blocks.

[0064] The flowchart and block diagrams in the Figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer readable media according to various embodiments. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of instructions, which comprises one or more executable instructions for implementing the specified logical function(s). The method, computer system, and computer-readable storage medium may include additional blocks, fewer blocks, different blocks, or differently arranged blocks than those depicted in the Figures. In some alternative implementations, the functions noted in the blocks may occur out of the order noted in the Figures. For example, two blocks shown in succession may, in fact, be executed concurrently or substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and / or flowchart illustration, and combinations of blocks in the block diagrams and / or flowchart illustration, can be implemented by special purpose hardware-based systems that perform the specified functions or acts or carry out combinations of special purpose hardware and computer instructions.

[0065] It will be apparent that systems and / or methods, described herein, may be implemented in different forms of hardware, firmware, or a combination of hardware and software. The actual specialized control hardware or software code used to implement these systems and / or methods is not limiting of the implementations. Thus, the operation and behavior of the systems and / or methods were described herein without reference to specificsoftware code — it being understood that software and hardware may be designed to implement the systems and / or methods based on the description herein.

[0066] No element, act, or instruction used herein should be construed as critical or essential unless explicitly described as such. Also, as used herein, the articles “a” and “an” are intended to include one or more items and may be used interchangeably with “one or more.” Furthermore, as used herein, the term “set” is intended to include one or more items (e.g., related items, unrelated items, a combination of related and unrelated items, etc.), and may be used interchangeably with “one or more.” Where only one item is intended, the term “one” or similar language is used. Also, as used herein, the terms “has,” “have,” “having,” or the like are intended to be open-ended terms. Further, the phrase “based on” is intended to mean “based, at least in part, on” unless explicitly stated otherwise.

[0067] The descriptions of the various aspects and embodiments have been presented for purposes of illustration but are not intended to be exhaustive or limited to the embodiments disclosed. Even though combinations of features are recited in the claims and / or disclosed in the specification, these combinations are not intended to limit the disclosure of possible implementations. In fact, many of these features may be combined in ways not specifically recited in the claims and / or disclosed in the specification. Although each dependent claim listed below may directly depend on only one claim, the disclosure of possible implementations includes each dependent claim in combination with every other claim in the claim set. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope of the described embodiments. The terminology used herein was chosen to best explain the principles of the embodiments, the practical application or technical improvement over technologies found in the marketplace, or to enable others of ordinary skill in the art to understand the embodiments disclosed herein.

Claims

CLAIMSWhat is claimed is:

1. A method of eliminating impermanent loss in cryptocurrency transactions, comprising:maintaining, with a processor, a liquidity pool of a plurality of cryptocurrency assets comprising, at least, a first cryptocurrency;receiving, with the processor, a transaction request for the first cryptocurrency; in response to the transaction request, maintaining, with the processor, a given leverage of the liquidity pool by re-leveraging the first cryptocurrency based on a stablecoin;generating, with the processor, a smart contract corresponding to decentralized trade of the re-leveraged first cryptocurrency for a second cryptocurrency;broadcasting, with the processor, the generated smart contract onto a blockchain; and executing, with the processor, the broadcast smart contract.

2. The method of claim 1, wherein maintaining the given leverage of the liquidity pool comprises:maintaining reserves of a collateral y;establishing communication with a price oracle configured to provide a price p0of the first cryptocurrency; andborrowing the stablecoin with a debt d, wherein based on a market price p of the first ~ L— 1cryptocurrency being equal to p0, an ideal debt value is equal to d̃ = (L−1) / L · pₒỹ for a givenleverage amount L, wherein d and y correspond to market prices of d and y being equal to a price given by the price oracle.

3. The method of claim 1 or claim 2, wherein the transaction request comprises a deposit request to deposit a given amount of the first cryptocurrency into the liquidity pool.

4. The method of claim 3, further comprising, in response to receiving the deposit request:receiving data corresponding to a specified debt amount Ad;depositing the first cryptocurrency in the liquidity pool;borrowing an amount Ad of the stablecoin;depositing the borrowed Ad of the stablecoin;generating liquidity pool tokens;calculating a yield basis value based on a value of the liquidity pool before and after depositing the first cryptocurrency and the Ad of the stablecoin; andgenerating yield basis tokens proportional to the calculated yield basis value.

5. The method of claim 1 or claim 2, wherein the transaction request comprises a withdrawal request to withdraw a given amount of the first cryptocurrency from the liquidity pool.

6. The method of claim 5, further comprising, in response to receiving the withdrawal request:reducing respective values of a liquidity, a collateral, and a debt of the liquidity pool; withdrawing liquidity pool (LP) tokens from the liquidity pool;repaying at least a portion of the amount by which the debt was reduced with withdrawn stablecoins; andproviding a user with an amount of the first cryptocurrency from the liquidity pool.

7. The method of claim 6, wherein:prior to the request the liquidity pool has a collateral c and a debt d; andthe amount requested to be withdrawn from the liquidity pool is equal to t LP tokens.

8. The method of claim 7, wherein:the value of the collateral is reduced by an amount δc equal to (c × t) ÷ s;the value of the debt is reduced by an amount δd equal to (d × t) ÷ s; ands corresponds to a total supply of liquidity pool tokens.

9. The method of claim 8, wherein δc LP tokens are withdrawn from the liquidity pool.

10. The method of claim 8 or claim 9, wherein the first cryptocurrency varies as a function of δc and δd by the smart contract.

11. The method of any one of the preceding claims, further comprising:providing a user with a share in one or more fees in response to the user placing an amount of the first cryptocurrency in the liquidity pool.

12. The method of claim 11, wherein the one or more fees comprise, at least, anadministration fee ( = wherein:S corresponds to an amount of liquidity pool tokens staked to earn yield basis tokens;T corresponds to a total amount of liquidity pool tokens; andcorresponds to a minimal value of the administration fee.

13. The method of any one of the preceding claims, wherein the given leverage is kept constant by determining (x0(po) − d)y = I(po), where d is debt, y is collateral, po is a price determined by the oracle, I is an invariant that is constant for the same po, L is the leverage, and xo is a function of the price given by the price oracle such that14. A computer system for eliminating impermanent loss in cryptocurrency transactions, the computer system comprising:one or more computer-readable non-transitory storage media configured to store computer program code; andone or more computer processors configured to access said computer program code and operate as instructed by said computer program code, wherein the computer program code causes the one or more computer processors to be configured to perform the method of any one of claims 1 to 13.

15. A computer-readable storage medium storing a computer program for eliminating impermanent loss in cryptocurrency transactions, the computer program comprising program code that, when executed by one or more computer processors, cause the one or more computer processors to perform the method of any one of claims 1 to 13.