login
articles
forums
events
latest jobs
search
magazine area
about us

Bookshop

C++ Design Patterns and Derivatives Pricing by Mark Joshi

C++ Design Patterns and Derivatives Pricing

(Mathematics, Finance & Risk S.)
by Mark Joshi

- OUT OF PRINT -

This book is no longer available to buy.

As an alternative, consider C++ Design Patterns and Derivatives Pricing


Product code: 17705

ISBN: 0521832357, ISBN13: 9780521832359, 200 pages, hardback, published by Cambridge University Press, 1st edition, 2004
   
Description of C++ Design Patterns and Derivatives Pricing
Design patterns are the cutting-edge paradigm for programming in object-oriented languages. Here they are discussed, for the first time in a book, in the context of implementing financial models in C++.

Assuming only a basic knowledge of C++ and mathematical finance, the reader is taught how to produce well-designed, structured, re-usable code via concrete examples. Each example is treated in depth, with the whys and wherefores of the chosen method of solution critically examined.

Part of the book is devoted to designing re-usable components that are then put together to build a Monte Carlo pricer for path-dependent exotic options. Advanced topics treated include the factory pattern, the singleton pattern and the decorator pattern.

Complete ANSI/ISO-compatible C++ source code is included on a CD for the reader to study and re-use and so develop the skills needed to implement financial models with object-oriented programs and become a working financial engineer.
Contents of C++ Design Patterns and Derivatives Pricing
Preface

1. A simple Monte Carlo model
1.1 Introduction
1.2 The theory
1.3 A simple implementation of a Monte Carlo call option pricer
1.4 Critiquing the simple Monte Carlo routine
1.5 Identifying the classes
1.6 What will the classes buy us?
1.7 Why object-oriented programming?
1.8 Key points
1.9 Exercises

2. Encapsulation
2.1 Implementing the pay-off class
2.2 Privacy
2.3 Using the pay-off class
2.4 Further extensibility defects
2.5 The open-closed principle
2.6 Key points
2.7 Exercises

3. Inheritance and virtual functions
3.1 'is a'
3.2 Coding inheritance
3.3 Virtual functions
3.4 Why we must pass the inherited object by reference
3.5 Not knowing the type and virtual destruction
3.6 Adding extra pay-offs without changing files
3.7 Key points
3.8 Exercises

4. Bridging with a virtual constructor
4.1 The problem
4.2 A first solution
4.3 Virtual construction
4.4 The rule of three
4.5 The bridge
4.6 Beware of new
4.7 A parameters class
4.8 Key points
4.9 Exercises

5. Strategies, decoration and statistics
5.1 Differing outputs
5.2 Designing a statistics gatherer
5.3 Using the statistics gatherer
5.4 Templates and wrappers
5.5 A convergence table
5.6 Decoration
5.7 Key points
5.8 Exercises

6. A random numbers class
6.1 Why?
6.2 Design considerations
6.3 The base class
6.4 A linear congruential generator and the adapter pattern
6.5 Anti-thetic sampling via decoration
6.6 Using the random number generator class
6.7 Key points
6.8 Exercises

7. An exotics engine and the template pattern
7.1 Introduction
7.2 Identifying components
7.3 Communication between the components
7.4 The base classes
7.5 A Black–Scholes path generation engine
7.6 An arithmetic Asian option
7.7 Putting it all together
7.8 Key points
7.9 Exercises

8. Trees
8.1 Introduction
8.2 The design
8.3 The TreeProduct class
8.4 A tree class
8.5 Pricing on the tree
8.6 Key points
8.7 Exercises

9. Solvers, templates and implied volatilities
9.1 The problem
9.2 Function objects
9.3 Bisecting with a template
9.4 Newton–Raphson and function template arguments
9.5 Using Newton–Raphson to do implied volatilities
9.6 The pros and cons of templatization
9.7 Key points
9.8 Exercises

10. The factory
10.1 The problem
10.2 The basic idea
10.3 The singleton pattern
10.4 Coding the factory
10.5 Automatic registration
10.6 Using the factory
10.7 Key points
10.8 Exercises

11 Design patterns revisited
11.1 Introduction
11.2 Creational patterns
11.3 Structural patterns
11.4 Behavioural patterns
11.5 Why design patterns?
11.6 Key points
11.7 Further reading
11.8 Exercises

Appendix A. Black-Scholes formulas
Appendix B. Distribution functions
Appendix C. A simple array class
C.1 Choosing an array class
C.2 The header file
C.3 The source code
Appendix D. The code
D.1 Using the code
D.2 Compilers
D.3 License
Appendix E. Glossary

Bibliography
Index