24#include <ql/methods/finitedifferences/meshers/fdmmesher.hpp>
25#include <ql/methods/finitedifferences/operators/fdmlinearop.hpp>
26#include <ql/methods/finitedifferences/utilities/fdmindicesonboundary.hpp>
27#include <ql/methods/finitedifferences/utilities/fdmtimedepdirichletboundary.hpp>
34 const ext::shared_ptr<FdmMesher>& mesher,
35 ext::function<
Real(
Real)> valueOnBoundary,
39 valueOnBoundary_(
std::move(valueOnBoundary)), values_(indices_.size()) {}
42 const ext::shared_ptr<FdmMesher>& mesher,
43 ext::function<
Array(
Real)> valuesOnBoundary,
47 valuesOnBoundary_(
std::move(valuesOnBoundary)), values_(indices_.size()) {}
55 QL_FAIL(
"no boundary values defined");
62 <<
") does not match hypersurface size ("
1-D array used in linear algebra.
const_iterator end() const
Size size() const
dimension of the array
const_iterator begin() const
void applyAfterSolving(array_type &) const override
BoundaryCondition< FdmLinearOp >::Side Side
void applyAfterApplying(array_type &) const override
void setTime(Time) override
FdmTimeDepDirichletBoundary(const ext::shared_ptr< FdmMesher > &mesher, ext::function< Real(Real)> valueOnBoundary, Size direction, Side side)
const ext::function< Array(Real)> valuesOnBoundary_
const std::vector< Size > indices_
const ext::function< Real(Real)> valueOnBoundary_
Real Time
continuous quantity with 1-year units
std::size_t Size
size of a container