Mathematical Basis of the Project
The equations the protocol uses to operate
The information on this page and all other pages owned by, operated by, or related to Hector Network is for educational purposes only and does not constitute any kind of advice.

# Staking

$sHEC = HEC$
$sHEC will always be redeemable for$HEC as a 1:1 swap since the protocol will always convert bond sale profits to HEC.
$Rebase = 1 - (HecDeposited/sHECOutstanding)$
The treasury deposits HEC into the distributor. The distributor then deposits HEC into the staking contract, creating an imbalance between HEC and sHEC. sHEC is therefore rebased to correct this imbalance between HEC deposited and sHEC outstanding. The rebase brings sHEC outstanding back up to parity with HEC so that 1 sHEC always equals 1 staked HEC. This rebasing mechanism facilitates the sHEC = HEC equation above.

# Bonding

$Bond Price = 1 + Market Premium$
The price of a bond is governed by the interaction between DAI and the market sentiment of HEC. The sentiment of the market determines the premium applied to bond prices.
$MarketPremium = DebtRatio * BCV$
The Market Premium is derived from the debt ratio of the system and a scaling variable called BCV, which is in turn governed by market sentiment.
$DebtRatio = BondsOutstanding / HECSupply$
The debt ratio is a variable which allows us to measure the debt of the Protocol to Bonders, allowing for a dynamic Market Premium.
$BondPayout\scriptsize ReserveBond \normalsize = MarketValue \scriptsize Asset \normalsize / BondPrice$
Bond payout determines the number of HEC available to a bonder. For reserve bonds, the market value of the assets supplied by the bonder is used to determine the bond payout. For example, if a user supplies 100 DAI and the bond price is 25 DAI, the user will be entitled 4 HEC since 100/25 = 4.
$BondPayout \scriptsize lpBond \normalsize = MarketValue \scriptsize lpToken \normalsize / BondPrice$
For liquidity bonds, the market value of the LP tokens supplied by the bonder is used to determine the bond payout. For example, if a user supplies 0.001 HEC-DAI LP token which is valued at 1000 DAI at the time of bonding, and the bond price is 250 DAI, the user will be entitled to 4 HEC.

# \$HEC Supply Governance

$HEC \scriptsize SupplyGrowth \normalsize = HEC \scriptsize Stakers \normalsize + HEC \scriptsize Bonders \normalsize + HEC \scriptsize DAO$
HEC has a dynamic supply, meaning that it adjusts with market activity.
Supply increases when HEC is minted for staking or bonding.
$HEC \scriptsize Stakers \normalsize = HEC \scriptsize Total Supply \normalsize * RewardRate$
As each epoch ends, the treasury will determine and mint tokens based upon the current rate. This is then distributed to stakers.
$BondPayout =HEC \scriptsize Bonders \normalsize$
When a bond is taken, HEC is minted. The HEC willl be vested and released at linear intervals. Different types of bonds require different calculations. See above for more information.
$MintedHEC \scriptsize DAO \normalsize = MintedHEC \scriptsize Bonders \normalsize /10$

# RFV

$HEC \scriptsize RFV \normalsize = TreasuryBalance$
Every circulating HEC token is represented in the treasury in either stablecoins or non-stablecoins.
$TreasuryBalance \scriptsize stablecoins \normalsize = RFV \scriptsize ReserveBond \normalsize + RFV \scriptsize lpBond$
When bonds are taken, the stablecoin reserve of the treasury grows. RFV (risk-free value) is calculated differently based upon the bond type.
$RFV \scriptsize ReserveBond \normalsize = AssetSupplied$
Reserve bonds in stablecoins like DAI, the RFV is equal to the value of the token supplied by the bonder.
$RFV\scriptsize lpBond \normalsize = 2 \sqrt ConstantProduct * \% Ownership\scriptsize Pool$
For LP bonds such as HEC-DAI bond, the RFV is calculated differently because the protocol needs to mark down its value.
Why? The LP token pair consists of HEC, and each HEC in circulation will be backed by these LP tokens - there is a cyclical dependency. To safely guarantee all circulating HEC are represented, the protocol marks down the value of these LP tokens, hence the name risk-free value (RFV).