Nektar++
|
#include <PreconCfsBRJ.h>
Static Public Member Functions | |
static PreconCfsSharedPtr | create (const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const LibUtilities::SessionReaderSharedPtr &pSession, const LibUtilities::CommSharedPtr &vComm) |
Creates an instance of this class. More... | |
Static Public Attributes | |
static std::string | className |
Name of the class. More... | |
Protected Member Functions | |
void | v_InitObject () override |
void | v_DoPreconCfs (const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const Array< OneD, NekDouble > &pInput, Array< OneD, NekDouble > &pOutput, const bool &flag) override |
void | v_BuildPreconCfs (const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const Array< OneD, const Array< OneD, NekDouble > > &intmp, const NekDouble time, const NekDouble lambda) override |
bool | v_UpdatePreconMatCheck (const Array< OneD, const NekDouble > &res, const NekDouble dtLambda) override |
virtual void | v_InitObject ()=0 |
virtual void | v_DoPreconCfs (const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const Array< OneD, NekDouble > &pInput, Array< OneD, NekDouble > &pOutput, const bool &flag)=0 |
virtual void | v_BuildPreconCfs (const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const Array< OneD, const Array< OneD, NekDouble > > &intmp, const NekDouble time, const NekDouble lambda)=0 |
virtual bool | v_UpdatePreconMatCheck (const Array< OneD, const NekDouble > &res, const NekDouble dtLambda)=0 |
Protected Attributes | |
int | m_PreconItsStep |
int | m_BRJRelaxParam |
Array< OneD, Array< OneD, SNekBlkMatSharedPtr > > | m_PreconMatVarsSingle |
unsigned int | m_max_nblocks |
unsigned int | m_max_nElmtDof |
std::vector< simd< NekSingle >, tinysimd::allocator< simd< NekSingle > > > | m_sBlkDiagMat |
std::vector< int > | m_inputIdx |
Array< OneD, SNekBlkMatSharedPtr > | m_TraceJacSingle |
TensorOfArray4D< NekSingle > | m_TraceJacArraySingle |
Array< OneD, SNekBlkMatSharedPtr > | m_TraceJacDerivSingle |
TensorOfArray4D< NekSingle > | m_TraceJacDerivArraySingle |
Array< OneD, Array< OneD, NekSingle > > | m_TraceJacDerivSignSingle |
TensorOfArray5D< NekSingle > | m_TraceIPSymJacArraySingle |
Protected Attributes inherited from Nektar::PreconCfs | |
LibUtilities::CommSharedPtr | m_Comm |
bool | m_verbose |
int | m_spacedim |
NekPreconCfsOperators | m_operator |
int | m_PreconMatFreezNumb |
int | m_PreconTimesCounter |
NekDouble | m_DtLambdaPreconMat = -1.0 |
bool | m_CalcPreconMatFlag = false |
Private Member Functions | |
void | DoNullPrecon (const Array< OneD, NekDouble > &pInput, Array< OneD, NekDouble > &pOutput, const bool &flag) |
void | PreconBlkDiag (const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const Array< OneD, NekDouble > &inarray, Array< OneD, NekDouble > &outarray) |
template<typename DataType > | |
void | MinusOffDiag2Rhs (const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, const size_t nvariables, const size_t nCoeffs, const Array< OneD, const Array< OneD, NekDouble > > &inarray, Array< OneD, Array< OneD, NekDouble > > &outarray, TensorOfArray3D< NekDouble > &wspTrace, Array< OneD, Array< OneD, DataType > > &wspTraceDataType, const TensorOfArray4D< DataType > &TraceJacArray) |
template<typename TypeNekBlkMatSharedPtr > | |
void | AllocatePreconBlkDiagCoeff (const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields, Array< OneD, Array< OneD, TypeNekBlkMatSharedPtr > > &gmtxarray, const int &nscale=1) |
void | AllocateSIMDPreconBlkMatDiag (const Array< OneD, MultiRegions::ExpListSharedPtr > &pFields) |
This function creates the matrix structure for the block diagonal operator. It organizes the way that the matrix. More... | |
void | AllocateNekBlkMatDig (SNekBlkMatSharedPtr &mat, const Array< OneD, unsigned int > nrow, const Array< OneD, unsigned int > ncol) |
Friends | |
class | MemoryManager< PreconCfsBRJ > |
Block Relaxed(weighted) Jacobi iterative (BRJ) Preconditioner for CFS
Solves a linear system using iterative methods.
Definition at line 49 of file PreconCfsBRJ.h.
Nektar::PreconCfsBRJ::PreconCfsBRJ | ( | const Array< OneD, MultiRegions::ExpListSharedPtr > & | pFields, |
const LibUtilities::SessionReaderSharedPtr & | pSession, | ||
const LibUtilities::CommSharedPtr & | vComm | ||
) |
Definition at line 53 of file PreconCfsBRJ.cpp.
References AllocatePreconBlkDiagCoeff(), AllocateSIMDPreconBlkMatDiag(), m_BRJRelaxParam, m_PreconItsStep, and m_PreconMatVarsSingle.
|
overridedefault |
|
inlineprivate |
Definition at line 236 of file PreconCfsBRJ.h.
References Nektar::MemoryManager< DataType >::AllocateSharedPtr(), and Nektar::eDIAGONAL.
Referenced by AllocatePreconBlkDiagCoeff(), and v_BuildPreconCfs().
|
private |
Definition at line 499 of file PreconCfsBRJ.cpp.
References AllocateNekBlkMatDig().
Referenced by PreconCfsBRJ().
|
inlineprivate |
This function creates the matrix structure for the block diagonal operator. It organizes the way that the matrix.
by SIMD instructions. The degrees of freedom of each element are reorganized, so they are placed in the correct location to perfom SIMD instructions.
Definition at line 138 of file PreconCfsBRJ.h.
References ASSERTL1, m_inputIdx, m_max_nblocks, m_max_nElmtDof, and m_sBlkDiagMat.
Referenced by PreconCfsBRJ().
|
inlinestatic |
Creates an instance of this class.
Definition at line 55 of file PreconCfsBRJ.h.
References Nektar::MemoryManager< DataType >::AllocateSharedPtr(), and CellMLToNektar.cellml_metadata::p.
|
private |
Definition at line 288 of file PreconCfsBRJ.cpp.
References Vmath::Vcopy().
Referenced by v_DoPreconCfs().
|
private |
Definition at line 377 of file PreconCfsBRJ.cpp.
References Nektar::LibUtilities::Timer::AccumulateRegion(), Vmath::Fill(), Nektar::PreconCfs::m_DtLambdaPreconMat, Nektar::PreconCfs::m_spacedim, CellMLToNektar.cellml_metadata::p, Nektar::LibUtilities::Timer::Start(), Nektar::LibUtilities::Timer::Stop(), and Vmath::Zero().
Referenced by v_DoPreconCfs().
|
private |
Definition at line 298 of file PreconCfsBRJ.cpp.
References m_inputIdx, m_max_nblocks, m_max_nElmtDof, and m_sBlkDiagMat.
Referenced by v_DoPreconCfs().
|
overrideprotectedvirtual |
Copy array into column major blocks of vector width
Implements Nektar::PreconCfs.
Definition at line 188 of file PreconCfsBRJ.cpp.
References AllocateNekBlkMatDig(), Nektar::NekPreconCfsOperators::DoCalcPreconMatBRJCoeff(), Nektar::PreconCfs::m_CalcPreconMatFlag, Nektar::PreconCfs::m_Comm, Nektar::PreconCfs::m_DtLambdaPreconMat, Nektar::PreconCfs::m_operator, m_PreconItsStep, m_PreconMatVarsSingle, Nektar::PreconCfs::m_PreconTimesCounter, m_sBlkDiagMat, m_TraceIPSymJacArraySingle, m_TraceJacArraySingle, m_TraceJacDerivArraySingle, m_TraceJacDerivSignSingle, m_TraceJacDerivSingle, m_TraceJacSingle, and Nektar::PreconCfs::m_verbose.
|
overrideprotectedvirtual |
Implements Nektar::PreconCfs.
Definition at line 85 of file PreconCfsBRJ.cpp.
References Nektar::LibUtilities::Timer::AccumulateRegion(), ASSERTL0, DoNullPrecon(), m_BRJRelaxParam, m_PreconItsStep, Nektar::PreconCfs::m_spacedim, m_TraceJacArraySingle, MinusOffDiag2Rhs(), PreconBlkDiag(), Vmath::Smul(), Nektar::LibUtilities::Timer::Start(), Nektar::LibUtilities::Timer::Stop(), and Vmath::Svtvp().
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
Implements Nektar::PreconCfs.
Definition at line 275 of file PreconCfsBRJ.cpp.
References Nektar::PreconCfs::m_CalcPreconMatFlag, Nektar::PreconCfs::m_DtLambdaPreconMat, Nektar::PreconCfs::m_PreconMatFreezNumb, and Nektar::PreconCfs::m_PreconTimesCounter.
|
friend |
Definition at line 1 of file PreconCfsBRJ.h.
|
static |
Name of the class.
Definition at line 66 of file PreconCfsBRJ.h.
|
protected |
Definition at line 75 of file PreconCfsBRJ.h.
Referenced by PreconCfsBRJ(), and v_DoPreconCfs().
|
protected |
Definition at line 83 of file PreconCfsBRJ.h.
Referenced by AllocateSIMDPreconBlkMatDiag(), and PreconBlkDiag().
|
protected |
Definition at line 79 of file PreconCfsBRJ.h.
Referenced by AllocateSIMDPreconBlkMatDiag(), and PreconBlkDiag().
|
protected |
Definition at line 80 of file PreconCfsBRJ.h.
Referenced by AllocateSIMDPreconBlkMatDiag(), and PreconBlkDiag().
|
protected |
Definition at line 74 of file PreconCfsBRJ.h.
Referenced by PreconCfsBRJ(), v_BuildPreconCfs(), and v_DoPreconCfs().
|
protected |
Definition at line 77 of file PreconCfsBRJ.h.
Referenced by PreconCfsBRJ(), and v_BuildPreconCfs().
|
protected |
Definition at line 82 of file PreconCfsBRJ.h.
Referenced by AllocateSIMDPreconBlkMatDiag(), PreconBlkDiag(), and v_BuildPreconCfs().
|
protected |
Definition at line 90 of file PreconCfsBRJ.h.
Referenced by v_BuildPreconCfs().
|
protected |
Definition at line 86 of file PreconCfsBRJ.h.
Referenced by v_BuildPreconCfs(), and v_DoPreconCfs().
|
protected |
Definition at line 88 of file PreconCfsBRJ.h.
Referenced by v_BuildPreconCfs().
Definition at line 89 of file PreconCfsBRJ.h.
Referenced by v_BuildPreconCfs().
|
protected |
Definition at line 87 of file PreconCfsBRJ.h.
Referenced by v_BuildPreconCfs().
|
protected |
Definition at line 85 of file PreconCfsBRJ.h.
Referenced by v_BuildPreconCfs().