Nektar++
Public Member Functions | Protected Attributes | Friends | List of all members
Nektar::MultiRegions::GlobalLinSysKey Class Reference

Describe a linear system. More...

#include <GlobalLinSysKey.h>

Inheritance diagram for Nektar::MultiRegions::GlobalLinSysKey:
Inheritance graph
[legend]
Collaboration diagram for Nektar::MultiRegions::GlobalLinSysKey:
Collaboration graph
[legend]

Public Member Functions

 GlobalLinSysKey (const StdRegions::MatrixType matrixType, const AssemblyMapSharedPtr &locToGloMap=NullAssemblyMapSharedPtr, const StdRegions::ConstFactorMap &factors=StdRegions::NullConstFactorMap, const StdRegions::VarCoeffMap &varCoeffs=StdRegions::NullVarCoeffMap)
 
 GlobalLinSysKey (const GlobalLinSysKey &key)
 Copy constructor. More...
 
virtual ~GlobalLinSysKey ()
 Destructor. More...
 
GlobalSysSolnType GetGlobalSysSolnType () const
 Return the associated solution type. More...
 
- Public Member Functions inherited from Nektar::MultiRegions::GlobalMatrixKey
 GlobalMatrixKey (const StdRegions::MatrixType matrixType, const AssemblyMapSharedPtr &locToGloMap=NullAssemblyMapSharedPtr, const StdRegions::ConstFactorMap &factors=StdRegions::NullConstFactorMap, const StdRegions::VarCoeffMap &varCoeffs=StdRegions::NullVarCoeffMap)
 
 GlobalMatrixKey (const GlobalMatrixKey &key, const LibUtilities::ShapeType shapeType)
 Copy constructor with change in expansion type. More...
 
 GlobalMatrixKey (const GlobalMatrixKey &key)
 Copy constructor. More...
 
virtual ~GlobalMatrixKey ()
 Destructor. More...
 
StdRegions::MatrixType GetMatrixType () const
 Return the matrix type. More...
 
LibUtilities::ShapeType GetShapeType () const
 Return the expansion type associated with key. More...
 
bool LocToGloMapIsDefined () const
 Returns true if a local to global map is defined. More...
 
int GetNConstFactors () const
 Returns the number of constants defined for this matrix. More...
 
NekDouble GetConstFactor (const StdRegions::ConstFactorType &factor) const
 Returns the requested constant. More...
 
const StdRegions::ConstFactorMapGetConstFactors () const
 Returns all the constants. More...
 
int GetNVarCoeffs () const
 
const Array< OneD, const NekDouble > & GetVarCoeff (const StdRegions::VarCoeffType &coeff) const
 
const StdRegions::VarCoeffMapGetVarCoeffs () const
 

Protected Attributes

GlobalSysSolnType m_solnType
 Store the solution type associated with the linear system. This may be none, full matrix, static condensation or multi-level static condensation. More...
 
- Protected Attributes inherited from Nektar::MultiRegions::GlobalMatrixKey
StdRegions::MatrixType m_matrixType
 Stores the matrix type based on the enum StdRegions::MatrixType. More...
 
LibUtilities::ShapeType m_shapeType
 Stores the expansion/shape type that the matrix is to be based on. More...
 
StdRegions::ConstFactorMap m_constFactors
 
StdRegions::VarCoeffMap m_varCoeffs
 
AssemblyMapSharedPtr m_locToGloMap
 Pointer to the local to global mapping. More...
 

Friends

bool operator< (const GlobalLinSysKey &lhs, const GlobalLinSysKey &rhs)
 Less-than operator for GlobalLinSysKey comparison. More...
 

Additional Inherited Members

- Protected Member Functions inherited from Nektar::MultiRegions::GlobalMatrixKey
 GlobalMatrixKey ()
 Default constructor. More...
 

Detailed Description

Describe a linear system.

This class represents a global linear system and is in essence a wrapper around a global matrix key, augmenting it with a specific solution type from GlobalSysSolnType. Each constructor accepts a MatrixType, describing the matrix to be constructed, a AssemblyMap, defining the mapping from the local elemental expansions to a global system, and a GlobalSysSolnType, defining the type of solution (e.g. full matrix, static condenstation). Some constructors include additional parameters for customising the global operator matrix.

Definition at line 47 of file GlobalLinSysKey.h.

Constructor & Destructor Documentation

Nektar::MultiRegions::GlobalLinSysKey::GlobalLinSysKey ( const StdRegions::MatrixType  matrixType,
const AssemblyMapSharedPtr locToGloMap = NullAssemblyMapSharedPtr,
const StdRegions::ConstFactorMap factors = StdRegions::NullConstFactorMap,
const StdRegions::VarCoeffMap varCoeffs = StdRegions::NullVarCoeffMap 
)

Definition at line 57 of file GlobalLinSysKey.cpp.

60  :
61  GlobalMatrixKey(matrixType, locToGloMap, factors, varCoeffs),
62  m_solnType(locToGloMap->GetGlobalSysSolnType())
63  {
64 
65  }
GlobalSysSolnType m_solnType
Store the solution type associated with the linear system. This may be none, full matrix...
GlobalMatrixKey()
Default constructor.
Nektar::MultiRegions::GlobalLinSysKey::GlobalLinSysKey ( const GlobalLinSysKey key)

Copy constructor.

Parameters
keyExisting key to duplicate.

Definition at line 71 of file GlobalLinSysKey.cpp.

71  :
72  GlobalMatrixKey(key),
73  m_solnType(key.m_solnType)
74  {
75  }
GlobalSysSolnType m_solnType
Store the solution type associated with the linear system. This may be none, full matrix...
GlobalMatrixKey()
Default constructor.
Nektar::MultiRegions::GlobalLinSysKey::~GlobalLinSysKey ( )
virtual

Destructor.

Definition at line 81 of file GlobalLinSysKey.cpp.

82  {
83  }

Member Function Documentation

GlobalSysSolnType Nektar::MultiRegions::GlobalLinSysKey::GetGlobalSysSolnType ( ) const
inline

Friends And Related Function Documentation

bool operator< ( const GlobalLinSysKey lhs,
const GlobalLinSysKey rhs 
)
friend

Less-than operator for GlobalLinSysKey comparison.

Compares two GlobalLinSysKeys by comparing their solution types and matrix keys.

Parameters
lhsFirst operand.
rhsSecond operand.
Returns
true if the first operand is considered less than the second operand.

Definition at line 94 of file GlobalLinSysKey.cpp.

95  {
96  if(lhs.m_solnType < rhs.m_solnType)
97  {
98  return true;
99  }
100 
101  if(lhs.m_solnType > rhs.m_solnType)
102  {
103  return false;
104  }
105 
106  return (*dynamic_cast<const GlobalMatrixKey*>(&lhs)
107  < *dynamic_cast<const GlobalMatrixKey*>(&rhs));
108  }
StandardMatrixTag & lhs

Member Data Documentation

GlobalSysSolnType Nektar::MultiRegions::GlobalLinSysKey::m_solnType
protected

Store the solution type associated with the linear system. This may be none, full matrix, static condensation or multi-level static condensation.

Definition at line 71 of file GlobalLinSysKey.h.

Referenced by GetGlobalSysSolnType(), and Nektar::MultiRegions::operator<().