35#ifndef NEKTAR_LIBRARY_SOLVERUTILS_PYTHON_EQUATIONSYSTEM_H
36#define NEKTAR_LIBRARY_SOLVERUTILS_PYTHON_EQUATIONSYSTEM_H
57 : T(session, graph),
py::wrapper<T>()
63 if (py::override f = this->get_override(
"InitObject")(declareField))
75 return this->T::v_InitObject(declareField);
80 if (py::override f = this->get_override(
"DoInitialise"))
82 f(dumpInitialConditions);
86 T::v_DoInitialise(dumpInitialConditions);
92 this->T::v_DoInitialise(dumpInitialConditions);
97 if (py::override f = this->get_override(
"DoSolve"))
109 this->T::v_DoSolve();
113 bool dumpInitialConditions,
114 const int domain)
override
116 if (py::override f = this->get_override(
"SetInitialConditions"))
118 f(initialtime, dumpInitialConditions, domain);
122 T::v_SetInitialConditions(initialtime, dumpInitialConditions,
128 bool dumpInitialConditions,
131 this->T::v_SetInitialConditions(initialtime, dumpInitialConditions,
138 if (py::override f = this->get_override(
"EvaluateExactSolution"))
140 py::object tmpPy = f(
field, time);
142 py::extract<Array<OneD, NekDouble>>(tmpPy);
148 this->m_fields[
field]->GetNpoints());
149 T::v_EvaluateExactSolution(
field, outfield, time);
158 this->T::v_EvaluateExactSolution(
field, outfield, time);
164 if (py::override f = this->get_override(
"LinfError"))
169 return T::v_LinfError(
field);
174 return this->T::v_LinfError(
field);
179 if (py::override f = this->get_override(
"L2Error"))
184 return T::v_L2Error(
field);
189 return this->T::v_L2Error(
field);
std::shared_ptr< SessionReader > SessionReaderSharedPtr
std::shared_ptr< MeshGraph > MeshGraphSharedPtr
EquationSystem wrapper to handle virtual function calls in EquationSystem and its subclasses.
void v_DoSolve() override
Array< OneD, NekDouble > v_EvaluateExactSolution(unsigned int field, const NekDouble time)
EquationSystemWrap(LibUtilities::SessionReaderSharedPtr session, SpatialDomains::MeshGraphSharedPtr graph)
Constructor, which is identical to Filter.
NekDouble v_L2Error(unsigned int field)
Array< OneD, NekDouble > Default_v_EvaluateExactSolution(unsigned int field, const NekDouble time)
void v_DoInitialise(bool dumpInitialConditions) override
void Default_v_SetInitialConditions(NekDouble initialtime, bool dumpInitialConditions, const int domain)
NekDouble Default_v_LinfError(unsigned int field)
void v_SetInitialConditions(NekDouble initialtime, bool dumpInitialConditions, const int domain) override
NekDouble Default_v_L2Error(unsigned int field)
NekDouble v_LinfError(unsigned int field)
void v_InitObject(bool declareField) override
void Default_v_InitObject(bool declareField)
void Default_v_DoInitialise(bool dumpInitialConditions)