Update of /cvsroot/quantlibaddin/QuantLibAddin/qlo
In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv1302/qlo
Modified Files:
swaptionvolstructure.cpp swaptionvolstructure.hpp
Log Message:
Index: swaptionvolstructure.cpp
===================================================================
RCS file: /cvsroot/quantlibaddin/QuantLibAddin/qlo/swaptionvolstructure.cpp,v
retrieving revision 1.44
retrieving revision 1.45
diff -C2 -d -r1.44 -r1.45
*** swaptionvolstructure.cpp 24 Nov 2006 10:11:43 -0000 1.44
--- swaptionvolstructure.cpp 24 Nov 2006 14:17:36 -0000 1.45
***************
*** 46,51 ****
SwaptionVolatilityMatrix::SwaptionVolatilityMatrix(
const QuantLib::Calendar& calendar,
! const std::vector<QuantLib::Period>& expiries,
! const std::vector<QuantLib::Period>& tenors,
const std::vector<std::vector<QuantLib::Handle<QuantLib::Quote> > >& vols,
const QuantLib::DayCounter& dayCounter,
--- 46,51 ----
SwaptionVolatilityMatrix::SwaptionVolatilityMatrix(
const QuantLib::Calendar& calendar,
! const std::vector<QuantLib::Period>& optionTenors,
! const std::vector<QuantLib::Period>& swapTenors,
const std::vector<std::vector<QuantLib::Handle<QuantLib::Quote> > >& vols,
const QuantLib::DayCounter& dayCounter,
***************
*** 53,58 ****
libraryObject_ = boost::shared_ptr<QuantLib::Extrapolator>(new
QuantLib::SwaptionVolatilityMatrix(calendar,
! expiries,
! tenors,
vols,
dayCounter,
--- 53,58 ----
libraryObject_ = boost::shared_ptr<QuantLib::Extrapolator>(new
QuantLib::SwaptionVolatilityMatrix(calendar,
! optionTenors,
! swapTenors,
vols,
dayCounter,
***************
*** 74,79 ****
SwaptionVolatilityCubeByLinear::SwaptionVolatilityCubeByLinear(
const QuantLib::Handle<QuantLib::SwaptionVolatilityStructure>& atmVol,
! const std::vector<QuantLib::Period>& expiries,
! const std::vector<QuantLib::Period>& lengths,
const std::vector<QuantLib::Spread>& strikeSpreads,
const std::vector<std::vector<QuantLib::Handle<QuantLib::Quote> > >& volSpreads,
--- 74,79 ----
SwaptionVolatilityCubeByLinear::SwaptionVolatilityCubeByLinear(
const QuantLib::Handle<QuantLib::SwaptionVolatilityStructure>& atmVol,
! const std::vector<QuantLib::Period>& optionTenors,
! const std::vector<QuantLib::Period>& swapTenors,
const std::vector<QuantLib::Spread>& strikeSpreads,
const std::vector<std::vector<QuantLib::Handle<QuantLib::Quote> > >& volSpreads,
***************
*** 84,89 ****
libraryObject_ = boost::shared_ptr<QuantLib::Extrapolator>(new
QuantLib::SwaptionVolatilityCubeByLinear(atmVol,
! expiries,
! lengths,
strikeSpreads,
volSpreads,
--- 84,89 ----
libraryObject_ = boost::shared_ptr<QuantLib::Extrapolator>(new
QuantLib::SwaptionVolatilityCubeByLinear(atmVol,
! optionTenors,
! swapTenors,
strikeSpreads,
volSpreads,
***************
*** 94,99 ****
SwaptionVolatilityCubeBySabr::SwaptionVolatilityCubeBySabr(
const QuantLib::Handle<QuantLib::SwaptionVolatilityStructure>& atmVol,
! const std::vector<QuantLib::Period>& expiries,
! const std::vector<QuantLib::Period>& lengths,
const std::vector<QuantLib::Spread>& strikeSpreads,
const std::vector<std::vector<QuantLib::Handle<QuantLib::Quote> > >& volSpreads,
--- 94,99 ----
SwaptionVolatilityCubeBySabr::SwaptionVolatilityCubeBySabr(
const QuantLib::Handle<QuantLib::SwaptionVolatilityStructure>& atmVol,
! const std::vector<QuantLib::Period>& optionTenors,
! const std::vector<QuantLib::Period>& swapTenors,
const std::vector<QuantLib::Spread>& strikeSpreads,
const std::vector<std::vector<QuantLib::Handle<QuantLib::Quote> > >& volSpreads,
***************
*** 107,112 ****
libraryObject_ = boost::shared_ptr<QuantLib::Extrapolator>(new
QuantLib::SwaptionVolatilityCubeBySabr(atmVol,
! expiries,
! lengths,
strikeSpreads,
volSpreads,
--- 107,112 ----
libraryObject_ = boost::shared_ptr<QuantLib::Extrapolator>(new
QuantLib::SwaptionVolatilityCubeBySabr(atmVol,
! optionTenors,
! swapTenors,
strikeSpreads,
volSpreads,
***************
*** 235,251 ****
}
- SmileSectionByCube::SmileSectionByCube(
- const boost::shared_ptr<QuantLib::SwaptionVolatilityCube>& cube,
- const QuantLib::Period& expiry,
- const QuantLib::Period& length){
- libraryObject_ = cube->smileSection(expiry,length);
- }
-
- SmileSectionByCube::SmileSectionByCube(
- const boost::shared_ptr<QuantLib::SwaptionVolatilityCube>& cube,
- const QuantLib::Date& expiry,
- const QuantLib::Period& length){
- libraryObject_ = cube->smileSection(expiry,length);
- }
InterpolatedSmileSection::InterpolatedSmileSection(
--- 235,238 ----
***************
*** 275,277 ****
--- 262,279 ----
}
+
+ SmileSectionByCube::SmileSectionByCube(
+ const boost::shared_ptr<QuantLib::SwaptionVolatilityCube>& cube,
+ const QuantLib::Period& optionTenor,
+ const QuantLib::Period& swapTenors){
+ libraryObject_ = cube->smileSection(optionTenor,swapTenors);
+ }
+
+ SmileSectionByCube::SmileSectionByCube(
+ const boost::shared_ptr<QuantLib::SwaptionVolatilityCube>& cube,
+ const QuantLib::Date& optionDate,
+ const QuantLib::Period& swapTenors){
+ libraryObject_ = cube->smileSection(optionDate,swapTenors);
+ }
+
}
Index: swaptionvolstructure.hpp
===================================================================
RCS file: /cvsroot/quantlibaddin/QuantLibAddin/qlo/swaptionvolstructure.hpp,v
retrieving revision 1.39
retrieving revision 1.40
diff -C2 -d -r1.39 -r1.40
*** swaptionvolstructure.hpp 24 Nov 2006 10:11:43 -0000 1.39
--- swaptionvolstructure.hpp 24 Nov 2006 14:17:36 -0000 1.40
***************
*** 43,47 ****
public:
SwaptionVolatilityMatrix(const QuantLib::Calendar& calendar,
! const std::vector<QuantLib::Period>& expiries,
const std::vector<QuantLib::Period>& tenors,
const std::vector<std::vector<QuantLib::Handle<QuantLib::Quote> > >& vols,
--- 43,47 ----
public:
SwaptionVolatilityMatrix(const QuantLib::Calendar& calendar,
! const std::vector<QuantLib::Period>& optionTenors,
const std::vector<QuantLib::Period>& tenors,
const std::vector<std::vector<QuantLib::Handle<QuantLib::Quote> > >& vols,
***************
*** 60,65 ****
SwaptionVolatilityCubeByLinear(
const QuantLib::Handle<QuantLib::SwaptionVolatilityStructure>& atmVol,
! const std::vector<QuantLib::Period>& expiries,
! const std::vector<QuantLib::Period>& lengths,
const std::vector<QuantLib::Spread>& strikeSpreads,
const std::vector<std::vector<QuantLib::Handle<QuantLib::Quote> > >& volSpreads,
--- 60,65 ----
SwaptionVolatilityCubeByLinear(
const QuantLib::Handle<QuantLib::SwaptionVolatilityStructure>& atmVol,
! const std::vector<QuantLib::Period>& optionTenors,
! const std::vector<QuantLib::Period>& swapTenors,
const std::vector<QuantLib::Spread>& strikeSpreads,
const std::vector<std::vector<QuantLib::Handle<QuantLib::Quote> > >& volSpreads,
***************
*** 75,80 ****
SwaptionVolatilityCubeBySabr(
const QuantLib::Handle<QuantLib::SwaptionVolatilityStructure>& atmVol,
! const std::vector<QuantLib::Period>& expiries,
! const std::vector<QuantLib::Period>& lengths,
const std::vector<QuantLib::Spread>& strikeSpreads,
const std::vector<std::vector<QuantLib::Handle<QuantLib::Quote> > >& volSpreads,
--- 75,80 ----
SwaptionVolatilityCubeBySabr(
const QuantLib::Handle<QuantLib::SwaptionVolatilityStructure>& atmVol,
! const std::vector<QuantLib::Period>& optionTenors,
! const std::vector<QuantLib::Period>& swapTenors,
const std::vector<QuantLib::Spread>& strikeSpreads,
const std::vector<std::vector<QuantLib::Handle<QuantLib::Quote> > >& volSpreads,
***************
*** 105,113 ****
SmileSectionByCube(
const boost::shared_ptr<QuantLib::SwaptionVolatilityCube>& cube,
! const QuantLib::Period& expiry,
const QuantLib::Period& length);
SmileSectionByCube(
const boost::shared_ptr<QuantLib::SwaptionVolatilityCube>& cube,
! const QuantLib::Date& expiry,
const QuantLib::Period& length);
};
--- 105,113 ----
SmileSectionByCube(
const boost::shared_ptr<QuantLib::SwaptionVolatilityCube>& cube,
! const QuantLib::Period& optionTenors,
const QuantLib::Period& length);
SmileSectionByCube(
const boost::shared_ptr<QuantLib::SwaptionVolatilityCube>& cube,
! const QuantLib::Date& optionDate,
const QuantLib::Period& length);
};
|