The Glue protocol automatically calculates the distribution of Glued assets to holders based on the number of Sticky tokens they burn.

This is the simple Glue Formula:

$$ (X * Y) / Z = K $$

X = Total amount of a single glued collateral Y = Amount of sticky token supply sent for burning Z = Total supply of the sticky token K = Amount of single glued collateral available for withdrawal

This formula ensures that the entirety of each glued asset's supply corresponds to the total supply of the underlying sticky token.

Example:

Let's say we have a token called GlueCoin (GLC) with the following characteristics:

Total Supply: 1,000,000 GLC Glue Address: 0xGlueAddress...

The Glue for GlueCoin contains the following collateral:

100 ETH 50,000 USDC

Step 1: Calculating Backed Value

First, let's calculate the backed value per GLC token:

Assuming ETH price is $2,000, the total backed value per GLC is:

(0.0001 * $2,000) + $0.05 = $0.25 per GLC.

Step 2: Ungluing Process

Now, let's consider a scenario where a user decides to unglue 100,000 GLC, which represents 10% of the total supply.