Introduction to C++ for Financial Engineers. An Object–Oriented Approach. The Wiley Finance Series

  • ID: 2209272
  • Book
  • 438 Pages
  • John Wiley and Sons Ltd
1 of 4
The object–oriented programming language C++ is the de facto standard for developing real–life applications for Quantitative Finance and Financial Engineering. This language was designed by Dr. Bjarne Stroustup in the early 1990’s and it has become one of the most popular and robust languages for many important areas such as medical systems, computer graphics, telecommunications and in application areas where performance, accuracy and interoperability issues play a key role. The general expectation is that its importance will grow in the coming years.

C++ has also become the de facto standard for quant development and analysis. Knowledge of C++ is mandatory for many openings and job positions in Quantitative Finance. This book is the first book that discusses many of the issues that you need to know in order to be able to design and implement real–world applications. We focus on a number of critical topics:

  • Learning the essential syntax of C++ (′getting the fundamentals right′)
  • Designing and implementing generic data structures using STL
  • Numerous applications (lattices, finite difference, Monte Carlo, etc)
  • Libraries, design patterns (GOF, POSA) and reusable software frameworks
  • Introduction to COM and C++ to Excel interoperability

Each chapter deals with one major topic. Furthermore, each chapter builds only on the results of the chapters preceding it, so that we keep the amount of forward referencing to a minimum. We discuss all the syntax that is discussed in the IT books and we apply it to QF applications. This book is self–contained and we advise its use in combination with the well–known standard reference work by Dr. Stroustrup.

Last, but not least, each chapter concludes with exercises and projects to test what you learned in that chapter. The exercises are based on the tactic: ′get it working, then get it right, then get it optimised′. Furthermore, these exercises will also hopefully prepare you for your job interviews!

Included with the book is a companion website with all source code, including working code for lattice, finite difference and Monte Carlo methods for one–factor and two–factor pricing models as well as an easy–to–use C++ visualization package to help you examine the output from these numerical methods.

Note: Product cover images may vary from those shown
2 of 4

0 Goals of this Book and Global Overview 1


1 Introduction to C++ and Quantitative Finance 7

2 The Mechanics of C++: from Source Code to a Running Program 15

3 C++ Fundamentals and My First Option Class 31

4 Creating Robust Classes 49

5 Operator Overloading in C++ 63

6 Memory Management in C++ 79

7 Functions, Namespaces and Introduction to Inheritance 93

8 Advanced Inheritance and Payoff Class Hierarchies 113

9 Run–Time Behaviour in C++ 133

10 An Introduction to C++ Templates 153


11 Introduction to Generic Data Structures and Standard Template Library (STL) 169

12 Creating Simpler Interfaces to STL for QF Applications 187

13 Data Structures for Financial Engineering Applications 203

14 An Introduction to Design Patterns 223


15 Programming the Binomial Method in C++ 245

16 Implementing One–Factor Black Scholes in C++ 265

17 Two–Factor Option Pricing: Basket and Other Multi–Asset Options 283

18 Useful C++ Classes for Numerical Analysis Applications in Finance 305

19 Other Numerical Methods in Quantitative Finance 315

20 The Monte Carlo Method Theory and C++ Frameworks 327Dr. Joerg Kieritz and Daniel J. Duffy

21 Skills Development: from White Belt to Black Belt 345

21.1 Introduction and objectives 345


22 Basic C Survival Guide 353

23 Advanced C Syntax 363

24 Datasim Visualisation Package in Excel: Drivers and Mechanisms 373

25 Motivating COM and Emulation in C++ 391

26 COM Fundamentals 401

References 407

Index 409

Note: Product cover images may vary from those shown
3 of 4


4 of 4
DANIEL J. DUFFY has been involved in software development projects using C++ and object–oriented design techniques since 1988. He organized the first C++ course in the Netherlands in 1989 and has worked on a variety of C++ projects in areas such as computer graphics, optical technology, process control and quantitative finance systems. In 1993 he worked on an early version of a large object–oriented system for derivatives’ pricing and hedging models. He is designer/trainer and has trained mote than 2000 C++ developers in recent years.

A companion book to the current one is "Financial instrument pricing using C++" (Wiley 2004). Since 1996 he has written seven books on object–oriented design and programming. Daniel Duffy has a Phd in Numerical Analysis from Trinity College Dublin. He lives in the Netherlands with his wife Ilona and son Brendan.

He can be contacted at
Note: Product cover images may vary from those shown
5 of 4
Note: Product cover images may vary from those shown