Musing
  • 🏠Welcome to Musing
  • πŸ‘‹Frequently Asked Questions
  • Features
    • πŸ“ƒPosts
    • πŸ™‹Follow Users/Community
    • 🏘️Create Community
    • 🎁Create and Claim Airdrop
    • πŸ“‘Post Promotion
    • πŸ”’Community Exclusive Content
    • πŸ™β€β™‚οΈModerators
    • πŸ’―Points
  • Community Token
    • πŸ“”Overview
    • πŸ“ˆBonding Curve
    • πŸ†“Creator Free Minting
    • πŸ’΅Buy Token
    • πŸ’΄Sell Token
    • πŸ”Transfer Token
  • Rewards
    • πŸ“’Overview
    • πŸ…Post Rewards
    • πŸ†Moderator Rewards
    • 🎫Referral Rewards
  • Wallet
    • πŸ’°Overview
    • πŸ’ΈBuy AVAX
    • πŸ“₯Deposit AVAX
    • πŸ“€Withdraw AVAX
    • πŸ“©Export Private Key
    • πŸͺ™Community Token Balances
  • INFORMATION
    • πŸ”—Links
    • 🏠Addresses
    • πŸ”Security Audit
  • Terms of Service
  • Privacy Policy
Powered by GitBook
On this page
  • Key Elements of the Bonding Curve Logic:
  • Price Interval-based Bonding Curve
  • Mathematical Formula
  • Steps Calculation
  • Determining the Current Step in the Bonding Curve:
  • Calculating the Reserve Amount for Minting
  • Calculating the Refund Amount for Burning
  • Future Improvements
  1. Community Token

Bonding Curve

PreviousOverviewNextCreator Free Minting

Last updated 10 months ago

A bonding curve is a mathematical formula within a smart contract that defines the relationship between the price and supply of a token. As more tokens are minted and bought, the price increases along the bonding curve. Conversely, when tokens are sold or burned, the price decreases. This mechanism ensures a dynamic pricing model based on supply and demand.

Bonding curves simplify the creation and management of community tokens by eliminating traditional barriers such as writing, testing, and auditing smart contracts, as well as setting up liquidity pools. This ensures instant liquidity and automated pricing, allowing users to create and trade community coins with a single click. By leveraging bonding curves, Musing enables effortless token creation and trading, allowing communities to focus on growth and engagement without technical hassles.

Key Elements of the Bonding Curve Logic:

  • Dynamic Pricing: The price of the token increases as more tokens are minted and decreases as tokens are burned. This is managed through a constant product formula.

  • Instant Liquidity: The bonding curve ensures that there is always a price at which tokens can be bought or sold, providing continuous liquidity.

Price Interval-based Bonding Curve

Musing employs the Discrete Bonding Curve (DBC) model, which divides the curve into specific price intervals. Unlike a continuous linear curve (y = x), the DBC model uses stepped intervals, providing greater customization and addressing technical challenges in implementing bonding curves with smart contracts.

Mathematical Formula

The bonding curve is divided into steps, each with a specific price and supply range. The steps are calculated using a quadratic formula based on the initial and final prices, as well as the initial and maximum supply.

Steps Calculation

The steps in the bonding curve are determined using a quadratic formula based on the initial and final prices, as well as the initial and maximum supply.


Determining the Current Step in the Bonding Curve:

To find the current step based on the total supply:

Calculating the Reserve Amount for Minting

To calculate the reserve amount for minting tokens:

Calculating the Refund Amount for Burning

To calculate the refund amount for burning tokens:

Minting and burning tokens will incur a 7% tax, which will be split between the platform and rewards.

Future Improvements

Musing successfully launched on the Avalanche Mainnet with core platform features implemented. The following are enhancements to be added in the future.

  • Automated Liquidity Pools: Automated liquidity pools will enhance liquidity and price stability. This feature will automatically deploy liquidity to a DEX when community coins reach a certain market cap.

  • Governance Tools: Governance tools are being developed to empower community members with the ability to vote on critical decisions, such as selecting community leaders, configuring rewards, and appointing moderators.

  • Musing Coin (MSC) Integration: The MSC token will be integrated into the platform, backing community coins and providing additional utility. This integration will enhance the value and functionality of the platform, ensuring that the token is actively used within the ecosystem.

Let P0P_0P0​​ be the initial price.

Let PnP_nPn​​ be the final price.

Let S0S_0S0​​ be the initial supply.

Let SnS_nSn​​ be the maximum supply.

Let C C C be the creator allocation.

Let N N N be the number of steps.

Step Size ( Ξ”XΞ”XΞ”X)

Ξ”X=(Snβˆ’C)/NΞ”X=(S_nβˆ’C) / N Ξ”X=(Snβ€‹βˆ’C)/N

Ξ”X Ξ”X Ξ”X: Increment in supply for each step

Sn S_nSn​​: Maximum supply

C C C: Creator allocation

N N N: Number of steps

Total Range (totalX totalX totalX) and Total Price Difference (totalY totalY totalY):

totalX=Snβˆ’Cβˆ’Ξ”XtotalX=S_n βˆ’Cβˆ’Ξ”XtotalX=Snβ€‹βˆ’Cβˆ’Ξ”X

totalX totalX totalX: Total range in supply

Ξ”X Ξ”X Ξ”X: Increment in supply for each step

totalY=Pnβˆ’P0totalY=P_n βˆ’P_0totalY=Pnβ€‹βˆ’P0​

totalY totalY totalY: Total price difference

Pn P_nPn​​: Final price

P0 P_0P0​​: Initial price

Quadratic Coefficient (π‘Ž π‘Ž a):

a=totalY/totalX2a= totalY / totalX^2a=totalY/totalX2

π‘Ž π‘Ž a: Coefficient for the quadratic curve

Supply at Each Step ( π‘₯𝑖 π‘₯_𝑖 xi​ ):

xi=iΓ—Ξ”X+Cx_i =iΓ—Ξ”X+Cxi​=iΓ—Ξ”X+C

xi x_ixi​​: Supply at step i

i i i: Step number

Price at Each Step ( 𝑦𝑖 𝑦 𝑖 yi ):

yi=aΓ—(xiβˆ’Ξ”Xβˆ’C)2+P0y_i=aΓ—(x_iβˆ’Ξ”Xβˆ’C)^2 + P_0yi​=aΓ—(xiβ€‹βˆ’Ξ”Xβˆ’C)2+P0​

yi y_iyi​ ​ : Price at step 𝑖

Final Step Price (yN y_NyN​):

yN=Pny_N=P_nyN​=Pn​

yN y_NyN​ : Price at the final step

currentStep=min(i∣currentSupply≀rangeToi)currentStep=min({i∣currentSupply≀rangeTo_i})currentStep=min(i∣currentSupply≀rangeToi​)

This formula means that the current step is the smallest step index i such that the current supply is less than or equal to the upper limit of the supply range (rangeToi rangeTo_i rangeToi​) for that step.

min⁑ min⁑ min⁑: This denotes the minimum function, which finds the smallest value in a set.

i i i: This represents the step index.

currentSupply currentSupply currentSupply: The current total supply of the token.

rangeToi rangeTo_i rangeToi​​: The upper limit of the supply range for step i.

reserveAmount=βˆ‘isteps(tokensToMintΓ—pricei/10decimals)reserveAmount=βˆ‘_i^{steps} (tokensToMintΓ—price_i / 10^{decimals})reserveAmount=iβˆ‘steps​(tokensToMintΓ—pricei​/10decimals)

tokensToMint tokensToMint tokensToMint: The number of tokens to be minted.

pricei price_i pricei​​: The price per token at step iii.

decimals decimals decimals: The decimal places of the token.

refundAmount=βˆ‘i=1steps(tokensToBurnΓ—pricei/10decimals)refundAmount=βˆ‘ _{i=1}^{steps}(tokensToBurnΓ—price _i / 10^{decimals})refundAmount=i=1βˆ‘steps​(tokensToBurnΓ—pricei​/10decimals)

βˆ‘i=1steps βˆ‘_{i=1}^{steps} βˆ‘i=1steps​​: This denotes the summation, meaning that the value inside the parentheses is summed for each step i from 1 to the total number of steps.

tokensToBurn tokensToBurn tokensToBurn: The number of tokens to be burned.

pricei price_i pricei​​: The price per token at step iii.

10decimals 10^{decimals} 10decimals: The factor to adjust for the token's decimal places.

πŸ“ˆ