Nektar++
|
#include <LinearisedAdvection.h>
Static Public Member Functions | |
static AdvectionTermSharedPtr | create (const LibUtilities::SessionReaderSharedPtr &pSession, const SpatialDomains::MeshGraphSharedPtr &pGraph) |
Creates an instance of this class. |
Static Public Attributes | |
static std::string | className = GetAdvectionTermFactory().RegisterCreatorFunction("Linearised", LinearisedAdvection::create) |
Name of class. |
Protected Member Functions | |
DNekBlkMatSharedPtr | GetFloquetBlockMatrix (FloquetMatType mattype, bool UseContCoeffs=false) const |
DNekBlkMatSharedPtr | GenFloquetBlockMatrix (FloquetMatType mattype, bool UseContCoeffs=false) const |
LinearisedAdvection (const LibUtilities::SessionReaderSharedPtr &pSession, const SpatialDomains::MeshGraphSharedPtr &pGraph) | |
virtual | ~LinearisedAdvection () |
virtual void | v_InitObject () |
void | SetUpBaseFields (SpatialDomains::MeshGraphSharedPtr &mesh) |
void | UpdateBase (const NekDouble m_slices, Array< OneD, const NekDouble > &inarray, Array< OneD, NekDouble > &outarray, const NekDouble m_time, const NekDouble m_period) |
void | DFT (const string file, const NekDouble m_slices) |
void | ImportFldBase (std::string pInfile, SpatialDomains::MeshGraphSharedPtr pGraph, int cnt) |
Import Base flow. | |
void | ImportFldBase (std::string pInfile, SpatialDomains::MeshGraphSharedPtr pGraph) |
void | WriteFldBase (std::string &outname) |
Write field data to the given filename. | |
void | WriteFldBase (std::string &outname, MultiRegions::ExpListSharedPtr &field, Array< OneD, Array< OneD, NekDouble > > &fieldcoeffs, Array< OneD, std::string > &variables) |
Write input fields to the given filename. | |
Protected Member Functions inherited from Nektar::AdvectionTerm | |
AdvectionTerm (const LibUtilities::SessionReaderSharedPtr &pSession, const SpatialDomains::MeshGraphSharedPtr &pGraph) | |
Constructor. | |
virtual void | v_ComputeAdvectionTerm (Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const Array< OneD, Array< OneD, NekDouble > > &pV, const Array< OneD, const NekDouble > &pU, Array< OneD, NekDouble > &pOutarray, int pVelocityComponent, NekDouble m_time, Array< OneD, NekDouble > &pWk) |
Protected Attributes | |
Array< OneD, MultiRegions::ExpListSharedPtr > | m_base |
Array< OneD, MultiRegions::ExpListSharedPtr > | m_base_aux |
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 | |
FloquetBlockMatrixMapShPtr | m_FloquetBlockMat |
Protected Attributes inherited from Nektar::AdvectionTerm | |
LibUtilities::SessionReaderSharedPtr | m_session |
std::string | m_sessionName |
Name of the session. | |
SpatialDomains::MeshGraphSharedPtr | m_graph |
Pointer to mesh graph. | |
bool | m_homogen_dealiasing |
flag to determine if use Fourier dealising or not | |
bool | m_specHP_dealiasing |
flag to determine if use Spectral/hp element dealising or not | |
bool | m_SingleMode |
Flag to determine if use single mode or not. | |
bool | m_HalfMode |
Flag to determine if use half mode or not. | |
MultiRegions::CoeffState | m_CoeffState |
enum MultiRegions::ProjectionType | m_projectionType |
Type of projection, i.e. Galerkin or DG. | |
int | m_spacedim |
Spatial dimension (> expansion dim) | |
int | m_expdim |
Dimension of the expansion. | |
int | nvariables |
Number of variables. | |
int | m_nConvectiveFields |
int | m_slices |
Number of fields to be convected;. | |
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 |
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 Member Functions | |
virtual void | v_ComputeAdvectionTerm (Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const Array< OneD, Array< OneD, NekDouble > > &pV, const Array< OneD, const NekDouble > &pU, Array< OneD, NekDouble > &pOutarray, int pVelocityComponent, NekDouble m_time, Array< OneD, NekDouble > &pWk) |
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::AdvectionTerm | |
virtual | ~AdvectionTerm () |
Destructor. | |
void | InitObject () |
void | DoAdvection (Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const int nConvectiveFields, const Array< OneD, int > &vel_loc, const Array< OneD, const Array< OneD, NekDouble > > &pInarray, Array< OneD, Array< OneD, NekDouble > > &pOutarray, NekDouble m_time, Array< OneD, NekDouble > &pWk=NullNekDouble1DArray) |
Compute advection term. | |
void | DoAdvection (Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const Array< OneD, const Array< OneD, NekDouble > > &Velocity, const Array< OneD, const Array< OneD, NekDouble > > &pInarray, Array< OneD, Array< OneD, NekDouble > > &pOutarray, NekDouble m_time, Array< OneD, NekDouble > &pWk=NullNekDouble1DArray) |
bool | GetSpecHPDealiasing (void) |
void | SetSpecHPDealiasing (bool value) |
Definition at line 53 of file LinearisedAdvection.h.
|
private |
A map between matrix keys and their associated block matrices.
Definition at line 63 of file LinearisedAdvection.h.
|
private |
A shared pointer to a BlockMatrixMap.
Definition at line 65 of file LinearisedAdvection.h.
|
private |
Definition at line 55 of file LinearisedAdvection.h.
|
private |
Parameter for homogeneous expansions.
Definition at line 150 of file LinearisedAdvection.h.
|
protected |
|
protectedvirtual |
Definition at line 251 of file LinearisedAdvection.cpp.
|
inlinestatic |
Creates an instance of this class.
Definition at line 71 of file LinearisedAdvection.h.
Definition at line 946 of file LinearisedAdvection.cpp.
References Nektar::LibUtilities::NekFactory< tKey, tBase, >::CreateInstance(), eForwardsPhys, Nektar::eWrapper, GetFloquetBlockMatrix(), Nektar::LibUtilities::GetNektarFFTFactory(), ImportFldBase(), m_base, m_FFT, Nektar::AdvectionTerm::m_graph, m_interp, m_period, Nektar::AdvectionTerm::m_session, m_slices, m_tmpIN, m_tmpOUT, Vmath::Smul(), Vmath::Vcopy(), and Vmath::Zero().
Referenced by v_InitObject().
|
protected |
|
protected |
Definition at line 907 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_base, 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 461 of file LinearisedAdvection.cpp.
References ASSERTL1, m_base, m_HalfMode, m_interp, m_MultipleModes, Nektar::AdvectionTerm::m_nConvectiveFields, m_npointsZ, Nektar::AdvectionTerm::m_session, m_SingleMode, Vmath::Vcopy(), and Vmath::Zero().
Referenced by DFT(), and v_InitObject().
|
protected |
|
protected |
Definition at line 255 of file LinearisedAdvection.cpp.
References ASSERTL0, Nektar::LibUtilities::eFourier, Nektar::LibUtilities::eFourierEvenlySpaced, Nektar::LibUtilities::eFourierHalfModeRe, Nektar::LibUtilities::eFourierSingleModeSpaced, Nektar::MultiRegions::eGalerkin, eHomogeneous1D, eHomogeneous2D, eHomogeneous3D, m_base, Nektar::AdvectionTerm::m_expdim, Nektar::AdvectionTerm::m_graph, m_HalfMode, Nektar::AdvectionTerm::m_homogen_dealiasing, m_HomogeneousType, m_LhomY, m_LhomZ, m_npointsY, m_npointsZ, Nektar::AdvectionTerm::m_projectionType, Nektar::AdvectionTerm::m_session, m_SingleMode, m_useFFT, and Nektar::AdvectionTerm::nvariables.
Referenced by v_InitObject().
|
protected |
Definition at line 837 of file LinearisedAdvection.cpp.
References m_base, m_period, m_slices, Vmath::Svtvp(), and Vmath::Vcopy().
Referenced by v_ComputeAdvectionTerm().
|
privatevirtual |
Definition at line 574 of file LinearisedAdvection.cpp.
References ASSERTL0, Nektar::LibUtilities::eFunctionTypeFile, m_base, Nektar::AdvectionTerm::m_CoeffState, m_HalfMode, Nektar::AdvectionTerm::m_homogen_dealiasing, m_interp, Nektar::AdvectionTerm::m_nConvectiveFields, m_period, Nektar::AdvectionTerm::m_session, m_slices, UpdateBase(), Vmath::Vadd(), Vmath::Vmul(), and Vmath::Vvtvp().
|
protectedvirtual |
Reimplemented from Nektar::AdvectionTerm.
Definition at line 69 of file LinearisedAdvection.cpp.
References ASSERTL0, DFT(), Nektar::MultiRegions::eDiscontinuous, Nektar::LibUtilities::eFunctionTypeFile, Nektar::MultiRegions::eGalerkin, eHomogeneous1D, eHomogeneous2D, eHomogeneous3D, eNotHomogeneous, ImportFldBase(), m_base, m_boundaryConditions, Nektar::AdvectionTerm::m_graph, m_HalfMode, m_HomoDirec, m_HomogeneousType, m_LhomX, m_LhomY, m_LhomZ, m_MultipleModes, m_npointsX, m_npointsY, m_npointsZ, Nektar::AdvectionTerm::m_projectionType, Nektar::AdvectionTerm::m_session, m_SingleMode, m_slices, Nektar::AdvectionTerm::m_spacedim, m_useFFT, and SetUpBaseFields().
|
protected |
Write field data to the given filename.
Definition at line 863 of file LinearisedAdvection.cpp.
References m_base, and m_boundaryConditions.
|
protected |
Write input fields to the given filename.
Writes the field data to a file with the given filename.
outname | Filename to write to. |
field | ExpList on which data is based |
fieldcoeffs | An array of array of expansion coefficients |
variables | An array of variable names |
Definition at line 886 of file LinearisedAdvection.cpp.
References Nektar::LibUtilities::Write().
|
friend |
Definition at line 68 of file LinearisedAdvection.h.
|
static |
Name of class.
Definition at line 79 of file LinearisedAdvection.h.
|
protected |
Definition at line 83 of file LinearisedAdvection.h.
Referenced by DFT(), GetFloquetBlockMatrix(), ImportFldBase(), SetUpBaseFields(), UpdateBase(), v_ComputeAdvectionTerm(), v_InitObject(), and WriteFldBase().
|
protected |
Definition at line 86 of file LinearisedAdvection.h.
|
private |
Definition at line 174 of file LinearisedAdvection.h.
Referenced by v_InitObject(), and WriteFldBase().
|
protected |
Definition at line 94 of file LinearisedAdvection.h.
Referenced by DFT().
|
protected |
Definition at line 104 of file LinearisedAdvection.h.
|
protected |
flag to determine if use half mode or not
Definition at line 99 of file LinearisedAdvection.h.
Referenced by ImportFldBase(), SetUpBaseFields(), v_ComputeAdvectionTerm(), and v_InitObject().
|
private |
number of homogenous directions
Definition at line 170 of file LinearisedAdvection.h.
Referenced by v_InitObject().
|
private |
Definition at line 160 of file LinearisedAdvection.h.
Referenced by SetUpBaseFields(), and v_InitObject().
Definition at line 92 of file LinearisedAdvection.h.
Referenced by DFT(), ImportFldBase(), and v_ComputeAdvectionTerm().
|
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 SetUpBaseFields(), and v_InitObject().
|
private |
physical length in Z direction (if homogeneous)
Definition at line 164 of file LinearisedAdvection.h.
Referenced by SetUpBaseFields(), and v_InitObject().
|
protected |
flag to determine if use multiple mode or not
Definition at line 100 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 SetUpBaseFields(), and v_InitObject().
|
private |
number of points in Z direction (if homogeneous)
Definition at line 168 of file LinearisedAdvection.h.
Referenced by ImportFldBase(), SetUpBaseFields(), 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 90 of file LinearisedAdvection.h.
Referenced by DFT(), UpdateBase(), and v_ComputeAdvectionTerm().
|
protected |
flag to determine if use single mode or not
Definition at line 98 of file LinearisedAdvection.h.
Referenced by ImportFldBase(), SetUpBaseFields(), and v_InitObject().
|
protected |
Definition at line 88 of file LinearisedAdvection.h.
Referenced by DFT(), GetFloquetBlockMatrix(), UpdateBase(), v_ComputeAdvectionTerm(), and v_InitObject().
Definition at line 95 of file LinearisedAdvection.h.
Referenced by DFT().
Definition at line 96 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 SetUpBaseFields(), and v_InitObject().
|
protected |
Definition at line 97 of file LinearisedAdvection.h.