Everything in Chapters 23–25 was architecture. This chapter is the toolbox that sits on top of it. Four exercises, four specific problems every quant faces in the real market. Each one takes a PDE result from earlier and turns it into a usable formula, a consistency check, or a calibration engine. Think of this as the manual for your quantitative workbench.
Four tools — four distinct problems every quant desk must solve.
Most SDEs have no closed-form solution — you simulate. But when the drift and diffusion are linear in X, an exact formula exists. This is the master key for Vasicek, Ornstein-Uhlenbeck, and Hull-White models:
The general solution uses an integrating factor e^(−bt). For the Vasicek model (c = 0, σ constant), this gives:
The key payoff: R(t) is normally distributed at every time t — mean and variance can be computed analytically. No Monte Carlo needed. The probability that the rate exceeds any threshold is a simple normal CDF calculation.
The Vasicek distribution at T = 0.5yr (green, narrow), T = 1yr (blue, medium), T = 2yr (purple, wide). All Gaussian — all analytically computable without simulation.
Use this when: your strategy involves a mean-reverting spread, rate, or factor. The closed-form distribution lets you compute the probability of a spread exceeding your entry threshold without running a single path simulation. This is the mathematical engine behind Pairs Trading and Z-score mean reversion strategies.
Two bonds driven by the same short rate R(t) must have the same reward-to-risk ratio. If not, an arbitrage exists: short the bond with the lower Sharpe ratio, long the other, cancel the dW term, and collect riskless profit. The no-arbitrage condition pins a single Market Price of Risk λ that all bonds must share:
λ is the single number that must be consistent across the entire yield curve. It tells you how many units of expected return the market demands per unit of interest rate volatility. When you specify a short-rate model (Vasicek, CIR, Hull-White), you must also specify λ. If λ is inconsistent across maturities, your model has an arbitrage leak.
All bonds on the same yield curve must share one λ. A model that assigns different λ values to different maturities contains a free lunch — and will fail in live trading.
Use this when: building or calibrating a multi-maturity fixed income model. Before trusting any yield curve model, compute the implied λ for each maturity. If they differ by more than model noise, you have an arbitrage in your model. This check costs two lines of code and can save an entire interest rate strategy from structural mispricing.
Standard BSM treats σ as a constant. But implied volatility from market prices is never flat — it smiles. The Heston Model gives volatility its own mean-reverting SDE, turning the problem into a 2D Feynman-Kac PDE where S and V are the two state variables.
The Heston PDE adds three new terms to BSM — vol drift, vol Gamma, and the correlation term ρ·ξ·√V·S·C_{SV}:
The reason equity implied vol is skewed (OTM puts more expensive than OTM calls) is precisely ρ < 0. When stocks drop, volatility spikes. OTM puts are protection against exactly that scenario — so they cost more. The Heston C_{SV} term is what mathematically creates this skew. Without it, the model produces a symmetric smile and systematically underprices crash protection.
Start at the future payoff and solve backward to find the price today. This is what Feynman-Kac does — and what BSM does. Time runs from T → t.
Use for: option pricing, hedge ratios, Greeks. Input = payoff at T. Output = fair value at t.
Start at today's price and propagate the probability density forward. The density spreads and drifts as time passes. Time runs from t → T.
Use for: VaR, probability of breaching a level, density of future prices. Input = current price. Output = distribution at T.
Same SDE, two directions. Backward gives you prices. Forward gives you probability densities — the foundation of risk management and VaR.
The forward (Fokker-Planck) equation is the engine of Dupire's formula (Exercise 6.10). By propagating the density forward under a local volatility model, Dupire derived the exact formula for what σ(T, K) must be to match every observed market option price simultaneously. The backward and forward equations are mathematically adjoint — they are transposes of each other in the space of probability densities.
If the market quotes call option prices C(T, K) for every maturity T and strike K, Dupire's formula extracts the exact local volatility σ(T, K) that is consistent with all of these prices simultaneously. It runs the forward equation in reverse — instead of asking "given σ, what prices does the model produce?", it asks "given the prices, what σ must the model use?"
The numerator captures how option prices change through time (the cost of carry). The denominator captures how option prices curve across strikes (the probability mass at each stock level). Their ratio is the market-implied variance at that specific (T, K) point.
Theoretical Dupire local vol surface σ(T, K) — higher near the money, term structure sloping downward. Each point is what the market implies for that specific maturity and strike.
Dupire's formula is why quant desks can match every market price exactly on day one. It is the bridge between theory and the trading screen. The local vol surface is recalibrated every morning when the options market opens. Any deviation of your model prices from market prices after calibration is a model error — Dupire's formula eliminates systematic miscalibration by construction. The downside: local vol models predict future smiles poorly. Stochastic vol models (Heston) predict future smiles better but match today's prices less cleanly.
Select a tool and explore it interactively. The Mean Reversion tool shows the Vasicek rate distribution at future times. The Vol Smile tool shows how Heston's ρ and ξ create the smile. The Lambda Check tool tests yield curve consistency.
Chapter 26 — the quant desk toolkit in five ideas: