44 "RHS forcing for coupled LNS stability solver");
48 const std::weak_ptr<SolverUtils::EquationSystem> &pEquation)
55 [[maybe_unused]]
const unsigned int &pNumForcingFields,
56 [[maybe_unused]]
const TiXmlElement *pForce)
66 size_t npts = fields[0]->GetTotPoints();
68 ASSERTL1(fields.size() == outarray.size(),
69 "Fields and outarray are of different size");
72 for (
size_t i = 0; i < fields.size(); i++)
74 Vmath::Vadd(npts, fields[i]->GetPhys(), 1, outarray[i], 1, outarray[i],
#define ASSERTL1(condition, msg)
Assert Level 1 – Debugging which is used whether in FULLDEBUG or DEBUG compilation mode....
void v_InitObject(const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const unsigned int &pNumForcingFields, const TiXmlElement *pForce) override
void v_Apply(const Array< OneD, MultiRegions::ExpListSharedPtr > &fields, const Array< OneD, Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray, const NekDouble &time) override
static SolverUtils::ForcingSharedPtr create(const LibUtilities::SessionReaderSharedPtr &pSession, const std::weak_ptr< SolverUtils::EquationSystem > &pEquation, const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const unsigned int &pNumForcingFields, const TiXmlElement *pForce)
Creates an instance of this class.
static std::string className
Name of the class.
ForcingStabilityCoupledLNS(const LibUtilities::SessionReaderSharedPtr &pSession, const std::weak_ptr< SolverUtils::EquationSystem > &pEquation)
tKey RegisterCreatorFunction(tKey idKey, CreatorFunction classCreator, std::string pDesc="")
Register a class with the factory.
Defines a forcing term to be explicitly applied.
std::shared_ptr< SessionReader > SessionReaderSharedPtr
ForcingFactory & GetForcingFactory()
Declaration of the forcing factory singleton.
void Vadd(int n, const T *x, const int incx, const T *y, const int incy, T *z, const int incz)
Add vector z = x+y.