2
$\begingroup$

I am reading Antoine Savine's book "Modern Computational Finance: AAD and Parallel Simulation" and exploring is code proposition at the same time.

Basically for him products (he doesn't speak about payoffs because he wants to keep it simple) have deflines and timelimes : he is exclusively in a Monte-Carlo pricing setting and the timelime of a product tells times at which market variables needed to evaluate the product and simulated in the pricing model have to be simulated, and the defline tell what has to be simulated, roughly.

He tells that his setup could be easily adjusted for making it cover pure rates products, like swaptions, but I cannot wrap my mind around it and see how. He has an equity Black-Scholes model and I would like to use it, even if it is stupid, to diffuse short rates, and price swaption like this, but I don't see how.

His general architecture is here : https://github.com/asavine/CompFinance/blob/master/mcBase.h

while concrete implementations are here :

https://github.com/asavine/CompFinance/blob/master/mcMdlBS.h (Black-Scholes Model)

https://github.com/asavine/CompFinance/blob/master/mcPrd.h (european option)

Help would be greatly appreciated.

$\endgroup$

1 Answer 1

1
$\begingroup$

I based parts of my masters thesis on a simulation engine inspired by the one presented in Antoine’s book. If you wish to you the European call and Black Scholes Class then you are essentially considering the underlying swap of the swaption as what he calls “forwards” which has a stochastic dynamic under the Black Scholes model (as opposed to any of the rates). Essentially this is “forcing” your approach onto the Classes.

Alternatively, you could extend the code in several ways. For instance by using a struct similar to the RateDef for (forward) swap rates and creating another product where you alter the payoff function to be that of an swaption.

In my thesis, we used this approach with the Vasicek model. Check out the Python Code here for the simulation and try to also navigate to the Vasicek model and Swaption product which are imported in the script:

https://github.com/KennoCapital/CenterfoldCapital/blob/main/application/experiments/vasicek/unit_tests/vasicek_mc_european_swaption.

It should perhaps also be noted that when Antoine writes “easily extended” you should keep in mind that Antoine is among some of the top quants in the world.

$\endgroup$
4
  • $\begingroup$ First, thanks for your answer. I wanted to keep it simple in my question, but what I am exactly doing is that I am trying to implement short rate models in Antoine Savine's (AS for short) framework (precisely a 2 and 3 factor Hull-White model), and to (brutally for a start, without any Jamshidian's trick) price vanilla swaptions with it. Regarding RateDef in AS code, for a short rate model, eveyrthing seems to be already here : just in his BS and Dupire model ZC's are precalculated from model parameter while in my case they'll be computed through diffusion. $\endgroup$ Commented Jul 10 at 7:13
  • $\begingroup$ You say that in you thesis you implement Vasicek's short rate model in AS framework in Python, right ? $\endgroup$ Commented Jul 10 at 7:14
  • $\begingroup$ Yeah, our code is greatly inspired by the framework of AS but written in Python. We chose to define a new “struct” for the swap rates and then create a new product for the swaption. But you can also use AS European Call option and just make your model store the sampled swaps (or swap rates) as forwards. $\endgroup$
    – Landscape
    Commented Jul 10 at 12:23
  • 1
    $\begingroup$ OK, I will have a detailed look at it before the week-end and will come back here if questions any, if that's fine with you of course. $\endgroup$ Commented Jul 10 at 12:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.