Derivation of the Black-Scholes-Merton PDE › Visualizing the PDE Residual
Michael BrenndoerferNovember 26, 20251 min read
Quantitative FinanceAll chapters Part 5 of 15Stochastic Calculus and Pricing Theory
Derivation of the Black-Scholes-Merton PDE › Visualizing the PDE ResidualOne section · Sections in this chapter10 / 16 ↓
Sections in this chapter16
Reading tools Definitions & inline links
Choose your expertise level to adjust how many terms are explained. Beginners see more tooltips, experts see fewer to maintain reading flow. Hover over underlined terms for instant definitions.
Article links
Make inline references clickable
Let's create a visualization showing the PDE residual across different stock prices for both valid and invalid pricing functions.
In[16]:
CodeS_range = np.linspace(50, 150, 100)
residuals_valid = [
bs_pde_residual(
power_derivative_price, S, t_test, r_test, sigma_test, T_test
)
for S in S_range
]
residuals_invalid = [
bs_pde_residual(
invalid_pricing_function, S, t_test, r_test, sigma_test, T_test
)
for S in S_range
]Out[17]:
Visualization