Staking & Yield Accrual
Staking converts ELUSD into sELUSD, a share token whose price appreciates over time as yield is pushed on-chain. Users hold sELUSD to capture yield; unstaking burns shares and returns ELUSD at the current (higher) exchange rate.
Overview
The staking system follows an ERC-4626-style share model:
Stake ELUSD → receive sELUSD shares at the current exchange rate.
Hold sELUSD → share price rises as
syncNAV()mints new ELUSD into the pool.Unstake sELUSD → receive ELUSD at the now-higher exchange rate.
There are no lock periods. Users can stake and unstake at any time.
Share price
The exchange rate between ELUSD and sELUSD is:
sharePrice = (accountedElUSD + VIRTUAL_ASSETS) × 1e18
─────────────────────────────────────────
(totalSElUSD + VIRTUAL_SHARES)VIRTUAL_ASSETS and VIRTUAL_SHARES are both 1e12. They ensure:
An empty pool always returns a share price of exactly
1e18(1:1).A dust first-deposit cannot manipulate the exchange rate for subsequent stakers (inflation-attack hardening).
Only three operations change accountedElUSD: stake(), unstake(), and syncNAV(). Direct token transfers to ElUSDStake are never reflected in share math.
Staking
Function: ElUSDStake.stake(uint256 amount) → uint256 shares
ELUSD is transferred from the user to ElUSDStake, then sELUSD is minted to the user. _totalAccountedElUSD increases by amount.
Use previewStake(amount) to read the expected share count before transacting.
Unstaking
Function: ElUSDStake.unstake(uint256 shares) → uint256 amount
sELUSD is burned from the user; _totalAccountedElUSD decreases by amount; ELUSD is transferred to the user.
Use previewUnstake(shares) to read the expected ELUSD return before transacting.
Yield accrual: syncNAV()
Function: ElUSDStake.syncNAV(), restricted to YIELD_OPERATOR
This function is called by an authorized backend operator once per day. It reads the on-chain NAV from NAVAggregator, computes the net yield since the last sync, deducts fees, and mints or burns ELUSD to reflect that yield in the share price.
Yield isolation formula
Because the NAV also includes newly deposited vault collateral (which should not inflate the share price), the formula isolates only genuine venue returns:
New vault deposits increase both navUsdNow and elUSDSupplyNow by the same amount, so their difference is zero; deposits have no effect on share price.
Fee deduction
Two fee types are deducted from grossYield before stakers receive their share:
Management fee
lastElUSDSupply × feePercent × elapsed / (10_000 × SECONDS_PER_YEAR)
Performance fee
max(0, grossYield) × feePercent / 10_000
Current fee schedule in the contracts: 1% management fee and 30% performance fee. Both are currently waived by Elara and Arken as a joint growth measure, so _feeCollected accrues nothing in practice today. The mechanism remains in place and fees will return once the fee model is reworked.
Fees are accumulated as USD accounting entries in _feeCollected; no tokens are minted at this point. When collectFees() is called by CONTRACT_ADMIN, the accrued amounts are swept to the fee recipient.
Net yield application
After fee deduction:
Positive
netYield→ElUSD.mint(elUSDStake, netYield): new ELUSD enters the pool, raising the share price for all current holders.Negative
netYield→ElUSD.burn(elUSDStake, |netYield|): ELUSD is removed from the pool, lowering the share price. This is the mechanism by which sELUSD holders bear strategy and NAV losses. A negative sync reduces the share price for all holders; there is no reserve fund or junior tranche that absorbs the loss first. Holders of unstaked ELUSD are unaffected.
Staking & yield flow
NAVAggregator
NAVAggregator reads balances and positions from a configurable set of strategy adapters (Aave, Morpho, Pendle, Curve, Convex, Uniswap v3/v4, ERC-4626 vaults) plus treasury wallet balances, and sums them into a single USD NAV figure. ElUSDStake.syncNAV() calls NAVAggregator.getNAV() to get this figure.
Key view functions
sharePrice()
Current ELUSD per sELUSD share (18 dec)
previewStake(amount)
sELUSD shares received for amount ELUSD
previewUnstake(shares)
ELUSD received for shares sELUSD
totalElUSD()
Total ELUSD accounted in the staking contract
lastNavUsd()
NAV recorded at the last syncNAV()
lastSyncTimestamp()
Timestamp of the last syncNAV()
totalUncollectedFees()
Accumulated USD fees not yet collected
Key events
Staked(user, amount, shares)
User stakes ELUSD
Unstaked(user, shares, amount)
User unstakes sELUSD
NAVSynced(navUsd, netYield, timestamp)
syncNAV() completes
FeesCollected(amounts[])
Fee sweep executed
Last updated
Was this helpful?