ElementType.h
Go to the documentation of this file.
/*****************************************************************************
*
* Copyright (c) 2010-2018 by The University of Queensland
* http://www.uq.edu.au
*
* Primary Business: Queensland, Australia
* Licensed under the Apache License, version 2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
* Development until 2012 by Earth Systems Science Computational Center (ESSCC)
* Development 2012-2013 by School of Earth Sciences
* Development from 2014-2017 by Centre for Geoscience Computing (GeoComp)
* Development from 2019 by School of Earth and Environmental Sciences
**
*****************************************************************************/
#ifndef __DUDLEY_ELEMENTTYPE_H__
#define __DUDLEY_ELEMENTTYPE_H__
#include <string>
namespace dudley {
typedef enum {
Dudley_Point1 = 0,
Dudley_Line2 = 1,
Dudley_Tri3 = 2,
Dudley_Tet4 = 3,
Dudley_Line2Face = 4,
Dudley_Tri3Face = 5,
Dudley_Tet4Face = 6,
Dudley_NoRef = 7 // marks end of list
} ElementTypeId;
inline ElementTypeId eltTypeFromString(const std::string& s)
{
if (s == "Point1")
return Dudley_Point1;
else if (s == "Line2")
return Dudley_Line2;
else if (s == "Tri3")
return Dudley_Tri3;
else if (s == "Tet4")
return Dudley_Tet4;
else if (s == "Line2Face")
return Dudley_Line2Face;
else if (s == "Tri3Face")
return Dudley_Tri3Face;
else if (s == "Tet4Face")
return Dudley_Tet4Face;
else
return Dudley_NoRef;
}
}
#endif // __DUDLEY_ELEMENTTYPE_H__
dudley::ElementFile_Jacobians::DSDX
double * DSDX
Definition: dudley/src/ElementFile.h:77
dudley::ElementFile_Jacobians::numShapes
int numShapes
number of shape functions
Definition: dudley/src/ElementFile.h:68
finley::ElementFile_Jacobians::ElementFile_Jacobians
ElementFile_Jacobians(const_ShapeFunction_ptr basis)
Definition: finley/src/ElementFile_jacobians.cpp:37
dudley::ElementFile::Tag
int * Tag
Tag[i] is the tag of element i.
Definition: dudley/src/ElementFile.h:135
dudley::ElementFile_Jacobians
Definition: dudley/src/ElementFile.h:42
dudley::Assemble_jacobians_3D_M2D_E2D
void Assemble_jacobians_3D_M2D_E2D(const double *coordinates, int numQuad, dim_t numElements, int numNodes, const index_t *nodes, double *dTdX, double *absD, double *quadWeight, const index_t *elementId)
Definition: dudley/src/Assemble_jacobians.cpp:255
dudley::Dudley_Point1
@ Dudley_Point1
Definition: ElementType.h:54
dudley::DudleyException
Definition: DudleyException.h:39
dudley::ElementFile::jacobians_reducedQ
ElementFile_Jacobians * jacobians_reducedQ
Definition: dudley/src/ElementFile.h:181
dudley::NodeFile::numDim
int numDim
number of spatial dimensions
Definition: dudley/src/NodeFile.h:146
dudley::ElementFile::createColoring
void createColoring(dim_t numNodes, const index_t *degreeOfFreedom)
Definition: ElementFile_createColoring.cpp:39
DUDLEY_INITIAL_STATUS
#define DUDLEY_INITIAL_STATUS
Definition: Dudley.h:81
dudley::NodeFile
Definition: dudley/src/NodeFile.h:39
INDEX2
#define INDEX2(_X1_, _X2_, _N1_)
Definition: index.h:23
finley::ElementFile_Jacobians::numShapesTotal
int numShapesTotal
total number of shape functions = BasisFunctions->numShapes * numSides
Definition: finley/src/ElementFile.h:77
dudley::Dudley_Tet4Face
@ Dudley_Tet4Face
Definition: ElementType.h:60
dudley::util::getMinMaxInt
IndexPair getMinMaxInt(int dim, dim_t N, const index_t *values)
Definition: dudley/src/Util.cpp:187
dudley::ElementFile::Nodes
index_t * Nodes
Nodes[INDEX(k, i, numNodes)] is the k-th node in the i-th element.
Definition: dudley/src/ElementFile.h:147
finley::ElementFile_Jacobians::volume
double * volume
local volume
Definition: finley/src/ElementFile.h:84
finley::ElementFile_Jacobians::node_selection
const int * node_selection
Definition: finley/src/ElementFile.h:80
finley::ElementFile_Jacobians
Definition: finley/src/ElementFile.h:42
dudley::ElementFile::allocTable
void allocTable(dim_t NE)
allocates the element table within an element file to hold NE elements
Definition: dudley/src/ElementFile.cpp:68
dudley::ElementFile_Jacobians::numQuad
int numQuad
number of quadrature nodes used to calculate jacobians
Definition: dudley/src/ElementFile.h:66
dudley::Dudley_Tri3Face
@ Dudley_Tri3Face
Definition: ElementType.h:59
finley::Assemble_jacobians_1D
void Assemble_jacobians_1D(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:64
finley::const_ReferenceElement_ptr
boost::shared_ptr< const ReferenceElement > const_ReferenceElement_ptr
Definition: ReferenceElements.h:214
dudley::ElementFile::Owner
int * Owner
Owner[i] contains the rank that owns element i.
Definition: dudley/src/ElementFile.h:138
dudley::ElementFile_Jacobians::absD
double * absD
used to compute volume
Definition: dudley/src/ElementFile.h:72
finley::Assemble_jacobians_3D_M2D_E2D_C
void Assemble_jacobians_3D_M2D_E2D_C(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:747
dudley::ElementFile::jacobians
ElementFile_Jacobians * jacobians
jacobians of the shape function used for solution approximation
Definition: dudley/src/ElementFile.h:177
dudley::QuadNums
static const int QuadNums[4][2]
Definition: ShapeTable.h:89
dudley::ElementFile::distributeByRankOfDOF
void distributeByRankOfDOF(const int *mpiRankOfDOF, const index_t *nodesId)
redistributes the elements including overlap by rank
Definition: ElementFile_distributeByRankOfDOF.cpp:38
dudley::NodeFile::status
int status
Definition: dudley/src/NodeFile.h:177
dudley::ElementFile_Jacobians::status
int status
status of mesh when jacobians were updated last time
Definition: dudley/src/ElementFile.h:62
MPI_INT
#define MPI_INT
Definition: EsysMPI.h:46
dudley::ElementFile::maxColor
index_t maxColor
maximum color value
Definition: dudley/src/ElementFile.h:158
finley::Assemble_jacobians_3D_M2D_E3D_C
void Assemble_jacobians_3D_M2D_E3D_C(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:547
finley::NodeFile::Coordinates
double * Coordinates
Coordinates[INDEX2(k,i,numDim)] is the k-th coordinate of node i.
Definition: finley/src/NodeFile.h:175
dudley::ElementFile::minColor
index_t minColor
minimum color value
Definition: dudley/src/ElementFile.h:155
dudley
A suite of factory methods for creating 2D and 3D dudley domains.
Definition: dudley/src/Assemble.h:32
finley::ElementFile_Jacobians::numElements
dim_t numElements
number of elements
Definition: finley/src/ElementFile.h:82
dudley::Dudley_Line2Face
@ Dudley_Line2Face
Definition: ElementType.h:58
dudley::Assemble_jacobians_2D
void Assemble_jacobians_2D(const double *coordinates, int numQuad, dim_t numElements, int numNodes, const index_t *nodes, double *dTdX, double *absD, double *quadWeight, const index_t *elementId)
Definition: dudley/src/Assemble_jacobians.cpp:56
escript::DataTypes::dim_t
index_t dim_t
Definition: DataTypes.h:93
dudley::ElementFile::numElements
dim_t numElements
number of elements
Definition: dudley/src/ElementFile.h:127
dudley::Assemble_jacobians_3D
void Assemble_jacobians_3D(const double *coordinates, int numQuad, dim_t numElements, int numNodes, const index_t *nodes, double *dTdX, double *abs_D, double *quadWeight, const index_t *elementId)
Definition: dudley/src/Assemble_jacobians.cpp:180
ElementFile.h
ElementFile.h
finley::ElementFile_Jacobians::numQuadTotal
int numQuadTotal
Definition: finley/src/ElementFile.h:69
finley::Assemble_jacobians_3D_M2D_E3D
void Assemble_jacobians_3D_M2D_E3D(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:466
dudley::ElementFile::Id
index_t * Id
Definition: dudley/src/ElementFile.h:132
Assemble.h
dudley::ElementFile::numDim
int numDim
number of spatial dimensions of the domain
Definition: dudley/src/ElementFile.h:161
dudley::ElementFile::MPIInfo
escript::JMPI MPIInfo
Definition: dudley/src/ElementFile.h:124
ShapeTable.h
finley::NodeFile::status
int status
Definition: finley/src/NodeFile.h:209
dudley::ElementFile_Jacobians::numDim
int numDim
number of spatial dimensions
Definition: dudley/src/ElementFile.h:64
dudley::Assemble_jacobians_2D_M1D_E1D
void Assemble_jacobians_2D_M1D_E1D(const double *coordinates, int numQuad, dim_t numElements, int numNodes, const index_t *nodes, double *dTdX, double *absD, double *quadWeight, const index_t *elementId)
Definition: dudley/src/Assemble_jacobians.cpp:134
finley::ElementFile_Jacobians::offsets
const int * offsets
offset to sides (borrowed reference)
Definition: finley/src/ElementFile.h:73
finley::ElementFile_Jacobians::status
int status
status of mesh when jacobians were updated last time
Definition: finley/src/ElementFile.h:62
dudley::ElementFile::numLocalDim
int numLocalDim
dimension of the element e.g. 2 for a line in 2D or 3D
Definition: dudley/src/ElementFile.h:164
escript::DataTypes::index_t
int index_t
type for array/matrix indices used both globally and on each rank
Definition: DataTypes.h:88
finley::NodeFile
Definition: finley/src/NodeFile.h:41
dudley::Dudley_Tet4
@ Dudley_Tet4
Definition: ElementType.h:57
finley::Assemble_jacobians_2D_M1D_E2D
void Assemble_jacobians_2D_M1D_E2D(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:260
Util.h
finley::ElementFile_Jacobians::numSides
int numSides
number of sides (=1 normal, =2 contact)
Definition: finley/src/ElementFile.h:71
dudley::ElementFile_Jacobians::numElements
dim_t numElements
number of elements
Definition: dudley/src/ElementFile.h:70
dudley::ElementFile_Jacobians::quadweight
double quadweight
used to compute volume
Definition: dudley/src/ElementFile.h:74
finley::Assemble_jacobians_2D_M1D_E1D_C
void Assemble_jacobians_2D_M1D_E1D_C(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:200
dudley::ElementFile_Jacobians::ElementFile_Jacobians
ElementFile_Jacobians()
Definition: dudley/src/ElementFile_jacobians.cpp:38
finley::ElementFile_Jacobians::numDim
int numDim
number of spatial dimensions
Definition: finley/src/ElementFile.h:64
dudley::ElementFile::Color
index_t * Color
Definition: dudley/src/ElementFile.h:152
finley::const_ShapeFunction_ptr
boost::shared_ptr< const ShapeFunction > const_ShapeFunction_ptr
Definition: ShapeFunctions.h:100
dudley::Dudley_NoRef
@ Dudley_NoRef
Definition: ElementType.h:61
finley::ElementFile_Jacobians::BasisFunctions
const_ShapeFunction_ptr BasisFunctions
basis function used
Definition: finley/src/ElementFile.h:66
finley::ElementFile_Jacobians::DSDX
double * DSDX
Definition: finley/src/ElementFile.h:87
finley::Assemble_jacobians_2D_M1D_E2D_C
void Assemble_jacobians_2D_M1D_E2D_C(const double *coordinates, int numQuad, const double *QuadWeights, int numShape, dim_t numElements, int numNodes, const index_t *nodes, const double *DSDv, int numTest, const double *DTDv, double *dTdX, double *volume, const index_t *elementId)
Definition: finley/src/Assemble_jacobians.cpp:314
finley::ElementFile_Jacobians::numSub
int numSub
number of subelements
Definition: finley/src/ElementFile.h:75
dudley::Dudley_Line2
@ Dudley_Line2
Definition: ElementType.h:55
finley
A suite of factory methods for creating various finley domains.
Definition: finley/src/Assemble.h:32
FINLEY_INITIAL_STATUS
#define FINLEY_INITIAL_STATUS
Definition: Finley.h:95
finley::NodeFile::numDim
int numDim
number of spatial dimensions
Definition: finley/src/NodeFile.h:162
ESYS_ASSERT
#define ESYS_ASSERT(a, b)
EsysAssert is a MACRO that will throw an exception if the boolean condition specified is false.
Definition: Assert.h:79
dudley::Dudley_Tri3
@ Dudley_Tri3
Definition: ElementType.h:56
dudley::NodeFile::Coordinates
double * Coordinates
Coordinates[INDEX2(k,i,numDim)] is the k-th coordinate of node i.
Definition: dudley/src/NodeFile.h:159
escript::ValueError
An exception class that signals an invalid argument value.
Definition: EsysException.h:103
dudley::ElementTypeId
ElementTypeId
Definition: ElementType.h:39
dudley::eltTypeFromString
ElementTypeId eltTypeFromString(const std::string &s)
Definition: ElementType.h:50
dudley::ElementFile_Jacobians::~ElementFile_Jacobians
~ElementFile_Jacobians()
Definition: dudley/src/ElementFile_jacobians.cpp:49
Assemble.h
dudley::ElementFile::numNodes
int numNodes
number of nodes per element
Definition: dudley/src/ElementFile.h:144
dudley::ElementFile::borrowJacobians
ElementFile_Jacobians * borrowJacobians(const NodeFile *nodes, bool reducedOrder) const
Definition: dudley/src/ElementFile_jacobians.cpp:55