Nektar++
|
Filter for one-dimensional energy spectrum. More...
#include <FilterEnergy1D.h>
Static Public Member Functions | |
static FilterSharedPtr | create (const LibUtilities::SessionReaderSharedPtr &pSession, const std::shared_ptr< EquationSystem > &pEquation, const std::map< std::string, std::string > &pParams) |
Creates an instance of this class. More... | |
Static Public Attributes | |
static std::string | className |
Name of the class. More... | |
Protected Member Functions | |
void | v_Initialise (const Array< OneD, const MultiRegions::ExpListSharedPtr > &pField, const NekDouble &time) override |
Initialize filter. More... | |
void | v_Update (const Array< OneD, const MultiRegions::ExpListSharedPtr > &pField, const NekDouble &time) override |
Update filter output with the current timestep's orthogonal coefficients. More... | |
void | v_Finalise (const Array< OneD, const MultiRegions::ExpListSharedPtr > &pField, const NekDouble &time) override |
bool | v_IsTimeDependent () override |
![]() | |
virtual void | v_Initialise (const Array< OneD, const MultiRegions::ExpListSharedPtr > &pFields, const NekDouble &time)=0 |
virtual void | v_Update (const Array< OneD, const MultiRegions::ExpListSharedPtr > &pFields, const NekDouble &time)=0 |
virtual void | v_Finalise (const Array< OneD, const MultiRegions::ExpListSharedPtr > &pFields, const NekDouble &time)=0 |
virtual bool | v_IsTimeDependent ()=0 |
virtual SOLVER_UTILS_EXPORT std::string | v_SetupOutput (const std::string ext, const ParamMap &pParams) |
virtual SOLVER_UTILS_EXPORT std::string | v_SetupOutput (const std::string ext, const std::string inname) |
Private Attributes | |
std::ofstream | m_out |
Output file. More... | |
unsigned int | m_outputFrequency |
Output frequency. More... | |
unsigned int | m_index |
Current index counter. More... | |
Friends | |
class | MemoryManager< FilterEnergy1D > |
Additional Inherited Members | |
![]() | |
typedef std::map< std::string, std::string > | ParamMap |
![]() | |
LibUtilities::SessionReaderSharedPtr | m_session |
const std::weak_ptr< EquationSystem > | m_equ |
bool | m_updateOnInitialise = true |
Filter for one-dimensional energy spectrum.
This filter transforms the coefficients of each element into an orthogonal basis and outputs these coefficients at each timestep. It can be used to, for example, detect high-order oscillations in the solution field.
Definition at line 50 of file FilterEnergy1D.h.
Nektar::SolverUtils::FilterEnergy1D::FilterEnergy1D | ( | const LibUtilities::SessionReaderSharedPtr & | pSession, |
const std::shared_ptr< EquationSystem > & | pEquation, | ||
const ParamMap & | pParams | ||
) |
Set up filter with output file and frequency parameters.
pSession | Current session. |
pParams | Map of parameters defined in XML file. |
Definition at line 52 of file FilterEnergy1D.cpp.
References ASSERTL0, Nektar::LibUtilities::Equation::Evaluate(), m_out, m_outputFrequency, Nektar::SolverUtils::Filter::m_session, and Nektar::SolverUtils::Filter::SetupOutput().
|
override |
|
inlinestatic |
Creates an instance of this class.
Definition at line 56 of file FilterEnergy1D.h.
References Nektar::MemoryManager< DataType >::AllocateSharedPtr(), and CellMLToNektar.cellml_metadata::p.
|
overrideprotectedvirtual |
Implements Nektar::SolverUtils::Filter.
Definition at line 156 of file FilterEnergy1D.cpp.
References m_out.
|
overrideprotectedvirtual |
Initialize filter.
Implements Nektar::SolverUtils::Filter.
Definition at line 90 of file FilterEnergy1D.cpp.
References ASSERTL0.
|
overrideprotectedvirtual |
Implements Nektar::SolverUtils::Filter.
Definition at line 164 of file FilterEnergy1D.cpp.
|
overrideprotectedvirtual |
Update filter output with the current timestep's orthogonal coefficients.
Implements Nektar::SolverUtils::Filter.
Definition at line 102 of file FilterEnergy1D.cpp.
References Nektar::LibUtilities::eOrtho_A, Nektar::LibUtilities::InterpCoeff1D(), m_index, m_out, and m_outputFrequency.
|
friend |
Definition at line 1 of file FilterEnergy1D.h.
|
static |
Name of the class.
Definition at line 67 of file FilterEnergy1D.h.
|
private |
|
private |
Output file.
Definition at line 89 of file FilterEnergy1D.h.
Referenced by FilterEnergy1D(), v_Finalise(), and v_Update().
|
private |
Output frequency.
Definition at line 91 of file FilterEnergy1D.h.
Referenced by FilterEnergy1D(), and v_Update().