vAMM (Virtual AMM)
Overview
The Virtual Automated Market Maker (vAMM) system is the core of Black Market's exchange. vAMM facilitates exchange between sSPL and VALOR tokens to ensure price stability and adequate liquidity.
The below models can be updated due to the balance update
Key Definitions and Variables
Volatility Parameter: Parameter to control volatility. Calculated with C and k value
k: Constant to give minimum stability to the system
: Total supply of specific sSPL tokens.
: Total supply of specific sSPL tokens before the calculation.
: Total supply of specific sSPL tokens after the calculation.
: represents the trade-induced change in supply.
: Price of the sSPL when initialized.
: Price of the sSPL before calculation.
: Price of the sSPL after calculation.
: The price of the sSPL applies to a specific trade.
Models
The vAMM model dynamically adjusts the token price to provide appropriate stability and volatility while ensuring symmetry in trading.
Symmetric Model
vAMM calculates the price after the trade using the symmetric model.
Calculation based on sSPL amount
Calculate based on VALOR budget
Average Price Model
vAMM swap transaction works based on the average price before the trade and the adjusted price after the trade.
Price Adjustment Due to External Changes
If the supply of sSPL tokens changes outside of vAMM trades, the system adjusts the price using the following equation:
Initial price
Voodoo Doll ($VD)
0.46118
Gold Teeth ($GT)
0.72776
JB Whiskey ($JBW)
0.94118
Canteen ($CT)
1.07882
G Badge ($GB)
1.55294
Holy Water ($HW)
2.32353
Used Engine ($UE)
3.41176
Enhanced Bullet ($EB)
3.43529
Oil Lighter Case ($OLC)
6.82353
Oil ($OIL)
0.00750
MRE ($MRE)
0.00750
Examples
Swap:
Buy: Paying VALOR to buy 1 sSPL
Stability constant sSPL (after buying)
Current supply sSPL
New supply sSPL
Current price VALOR
New price VALOR
Average price VALOR
Fee: VALOR
Result: Paying 10.5525 VALOR to buy 1 sSPL
Sell Transaction: Selling 1 sSPL to get VALOR
Stability constant sSPL (after buying)
Current supply sSPL (after buying)
New supply sSPL
Current price VALOR (after buying)
New price VALOR
Average price VALOR
Fee: VALOR
Result: Receiving 10.5525 VALOR for selling 1 sSPL
Price Adjustment:
On Mint:
Stability constant sSPL (after buying)
Current supply sSPL
Supply after mint sSPL
Initial price VALOR
Current price VALOR
Adjusted price VALOR
On Burn:
Stability constant sSPL (after buying)
Existing supply sSPL
Supply after burn sSPL
Initial price VALOR
Current price VALOR
Adjusted price VALOR
Last updated