6 #ifndef TPZGEOTETRAPIRAMIDH 7 #define TPZGEOTETRAPIRAMIDH 73 static std::string
TypeName() {
return "Pyramid";}
115 int space = nodes.
Rows();
117 for(
int i = 0; i < space; i++) {
119 for(
int j = 0; j < 5; j++) {
120 x[i] += phi(j,0)*nodes.
GetVal(i,j);
131 int nrow = nodes.
Rows();
132 int ncol = nodes.
Cols();
134 if(nrow != 3 || ncol != 5){
135 std::cout <<
"Objects of incompatible lengths, gradient cannot be computed." << std::endl;
136 std::cout <<
"nodes matrix must be 3x5." << std::endl;
144 for(
int i = 0; i < 5; i++)
146 for(
int j = 0; j < 3; j++)
148 gradx(j,0) += nodes.
GetVal(j,i)*dphi(0,i);
149 gradx(j,1) += nodes.
GetVal(j,i)*dphi(1,i);
150 gradx(j,2) += nodes.
GetVal(j,i)*dphi(2,i);
Defines the topology of a Pyramid element. Topology Sides 0 to 4 are vertices, sides 5 to 12 are line...
TPZPyramid()
Default constructor.
int ClassId() const override
Define the class id associated with the class.
Templated vector implementation.
void Write(TPZStream &buf, int withclassid) const override
Writes this object to the TPZStream buffer. Include the classid if withclassid = true.
Defines enum MElementType and contains the implementation of MElementType_NNodes(...) functions.
TPZGeoPyramid(const TPZGeoPyramid &cp)
Copy constructor.
pztopology::TPZPyramid Top
int Zero() override
Makes Zero all the elements.
static void X(const TPZFMatrix< REAL > &nodes, TPZVec< T > &loc, TPZVec< T > &x)
Computes the geometric location.
static void GradX(const TPZFMatrix< REAL > &nodes, TPZVec< T > &loc, TPZFMatrix< T > &gradx)
Compute gradient of x mapping from element nodes and local parametric coordinates.
Groups all classes defining the structure of the master element.
Defines the behaviour of all geometric elements. GeometryTPZGeoEl is the common denominator for all g...
TPZGeoPyramid(const TPZGeoPyramid &cp, TPZGeoMesh &)
Copy constructor.
Contains TPZMatrixclass which implements full matrix (using column major representation).
#define DebugStop()
Returns a message to user put a breakpoint in.
int64_t Rows() const
Returns number of rows.
Contains the TPZNodeRep class which implements ... Clase intermediaria que guarda.
Implements ... Geometry Topology.
Implements the geometry of pyramid element. Geometry.
Contains the TPZPyramid class which defines the topology of a pyramid element.
static void InsertExampleElement(TPZGeoMesh &gmesh, int matid, TPZVec< REAL > &lowercorner, TPZVec< REAL > &size)
create an example element based on the topology
static std::string TypeName()
Returns the type name of the element.
This class implements a geometric mesh for the pz environment. Geometry.
static bool IsLinearMapping(int side)
static void TShape(const TPZVec< T > &loc, TPZFMatrix< T > &phi, TPZFMatrix< T > &dphi)
Compute the shape being used to construct the x mapping from local parametric coordinates.
TPZGeoPyramid(const TPZGeoPyramid &cp, std::map< int64_t, int64_t > &gl2lcNdMap)
Constructor with node map.
static void Jacobian(const TPZFMatrix< REAL > &coord, TPZVec< REAL > &par, TPZFMatrix< REAL > &jacobian, TPZFMatrix< REAL > &axes, REAL &detjac, TPZFMatrix< REAL > &jacinv)
Computes the jacobian.
int64_t Cols() const
Returns number of cols.
int Resize(const int64_t newRows, const int64_t wCols) override
Redimension a matrix, but maintain your elements.
Defines the interface for saving and reading data. Persistency.
Groups all classes which model the geometry.
void Read(TPZStream &buf, void *context) override
read objects from the stream
const TVar & GetVal(const int64_t row, const int64_t col) const override
Get values without bounds checking This method is faster than "Get" if DEBUG is defined.
Non abstract class which implements full matrices with preallocated storage with (N+1) entries...
TPZGeoPyramid(TPZVec< int64_t > &nodeindexes)
Constructor with list of nodes.
TPZGeoPyramid()
Empty constructor.