1. LEARNING OBJECTIVES
By the end of this lesson, you will be able to:
-
Define stochastic processes and classify them by state space and time space.
-
Construct Brownian Motion (Wiener process) from a simple random walk and prove its key properties.
-
Understand the properties of Brownian Motion (continuity, independent increments, normal increments, quadratic variation).
-
Define and apply Ito’s Lemma to transform stochastic differential equations.
-
Derive the solution to Geometric Brownian Motion (GBM) using Ito’s Lemma.
-
Apply Ito’s Lemma to derive the Black-Scholes partial differential equation.
-
Understand the relationship between Brownian Motion and the heat equation.
-
Simulate Brownian Motion and Geometric Brownian Motion paths.
2. STOCHASTIC PROCESSES – DEFINITION AND CLASSIFICATION
2.1 Definition
A stochastic process is a collection of random variables {X_t, t ∈ T} indexed by time t in some set T. For each fixed ω ∈ Ω, the function t → X_t(ω) is called a sample path or trajectory.
2.2 Classification
By State Space:
-
Discrete State: The process takes on a countable number of values (e.g., number of defaults, stock price movements in ticks).
-
Continuous State: The process takes on values in a continuous interval (e.g., stock price, interest rate).
By Time Space:
-
Discrete Time: T = {0, 1, 2, …} (e.g., daily returns, weekly volatility).
-
Continuous Time: T = [0, ∞) (e.g., Brownian Motion, diffusion processes).
2.3 Key Properties of Stochastic Processes
-
Adaptedness: X_t is F_t-measurable (the value at time t is known given the information up to time t).
-
Markov Property: The future depends only on the present, not on the past:
P(X_{t+s} ∈ A | F_t) = P(X_{t+s} ∈ A | X_t)
-
Martingale Property: E[X_t | F_s] = X_s for s ≤ t.
-
Stationarity: The distribution of X_t is invariant under time shifts.
-
Independent Increments: X_{t+s} – X_t is independent of F_t.
2.4 Financial Application – Asset Price Processes
Asset prices are modelled as continuous-time stochastic processes with:
-
Drift: The expected return (μ).
-
Volatility: The standard deviation of returns (σ).
-
Random Shocks: Brownian Motion (W_t).
3. BROWNIAN MOTION (WIENER PROCESS) – CONSTRUCTION AND PROPERTIES
3.1 Definition
A stochastic process {W_t, t ≥ 0} is a Brownian Motion (Wiener process) if:
-
W_0 = 0 (starts at zero).
-
Independent Increments: For any 0 ≤ t_1 < t_2 < … < t_n, the increments:
W_{t_2} – W_{t_1}, W_{t_3} – W_{t_2}, …, W_{t_n} – W_{t_{n-1}}
are independent. -
Normally Distributed Increments: For any 0 ≤ s < t:
W_t – W_s ~ N(0, t – s)
-
Continuity: The sample paths t → W_t are continuous almost surely.
3.2 Construction from a Random Walk
Let S_n = Σ_{i=1}^n ξ_i, where ξ_i = ±1 with equal probability (simple symmetric random walk).
Define the scaled process:
W_t^{(n)} = (1/√n) * S_{⌊nt⌋}
As n → ∞, W_t^{(n)} converges in distribution to Brownian Motion W_t.
3.3 Key Properties of Brownian Motion
-
Mean: E[W_t] = 0.
-
Variance: Var(W_t) = t.
-
Covariance: For s ≤ t:
Cov(W_s, W_t) = s
-
Self-Similarity: For any scaling factor c > 0:
{W_{ct}, t ≥ 0} = √c * {W_t, t ≥ 0} (in distribution).
-
Time Reversal: {W_t – W_T, 0 ≤ t ≤ T} = {W_t, 0 ≤ t ≤ T} (in distribution).
-
Fractal Dimension: Brownian Motion paths have fractal dimension 1.5 (they are nowhere differentiable).
3.4 Quadratic Variation of Brownian Motion
For a partition 0 = t_0 < t_1 < … < t_n = T, the quadratic variation is:
[W]T = lim{n→∞} Σ_{i=1}^n (W_{t_i} – W_{t_{i-1}})² = T
Implications:
-
The quadratic variation of Brownian Motion is deterministic (equal to T).
-
This is a fundamental result for stochastic calculus. It implies that (dW_t)² = dt.
3.5 The Covariation of Two Brownian Motions
If W_t^{(1)} and W_t^{(2)} are two Brownian motions with correlation ρ, then:
dW_t^{(1)} dW_t^{(2)} = ρ dt
3.6 Brownian Motion as a Martingale
Brownian Motion W_t is a martingale:
E[W_t | F_s] = W_s for s ≤ t
Proof:
E[W_t | F_s] = E[W_s + (W_t – W_s) | F_s] = W_s + E[W_t – W_s] = W_s
4. ITO’S LEMMA – THE CHAIN RULE FOR STOCHASTIC CALCULUS
4.1 The Ito Integral
Before Ito’s Lemma, we need the Ito integral. For an adapted process θ_t satisfying E[∫_0^T θ_t² dt] < ∞, the Ito integral is:
∫_0^T θ_t dW_t
This is defined as the limit of Riemann sums:
∫0^T θ_t dW_t = lim{n→∞} Σ_{i=1}^n θ_{t_{i-1}} (W_{t_i} – W_{t_{i-1}})
Key Properties of the Ito Integral:
-
Martingale: ∫_0^T θ_t dW_t is a martingale.
-
Ito Isometry: E[(∫_0^T θ_t dW_t)²] = E[∫_0^T θ_t² dt].
-
Zero Mean: E[∫_0^T θ_t dW_t] = 0.
4.2 The Ito Lemma (Univariate Version)
Let X_t be an Ito process:
dX_t = μ_t dt + σ_t dW_t
Let f(t, x) be a twice continuously differentiable function. Then:
df(t, X_t) = (∂f/∂t + μ_t ∂f/∂x + (1/2) σ_t² ∂²f/∂x²) dt + σ_t ∂f/∂x dW_t
Derivation (Taylor Expansion):
Expand f(t + dt, X_t + dX_t) using a Taylor series up to second order:
df = (∂f/∂t) dt + (∂f/∂x) dX_t + (1/2) (∂²f/∂x²) (dX_t)² + (∂²f/∂x∂t) dX_t dt + …
Substitute dX_t = μ_t dt + σ_t dW_t:
(dX_t)² = μ_t² (dt)² + 2 μ_t σ_t dt dW_t + σ_t² (dW_t)²
Using the rules:
-
(dt)² = 0
-
dt dW_t = 0
-
(dW_t)² = dt
We get:
(dX_t)² = σ_t² dt
Substituting back into the Taylor expansion:
df = (∂f/∂t) dt + (∂f/∂x)(μ_t dt + σ_t dW_t) + (1/2)(∂²f/∂x²) σ_t² dt
Collecting terms:
df = (∂f/∂t + μ_t ∂f/∂x + (1/2) σ_t² ∂²f/∂x²) dt + σ_t ∂f/∂x dW_t
4.3 The Ito Lemma (Multivariate Version)
Let X_t = (X_t^{(1)}, X_t^{(2)}, …, X_t^{(n)}) be an n-dimensional Ito process:
dX_t^{(i)} = μ_i(t, X_t) dt + Σ_{j=1}^m σ_{ij}(t, X_t) dW_t^{(j)}
For a function f(t, X_t):
df = (∂f/∂t + Σ_i μ_i ∂f/∂x_i + (1/2) Σ_{i,j} (σ σ^T){ij} ∂²f/∂x_i∂x_j) dt + Σ{i,j} σ_{ij} ∂f/∂x_i dW_t^{(j)}
5. GEOMETRIC BROWNIAN MOTION (GBM)
5.1 Definition
Geometric Brownian Motion is defined by the SDE:
dS_t = μ S_t dt + σ S_t dW_t
Where:
-
μ is the drift (expected return).
-
σ is the volatility (standard deviation of returns).
5.2 Solution Using Ito’s Lemma
We want to solve for S_t. Take f(S) = ln(S):
∂f/∂t = 0
∂f/∂S = 1/S
∂²f/∂S² = -1/S²
Applying Ito’s Lemma:
d(ln S_t) = (0 + μ S_t * (1/S_t) + (1/2) σ² S_t² * (-1/S_t²)) dt + σ S_t * (1/S_t) dW_t
d(ln S_t) = (μ – (1/2) σ²) dt + σ dW_t
Integrating from 0 to t:
ln(S_t) – ln(S_0) = (μ – (1/2) σ²) t + σ W_t
Exponentiating:
S_t = S_0 * exp( (μ – (1/2) σ²) t + σ W_t )
5.3 Properties of GBM
-
Log-Normal Distribution: S_t is log-normally distributed.
-
Mean: E[S_t] = S_0 e^{μt}.
-
Variance: Var(S_t) = S_0² e^{2μt} (e^{σ²t} – 1).
-
No Negative Prices: S_t > 0 for all t.
5.4 Financial Application – Stock Price Modelling
GBM is the standard model for stock prices in the Black-Scholes framework. The drift under the risk-neutral measure Q becomes r (the risk-free rate):
dS_t = r S_t dt + σ S_t dW_t^Q
The solution under Q is:
S_t = S_0 * exp( (r – (1/2) σ²) t + σ W_t^Q )
6. ITO’S LEMMA AND THE BLACK-SCHOLES PDE
6.1 Derivation of the PDE
Let V(t, S_t) be the price of a European option. Applying Ito’s Lemma:
dV = (∂V/∂t + μ S ∂V/∂S + (1/2) σ² S² ∂²V/∂S²) dt + σ S ∂V/∂S dW_t
6.2 Constructing a Risk-Free Portfolio
We construct a portfolio Π that contains one option and a short position of Δ shares:
Π = V – Δ S
We choose Δ = ∂V/∂S (delta hedging) to eliminate the dW_t term.
The portfolio differential is:
dΠ = dV – Δ dS
Substitute dV and dS:
dΠ = (∂V/∂t + μ S ∂V/∂S + (1/2) σ² S² ∂²V/∂S² – Δ μ S) dt + (σ S ∂V/∂S – Δ σ S) dW_t
With Δ = ∂V/∂S, the dW_t term cancels:
dΠ = (∂V/∂t + (1/2) σ² S² ∂²V/∂S²) dt
6.3 The Risk-Free Rate
Since Π is risk-free, it must earn the risk-free rate r:
dΠ = r Π dt = r (V – Δ S) dt
Equating the two expressions:
∂V/∂t + (1/2) σ² S² ∂²V/∂S² = r (V – S ∂V/∂S)
Rearranging gives the Black-Scholes PDE:
∂V/∂t + (1/2) σ² S² ∂²V/∂S² + r S ∂V/∂S – r V = 0
7. BROWNIAN MOTION AND THE HEAT EQUATION
7.1 The Heat Equation
The heat equation (diffusion equation) is:
∂u/∂t = (1/2) ∂²u/∂x²
7.2 Fundamental Solution
The fundamental solution of the heat equation is the Gaussian kernel:
u(t, x) = [1 / √(2πt)] * exp( -x² / (2t) )
7.3 Relationship with Brownian Motion
The transition density of Brownian Motion is the fundamental solution of the heat equation:
P(W_t ∈ dx) = [1 / √(2πt)] * exp( -x² / (2t) ) dx
This is why Brownian Motion is also called the “heat equation process.”
7.4 The Black-Scholes PDE as a Heat Equation
By a change of variables, the Black-Scholes PDE can be transformed into the heat equation. This is how the Black-Scholes formula is derived.
8. PRACTICAL IMPLEMENTATION
A. Simulating Brownian Motion Paths:
import numpy as np import matplotlib.pyplot as plt def simulate_brownian(T, n_steps, n_paths): dt = T / n_steps dW = np.random.normal(0, np.sqrt(dt), (n_paths, n_steps)) W = np.cumsum(dW, axis=1) return W # Parameters T = 1.0 n_steps = 252 n_paths = 100 # Simulate W = simulate_brownian(T, n_steps, n_paths) # Plot t = np.linspace(0, T, n_steps) plt.figure(figsize=(10, 6)) for i in range(min(10, n_paths)): plt.plot(t, W[i, :], alpha=0.6) plt.xlabel('Time') plt.ylabel('W_t') plt.title('Simulated Brownian Motion Paths') plt.show() # Verify properties print(f"E[W_T] = {np.mean(W[:, -1]):.4f} (expected 0)") print(f"Var[W_T] = {np.var(W[:, -1]):.4f} (expected {T:.4f})")
B. Simulating Geometric Brownian Motion:
def simulate_gbm(S0, mu, sigma, T, n_steps, n_paths): dt = T / n_steps dW = np.random.normal(0, np.sqrt(dt), (n_paths, n_steps)) W = np.cumsum(dW, axis=1) t = np.linspace(0, T, n_steps) S = S0 * np.exp((mu - 0.5 * sigma**2) * t + sigma * W) return S, t # Parameters S0 = 100 mu = 0.08 sigma = 0.20 T = 1.0 n_steps = 252 n_paths = 100 # Simulate S, t = simulate_gbm(S0, mu, sigma, T, n_steps, n_paths) # Plot plt.figure(figsize=(10, 6)) for i in range(min(10, n_paths)): plt.plot(t, S[i, :], alpha=0.6) plt.xlabel('Time') plt.ylabel('S_t') plt.title('Simulated GBM Paths') plt.show() # Verify properties print(f"E[S_T] = {np.mean(S[:, -1]):.4f} (expected {S0 * np.exp(mu * T):.4f})") print(f"Var[S_T] = {np.var(S[:, -1]):.4f}")
C. Verifying Ito’s Lemma:
def black_scholes_call(S, K, T, r, sigma): d1 = (np.log(S / K) + (r + 0.5 * sigma**2) * T) / (sigma * np.sqrt(T)) d2 = d1 - sigma * np.sqrt(T) from scipy.stats import norm return S * norm.cdf(d1) - K * np.exp(-r * T) * norm.cdf(d2) # Compute Delta and Gamma (derivatives of the option price) S0 = 100 K = 100 T = 1.0 r = 0.03 sigma = 0.20 eps = 0.01 V = black_scholes_call(S0, K, T, r, sigma) V_up = black_scholes_call(S0 + eps, K, T, r, sigma) V_down = black_scholes_call(S0 - eps, K, T, r, sigma) # Delta = dV/dS delta = (V_up - V_down) / (2 * eps) # Gamma = d²V/dS² gamma = (V_up - 2 * V + V_down) / (eps**2) print(f"Option Price: {V:.4f}") print(f"Delta: {delta:.4f}") print(f"Gamma: {gamma:.4f}") # Verify Ito's Lemma: dV = Delta * dS + 0.5 * Gamma * (dS)^2 dS = 0.10 dV_approx = delta * dS + 0.5 * gamma * dS**2 dV_actual = black_scholes_call(S0 + dS, K, T, r, sigma) - V print(f"dS = {dS:.2f}") print(f"Actual dV: {dV_actual:.4f}") print(f"Approx dV: {dV_approx:.4f}") print(f"Error: {dV_actual - dV_approx:.6f}")
D. The Quadratic Variation of Brownian Motion:
# Compute quadratic variation empirically W = simulate_brownian(T=1.0, n_steps=252, n_paths=1)[0] quadratic_var = np.sum(np.diff(W)**2) print(f"Quadratic Variation: {quadratic_var:.4f} (expected {T:.4f})")
9. SUMMARY FOR THE FINANCE PRACTITIONER
-
Stochastic Processes model the evolution of random variables over time. Asset prices are stochastic processes.
-
Brownian Motion is the building block of continuous-time finance. It has independent, normally distributed increments and continuous paths.
-
Quadratic Variation of Brownian Motion is deterministic (equal to t). This is captured by the rule (dW_t)² = dt.
-
Ito’s Lemma is the chain rule for stochastic calculus. It is used to derive the dynamics of functions of Ito processes.
-
Geometric Brownian Motion is the standard model for stock prices. The solution is log-normal: S_t = S_0 * exp((μ – σ²/2)t + σW_t).
-
The Black-Scholes PDE is derived using Ito’s Lemma and delta hedging. It is the foundation of option pricing.