33 const ext::shared_ptr<FdmMesher>& mesher,
34 const ext::shared_ptr<HullWhite>& model,
37 x_(mesher->locations(direction)),
41 *
Array(mesher->layout()->size(), 1.0)))),
42 mapT_(direction, mesher),
50 const ext::shared_ptr<OneFactorModel::ShortRateDynamics> dynamics =
53 const Real phi = 0.5*( dynamics->shortRate(t1, 0.0)
54 + dynamics->shortRate(t2, 0.0));
64 return Array(
r.size(), 0.0);
71 return Array(
r.size(), 0.0);
80 return Array(
r.size(), 0.0);
1-D array used in linear algebra.
Size size() const override
Array apply_direction(Size direction, const Array &r) const override
Array preconditioner(const Array &r, Real s) const override
std::vector< SparseMatrix > toMatrixDecomp() const override
const TripleBandLinearOp dzMap_
FdmHullWhiteOp(const ext::shared_ptr< FdmMesher > &mesher, const ext::shared_ptr< HullWhite > &model, Size direction)
void setTime(Time t1, Time t2) override
Time is required.
Array apply_mixed(const Array &r) const override
Array solve_splitting(Size direction, const Array &r, Real s) const override
Array apply(const Array &r) const override
const ext::shared_ptr< HullWhite > model_
SparseMatrix toMatrix() const override
Array solve_splitting(const Array &r, Real a, Real b=1.0) const
void axpyb(const Array &a, const TripleBandLinearOp &x, const TripleBandLinearOp &y, const Array &b)
Array apply(const Array &r) const override
FDM operator for the Hull-White interest rate model.
memory layout of a fdm linear operator
first derivative linear operator
Real Time
continuous quantity with 1-year units
std::size_t Size
size of a container
ext::shared_ptr< YieldTermStructure > r
second derivative operator