Diagnosing Calendar Arbitrage in QuantLib Black Variance Surfaces
Summary
The document describes a problem generating Monte Carlo paths from a QuantLib Black variance surface. The surface is interpolated and extrapolated from market data, with checks for decreasing total variance across maturities and butterfly irregularities, yet the local volatility calculation still reports a negative value. An Andreasen–Huge surface adapter works, but the questioner wants a custom construction with more control.
The reply points to calendar arbitrage in the calibrated model as the likely reason for QuantLib's rejection. This suggests that checking sampled Black volatilities or total variance alone may not capture the condition that the local volatility calculation tests. The note offers no detailed diagnosis, reproducible example, or custom smoothing procedure, so it identifies a likely issue rather than establishing which surface feature causes the error in this case.
Key ideas
- QuantLib may reject a surface for calendar arbitrage when deriving local volatility.
- A surface that prices with several engines may still fail when used for Monte Carlo path generation.
- Checking total variance at queried points may not expose every issue relevant to local volatility smoothness.
Tags
Full text
# Quantlib vol surface issue 'the black vol surface is not smooth enough' # Quantlib vol surface issue 'the black vol surface is not smooth enough' I create a vol surface from the market and do smoothing(interpolation and extrapolation), and explicitly correct for any total variance decreasing on a given strike as we increase maturity. I create a ql.BlackVarianceSurface surface with my grid and am able to price using most quantlib engines. When I use my surface to create Monte Carlo paths using ql.BlackScholesMertonProcess and ql.GaussianMultiPathGenerator,however, I invariably get an error of the type: "RuntimeError: negative local vol^2 at strike 2167.82 and time 0.138889; the black vol surface is not smooth enough". If I create an Andreasen Huge surface using ql.AndreasenHugeVolatilityAdapter, then I get a local vol surface I can use for Monte Carlo paths. However, I want to have more control about how the surface is created so I am trying to create my own surface from the data, rather than running AH. If I poll the Ql vol surface using vol_process.blackVol(expiry, strike), I don’t find any decreasing total variance violations, so I believe something else is leading QL to say the surface is not smooth enough. Does anyone know why QL may find the surface unsatisfactory, and anything I can do/ check for/ or change? Note I check the QL surface for both falling variance and for butterfly variations (along expiries). thank you very much for the help ## Answer by Chiu-Tzu-Hsuan (score 1) https://quant.stackexchange.com/a/75109 This is because QuantLib checks if the model you calibrated has "calendar arbitrage". https://github.com/lballabio/QuantLib/issues/1124
Shown in full with attribution under the source's licence. Licence: CC BY-SA 4.0 (Stack Exchange)
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.