Can a network learn Black-Scholes?
Teaching a model a formula we already know, to find out what it can and cannot be trusted with.
Black-Scholes is the rare thing in finance with a closed form. Give it a spot price, a strike, a volatility, a rate and a time, and it hands back the fair price of a European option. That makes it a useful test: if a neural network cannot learn a function we can already write down, it has no business pricing the ones we cannot.
The exercise is adapted from the derivative-pricing case study in Machine Learning and Data Science Blueprints for Finance. I generated ten thousand synthetic options, with moneyness drawn around one and time to expiry between zero and a year, priced each one with the closed form under a simple volatility surface that rises with time and with distance from the money, and asked a multi-layer perceptron to learn the mapping back.
- Call
- 4.77
- Put
- 3.18
- Delta (call)
- 0.584
- Gamma
- 0.0393
- Vega / vol pt
- 0.194
- Theta / day
- -0.031
Green: call value today. Dashed: what it pays at expiry. The gap between them is time value.
What the exercise is really testing
Play with the pricer above and the shape the network has to learn becomes clear. Far out of the money the price is nearly flat; near the strike it bends sharply; as expiry approaches the bend tightens into a corner. A model can fit the smooth middle well and still be wrong exactly where the risk lives.
A model that is right on average and wrong at the strike is wrong where it matters.
So the honest way to read a result like this is not the overall error but the error near the money and near expiry, and how the model’s implied Greeks compare with the real ones. That is the next step for this work: the repository trains and tunes the network with cross-validation, but it does not yet measure error by region or check the Greeks.