The C++ programming language was originally designed and implemented by a Danish computer scientist, Bjarne Stroustrup. He wanted to distribute the services of the UNIX kernel across multiprocessors and local area networks.

C++ software libraries are extensively used in graphics and game programming, to numerically solve equations in mathematics, to perform simulations in engineering and Physics.

Within the framework of mathematical finance, C++ libraries are, for example, applied to –

  • Matrix factorizations.
  • Solving partial differential equations(PDEs) using numerical methods.
  • Monte Carlo simulation.

We work with data structures relevant to quantitative finance and mathematics.

Creating an executable from C++ source code

C++ is a compiled language. Building an executable or library from C++ code is a multi-stage process (i) Pre-processing (ii) Compile(build) (iii) Link.

I. Preprocessing: When parsing the source code, the C++ compiler looks for each identifier being used in the current translation unit, is previously declared or not in the current unit. For example, calling a helper function such as sqrt(), float(), ceil() in a C++ program, the compiler wants to ensure you haven’t made spelling mistakes or passed the wrong number of arguments. So, it insists it see a declaration of the function sqrt() (or any other types and functions) before they are used. This really just allows the compiler to do a better job of validating the code.

The file cmath in the Standard C++ library declares mathematical functions. #include <cmath> is a pre-processor directive. It is an instruction to the pre-processor add the declarations in cmath to your C++ program. When the compiler encounters a call to sqrt(), it validates the call against the function header. 

The preprocessor 



int main()
    std::cout << "Hello World\n";
    return 0;