You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
mlp_fee = amount_ONS * fee_rate_mlp * fee_share_mlp // calculate fee cut for MLP2 x += mlp_fee // add fee to MLP2 k = x * y // calculate invariant x += amount_ONS * (1 - fee_rate_mlp) // amount to exchange amount_asset = y - k / x // amount to return
Exchange asset to ONS
k = x * y // calculate invariant y += amount_asset // amount to exchange amount_ONS = x - k / y // amount to return
Exchange asset_1 to asset_2
mlp_fee = amount_asset_1 * fee_rate_mlp * fee_share_mlp // calculate fee cut for MLP2 x += mlp_fee // add fee to MLP2 k = x * y // calculate invariant x += amount_asset_1 * (1 - fee_rate_mlp) // amount to exchange amount_asset_2 = y - k / x // amount to return
Flow Chart
Discussion and Summary for Shareholders
This is a very important feature, to strengthen our infrastructure, use case and core token value
This enables every user to take part in value creation and earning market fees at the same time
Risks
Adding only one asset to the liquidity allows to increase rewards or looses.
Abstract
Motivation
Rationale
Solution
asset
pair can have theMLP2
asset featureMLP2
asset feature is based on the x * y = k modellx
=amount_asset_X
,y
=amount_asset_Y
,k
=invariant
MLP2
is separated in passive and active liquidity, to allow one asset deposit/withdrawExchange
amount_asset_X
/amount_asset_Y
orprice_asset
defines the asset exchange rateinvariant
is not changed during the asset exchangeamount_asset_X
* sqrt(price_X
) =amount_asset_Y
* sqrt(price_Y
)Passive liquidity
MLP2
.MLP2
, are prioritized for active liquidity over newly added assets.Add/remove asset(s) from MLP2
Add an equivalent amount of both assets
Remove an equivalent amount of both assets
Add only one asset
Remove only one asset
MLP2 start values
MLP2 after quadruple ONS price or asset sell for half amount_ONS
MLP2 Charts
amount_ONS
*amount_asset
=invariant
price_ONS
) *amount_ONS
= constantprice_asset
) *amount_asset
= constantprice_ONS
*price_asset
= 1Fee structure
The asset owner, defines the fee structure for the
MLP2
The
market fee share to network
is defined by the network.ONS market pairs
asset
tradingMLP2
Other market pairs
MLP2
Example fee schedule
0.6% ONS -> asset market fee
0.3% asset -> asset market fee
Price Distribution
Network Example with different MLP asset features
Market Dynamics
MLP2
asset featureasset
is backed by same value of the otherasset
MLP2 price changes
ROS = (Relative Order Size) = amount_order/active_mlp
Premium on the exchange rate compared to the current
price_asset
Orderbook
market fee
reducesasset
/asset
market spreadPrice feed
The
MLP2
asset feature is not only exchange feature, but also a price feed indicator, which oscillates around the market price.Manipulation
MLP2
generatesmarket fee
and market spreadmarket fee
and gets an advantage to increase ONS price on DEXComparison
Lending options
MLP2
CR
&debt
Implementation
MLP2
Specifications
Network_parameter
fee_share_for_reserve
MLP_parameters
asset_id
mlp_fee_rate
fee_share_asset
fee_share_mlp
fee_share_referral
MLP_object
asset_id
delta_asset_balance
user_id
mlp_function_id
MLP_asset_functions
x
=active_amount_asset_X
y
=active_amount_asset_Y
x_p
=passive_amount_asset_X
y_p
=passive_amount_asset_Y
Add both assets
if (
y
/x
==delta_asset_X
/delta_asset_Y
) {x
+=delta_asset_X
y
+=delta_asset_Y
}
Add one asset
if (
delta_asset
==passive_asset
) {mlp_passive +=
delta_asset
}
if (
delta_asset_1
!=passive_asset
) {mlp_passive -=
delta_asset_2
mlp_active +=
delta_asset_1
}
Remove both assets
x
-=delta_asset_X
+market_fee_share_X
y
-=delta_asset_Y
+market_fee_share_Y
market_fee_share
= ∫(market_fees
*mlp_share
)dnRemove one asset
if (
delta_asset_1
==passive_asset
) {mlp_active
-= (delta_asset_1
+market_fee_share_1
)mlp_passive
+=delta_asset_2
}
if (
delta_asset_1
!=passive_asset
) {mlp_active
-= (delta_asset_1
+market_fee_share_1
)mlp_passive
-=delta_asset_2
}
market_fee_share
= ∫(mlp_fee_rate
*fee_share_mlp
*mlp_active/(mlp_active + mlp_passive)
)dnExchange ONS to asset
mlp_fee
=amount_ONS
*fee_rate_mlp
*fee_share_mlp
// calculate fee cut for MLP2x
+=mlp_fee
// add fee to MLP2k
=x
*y
// calculate invariantx
+=amount_ONS
* (1 -fee_rate_mlp
) // amount to exchangeamount_asset
=y
-k
/x
// amount to returnExchange asset to ONS
k
=x
*y
// calculate invarianty
+=amount_asset
// amount to exchangeamount_ONS
=x
-k
/y
// amount to returnExchange asset_1 to asset_2
mlp_fee
=amount_asset_1
*fee_rate_mlp
*fee_share_mlp
// calculate fee cut for MLP2x
+=mlp_fee
// add fee to MLP2k
=x
*y
// calculate invariantx
+=amount_asset_1
* (1 -fee_rate_mlp
) // amount to exchangeamount_asset_2
=y
-k
/x
// amount to returnFlow Chart
Discussion and Summary for Shareholders
Risks
Copyright
This document is placed in the public domain.
Sources
The text was updated successfully, but these errors were encountered: