NeoPZ
pzshapecube.h
Go to the documentation of this file.
1 
6 #ifndef SHAPECUBEHPP
7 #define SHAPECUBEHPP
8 
9 #include "pzfmatrix.h"
10 #include "pzstack.h"
11 #include "pztrnsform.h"
12 #include "tpzcube.h"
13 #include "pzshtmat.h"
14 
15 #ifdef _AUTODIFF
16 #include "fadType.h"
17 #endif
18 
20 namespace pzshape {
21 
30 
31  public:
32 
45  static void Shape(TPZVec<REAL> &pt, TPZVec<int64_t> &id, TPZVec<int> &order, TPZFMatrix<REAL> &phi,TPZFMatrix<REAL> &dphi);
46 
47  static void SideShape(int side, TPZVec<REAL> &pt, TPZVec<int64_t> &id, TPZVec<int> &order, TPZFMatrix<REAL> &phi,TPZFMatrix<REAL> &dphi);
48 
52  static void ShapeOrder(TPZVec<int64_t> &id, TPZVec<int> &order, TPZGenMatrix<int> &shapeorders);//, TPZVec<int64_t> &sides;
53 
58  static void SideShapeOrder(int side, TPZVec<int64_t> &id, int order, TPZGenMatrix<int> &shapeorders);
59 
60 
61 #ifdef _AUTODIFF
62 
73  static void ShapeCube(TPZVec<REAL> &point, TPZVec<int64_t> &id, TPZVec<int> &order, TPZVec<FADREAL> &phi);
74 
80  static void ShapeCornerCube(TPZVec<FADREAL> &pt, TPZVec<FADREAL> &phi);
81 
93  static void Shape3dCubeInternal(TPZVec<FADREAL> &x, int order,TPZVec<FADREAL> &phi);//,int quad_transformation_index
94 #endif
95 
102  static void ShapeCorner(TPZVec<REAL> &pt, TPZFMatrix<REAL> &phi, TPZFMatrix<REAL> &dphi);
103 
110  static void ShapeGenerating(TPZVec<REAL> &pt, TPZFMatrix<REAL> &phi, TPZFMatrix<REAL> &dphi);
111 
112  private:
113 
114 
115 
129  static void ShapeInternal(TPZVec<REAL> &x, int order,TPZFMatrix<REAL> &phi,
130  TPZFMatrix<REAL> &dphi);//,int quad_transformation_index
137  static void ProjectPoint3dCubeToRib(int face, TPZVec<REAL> &in, REAL &outval);
138 
139 #ifdef _AUTODIFF
140 
146  static void ProjectPoint3dCubeToRib(int face, TPZVec<FADREAL> &in, FADREAL &outval);
147 
154  static void ProjectPoint3dCubeToFace(int face, TPZVec<FADREAL> &in, TPZVec<FADREAL> &outval);
155 #endif
156 
163  static void ProjectPoint3dCubeSide(int face, TPZVec<REAL> &in, REAL &out);
164 
171  static void ProjectPoint3dCubeFace(int face, TPZVec<REAL> &in, TPZVec<REAL> &out);
172 
179  static void ProjectPoint3dCubeToFace(int face, TPZVec<REAL> &in, TPZVec<REAL> &outval);
180 
188  static void TransformDerivativeFromRibToCube(int rib,int num,TPZFMatrix<REAL> &dphi);
189 
197  static void TransformDerivativeFromFaceToCube(int rib,int num,TPZFMatrix<REAL> &dphi);
198 
200  static REAL gFaceTrans3dCube2d[6][2][3];
202  static REAL gRibTrans3dCube1d[12][3];
203 
204  public:
212  static int NConnectShapeF(int side, int order);
213 
219  static int NShapeF(TPZVec<int> &order);
220  static void ShapeInternal(int side, TPZVec<REAL> &x, int order, TPZFMatrix<REAL> &phi, TPZFMatrix<REAL> &dphi);
221 
222  };
223 
224 };
225 
226 #endif
static void ProjectPoint3dCubeToFace(int face, TPZVec< REAL > &in, TPZVec< REAL > &outval)
Projects a point from the interior of the element to a face.
static void SideShape(int side, TPZVec< REAL > &pt, TPZVec< int64_t > &id, TPZVec< int > &order, TPZFMatrix< REAL > &phi, TPZFMatrix< REAL > &dphi)
static REAL gFaceTrans3dCube2d[6][2][3]
Data structure which defines the hexahedral transformations.
Definition: pzshapecube.h:200
groups all classes dedicated to the computation of shape functions
Definition: pzshapeextend.h:16
static void ProjectPoint3dCubeSide(int face, TPZVec< REAL > &in, REAL &out)
Projects a point from the interior of the element to a rib.
static void SideShapeOrder(int side, TPZVec< int64_t > &id, int order, TPZGenMatrix< int > &shapeorders)
returns the polynomial order in the natural ksi, eta of the internal shapefunctions of a side ...
Defines the topology of the hexahedron element. Topology Sides 0 to 7 are vertices, sides 8 to 19 are lines, 20 to 25 are quadrilaterals and side 26 is the hexahedra (cube).
Definition: tpzcube.h:38
static void TransformDerivativeFromFaceToCube(int rib, int num, TPZFMatrix< REAL > &dphi)
Transforms the derivative of a shapefunction computed on the face into the three dimensional derivati...
static void ShapeCorner(TPZVec< REAL > &pt, TPZFMatrix< REAL > &phi, TPZFMatrix< REAL > &dphi)
Computes the corner shape functions for a hexahedral element.
Definition: pzshapecube.cpp:34
Contains TPZMatrixclass which implements full matrix (using column major representation).
static void ShapeInternal(TPZVec< REAL > &x, int order, TPZFMatrix< REAL > &phi, TPZFMatrix< REAL > &dphi)
Compute the internal functions of the hexahedral shape function at a point.
static void ShapeGenerating(TPZVec< REAL > &pt, TPZFMatrix< REAL > &phi, TPZFMatrix< REAL > &dphi)
Computes the generating shape functions for a quadrilateral element.
Definition: pzshapecube.cpp:90
static void Shape(TPZVec< REAL > &pt, TPZVec< int64_t > &id, TPZVec< int > &order, TPZFMatrix< REAL > &phi, TPZFMatrix< REAL > &dphi)
Computes the values of the shape functions and their derivatives for a hexahedral element...
static int NShapeF(TPZVec< int > &order)
Total number of shapefunctions, considering the order of interpolation of the element.
Implements generic class which holds a matrix of objects. Matrix.
Definition: pzshtmat.h:18
A simple stack.
static void ShapeOrder(TPZVec< int64_t > &id, TPZVec< int > &order, TPZGenMatrix< int > &shapeorders)
returns the polynomial order in the natural ksi, eta of the side associated with each shapefunction ...
static REAL gRibTrans3dCube1d[12][3]
Data structure which defines the hexahedral transformations.
Definition: pzshapecube.h:202
static void ProjectPoint3dCubeToRib(int face, TPZVec< REAL > &in, REAL &outval)
Projects a point from the interior of the element to a rib.
Contains TPZGenMatrix class which implements generic class which holds a matrix of objects...
Contains the TPZTransform<> class which implements an affine transformation between points in paramet...
static void ProjectPoint3dCubeFace(int face, TPZVec< REAL > &in, TPZVec< REAL > &out)
Projects a point from the interior of the element to a face.
Contains the TPZCube class which defines the topology of the hexahedron element.
Implements the shape functions of a hexahedral (3D) element. Shape.
Definition: pzshapecube.h:29
static void TransformDerivativeFromRibToCube(int rib, int num, TPZFMatrix< REAL > &dphi)
Transforms the derivative of a shapefunction computed on the rib into the three dimensional derivativ...
static int NConnectShapeF(int side, int order)
Number of shapefunctions of the connect associated with the side, considering the order of interpolat...