Documentation a537f1bdf2
Loading...
Searching...
No Matches
CPrimalGridFEM Class Referencefinal

Class to define primal grid element for the FEM solver. More...

#include <CPrimalGridFEM.hpp>

Inheritance diagram for CPrimalGridFEM:
[legend]

Public Member Functions

 CPrimalGridFEM (const unsigned long *dataElem, unsigned long &offsetSolDOFs)
 Constructor using data to initialize the element.
 
unsigned short GetnNodesFace (unsigned short val_face) const override
 Get the number of nodes that composes a face of an element.
 
unsigned short GetFaces (unsigned short val_face, unsigned short val_index) const override
 Get the face index of an element.
 
unsigned short GetNeighbor_Nodes (unsigned short val_node, unsigned short val_index) const override
 Get the local index of the neighbors to a node (given the local index).
 
unsigned short GetnNodes (void) const override
 Get the number of nodes of an element.
 
unsigned short GetnFaces (void) const override
 Get the number of faces of an element.
 
unsigned short GetnNeighbor_Nodes (unsigned short val_node) const override
 Get the number of neighbors nodes of a node.
 
void Change_Orientation (void) override
 Change the orientation of an element.
 
unsigned long GetGlobalElemID (void) const override
 Make available the global ID of this element.
 
unsigned long GetGlobalOffsetDOFsSol (void) const override
 Make available the global offset of the solution DOFs of this element.
 
unsigned short GetMaxNodesFace (void) const override
 Get the Maximum number of nodes of a face of an element.
 
unsigned short GetVTK_Type (void) const override
 Get the type of the element using VTK nomenclature.
 
unsigned short GetNPolyGrid (void) const override
 Get the polynomial degree of the grid for this element.
 
unsigned short GetNPolySol (void) const override
 Get the polynomial degree of the solution for this element.
 
unsigned short GetNDOFsGrid (void) const override
 Function to make available the number of DOFs of the grid in the element.
 
unsigned short GetNDOFsSol (void) const override
 Function to make available the number of DOFs of the solution in the element.
 
void GetCornerPointsAllFaces (unsigned short &numFaces, unsigned short nPointsPerFace[], unsigned long faceConn[6][4]) const override
 Get all the corner points of all the faces of this element. It must be made sure that the numbering of the faces is identical to the numbering used for the standard elements.
 
bool GetJacobianConsideredConstant (void) const override
 Function to get whether or not the Jacobian is considered constant.
 
void SetColor (unsigned long val_color) override
 Set the color of the element.
 
unsigned long GetColor (void) const override
 Get the color of the element for the partitioning. return - The color of the element in the partitioning.
 
void SetJacobianConsideredConstant (bool val_JacobianConsideredConstant) override
 Function to set the value of JacobianConsideredConstant.
 
void AddOffsetGlobalDOFs (const unsigned long val_offsetRank) override
 Function to correct the offset of the global DOFs.
 
- Public Member Functions inherited from CPrimalGrid
 CPrimalGrid ()=delete
 
 CPrimalGrid (bool FEM, unsigned short nNodes, unsigned short nNeighbor_Elements)
 Constructor of the class.
 
virtual ~CPrimalGrid ()=default
 Destructor of the class.
 
unsigned long GetNode (unsigned short val_node) const
 Get the nodes shared by the primal grid element.
 
void SetNode (unsigned short val_node, unsigned long val_point)
 Set the nodes shared by the primal grid element.
 
long GetNeighbor_Elements (unsigned short val_face) const
 Get the elements that surround an element.
 
void SetNeighbor_Elements (unsigned long val_elem, unsigned short val_face)
 Set the elements that surround an element.
 
su2double GetLengthScale () const
 Make available the length scale of the element.
 
void SetLengthScale (su2double val_lenScale)
 Set the length scale of the element.
 
unsigned short GetTimeLevel () const
 Make available the time level of the element.
 
void SetTimeLevel (unsigned short val_timeLevel)
 Set the time level of the element.
 
bool GetOwnerFace (unsigned short val_face) const
 Get the boolean to indicate whether or not this element owns the face between the current and the adjacent element with index val_face.
 
void SetOwnerFace (bool val_owner, unsigned short val_face)
 Set the boolean to indicate whether or not this element owns the face between the current and the adjacent element with index val_face.
 
short GetPeriodicIndex (unsigned short val_face) const
 Get the index of the periodic transformation to the neighboring element.
 
void SetPeriodicIndex (unsigned short val_periodic, unsigned short val_face)
 Set the index of the periodic transformation to the neighboring element.
 
bool GetJacobianConstantFace (unsigned short val_face) const
 Get whether or not the Jacobian of the given face is considered constant.
 
void SetJacobianConstantFace (bool val_JacFaceIsConstant, unsigned short val_face)
 Set whether or not the Jacobian of the given face is considered constant.
 
template<class T >
su2double * SetCoord_CG (unsigned short nDim, const T &val_coord)
 Set the center of gravity of an element (including edges).
 
su2double GetCG (unsigned short val_dim) const
 Get the center of gravity of an element (including edges).
 
const su2double * GetCG () const
 
void SetVolume (su2double val_volume)
 Set the center of gravity of an element (including edges).
 
su2double GetVolume () const
 Get the center of gravity of an element (including edges).
 
void ResetJacobianConstantFaces ()
 Reset the array, which stores whether or not the faces have a constant Jacobian, to false.
 
void InitializeNeighbors (unsigned short val_nFaces)
 Initialize the information about the neighboring elements.
 
unsigned long GetGlobalIndex () const
 Get the element global index in a parallel computation.
 
void SetGlobalIndex (unsigned long val_globalindex)
 Set the global index for an element in a parallel computation.
 
void SetDomainElement (unsigned long val_domainelement)
 Set the index of the domain element of which this boundary element is a face.
 
unsigned long GetDomainElement () const
 Get the index of the domain element of which this boundary element is a face.
 
virtual unsigned short GetRotation_Type () const
 A pure virtual member.
 
virtual void SetRotation_Type (unsigned short val_rotation_type)
 A pure virtual member.
 
virtual void AddDonorWallFunctions (const unsigned long donorElement)
 Virtual function to add the given donor ID to the donor elements for the wall function treatment.
 
virtual unsigned short GetNDonorsWallFunctions () const
 Virtual function to make available the number of donor elements for the wall function treatment.
 
virtual unsigned long * GetDonorsWallFunctions ()
 Virtual function to make available the pointer to the vector for the donor elements for the wall function treatment.
 
virtual const unsigned long * GetDonorsWallFunctions () const
 
virtual void SetDonorsWallFunctions (const std::vector< unsigned long > &donorElements)
 Virtual function to set the global ID's of the donor elements for the wall function treatment.
 
virtual void RemoveMultipleDonorsWallFunctions ()
 Virtual function to remove the multiple donors for the wall function treatment.
 

Static Public Member Functions

static void GetLocalCornerPointsAllFaces (unsigned short elementType, unsigned short nPoly, unsigned short nDOFs, unsigned short &numFaces, unsigned short nPointsPerFace[], unsigned long faceConn[6][4])
 Static member function to get the local the corner points of all the faces of this element. It must be made sure that the numbering of the faces is identical to the numbering used for the standard elements.
 

Additional Inherited Members

- Protected Attributes inherited from CPrimalGrid
unsigned long GlobalIndex_DomainElement
 
std::unique_ptr< unsigned long[]> Nodes
 Global node indices of the element.
 
std::unique_ptr< long[]> Neighbor_Elements
 Vector to store the elements surronding this element.
 
su2double Coord_CG [3] = {0.0}
 Coordinates of the center-of-gravity of the element.
 
su2double Volume
 Volume of the element.
 
su2double LenScale
 Length scale of the element.
 
unsigned short TimeLevel
 Time level of the element for time accurate local time stepping.
 
int8_t PeriodIndexNeighbors [N_FACES_MAXIMUM]
 
bool JacobianFaceIsConstant [N_FACES_MAXIMUM]
 Whether or not the Jacobian of the faces can be considered constant in the transformation to the standard element.
 
bool ElementOwnsFace [N_FACES_MAXIMUM]
 Whether or not the element owns each face.
 
const bool FEM
 Whether this is a FEM element.
 

Detailed Description

Class to define primal grid element for the FEM solver.

Version
8.5.0 "Harrier"

Constructor & Destructor Documentation

◆ CPrimalGridFEM()

CPrimalGridFEM::CPrimalGridFEM ( const unsigned long *  dataElem,
unsigned long &  offsetSolDOFs 
)

Constructor using data to initialize the element.

Parameters
[in]dataElem- Meta and connectivity data for this element.
[in,out]offsetDOFs- The offset of the solution DOFs for this element.

Member Function Documentation

◆ AddOffsetGlobalDOFs()

void CPrimalGridFEM::AddOffsetGlobalDOFs ( const unsigned long  val_offsetRank)
inlineoverridevirtual

Function to correct the offset of the global DOFs.

Parameters
[in]val_offsetRank- The offset that must be added for this rank.

Reimplemented from CPrimalGrid.

◆ Change_Orientation()

void CPrimalGridFEM::Change_Orientation ( void  )
inlineoverridevirtual

Change the orientation of an element.

Implements CPrimalGrid.

◆ GetColor()

unsigned long CPrimalGridFEM::GetColor ( void  ) const
inlineoverridevirtual

Get the color of the element for the partitioning. return - The color of the element in the partitioning.

Reimplemented from CPrimalGrid.

◆ GetCornerPointsAllFaces()

void CPrimalGridFEM::GetCornerPointsAllFaces ( unsigned short &  numFaces,
unsigned short  nPointsPerFace[],
unsigned long  faceConn[6][4] 
) const
overridevirtual

Get all the corner points of all the faces of this element. It must be made sure that the numbering of the faces is identical to the numbering used for the standard elements.

Parameters
[out]nFaces- Number of faces of this element.
[out]nPointsPerFace- Number of corner points for each of the faces.
[out]faceConn- Global IDs of the corner points of the faces.

Reimplemented from CPrimalGrid.

◆ GetFaces()

unsigned short CPrimalGridFEM::GetFaces ( unsigned short  val_face,
unsigned short  val_index 
) const
inlineoverridevirtual

Get the face index of an element.

Parameters
[in]val_face- Local index of the face.
[in]val_index- Local (to the face) index of the nodes that compose the face.
Returns
Local (to the element) index of the nodes that compose the face.

Implements CPrimalGrid.

◆ GetGlobalElemID()

unsigned long CPrimalGridFEM::GetGlobalElemID ( void  ) const
inlineoverridevirtual

Make available the global ID of this element.

Returns
The global ID of this element.

Reimplemented from CPrimalGrid.

◆ GetGlobalOffsetDOFsSol()

unsigned long CPrimalGridFEM::GetGlobalOffsetDOFsSol ( void  ) const
inlineoverridevirtual

Make available the global offset of the solution DOFs of this element.

Returns
The global offset of the solution DOFs.

Reimplemented from CPrimalGrid.

◆ GetJacobianConsideredConstant()

bool CPrimalGridFEM::GetJacobianConsideredConstant ( void  ) const
inlineoverridevirtual

Function to get whether or not the Jacobian is considered constant.

Returns
True if the Jacobian is (almost) constant and false otherwise.

Reimplemented from CPrimalGrid.

◆ GetLocalCornerPointsAllFaces()

void CPrimalGridFEM::GetLocalCornerPointsAllFaces ( unsigned short  elementType,
unsigned short  nPoly,
unsigned short  nDOFs,
unsigned short &  numFaces,
unsigned short  nPointsPerFace[],
unsigned long  faceConn[6][4] 
)
static

Static member function to get the local the corner points of all the faces of this element. It must be made sure that the numbering of the faces is identical to the numbering used for the standard elements.

Parameters
[in]elementType- Type of the element using the VTK convention.
[in]nPoly- Polynomial degree of the element.
[in]nDOFs- Number of DOFs of the element.
[out]nFaces- Number of faces of this element.
[out]nPointsPerFace- Number of corner points for each of the faces.
[out]faceConn- Global IDs of the corner points of the faces.

◆ GetMaxNodesFace()

unsigned short CPrimalGridFEM::GetMaxNodesFace ( void  ) const
inlineoverridevirtual

Get the Maximum number of nodes of a face of an element.

Returns
Maximum number of nodes of a face of an element.

Implements CPrimalGrid.

◆ GetNDOFsGrid()

unsigned short CPrimalGridFEM::GetNDOFsGrid ( void  ) const
inlineoverridevirtual

Function to make available the number of DOFs of the grid in the element.

Returns
The number of DOFs of the grid in the element.

Reimplemented from CPrimalGrid.

◆ GetNDOFsSol()

unsigned short CPrimalGridFEM::GetNDOFsSol ( void  ) const
inlineoverridevirtual

Function to make available the number of DOFs of the solution in the element.

Returns
The number of DOFs of the solution in the element.

Reimplemented from CPrimalGrid.

◆ GetNeighbor_Nodes()

unsigned short CPrimalGridFEM::GetNeighbor_Nodes ( unsigned short  val_node,
unsigned short  val_index 
) const
inlineoverridevirtual

Get the local index of the neighbors to a node (given the local index).

Parameters
[in]val_node- Local (to the element) index of a node.
[in]val_index- Local (to the neighbor nodes of val_node) index of the nodes that are neighbor to val_node.
Returns
Local (to the element) index of the nodes that are neighbor to val_node.

Implements CPrimalGrid.

◆ GetnFaces()

unsigned short CPrimalGridFEM::GetnFaces ( void  ) const
inlineoverridevirtual

Get the number of faces of an element.

Returns
Number of faces of an element.

Implements CPrimalGrid.

◆ GetnNeighbor_Nodes()

unsigned short CPrimalGridFEM::GetnNeighbor_Nodes ( unsigned short  val_node) const
inlineoverridevirtual

Get the number of neighbors nodes of a node.

Parameters
[in]val_node- Local (to the element) index of a node.
Returns
Number if neighbors of a node val_node.

Implements CPrimalGrid.

◆ GetnNodes()

unsigned short CPrimalGridFEM::GetnNodes ( void  ) const
inlineoverridevirtual

Get the number of nodes of an element.

Returns
Number of nodes that composes an element.

Implements CPrimalGrid.

◆ GetnNodesFace()

unsigned short CPrimalGridFEM::GetnNodesFace ( unsigned short  val_face) const
inlineoverridevirtual

Get the number of nodes that composes a face of an element.

Parameters
[in]val_face- Local index of the face.
Returns
Number of nodes that composes a face of an element.

Reimplemented from CPrimalGrid.

◆ GetNPolyGrid()

unsigned short CPrimalGridFEM::GetNPolyGrid ( void  ) const
inlineoverridevirtual

Get the polynomial degree of the grid for this element.

Returns
The polynomial degree of the grid.

Reimplemented from CPrimalGrid.

◆ GetNPolySol()

unsigned short CPrimalGridFEM::GetNPolySol ( void  ) const
inlineoverridevirtual

Get the polynomial degree of the solution for this element.

Returns
The polynomial degree of the solution.

Reimplemented from CPrimalGrid.

◆ GetVTK_Type()

unsigned short CPrimalGridFEM::GetVTK_Type ( void  ) const
inlineoverridevirtual

Get the type of the element using VTK nomenclature.

Returns
Type of the element using VTK nomenclature.

Implements CPrimalGrid.

◆ SetColor()

void CPrimalGridFEM::SetColor ( unsigned long  val_color)
inlineoverridevirtual

Set the color of the element.

Parameters
[in]val_color- New color of the element.

Reimplemented from CPrimalGrid.

◆ SetJacobianConsideredConstant()

void CPrimalGridFEM::SetJacobianConsideredConstant ( bool  val_JacobianConsideredConstant)
inlineoverridevirtual

Function to set the value of JacobianConsideredConstant.

Parameters
[in]val_JacobianConsideredConstant- The value to be set for JacobianConsideredConstant.

Reimplemented from CPrimalGrid.


The documentation for this class was generated from the following files: