NeoPZ
tpzquadraticline.h
Go to the documentation of this file.
1 
5 #ifndef TPZQUADRATICLINE_H
6 #define TPZQUADRATICLINE_H
7 
8 #include "TPZGeoLinear.h"
9 #include "pzgeoel.h"
10 #include "pznoderep.h"
11 
12 #include <iostream>
13 
14 namespace pzgeom {
15 
22  class TPZQuadraticLine : public pzgeom::TPZNodeRep<3,pztopology::TPZLine>
23  {
24  public:
26  enum {NNodes = 3};
27 
28  public:
29 int ClassId() const override;
30 
31 
32  //virtual void ParametricDomainNodeCoord(int node, TPZVec<REAL> &nodeCoord);
33 
34 
37  pzgeom::TPZNodeRep<NNodes,pztopology::TPZLine>(nodeindexes)
38  {
39  }
40 
43  {
44  }
45 
46  TPZQuadraticLine(const TPZQuadraticLine &cp,std::map<int64_t,int64_t> & gl2lcNdMap) : TPZRegisterClassId(&TPZQuadraticLine::ClassId),
47  pzgeom::TPZNodeRep<NNodes,pztopology::TPZLine>(cp,gl2lcNdMap)
48  {
49  }
50 
53  {
54  }
55 
58  {
59  }
60 
62  static std::string TypeName() { return "Line";}
63 
64  static bool IsLinearMapping(int side)
65  {
66  return false;
67  }
68 
74  // static TPZGeoEl * CreateBCGeoEl(TPZGeoEl *orig,int side,int bc);
75 
79  // static TPZGeoEl *CreateGeoElement(TPZGeoMesh &mesh, MElementType type,
80  // TPZVec<int64_t>& nodeindexes,
81  // int matid,
82  // int64_t& index);
83 
85  static void Shape(TPZVec<REAL> &loc,TPZFMatrix<REAL> &phi,TPZFMatrix<REAL> &dphi){
86  TShape(loc, phi, dphi);
87  }
88 
89 
90  /* brief compute the coordinate of a point given in parameter space */
91 // template<class T>
92 // void X(const TPZGeoEl &gel,TPZVec<T> &loc,TPZVec<T> &result) const
93 // {
94 // TPZFNMatrix<3*NNodes> coord(3,NNodes);
95 // CornerCoordinates(gel, coord);
96 // X(coord,loc,result);
97 // }
98 
99 
101  template<class T>
102  static void TShape(const TPZVec<T> &loc,TPZFMatrix<T> &phi,TPZFMatrix<T> &dphi);
103 
104  template<class T>
105  static void X(const TPZFMatrix<REAL> &coord, TPZVec<T> &par, TPZVec<T> &result);
106 
108  template<class T>
109  static void GradX(const TPZFMatrix<REAL> &nodes,TPZVec<T> &loc, TPZFMatrix<T> &gradx);
110 
111  static void InsertExampleElement(TPZGeoMesh &gmesh, int matid, TPZVec<REAL> &lowercorner, TPZVec<REAL> &size);
112 
113  };
114 
115 
116 };
117 
118 #endif
Defines a linear geometric element with quadratic map. Geometry.
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.
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.
Implements a line. Utility.
Definition: pzline.h:18
static void InsertExampleElement(TPZGeoMesh &gmesh, int matid, TPZVec< REAL > &lowercorner, TPZVec< REAL > &size)
create an example element based on the topology
TPZQuadraticLine(const TPZQuadraticLine &cp)
TPZQuadraticLine(TPZVec< int64_t > &nodeindexes)
Groups all classes defining the structure of the master element.
Definition: PrismExtend.cpp:15
int ClassId() const override
CreateGeoElement -> TPZQuadraticLine.
pztopology::TPZLine Top
Contains the TPZNodeRep class which implements ... Clase intermediaria que guarda.
Defines the topology of a line element. Topology Sides 0 and 1 are vertices, side 2 is the line...
Definition: tpzline.h:38
Implements ... Geometry Topology.
Definition: pznoderep.h:40
TPZQuadraticLine(const TPZQuadraticLine &cp, TPZGeoMesh &)
TPZQuadraticLine(const TPZQuadraticLine &cp, std::map< int64_t, int64_t > &gl2lcNdMap)
static void Shape(TPZVec< REAL > &loc, TPZFMatrix< REAL > &phi, TPZFMatrix< REAL > &dphi)
Method which creates a geometric boundary condition element based on the current geometric element...
static std::string TypeName()
Returns the type name of the element.
This class implements a geometric mesh for the pz environment. Geometry.
Definition: pzgmesh.h:48
static bool IsLinearMapping(int side)
static void X(const TPZFMatrix< REAL > &coord, TPZVec< T > &par, TPZVec< T > &result)
Groups all classes which model the geometry.
Definition: pzgeopoint.cpp:18