TQBTHEQUANTBATEMAN
TQB/ learn/ equity/ term structureEN · DARK
Volatility · intermediate

Volatility term structure

Locating uncertainty, events and mean reversion along the expiry axis

BY THE END, YOU CAN

01Convert implied volatility into total variance.

02Derive forward variance between two maturities.

03Recognize event bumps and term inversion.

04Test a term slice for calendar consistency.

01
INTUITION

Separate the quote from the quantity inferred from it.

A term structure shows where the option market locates uncertainty in time. Volatility levels are not additive; total variance is the object that carries across adjacent horizons.

01

A flat volatility curve still implies increasing total variance.

02

Scheduled events create localized variance increments.

03

Negative forward variance signals inconsistent inputs or interpolation.

02
WHY MARKETS CARE

Start from executable inputs and conventions.

Term structure controls calendar spreads, event trades, variance forwards and the maturity dimension of every surface.

INSTRUMENTS

calendar spreads

variance swaps

forward-start options

earnings and event options

QUOTE CONVENTION

This lesson uses annualized implied volatility and total variance w(T)=σ²(T)T. Expiries use a consistent ACT/365-like year fraction.

03
MATHEMATICS

Transform quotes without losing units or arbitrage constraints.

Formula · Definition

Total variance

w(T)=σimp2(T)Tw(T)=\sigma_{imp}^2(T)T

Variance accumulated to maturity in the chosen strike or delta slice.

Open in Analytics
Formula · Short derivation

Forward variance

ξ(T1,T2)=w(T2)−w(T1)T2−T1\xi(T_1,T_2)=\frac{w(T_2)-w(T_1)}{T_2-T_1}

Average variance priced for the forward interval.

Open in Analytics
Short derivation
Short derivation

Extracting a forward variance interval

Assume integrated variance adds over non-overlapping time intervals.

  1. 01

    Express each maturity in total variance

    Convert annualized volatility quotes before taking differences.

    wi=σi2Tiw_i=\sigma_i^2T_i
  2. 02

    Partition integrated variance

    Cumulative variance to T2 equals cumulative variance to T1 plus the forward interval.

    w(T2)=w(T1)+ξ(T1,T2)(T2−T1)w(T_2)=w(T_1)+\xi(T_1,T_2)(T_2-T_1)
  3. 03

    Solve for the forward rate

    Rearrange the partition identity.

    ξ=w2−w1T2−T1\xi=\frac{w_2-w_1}{T_2-T_1}
  4. 04

    Require non-negative increments

    A negative forward interval is economically and numerically suspect for a diffusion-style variance representation.

    w2−w1≥0w_2-w_1\ge0
  5. 05

    Interpret event bumps

    A discrete event variance can be added to baseline integrated variance, causing short maturities spanning the event to look elevated.

Term structure becomes coherent when represented as cumulative and forward variance, with the maturity clock and coordinate held fixed.

Inputs
  • w(T)=σ²(T)T: total variance
  • ξ(T1,T2): forward variance
  • T1<T2: maturity interval
  • ΔT=T2-T1
Assumptions and limits
  • Fixed-strike and fixed-delta slices differ as forward moves.
  • Sparse long maturities require extrapolation.
  • Event variance is not directly observable.
Formula · Definition

Calendar condition

w(k,T2)≥w(k,T1)for T2>T1w(k,T_2)\ge w(k,T_1)\quad\text{for }T_2>T_1

A practical fixed-coordinate condition used to detect negative forward variance.

Open in Analytics
05
MODEL / PRICING

Invert, fit, and reprice the market instruments.

METHOD

Fit monotone total variance through liquid expiries, preserve event knots, and extract forward intervals for interpretation.

CALIBRATION

Use spreads and liquidity weights; do not smooth away scheduled events or force a parametric curve that creates negative increments.

Implementation with current QuantLib

Current QuantLib separates market structures, processes, instruments, engines and calibration helpers. Use those abstractions only after the lesson’s conventions, domains and numerical checks are explicit.

API authority: upstream QuantLib reference pinned in the source registry.
06PYTHON IMPLEMENTATIONOpen the implementation and checks.
ARCHITECTURE
  • Validate domains and units at the boundary.
  • Keep the numerical kernel framework-free and deterministic.
  • Return diagnostics with values.
  • Test analytical limits and failure states.
PYTHON 3 · NUMPY / SCIPY

Forward variance extraction

Convert a volatility term structure into non-negative forward intervals.

REUSABLE EXAMPLE
01from __future__ import annotations
02
03import numpy as np
04
05def forward_variances(times: np.ndarray, vols: np.ndarray) -> np.ndarray:
06 if times.shape != vols.shape or np.any(np.diff(times) <= 0) or np.any(vols < 0):
07 raise ValueError("times must increase and vols must be non-negative")
08 total = vols**2 * times
09 forwards = np.diff(total) / np.diff(times)
10 if np.any(forwards < -1e-12):
11 raise ValueError("negative forward variance")
12 return forwards
13
14t = np.array([30, 90, 180, 365]) / 365.0
15vol = np.array([0.28, 0.24, 0.225, 0.22])
16fwd = forward_variances(t, vol)
17assert np.isfinite(fwd).all() and np.all(fwd >= 0.0)
18print(np.round(np.sqrt(fwd), 4))
EXPECTED OUTPUTForward interval volatilities derived from total variance.
SANITY CHECKS

✓ Maturities strictly increase.

✓ Inputs are decimal vols.

✓ Forward variance cannot be materially negative.

07
INTERACTIVE LAB

Move the quote and inspect every linked representation.

TOTAL AND FORWARD VARIANCE

Forward-variance lab

Add an event bump or invert the front end; inspect total and forward variance by interval.

SYNTHETIC · CONTROLLED SCENARIOS
1Y total variance0.0378
Min forward0.0337
StateNormal
Annualized variance by Maturity (years)

Normal: Gently rising cumulative uncertainty.

  • total variance
  • forward variance
Maturity (years): 0.1Y. total variance: 0.0026. forward variance: 0.0512.

Use Left/Right or Up/Down arrows to inspect values; Home and End jump to the bounds.

ACTIVE STATE

Normal — Gently rising cumulative uncertainty. Move the intensity control and inspect every series with pointer or touch.

08
FRONT OFFICE

Where the model meets the book.

ON THE DESK
“The front expiry is not high; it contains a different piece of time.”
VISIBLE INPUTS

expiry timestamps

forward coordinate

ATM/slice vols

event calendar

spread weights

CALIBRATION

Use spreads and liquidity weights; do not smooth away scheduled events or force a parametric curve that creates negative increments.

RISK

calendar vega

event variance

roll-down

forward-vol exposure

DAILY WORKFLOW
  1. normalize expiries
  2. convert total variance
  3. fit monotone curve
  4. extract forwards
  5. stress events
Production failure modes
  • day-count mismatch
  • event timestamp error
  • negative forwards
  • over-smoothed knots
09MACRO CONNECTIONOpen the transmission channel.
MACRO CONNECTION

Events redistribute variance through time

Policy decisions, elections and earnings concentrate uncertainty in intervals rather than lifting every maturity equally.

01Scheduled catalysttransmits

localizes uncertainty

02Total variancetransmits

adds an event increment

03Term curvetransmits

forms a bump or inversion

04Calendar tradeoutput

isolates the interval

10COMMON PITFALLSOpen the failure checklist.
01

Subtracting volatilities to obtain forward volatility.

02

Comparing expiries with inconsistent clocks.

03

Smoothing through known events.

04

Calling an inverted volatility curve arbitrage by itself without inspecting total variance.

11SOURCES / FURTHER READINGOpen sources and continue the track.
research

Volatility, Monte Carlo and stochastic-volatility lectures

Research map for the mathematical progression and numerical experiments; prose, examples and code are original.

Source
Computational Finance Course
Author
L. A. Grzelak
Ref
main
OPEN ORIGINAL SOURCE ↗
implementation reference

Current volatility structures, processes, calibration helpers and tests

Implementation reference for production abstractions and validation patterns.

Source
QuantLib upstream
Author
QuantLib contributors
Ref
v1.42.1
OPEN ORIGINAL SOURCE ↗