Nektar++
|
#include <LinearisedAdvection.h>
Static Public Member Functions | |
static SolverUtils::AdvectionSharedPtr | create (std::string) |
Creates an instance of this class. |
Static Public Attributes | |
static std::string | className |
Name of class. |
Protected Member Functions | |
DNekBlkMatSharedPtr | GetFloquetBlockMatrix (FloquetMatType mattype, bool UseContCoeffs=false) const |
DNekBlkMatSharedPtr | GenFloquetBlockMatrix (FloquetMatType mattype, bool UseContCoeffs=false) const |
LinearisedAdvection () | |
virtual | ~LinearisedAdvection () |
virtual void | v_InitObject (LibUtilities::SessionReaderSharedPtr pSession, Array< OneD, MultiRegions::ExpListSharedPtr > pFields) |
Initialises the advection object. | |
virtual void | v_Advect (const int nConvectiveFields, const Array< OneD, MultiRegions::ExpListSharedPtr > &fields, const Array< OneD, Array< OneD, NekDouble > > &advVel, const Array< OneD, Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray, const NekDouble &time) |
Advects a vector field. | |
virtual void | v_SetBaseFlow (const Array< OneD, Array< OneD, NekDouble > > &inarray) |
Overrides the base flow used during linearised advection. | |
void | UpdateBase (const NekDouble m_slices, const Array< OneD, const NekDouble > &inarray, Array< OneD, NekDouble > &outarray, const NekDouble m_time, const NekDouble m_period) |
void | DFT (const string file, Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const NekDouble m_slices) |
void | ImportFldBase (std::string pInfile, Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, int slice) |
Import Base flow. |
Protected Attributes | |
LibUtilities::SessionReaderSharedPtr | m_session |
MultiRegions::ProjectionType | m_projectionType |
int | m_spacedim |
int | m_expdim |
Array< OneD, Array< OneD, NekDouble > > | m_baseflow |
Storage for base flow. | |
int | m_slices |
NekDouble | m_period |
Array< OneD, Array< OneD, NekDouble > > | m_interp |
LibUtilities::NektarFFTSharedPtr | m_FFT |
Array< OneD, NekDouble > | m_tmpIN |
Array< OneD, NekDouble > | m_tmpOUT |
bool | m_useFFTW |
bool | m_SingleMode |
flag to determine if use single mode or not | |
bool | m_HalfMode |
flag to determine if use half mode or not | |
bool | m_MultipleModes |
flag to determine if use multiple mode or not | |
bool | m_homogen_dealiasing |
MultiRegions::CoeffState | m_CoeffState |
FloquetBlockMatrixMapShPtr | m_FloquetBlockMat |
Protected Attributes inherited from Nektar::SolverUtils::Advection | |
AdvectionFluxVecCB | m_fluxVector |
Callback function to the flux vector (set when advection is in conservative form). | |
RiemannSolverSharedPtr | m_riemann |
Riemann solver for DG-type schemes. | |
int | m_spaceDim |
Storage for space dimension. Used for homogeneous extension. |
Private Types | |
enum | FloquetMatType { eForwardsCoeff, eForwardsPhys } |
enum | HomogeneousType { eHomogeneous1D, eHomogeneous2D, eHomogeneous3D, eNotHomogeneous } |
Parameter for homogeneous expansions. More... | |
typedef map< FloquetMatType, DNekBlkMatSharedPtr > | FloquetBlockMatrixMap |
A map between matrix keys and their associated block matrices. | |
typedef boost::shared_ptr < FloquetBlockMatrixMap > | FloquetBlockMatrixMapShPtr |
A shared pointer to a BlockMatrixMap. |
Private Attributes | |
bool | m_useFFT |
flag to determine if use or not the FFT for transformations | |
enum HomogeneousType | m_HomogeneousType |
NekDouble | m_LhomX |
physical length in X direction (if homogeneous) | |
NekDouble | m_LhomY |
physical length in Y direction (if homogeneous) | |
NekDouble | m_LhomZ |
physical length in Z direction (if homogeneous) | |
int | m_npointsX |
number of points in X direction (if homogeneous) | |
int | m_npointsY |
number of points in Y direction (if homogeneous) | |
int | m_npointsZ |
number of points in Z direction (if homogeneous) | |
int | m_HomoDirec |
number of homogenous directions | |
int | m_NumMode |
Mode to use in case of single mode analysis. | |
SpatialDomains::BoundaryConditionsSharedPtr | m_boundaryConditions |
Friends | |
class | MemoryManager< LinearisedAdvection > |
Additional Inherited Members | |
Public Member Functions inherited from Nektar::SolverUtils::Advection | |
SOLVER_UTILS_EXPORT void | InitObject (LibUtilities::SessionReaderSharedPtr pSession, Array< OneD, MultiRegions::ExpListSharedPtr > pFields) |
Interface function to initialise the advection object. | |
SOLVER_UTILS_EXPORT void | Advect (const int nConvectiveFields, const Array< OneD, MultiRegions::ExpListSharedPtr > &fields, const Array< OneD, Array< OneD, NekDouble > > &advVel, const Array< OneD, Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray, const NekDouble &time) |
Interface function to advect the vector field. | |
template<typename FuncPointerT , typename ObjectPointerT > | |
void | SetFluxVector (FuncPointerT func, ObjectPointerT obj) |
Set the flux vector callback function. | |
void | SetRiemannSolver (RiemannSolverSharedPtr riemann) |
Set a Riemann solver object for this advection object. | |
void | SetFluxVector (AdvectionFluxVecCB fluxVector) |
Set the flux vector callback function. | |
void | SetBaseFlow (const Array< OneD, Array< OneD, NekDouble > > &inarray) |
Set the base flow used for linearised advection objects. |
Definition at line 47 of file LinearisedAdvection.h.
|
private |
A map between matrix keys and their associated block matrices.
Definition at line 57 of file LinearisedAdvection.h.
|
private |
A shared pointer to a BlockMatrixMap.
Definition at line 59 of file LinearisedAdvection.h.
|
private |
Definition at line 49 of file LinearisedAdvection.h.
|
private |
Parameter for homogeneous expansions.
Definition at line 149 of file LinearisedAdvection.h.
|
protected |
Constructor. Creates ...
\param |
Definition at line 64 of file LinearisedAdvection.cpp.
|
protectedvirtual |
Definition at line 274 of file LinearisedAdvection.cpp.
|
inlinestatic |
Creates an instance of this class.
Definition at line 65 of file LinearisedAdvection.h.
|
protected |
Definition at line 758 of file LinearisedAdvection.cpp.
References Nektar::LibUtilities::NekFactory< tKey, tBase, >::CreateInstance(), eForwardsPhys, Nektar::eWrapper, GetFloquetBlockMatrix(), Nektar::LibUtilities::GetNektarFFTFactory(), ImportFldBase(), m_baseflow, m_FFT, m_interp, m_slices, m_tmpIN, m_tmpOUT, Vmath::Smul(), Vmath::Vcopy(), and Vmath::Zero().
Referenced by v_InitObject().
|
protected |
|
protected |
Definition at line 719 of file LinearisedAdvection.cpp.
References Nektar::StdRegions::StdExpansion::DetShapeType(), Nektar::eDIAGONAL, Nektar::LibUtilities::eFourier, Nektar::LibUtilities::eFourierEvenlySpaced, Nektar::StdRegions::eFwdTrans, Nektar::StdRegions::StdExpansion::GetStdMatrix(), m_baseflow, and m_slices.
Referenced by DFT().
|
protected |
Import Base flow.
Import field from infile and load into m_fields. This routine will also perform a BwdTrans to ensure data is in both the physical and coefficient storage.
infile | Filename to read. |
Definition at line 586 of file LinearisedAdvection.cpp.
References ASSERTL0, m_baseflow, m_HalfMode, m_interp, m_MultipleModes, m_npointsZ, m_session, m_SingleMode, Vmath::Vcopy(), and Vmath::Zero().
Referenced by DFT(), and v_InitObject().
|
protected |
Definition at line 694 of file LinearisedAdvection.cpp.
References m_baseflow, m_period, m_slices, Vmath::Svtvp(), and Vmath::Vcopy().
Referenced by v_Advect().
|
protectedvirtual |
Advects a vector field.
Implements Nektar::SolverUtils::Advection.
Definition at line 281 of file LinearisedAdvection.cpp.
References ASSERTL0, ASSERTL1, Nektar::LibUtilities::eFunctionTypeFile, m_baseflow, m_CoeffState, m_HalfMode, m_homogen_dealiasing, m_interp, m_period, m_session, m_SingleMode, m_slices, Vmath::Neg(), UpdateBase(), Vmath::Vadd(), Vmath::Vmul(), and Vmath::Vvtvp().
|
protectedvirtual |
Initialises the advection object.
This function should be overridden in derived classes to initialise the specific advection data members. However, this base class function should be called as the first statement of the overridden function to ensure the base class is correctly initialised in order.
pSession | Session information. |
pFields | Expansion lists for scalar fields. |
Reimplemented from Nektar::SolverUtils::Advection.
Definition at line 70 of file LinearisedAdvection.cpp.
References ASSERTL0, DFT(), Nektar::MultiRegions::eDiscontinuous, Nektar::LibUtilities::eFunctionTypeFile, Nektar::MultiRegions::eGalerkin, eHomogeneous1D, eHomogeneous2D, eHomogeneous3D, Nektar::MultiRegions::eLocal, eNotHomogeneous, ImportFldBase(), m_baseflow, m_boundaryConditions, m_CoeffState, m_expdim, m_HalfMode, m_HomoDirec, m_homogen_dealiasing, m_HomogeneousType, m_LhomX, m_LhomY, m_LhomZ, m_MultipleModes, m_npointsX, m_npointsY, m_npointsZ, m_period, m_projectionType, m_session, m_SingleMode, m_slices, m_spacedim, and m_useFFT.
|
protectedvirtual |
Overrides the base flow used during linearised advection.
Reimplemented from Nektar::SolverUtils::Advection.
Definition at line 552 of file LinearisedAdvection.cpp.
References ASSERTL1, m_baseflow, m_session, npts, and Vmath::Vcopy().
|
friend |
Definition at line 62 of file LinearisedAdvection.h.
|
static |
Storage for base flow.
Definition at line 79 of file LinearisedAdvection.h.
Referenced by DFT(), GetFloquetBlockMatrix(), ImportFldBase(), UpdateBase(), v_Advect(), v_InitObject(), and v_SetBaseFlow().
|
private |
Definition at line 174 of file LinearisedAdvection.h.
Referenced by v_InitObject().
|
protected |
Definition at line 99 of file LinearisedAdvection.h.
Referenced by v_Advect(), and v_InitObject().
|
protected |
Definition at line 76 of file LinearisedAdvection.h.
Referenced by v_InitObject().
|
protected |
Definition at line 88 of file LinearisedAdvection.h.
Referenced by DFT().
|
protected |
Definition at line 107 of file LinearisedAdvection.h.
|
protected |
flag to determine if use half mode or not
Definition at line 95 of file LinearisedAdvection.h.
Referenced by ImportFldBase(), v_Advect(), and v_InitObject().
|
private |
number of homogenous directions
Definition at line 170 of file LinearisedAdvection.h.
Referenced by v_InitObject().
|
protected |
Definition at line 98 of file LinearisedAdvection.h.
Referenced by v_Advect(), and v_InitObject().
|
private |
Definition at line 160 of file LinearisedAdvection.h.
Referenced by v_InitObject().
Definition at line 86 of file LinearisedAdvection.h.
Referenced by DFT(), ImportFldBase(), and v_Advect().
|
private |
physical length in X direction (if homogeneous)
Definition at line 162 of file LinearisedAdvection.h.
Referenced by v_InitObject().
|
private |
physical length in Y direction (if homogeneous)
Definition at line 163 of file LinearisedAdvection.h.
Referenced by v_InitObject().
|
private |
physical length in Z direction (if homogeneous)
Definition at line 164 of file LinearisedAdvection.h.
Referenced by v_InitObject().
|
protected |
flag to determine if use multiple mode or not
Definition at line 97 of file LinearisedAdvection.h.
Referenced by ImportFldBase(), and v_InitObject().
|
private |
number of points in X direction (if homogeneous)
Definition at line 166 of file LinearisedAdvection.h.
Referenced by v_InitObject().
|
private |
number of points in Y direction (if homogeneous)
Definition at line 167 of file LinearisedAdvection.h.
Referenced by v_InitObject().
|
private |
number of points in Z direction (if homogeneous)
Definition at line 168 of file LinearisedAdvection.h.
Referenced by ImportFldBase(), and v_InitObject().
|
private |
Mode to use in case of single mode analysis.
Definition at line 172 of file LinearisedAdvection.h.
|
protected |
Definition at line 84 of file LinearisedAdvection.h.
Referenced by UpdateBase(), v_Advect(), and v_InitObject().
|
protected |
Definition at line 74 of file LinearisedAdvection.h.
Referenced by v_InitObject().
|
protected |
Definition at line 72 of file LinearisedAdvection.h.
Referenced by ImportFldBase(), v_Advect(), v_InitObject(), and v_SetBaseFlow().
|
protected |
flag to determine if use single mode or not
Definition at line 93 of file LinearisedAdvection.h.
Referenced by ImportFldBase(), v_Advect(), and v_InitObject().
|
protected |
Definition at line 82 of file LinearisedAdvection.h.
Referenced by DFT(), GetFloquetBlockMatrix(), UpdateBase(), v_Advect(), and v_InitObject().
|
protected |
Definition at line 75 of file LinearisedAdvection.h.
Referenced by v_InitObject().
Definition at line 89 of file LinearisedAdvection.h.
Referenced by DFT().
Definition at line 90 of file LinearisedAdvection.h.
Referenced by DFT().
|
private |
flag to determine if use or not the FFT for transformations
Definition at line 158 of file LinearisedAdvection.h.
Referenced by v_InitObject().
|
protected |
Definition at line 91 of file LinearisedAdvection.h.