24#ifndef quantext_average_off_peak_power_helper_hpp
25#define quantext_average_off_peak_power_helper_hpp
30#include <ql/termstructures/bootstraphelper.hpp>
34typedef QuantLib::BootstrapHelper<PriceTermStructure>
PriceHelper;
55 const QuantLib::ext::shared_ptr<CommodityIndex>& index,
56 const QuantLib::Date& start,
57 const QuantLib::Date& end,
58 const ext::shared_ptr<FutureExpiryCalculator>& calc,
59 const QuantLib::ext::shared_ptr<CommodityIndex>& peakIndex,
60 const QuantLib::Calendar& peakCalendar,
61 QuantLib::Natural peakHoursPerDay = 16);
76 const QuantLib::ext::shared_ptr<CommodityIndex>& index,
77 const QuantLib::Date& start,
78 const QuantLib::Date& end,
79 const ext::shared_ptr<FutureExpiryCalculator>& calc,
80 const QuantLib::ext::shared_ptr<CommodityIndex>& peakIndex,
81 const QuantLib::Calendar& peakCalendar,
82 QuantLib::Natural peakHoursPerDay = 16);
93 void accept(QuantLib::AcyclicVisitor& v)
override;
100 void init(
const QuantLib::ext::shared_ptr<CommodityIndex>& index,
101 const QuantLib::Date& start,
102 const QuantLib::Date& end,
103 const ext::shared_ptr<FutureExpiryCalculator>& calc,
104 const QuantLib::ext::shared_ptr<CommodityIndex>& peakIndex,
105 const QuantLib::Calendar& peakCalendar,
106 QuantLib::Natural peakHoursPerDay);
110 QuantLib::ext::shared_ptr<CommodityIndexedAverageCashFlow>
holidayPeak_;
AverageOffPeakPowerHelper(const QuantLib::Handle< QuantLib::Quote > &price, const QuantLib::ext::shared_ptr< CommodityIndex > &index, const QuantLib::Date &start, const QuantLib::Date &end, const ext::shared_ptr< FutureExpiryCalculator > &calc, const QuantLib::ext::shared_ptr< CommodityIndex > &peakIndex, const QuantLib::Calendar &peakCalendar, QuantLib::Natural peakHoursPerDay=16)
AverageOffPeakPowerHelper(QuantLib::Real price, const QuantLib::ext::shared_ptr< CommodityIndex > &index, const QuantLib::Date &start, const QuantLib::Date &end, const ext::shared_ptr< FutureExpiryCalculator > &calc, const QuantLib::ext::shared_ptr< CommodityIndex > &peakIndex, const QuantLib::Calendar &peakCalendar, QuantLib::Natural peakHoursPerDay=16)
QuantLib::Natural nonPeakDays_
void accept(QuantLib::AcyclicVisitor &v) override
void deepUpdate() override
QuantLib::ext::shared_ptr< CommodityIndexedAverageCashFlow > holidayOffPeak_
QuantLib::Real impliedQuote() const override
QuantLib::ext::shared_ptr< CommodityIndexedAverageCashFlow > businessOffPeak_
void init(const QuantLib::ext::shared_ptr< CommodityIndex > &index, const QuantLib::Date &start, const QuantLib::Date &end, const ext::shared_ptr< FutureExpiryCalculator > &calc, const QuantLib::ext::shared_ptr< CommodityIndex > &peakIndex, const QuantLib::Calendar &peakCalendar, QuantLib::Natural peakHoursPerDay)
Shared initialisation method.
QuantLib::RelinkableHandle< PriceTermStructure > termStructureHandle_
QuantLib::Natural peakDays_
QuantLib::ext::shared_ptr< CommodityIndexedAverageCashFlow > holidayPeak_
void setTermStructure(PriceTermStructure *ts) override
Cash flow dependent on the average commodity spot price or future's settlement price over a period....
Base class for classes that perform date calculations for future contracts.
QuantLib::BootstrapHelper< PriceTermStructure > PriceHelper
Term structure of prices.