37 const ext::shared_ptr<FdmInnerValueCalculator>& gasPrice,
38 const ext::shared_ptr<FdmInnerValueCalculator>& sparkSpreadPrice)
40 nStates(params.tMinUp, params.tMinDown, nStarts),
41 mesh, gasPrice, sparkSpreadPrice),
50 const Real startUpCost
57 const Size j = i % sss;
60 retVal[i] = std::max(state[i+1], state[
tMinUp_+i+1]);
63 retVal[i] = std::max(state[i+
tMinUp_+1],
64 std::max(state[i], state[i+
tMinUp_]));
70 retVal[i] = state[i+1];
73 retVal[i] = std::max(state[i],
78 retVal[i] = std::max(state[i],
79 std::max(state[i+1-2*sss], state[i+1-2*sss+
tMinUp_])
92 return (2*tMinUp+tMinDown)*((nStarts ==
Null<Size>())? 1 : nStarts+1);
96 return *std::max_element(states.
begin(), states.
end());
1-D array used in linear algebra.
1-D array used in linear algebra.
const_iterator end() const
Size size() const
dimension of the array
const_iterator begin() const
Array changeState(Real gasPrice, const Array &state, Time t) const override
Real maxValue(const Array &states) const override
FdmVPPStartLimitStepCondition(const FdmVPPStepConditionParams ¶ms, Size nStarts, const FdmVPPStepConditionMesher &mesh, const ext::shared_ptr< FdmInnerValueCalculator > &gasPrice, const ext::shared_ptr< FdmInnerValueCalculator > &sparkSpreadPrice)
const Real fuelCostAddon_
const Real startUpFixCost_
template class providing a null value for a given type.
#define QL_REQUIRE(condition, message)
throw an error if the given pre-condition is not verified
layer of abstraction to calculate the inner value
iterator for a linear fdm operator
memory layout of a fdm linear operator
VPP incl start limit step condition for FD models.
Real Time
continuous quantity with 1-year units
std::size_t Size
size of a container