Calculus for Traders
Calculus describes how quantities change. Learn derivatives, integrals and Taylor approximations, and how they underpin Greeks, duration and optimisation.
Calculus is the mathematics of change. In trading, many key ideas are calculus in disguise: an option's delta is a derivative of its price with respect to the underlying, a bond's duration is a derivative of its price with respect to yield, and portfolio optimisation finds where derivatives equal zero. You do not need to solve equations by hand to trade, but understanding what derivatives mean makes Greeks, duration, convexity and many models much clearer.
Derivatives: rates of change#
A derivative measures how fast one quantity changes when another changes slightly.
dy/dx ≈ change in y / change in x, for a very small change in x
| Financial measure | Derivative of | With respect to | Lesson |
|---|---|---|---|
| Delta | Option price | Underlying price | Delta |
| Gamma | Delta (second derivative of price) | Underlying price | Gamma |
| Theta | Option price | Time | Theta |
| Vega | Option price | Volatility | Vega |
| Rho | Option price | Interest rate | Rho |
| Duration | Bond price (scaled) | Yield | Duration |
| Convexity | Duration (second derivative) | Yield | Convexity |
Taylor approximations#
Calculus lets traders approximate how a value changes for a small move using derivatives:
change in value ≈ first derivative × Δx + ½ × second derivative × (Δx)²
Numerical derivatives#
When there is no formula, traders estimate derivatives by "bumping" inputs:
derivative ≈ [f(x + h) - f(x - h)] / (2h)
Risk systems compute Greeks and DV01 this way for complex positions. See DV01 and Managing Portfolio Greeks.
Integrals: adding up continuous changes#
Integration is the reverse of differentiation: it adds up small pieces. In finance:
- Expected values of continuous variables are integrals over probability densities. See Random Variables.
- Option prices are discounted integrals of payoffs over the probability distribution of the underlying. See Black-Scholes Model.
- Continuous compounding comes from integrating a constant growth rate. See Compounding and Geometric vs Arithmetic Returns.
Optimisation#
At a maximum or minimum, the derivative equals zero. This idea is used to:
- Find the Kelly bet size that maximises expected log growth. See Kelly Criterion.
- Fit models by maximising likelihood or minimising errors. See Maximum Likelihood.
- Optimise portfolios subject to constraints. See Optimization.
Stochastic calculus#
Prices move randomly, so ordinary calculus is not enough for continuous time models. Stochastic calculus, including Itô's lemma, handles functions of random processes and is the foundation of the Black Scholes model and modern derivatives pricing. It explains, for example, why the drift of log prices is μ minus σ²/2. See Lognormal Distribution.
Gradients and machine learning#
Many machine learning models are trained by gradient descent: the model's error is treated as a function of its parameters, the derivative (gradient) shows which direction reduces the error, and the parameters move a small step in that direction, repeatedly. Neural networks used in trading research rely on this. See Neural Networks and Deep Learning.
Alongside calculus, the other mathematical toolkit quants rely on is Linear Algebra for Traders, used for portfolios, factor models and regression.
Frequently asked questions#
Why do traders need calculus?#
Because key measures such as option Greeks, bond duration and convexity are derivatives, and optimisation relies on calculus.
What is a derivative in mathematics?#
The rate at which one quantity changes when another changes by a very small amount.
What is stochastic calculus?#
Calculus for random processes, used to model prices in continuous time and to derive option pricing models like Black Scholes.
Next, learn how to find the best parameters in Optimization.
3 quick questions on this lesson. Get them all right to finish it.
Turn on JavaScript to take the quiz.
Mentioned in
- Linear Algebra for TradersMath and Statistics