American-transaction costs 1.0.0.0 American option pricer under proportional transaction costs

- Main Page
- Namespaces
- Classes
- Files
- Directories

- File List
- File Members

integrablebridge.h
Go to the documentation of this file.

    00001 /*
    00002     American option pricer under proportional transaction costs
    00003     Copyright (C) 2011 Alet Roux alet.roux@york.ac.uk
    00004
    00005     This program is free software: you can redistribute it and/or modify
    00006     it under the terms of the GNU General Public License as published by
    00007     the Free Software Foundation, either version 3 of the License, or
    00008     (at your option) any later version.
    00009
    00010     This program is distributed in the hope that it will be useful,
    00011     but WITHOUT ANY WARRANTY; without even the implied warranty of
    00012     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    00013     GNU General Public License for more details.
    00014
    00015     You should have received a copy of the GNU General Public License
    00016     along with this program.  If not, see <http://www.gnu.org/licenses/>.
    00017
    00018 */
    00019
    00020 #ifndef PARAMETERINTEGRABLEBRIDGE_H
    00021 #define PARAMETERINTEGRABLEBRIDGE_H
    00022
    00023 #include "integrable.h"
    00024
    00026
    00030 class ParameterIntegrableBridge
    00031 {
    00032 public:
    00033         ParameterIntegrableBridge (const ParameterIntegrableBridge& original)
    00034         {
    00035                 _parameter = original._parameter->clone();
    00036         }
    00037
    00038         ParameterIntegrableBridge (const ParameterIntegrable& parameter)
    00039         {
    00040                 _parameter = parameter.clone();
    00041         }
    00042
    00044         ParameterIntegrableBridge& operator= (const ParameterIntegrableBridge& original)
    00045         {
    00046                 if (this != &original)
    00047                 {
    00048                         delete _parameter;
    00049                         _parameter = original._parameter->clone();
    00050                 }
    00051
    00052                 return *this;
    00053         }
    00054
    00056         coefficient integral (const coefficient time1, const coefficient time2) const
    00057         {
    00058                 return _parameter->integral (time1, time2);
    00059         }
    00060
    00062         coefficient integral_square (const coefficient time1, const coefficient time2) const
    00063         {
    00064                 return _parameter->integral_square (time1, time2);
    00065         }
    00066
    00068         coefficient root_integral_square (const coefficient time1, const coefficient time2) const
    00069         {
    00070                 return _parameter->root_integral_square (time1, time2);
    00071         }
    00072
    00074         inline coefficient operator() (const coefficient time) const
    00075         {
    00076                 return _parameter->operator() (time);
    00077         }
    00078
    00079         ~ParameterIntegrableBridge()
    00080         {
    00081                 delete _parameter;
    00082         }
    00083
    00084 private:
    00085         ParameterIntegrable* _parameter;
    00086 };
    00087
    00088 #endif // PARAMETERINTEGRABLEBRIDGE_H

All Classes Namespaces Files Functions Variables Typedefs Defines