Numerical MethodsFinite DifferencesBlack-Scholes PDEConvergence Analysis

Finite Difference Schemes and Convergence Analysis

Module 2 of 425 min readLevel: Hard

Setup

The Black-Scholes PDE as a Parabolic Problem

The Black-Scholes PDE for a European option price C(t,S)C(t, S) is:

Ct+12σ2S22CS2+rSCSrC=0,(t,S)[0,T)×(0,).\frac{\partial C}{\partial t} + \frac{1}{2}\sigma^2 S^2 \frac{\partial^2 C}{\partial S^2} + rS \frac{\partial C}{\partial S} - rC = 0, \qquad (t, S) \in [0, T) \times (0, \infty).

This is a parabolic PDE (heat equation type) in the variables tt and SS. It is solved backwards in time from the terminal condition C(T,S)=g(S)C(T, S) = g(S) (the payoff function).

Log-Spot Transformation

The variable coefficient σ2S2\sigma^2 S^2 in the second-order term introduces numerical difficulty. Setting x=lnSx = \ln S and reversing time τ=Tt\tau = T - t (time to expiry), the PDE becomes:

Cτ=12σ22Cx2+(r12σ2)CxrC,\frac{\partial C}{\partial \tau} = \frac{1}{2}\sigma^2 \frac{\partial^2 C}{\partial x^2} + \left(r - \frac{1}{2}\sigma^2\right)\frac{\partial C}{\partial x} - rC,

with constant coefficients. This is the canonical form used in finite difference implementations. It reduces to a heat equation modulo first-order and zero-order terms.

Grid Setup

Discretise on a uniform grid in xx and τ\tau:

  • xi=xmin+iΔxx_i = x_{\min} + i \Delta x, for i=0,1,,Mi = 0, 1, \ldots, M.
  • τj=jΔτ\tau_j = j \Delta\tau, for j=0,1,,Nj = 0, 1, \ldots, N; so τN=T\tau_N = T.

Let CijC(xi,τj)C_i^j \approx C(x_i, \tau_j). Boundary conditions:

  • At xminx_{\min} (far-left, S0S \approx 0): Cij=0C_i^j = 0 for a call.
  • At xmaxx_{\max} (far-right, SS \to \infty): Cij=exiKerτjC_i^j = e^{x_i} - K e^{-r\tau_j} for a call (forward price minus discounted strike).

Initial condition (τ=0\tau = 0): Ci0=g(exi)C_i^0 = g(e^{x_i}) (the payoff at expiry).


Explicit Scheme (FTCS)

Discretisation

Forward in time, central in space (FTCS — Forward Time, Centred Space):

Cij+1CijΔτ=σ22Ci+1j2Cij+Ci1jΔx2+(rσ22)Ci+1jCi1j2ΔxrCij.\frac{C_i^{j+1} - C_i^j}{\Delta\tau} = \frac{\sigma^2}{2} \frac{C_{i+1}^j - 2C_i^j + C_{i-1}^j}{\Delta x^2} + \left(r - \frac{\sigma^2}{2}\right)\frac{C_{i+1}^j - C_{i-1}^j}{2\Delta x} - rC_i^j.

Define λ=σ2Δτ2Δx2\lambda = \frac{\sigma^2 \Delta\tau}{2\Delta x^2}, ν=(rσ2/2)Δτ2Δx\nu = \frac{(r - \sigma^2/2)\Delta\tau}{2\Delta x}. Rearranging:

Cij+1=(λν)Ci1j+(12λrΔτ)Cij+(λ+ν)Ci+1j.C_i^{j+1} = (\lambda - \nu) C_{i-1}^j + (1 - 2\lambda - r\Delta\tau) C_i^j + (\lambda + \nu) C_{i+1}^j.

This is explicit: each new value Cij+1C_i^{j+1} is computed directly from the previous time level. No linear system to solve. Cost per time step: O(M)O(M).

Stability: Von Neumann Analysis

Assume Cij=ξjeiαxiC_i^j = \xi^j e^{i\alpha x_i} for some complex amplitude ξ\xi. Substituting into the FTCS stencil (considering only the diffusion term for clarity):

ξ=1+2λ(cos(αΔx)1).\xi = 1 + 2\lambda(\cos(\alpha\Delta x) - 1).

Stability requires ξ1|\xi| \leq 1 for all frequencies α\alpha. Since cos(αΔx)1[2,0]\cos(\alpha\Delta x) - 1 \in [-2, 0]:

ξmax=14λ1    λ12    σ2ΔτΔx21.|\xi|_{\max} = |1 - 4\lambda| \leq 1 \implies \lambda \leq \frac{1}{2} \implies \frac{\sigma^2 \Delta\tau}{\Delta x^2} \leq 1.

This is the CFL (Courant-Friedrichs-Lewy) condition for the parabolic problem. In physical variables: ΔtΔx2/σ2\Delta t \leq \Delta x^2 / \sigma^2. The time step is quadratically constrained by the spatial step — a serious limitation for fine grids.

Accuracy

Truncation error: Taylor-expanding each term shows the FTCS scheme is O(Δτ)+O(Δx2)O(\Delta\tau) + O(\Delta x^2): first-order in time, second-order in space. The overall convergence rate is O(Δτ)+O(Δx2)O(\Delta\tau) + O(\Delta x^2).


Implicit Scheme (BTCS)

Discretisation

Backward in time, central in space (BTCS):

Cij+1CijΔτ=σ22Ci+1j+12Cij+1+Ci1j+1Δx2+(rσ22)Ci+1j+1Ci1j+12ΔxrCij+1.\frac{C_i^{j+1} - C_i^j}{\Delta\tau} = \frac{\sigma^2}{2} \frac{C_{i+1}^{j+1} - 2C_i^{j+1} + C_{i-1}^{j+1}}{\Delta x^2} + \left(r - \frac{\sigma^2}{2}\right)\frac{C_{i+1}^{j+1} - C_{i-1}^{j+1}}{2\Delta x} - rC_i^{j+1}.

Rearranging into standard tridiagonal form:

(λν)Ci1j+1+(1+2λ+rΔτ)Cij+1(λ+ν)Ci+1j+1=Cij.-(\lambda - \nu) C_{i-1}^{j+1} + (1 + 2\lambda + r\Delta\tau) C_i^{j+1} - (\lambda + \nu) C_{i+1}^{j+1} = C_i^j.

This is a tridiagonal linear system of size (M1)×(M1)(M-1)\times(M-1). Solved in O(M)O(M) operations by the Thomas algorithm (forward elimination + back substitution).

Stability

Von Neumann analysis on the BTCS scheme gives:

ξ=11+2λ(1cos(αΔx)).\xi = \frac{1}{1 + 2\lambda(1 - \cos(\alpha\Delta x))}.

Since the denominator is always 1\geq 1, we have ξ1|\xi| \leq 1 for all α\alpha and all λ>0\lambda > 0. The BTCS scheme is unconditionally stable: no constraint between Δτ\Delta\tau and Δx\Delta x. Large time steps are permitted. The accuracy remains O(Δτ)+O(Δx2)O(\Delta\tau) + O(\Delta x^2).


Crank-Nicolson Scheme

Discretisation

The θ\theta-method averages the explicit and implicit discretisations with weights θ\theta and 1θ1-\theta:

Cij+1CijΔτ=θLj+1Ci+(1θ)LjCi,\frac{C_i^{j+1} - C_i^j}{\Delta\tau} = \theta \cdot \mathcal{L}^{j+1} C_i + (1-\theta) \cdot \mathcal{L}^j C_i,

where L\mathcal{L} is the finite difference operator for the spatial terms. Crank-Nicolson sets θ=1/2\theta = 1/2:

The full lesson requires Premium

The complete derivation, the C++ / Python implementation, the validation tables, the quiz, and the interview-angle notes are part of Premium. Start a Premium plan to unlock every module in this track.