Math appendix
This page gives the formulas the futures program and the oracle apply, with their rounding. They are here so you can check results. They are not a pricing model, and nothing here is a quote. The programs’ own arithmetic is the authority.
| Quantity | Unit |
|---|---|
| Oracle index values | 6 decimal places. An index level of 100 is 100_000_000. |
Grid positions lo, hi |
Whole steps of the market’s grid. On Amoeba’s markets one step is one index point, and the grid runs from 0 to 200. |
k |
Atoms one lot of a one-step claim pays in full. 10,000 on Amoeba’s markets: $0.01 per lot per point. |
| Fine units | 1/k of a step. Entries and the settlement value are measured in them. |
| USDC | 6 decimal places. 1 USDC = 1_000_000 atoms. |
| Basis points (bps) | 10,000 bps = 100%. |
trunc rounds toward zero. floor and ceil round down and up. clamp(x, a, b) is min(max(x, a), b).
Settlement index
Section titled “Settlement index”The final index for a market is built from the movement of each oracle source since its opening value. The program works in whole basis points.
delta_s = trunc(10000 × (P_s − P_s,0) / P_s,0) one source, in bpsd_b = median of eligible delta_s in bucket b in bpsindex_bps = Σ_b trunc(d_b × w_b / 10000) bucket weights: Σ_b w_b = 10000V = floor((B × (10000 + index_bps) + 5000) / 10000) final index, rounded half upP_s,0is the source’s accepted opening value.P_sis its settlement value, defined below.w_bis the fixed weight of bucketbin the product. Every eligible source in a bucket counts equally. Bonds and support capital never weight a source.Bis the oracle month’s settlement base. WithB= 100, a weighted move of +300 bps settles the index at 103.index_bpscannot be below −10,000.
A source’s settlement value. Let T be expiry. Step back from T one day at a time until five UTC weekdays (Monday to Friday) have been counted. Call that point W. P_s is the median of the source’s accepted values with timestamps from W to T, inclusive. With an even number of values, it is floor((a + b) / 2) of the middle two. If the source has no value in the window, its latest accepted value at or before W is used. That carried value is not a new update. A source with no usable value is not eligible.
A bucket’s median. With an even number of eligible sources, d_b is the average of the middle two, truncated toward zero. A bucket needs at least max(3, ceil(n / 2)) eligible sources, where n is the number of sources frozen for that bucket for the month. If it has fewer, the program re-runs the bucket once with a 10-weekday window. If it is still short, the bucket goes to the oracle council. The council can confirm the bucket’s measured median, d_b computed as above over its eligible sources, or keep its last accepted value; without three matching votes the bucket keeps its last accepted value.
The settlement value cannot be finalized earlier than 24 hours (86,400 seconds) after expiry. That time is reserved for evidence and disputes.
Market settlement value
Section titled “Market settlement value”The market reads its oracle period. With the period’s settlement value V (6 decimals) and step_value, the oracle units per grid step (1_000_000 on Amoeba’s markets):
S = floor(V × k / step_value) in fine units (1/k step)An index of 103.456789 settles a market at S = 1_034_567, that is 103.4567 points. If the council acts on a period still unsettled after expiry, S comes from the value the governance council sets, in the same units.
Claim payouts
Section titled “Claim payouts”A claim is a side, an interval [lo, hi) and a number of lots. Per lot, in USDC atoms:
set = (hi − lo) × klong(S) = clamp(S − lo × k, 0, set)short(S) = set − long(S)Because S is in fine units, every payout per lot is a whole number of atoms, and a long plus a short on the same interval pay exactly set. With k = 10,000, a long on 90–110 settling at 105 pays clamp(1_050_000 − 900_000, 0, 200_000) = 150_000 atoms, $0.15, per lot.
Entry, cost and leverage
Section titled “Entry, cost and leverage”A claim opens at a price p per lot, in atoms, with 0 ≤ p ≤ set. The API calls it premium. It places the entry on the price line:
entry (fine units) = lo × k + pentry (index) = lo + p / klong pays = p × lotsshort pays = (set − p) × lotsA fill’s average entry is lo × k + max(P, 0) / lots, with P the fill’s total price. Leverage at an entry E:
long: L = E / (E − lo) so lo = E − E / Lshort: L = E / (hi − E) so hi = E + E / LThe web ticket and Petri place the losing end from the leverage you choose, on the grid, and the winning end where you choose. At E = 100 a 50× long on 98–120 pays 2 points per lot and a 5× short on 98–120 pays 20; together they hold the set, 22 points.
Escrow and netting
Section titled “Escrow and netting”| What | Holds or releases, per lot |
|---|---|
Resting long at limit p |
holds p |
Resting short at limit p |
holds set − p |
| Resting close order | holds its claim, no cash |
| Maker ladder step | holds bid per bid lot and k − ask per ask lot (one-step sets) |
| Long and short of one owner on the same interval | redeem for set into free cash |
Selling a long at p |
free cash gains p |
Buying back a short at p |
free cash gains set − p |
Intervals that differ in either end are not complements and release nothing. Split divides a claim exactly: [a, c) = [a, b) + [b, c).
Market invariants
Section titled “Market invariants”After every instruction the program checks:
custody = deposits − withdrawals = free + reserved + backingreserved = the escrow of every resting order and ladderbacking = k × long coverage = k × short coverage while the market is openbacking = what the remaining claims pay once it is finalThere are no fees and no funding, so every atom deposited is withdrawable as free cash, held as escrow, or backing a claim.
Earn shares
Section titled “Earn shares”The Earn vault’s value is its idle cash plus, in each of its markets, its trader’s free and reserved cash and what its claims and ladder inventory pay. Payoffs are linear between grid positions, so one sweep over each market’s grid gives that market’s lowest and highest value over every settlement outcome; the vault’s V_low and V_high add them up with the idle cash. With N shares outstanding:
shares for a deposit of x atoms = floor(x × N / V_high) (x when N = 0)atoms for n shares = floor(n × V_low / N) paid from idle cash, then the vault's cash in its marketsA settled market’s part has one value, so V_high − V_low is the range of the open positions. Where a market’s free cash is short, a withdrawal retires the vault’s ladder there to release its escrow. The last shares wait while V_high is above what they would get. See Earn.
Display figures
Section titled “Display figures”The suggested range is index ∓ 2σ, rounded to whole grid positions and kept within the span the maker quotes. With a live maker ladder, σ is half the distance between the settlements the book prices at an 84.1% and a 15.9% chance of being exceeded: a one-step claim [x, x + 1)’s mid price over k is about the chance the index settles above x + 1/2. Without a ladder, σ = index × vol × √T, with T the time to expiry in years and vol the index’s annualized realized volatility over its last 30 days of samples (40% a year when there are too few). Chart values, the oracle reference index, the suggested range and P&L at the index are explanations. They are not quotes or inputs to the program’s checks.

