Del 404 - Wiley Finance Series
Introduction to C++ for Financial Engineers
An Object-Oriented Approach
Inbunden, Engelska, 2006
1 399 kr
Produktinformation
- Utgivningsdatum2006-10-13
- Mått177 x 254 x 31 mm
- Vikt879 g
- FormatInbunden
- SpråkEngelska
- SerieWiley Finance Series
- Antal sidor438
- FörlagJohn Wiley & Sons Inc
- ISBN9780470015384
Tillhör följande kategorier
About the author 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 more 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 dduffy@datasim.nl.
- 0 Goals of this Book and Global Overview 10.1 What is this book? 10.2 Why has this book been written? 10.3 For whom is this book intended? 20.4 Why should I read this book? 20.5 The structure of this book 20.6 What this book does not cover 20.7 More information and support 3Part I C++ Essential Skills 51 Introduction to C++ and Quantitative Finance 71.1 Introduction and objectives 71.2 A short history of C++ 71.3 C++, a multi-paradigm language 81.4 C++ and quantitative finance: what’s the relationship? 111.5 What is software quality? 111.6 Summary and conclusions 131.7 Exercises 142 The Mechanics of C++: from Source Code to a Running Program 152.1 Introduction and objectives 152.2 The compilation process 152.3 Header files and source files 162.4 Creating classes and using their objects 192.5 Template classes and template functions 222.6 Kinds of errors 252.7 The struct concept 272.8 Useful data conversion routines 272.9 Summary and conclusions 292.10 Exercises and projects 293 C++ Fundamentals and My First Option Class 313.1 Introduction and objectives 313.2 Class == member data + member functions 323.3 The header file (function prototypes) 333.4 The class body (code file) 353.5 Using the class 383.6 Examining the class in detail 403.7 Other paradigms 413.8 Summary and conclusions 453.9 Questions, exercises and projects 454 Creating Robust Classes 494.1 Introduction and objectives 494.2 Call by reference and call by value 494.3 Constant objects everywhere 524.4 Constructors in detail 544.5 Static member data and static member functions 554.6 Function overloading 574.7 Non-member functions 584.8 Performance tips and guidelines 584.9 Summary and conclusions 604.10 Questions, exercises and projects 605 Operator Overloading in C++ 635.1 Introduction and objectives 635.2 What is operator overloading and what are the possibilities? 635.3 Why use operator overloading? The advantages 655.4 Operator overloading: the steps 685.5 Using operator overloading for simple I/O 715.6 Friend functions in general 725.7 Summary and conclusions 745.8 Exercise 74Appendix: useful data structures in C++ 756 Memory Management in C++ 796.1 Introduction and objectives 796.2 Single objects and arrays of objects on the stack 796.3 Special operators: ‘new’ and ‘delete’ 826.4 Small application: working with complex numbers 846.5 Creating an array class 866.6 Summary and conclusions 896.7 Exercises 896.8 Review questions and comments 917 Functions, Namespaces and Introduction to Inheritance 937.1 Introduction and objectives 937.2 Functions and function pointers 937.3 An introduction to namespaces in C++ 967.4 An introduction to the inheritance mechanism in C++ 997.5 Multiple inheritance 1047.6 Solution of nonlinear equations 1047.7 Nonlinear solvers in C++: design and implementation 1067.8 Applying nonlinear solvers: calculating volatility 1087.9 Summary and conclusions 1097.10 Exercises and projects 1098 Advanced Inheritance and Payoff Class Hierarchies 1138.1 Introduction and objectives 1138.2 The virtual specifier and memory deallocation 1138.3 Abstract and concrete classes 1158.4 Lightweight payoff classes 1198.5 Super lightweight payoff functions 1218.6 The dangers of inheritance: a counterexample 1238.7 Implementation inheritance and fragile base class problem 1278.8 Two-factor payoff functions and classes 1278.9 Conclusions and summary 1308.10 Exercises and projects 1309 Run-Time Behaviour in C++ 1339.1 Introduction and objectives 1339.2 An introduction to reflection and self-aware objects 1339.3 Run-time type information (RTTI) 1349.4 Casting between types 1379.5 Client-server programming and exception handling 1409.6 try, throw and catch: ingredients of the C++ exception mechanism 1419.7 C++ implementation 1419.8 Pragmatic exception mechanisms 1459.9 Conclusions and summary 1499.10 Exercises and research 14910 An Introduction to C++ Templates 15310.1 Introduction and objectives 15310.2 My first template class 15410.3 Template functions 15810.4 Consolidation: understanding templates 15910.5 Summary and conclusions 16310.6 Exercises and projects 164Part II Data Structures, Templates and Patterns 16711 Introduction to Generic Data Structures and Standard Template Library (STL) 16911.1 Introduction and objectives 16911.2 Complexity analysis 17011.3 An introduction to data structures 17211.4 Algorithms 17611.5 Navigation in data structures: iterators in STL 17711.6 STL by example: my first example 17811.7 Conclusions and summary 18311.8 Exercises and projects 18312 Creating Simpler Interfaces to STL for QF Applications 18712.1 Introduction and objectives 18712.2 Maps and dictionaries 18712.3 Applications of maps 19012.4 User-friendly sets 19112.5 Associative arrays and associative matrices 19612.6 Applications of associative data structures 19912.7 Conclusions and summary 20012.8 Exercises and projects 20013 Data Structures for Financial Engineering Applications 20313.1 Introduction and objectives 20313.2 The property pattern 20313.3 Property sets 20513.4 Property sets and data modelling for quantitative finance 21313.5 Lattice structures 21513.6 Conclusions and summary 22113.7 Exercises and projects 22114 An Introduction to Design Patterns 22314.1 Introduction and objectives 22314.2 The software lifecycle 22314.3 Documentation issues 22514.4 An Introduction to design patterns 23314.5 Are we using the wrong design? Choosing the appropriate pattern 23714.6 CADObject, a C++ library for computer graphics 23814.7 Using patterns in CADObject 24114.8 Conclusions and summary 24114.9 Exercises and projects 241Part III QF Applications 24315 Programming the Binomial Method in C++ 24515.1 Introduction and objectives 24515.2 Scoping the problem 24615.3 A short overview of the binomial method 24615.4 Software requirements for a binomial solver 24915.5 Class design and class structure 25015.6 Applying design patterns 25215.7 The builder and director classes 25515.8 The process and the steps 25815.9 Test cases and examples 25915.10 Conclusions and summary 26015.11 Exercises and questions 26016 Implementing One-Factor Black Scholes in C++ 26516.1 Introduction and objectives 26516.2 Scope and assumptions 26516.3 Assembling the C++ building blocks 26716.4 Modelling the black scholes PDE 26716.5 Finite difference schemes 27016.6 Test cases and presentation in excel 27616.7 Summary 27916.8 Exercises and projects 27917 Two-Factor Option Pricing: Basket and Other Multi-Asset Options 28317.1 Introduction and objectives 28317.2 Motivation and background 28317.3 Scoping the problem: PDEs for basket options 28517.4 Modelling basket option PDE in UML and C++ 28617.5 The finite difference method for two-factor problems 29717.6 Discrete boundary and initial conditions 29817.7 Assembling the system of equations 29917.8 Post processing and output 30117.9 Summary and conclusions 30217.10 Exercises and projects 30218 Useful C++ Classes for Numerical Analysis Applications in Finance 30518.1 Introduction and objectives 30518.2 Solving tridiagonal systems 30518.3 An introduction to interpolation 31018.4 Summary and conclusions 31319 Other Numerical Methods in Quantitative Finance 31519.1 Introduction and objectives 31519.2 The trinomial method for assets 31519.3 Lattice data structures 31819.4 Trinomial tree for the short rate 31819.5 The multidimensional binomial method 32119.6 Generic lattice structures 32219.7 Approximating exponential functions 32619.8 Summary and conclusions 32619.9 Exercises 32620 The Monte Carlo Method Theory and C++ Frameworks 327Dr. Joerg Kieritz and Daniel J. Duffy20.1 Introduction and objectives 32720.2 A short history of the Monte Carlo (MC) method 32720.3 Examples of the application of the Monte Carlo method 32720.4 The Monte Carlo method in quantitative finance 33320.5 Software architecture for the Monte Carlo method 33720.6 Examples and test cases 33820.7 Summary and conclusions 34020.8 Appendix: comparing Monte Carlo with other numerical methods 34020.9 Exercises and projects 34121 Skills Development: from White Belt to Black Belt 34521.1 Introduction and objectives 34521.2 Review of book 34521.3 Part I: C++ essential skills 34521.4 Part II: data structures, templates and patterns 34621.5 Part III: applications in quantitative finance 34721.6 Part IV: background information 34721.7 Choosing a programming paradigm 34821.8 Summary and conclusions 349Part IV Background Information 35122 Basic C Survival Guide 35322.1 Introduction and objectives 35322.2 Basic data types 35322.3 The C preprocessor 35422.4 Pointers and references 35522.5 Other useful bits and pieces 35722.6 What to avoid in c 35722.7 Test case: numerical integration in one dimension 35822.8 Conclusions and summary 35922.9 Exercises 35923 Advanced C Syntax 36323.1 Introduction and objectives 36323.2 Fixed-size and dynamic arrays 36423.3 Multi-dimensional arrays 36423.4 Introduction to structures 36523.5 Unions 36623.6 Useful C libraries 36623.7 Test case: linear regression 36723.8 Conclusions and summary 37023.9 Exercises 37024 Datasim Visualisation Package in Excel: Drivers and Mechanisms 37324.1 Introduction and objectives 37324.2 Fundamental functionality in the package 37324.3 Basic driver functionality 37324.4 Excel mechanisms 37624.5 Option values and sensitivities in excel 38024.6 Finite difference method 38424.7 Summary and conclusions 38724.8 Exercises and projects 38725 Motivating COM and Emulation in C++ 39125.1 Introduction and objectives 39125.2 A short history of COM 39125.3 An introduction to multiple inheritance (MI) 39125.4 Interfaces and multiple inheritance 39625.5 Virtual function tables 39925.6 Summary 39926 COM Fundamentals 40126.1 Introduction and objectives 40126.2 Interfaces in COM 40126.3 The IUnknown interface 40126.4 Using IUnknown 40226.5 Defining new versions of components 40626.6 Summary 406References 407Index 409