HEDGEFUND.md

Models / Options / variance_carry

Variance carry

What does this variance position pay at this realized vol, and how much faster does a short lose than it earns?

Computes the settlement P and L of a variance position from its strike and vega notional, with realized vol taken from the caller's prices or sent directly. Shows the convexity from half the strike to three times it, and how much faster a short loses than it earns. All numbers come from the caller. Not a quote, a forecast of vol or advice.

The paste-ready promptmodel.md

On these numbers, a short variance position struck at 20 with realized vol of 26 shows a P and L of -69,000, and -300,000 if realized vol reaches twice the strike.

Hypothetical, and on made-up numbers until you replace them. Nobody traded this, and nothing here is on offer.

Readings

The numbers, with their units.

Realized vol

26%

As sent.

P and L at settlement

watch

-69,000

P and L at twice the strike

watch

-300,000

The most a short can earn

100,000

At zero realized vol. There is no matching limit on the loss.

Loss at twice the strike over gain at zero

3times

An equal move of K points each way. Doubling against halving gives 4 times.

Variance notional

250per variance point

Gap to a vol swap

-9,000

What the squared payoff adds or takes away at this realized vol.

What flips it

The value of one input where the outcome changes, with the others held.

  1. realized_vol_pct

    20%now 26

    P and L is zero at the strike. Above it a long gains and a short loses, and below it the reverse.

  2. realized_vol_pct

    66.33%now 26

    At this realized vol the short has lost the whole capital.

Flags

What went past a line, and what to read before you trust the rest.

  • watch
    A short loses faster than it earns. At twice the strike it loses 300,000: 3 times the most it can ever earn (100,000, at zero realized vol), and 4 times what it earns at half the strike. short_loses_faster_than_it_earns
  • watch
    Realized vol of 26 is above the 20 strike, so the short is losing on these numbers. realized_above_strike

What this leaves out

What the formula leaves out, by name.

  • Any cap on realized variance in the contract terms.
  • Marks before settlement and changes in implied variance.
  • Hedging costs, skew and the strike-replication gap.
  • Missed fixings, market closures and dividend adjustments in the return series.
  • Margin, financing, fees and counterparty default.
  • Taxes.
What it took as given (5)

What it took as given to get here.

  • Realized vol assumes a zero mean and divides by n, the number of returns: not n - 1, and not the number of prices.
  • Vega notional is money per vol point at the strike, so the variance notional is vega_notional / (2K) per variance point.
  • P and L is the settlement figure for the full period, with no discounting. A mark before settlement would also need implied variance for the time left.
  • The vol swap line in the table is vega_notional * (RV - K). It shows what convexity adds: the gap is exactly vega_notional * (RV - K)^2 / (2K).
  • A short's tail in the sleeve is its loss at twice the strike. A long gains there, so a long's tail is its loss at zero realized vol, the most it can lose.
P and L across realized vol, against a straight vol swapP and L
  • Variance
  • Vol swap
-500K0102030405060Realized vol, %-800,000-400,000
The data

P and L across realized vol

multiple_of_strikerealized_vol_pctvariance_pnlvol_swap_pnlconvexity_gap
0.51075,000100,000-25,000
0.751543,75050,000-6,250
120000
1.2525-56,250-50,000-6,250
1.530-125,000-100,000-25,000
240-300,000-200,000-100,000
2.550-525,000-300,000-225,000
360-800,000-400,000-400,000

Hypothetical, computed from the numbers sent and any stated default, with hindsight. Nobody traded it, and costs and liquidity are only as assumed. Not a forecast, a recommendation, an offer, or a record of real trading. Don't use it to market an investment.

formula Realized vol RV = 100 sqrt(periods/n * sum((ln r)^2)), zero mean, n returns. Long P and L = vega_notional * (RV^2 - K^2) / (2K), RV and K in vol points. Short is the negative.

inputs_hash 70a65dc5ce2fba75

Paste it into your agent

No connection needed. This prompt carries the method, the conventions and what this site's engine gives on the made-up numbers, so your agent can check its own work before it touches real ones. Every prompt, with its hash, is listed at /prompts.json. A copy that stays fixed for this version, for a stack to point at: /v/1.0/models/variance_carry.md.

prompt.md
# Variance carry: a prompt from hedgefund.mdPaste this into your AI agent. It needs no connection to hedgefund.md. An agent that can run code should write and run it, and shouldn't work a long series by hand.**Question.** What does this variance position pay at this realized vol, and how much faster does a short lose than it earns?## MethodRealized vol RV = 100 sqrt(periods/n * sum((ln r)^2)), zero mean, n returns. Long P and L = vega_notional * (RV^2 - K^2) / (2K), RV and K in vol points. Short is the negative.## Conventions- Realized vol assumes a zero mean and divides by n, the number of returns: not n - 1, and not the number of prices.- Vega notional is money per vol point at the strike, so the variance notional is vega_notional / (2K) per variance point.- P and L is the settlement figure for the full period, with no discounting. A mark before settlement would also need implied variance for the time left.- The vol swap line in the table is vega_notional * (RV - K). It shows what convexity adds: the gap is exactly vega_notional * (RV - K)^2 / (2K).- A short's tail in the sleeve is its loss at twice the strike. A long gains there, so a long's tail is its loss at zero realized vol, the most it can lose.## Step 1: check your method on these made-up numbersThe numbers and names below are made up. They aren't market levels, typical values or anyone's real figures.```json{  "strike_vol_pct": 20,  "vega_notional": 10000,  "side": "short",  "realized_vol_pct": 26,  "capital": 1000000}```Work them out with the method above. Yours should match these within 0.5%.- Realized vol: 26 %- P and L at settlement: -69000- P and L at twice the strike: -300000- The most a short can earn: 100000- Loss at twice the strike over gain at zero: 3 times- Variance notional: 250 per variance point- Gap to a vol swap: -9000Where the outcome flips, with the other inputs held:- realized_vol_pct at 20: P and L is zero at the strike. Above it a long gains and a short loses, and below it the reverse.- realized_vol_pct at 66.33249581: At this realized vol the short has lost the whole capital.If yours differ, stop and tell the person which ones and by how much. Don't go on to real numbers until they match, or until the person has seen the difference. These values come from one engine and can be wrong too.## Step 2: run it on the person's numbersReplace every input with the person's own. Ask for any number you don't have, and don't invent one.## Step 3: reportGive one sentence beginning "On these numbers,", then the values, then where the outcome flips. Always add what this leaves out:- Any cap on realized variance in the contract terms.- Marks before settlement and changes in implied variance.- Hedging costs, skew and the strike-replication gap.- Missed fixings, market closures and dividend adjustments in the return series.- Margin, financing, fees and counterparty default.- Taxes.## LimitsResults are hypothetical: arithmetic on the numbers given, prepared with hindsight. Nobody achieved them, and costs and liquidity are only as assumed. They aren't a forecast, a recommendation, an offer or a record of real trading. Don't say what to buy, sell or hold, and don't use them to market an investment. Whether a person may hold or trade an instrument is a legal question for counsel.Provided as is, at your own risk, by hedgefund.md, which is not a fund and isn't anyone's adviser. Version 1.0. Source: https://hedgefund.md/models/variance_carry/prompt.md. Terms: https://hedgefund.md/terms

Call it

The same code answers on this page, over HTTP, over MCP and on your own machine, and the same inputs give the same bytes. No key, and nothing is stored. Send positions by POST or run the library, because a URL can land in a server log. model.md holds all of this for your agent.

POST the inputs to /api/v1/variance_carry.

terminal
curl -s https://hedgefund.md/api/v1/variance_carry \  -H 'content-type: application/json' \  -d '{"strike_vol_pct":20,"vega_notional":10000,"side":"short","realized_vol_pct":26,"capital":1000000}' \  | jq '{summary, flags, flips, not_modeled, inputs_hash}'

Inputs

InputTypeRangeRequiredWhat it is
strike_vol_pctnumber0.01 to 500yesVariance strike quoted in vol. 20 means 20%.
vega_notionalnumber0.01 to 10000000000yesMoney per vol point at the strike.
sidestringlong | shortyesLong receives realized variance. Short pays it.
pricesarray2 to 2000 itemsnoPrice series for realized vol, oldest first. Send this or realized_vol_pct, not both.
realized_vol_pctnumber0 to 2000noRealized vol, if not sending prices. 25 means 25%.
periods_per_yearnumber1 to 100000noPrice periods in a year, needed with prices. 252 for trading days, 365 for calendar days.
capitalnumber0.01 to 10000000000000noOptional. Capital behind the position, for the sleeve and the wipe-out flip.

Hypothetical, and on made-up numbers until you replace them. Nobody traded this, and nothing here is on offer.

1.0Use at your own risk: hedgefund.md is not a fund, not an offer of any security, token or fund interest, and not advice. Results are hypothetical, may be wrong, and are not a record of real trading. Don't use them to market an investment. See the terms.