A Monte-Carlo simulation serves as an established algorithmic framework, offering robust capabilities in the realms of financial and quantitative analysis—particularly in the pricing of complex derivatives and in navigating intricate market dynamics. This project delves into the conjunction of Monte-Carlo simulation and an advanced computational method known as Algorithmic Adjoint Differentiation (AAD), intending to enhance the per- formance of the Monte-Carlo simulations. Initially, we examine the foun- dational principles of both Monte-Carlo simulation and AAD, explaining these concepts through practical examples. Subsequently, we conduct a risk analysis focusing on foreign exchange and interest rates, deploying four distinct simulation methodologies. We check that parallel Monte-Carlo simulation emerges as the most efficient technique. Moreover, we check that Monte-Carlo simulations incorporating AAD require significantly greater computational time and memory resources compared to their classical counterparts.
make clean
make
To run a serial Monte-Carlo simulation, use the following command:
./main
To perform a serial Monte-Carlo simulation that incorporates AAD, use the following command:
./main_mcaad
For a parallel version of the Monte-Carlo simulation, execute the following command:
./main_pthread
Before running this simulation, make sure to check the 'reset_adjoint()' function in the 'Node_v1.h' header file (lines 52-79). Use the following command to run the simulation:
./main_multiaad
Ensure to review and possibly adjust the 'reset_adjoint()' function in the 'Node_v1.h' header file (lines 52-79) before initiating the parallel Monte-Carlo simulation with AAD.
Project Link: STEPHAN-EOM/RISK_ANALYSIS
LinkedIn: Chanho Eom