NeoPZ
pzreducedspace.h
Go to the documentation of this file.
1 
7 #ifndef PZ_pzreducedspace_h
8 #define PZ_pzreducedspace_h
9 
10 #include "pzinterpolationspace.h"
11 
16 {
17 public:
20 
22  virtual ~TPZReducedSpace();
23 
25  TPZReducedSpace(TPZCompMesh &mesh, const TPZReducedSpace &copy);
26 
28  TPZReducedSpace(TPZCompMesh &mesh, const TPZReducedSpace &copy, std::map<int64_t,int64_t> &gl2lcElMap);
29 
31  TPZReducedSpace(TPZCompMesh &mesh, const TPZReducedSpace &copy, int64_t &index);
32 
40  TPZReducedSpace(TPZCompMesh &mesh, TPZGeoEl *gel, int64_t &index);
41 
43 
45  virtual int NConnects() const override
46  {
47  return 1;
48  }
49 
51  virtual int NSideConnects(int iside) const override
52  {
53  return NConnects();
54  }
55 
61  virtual int SideConnectLocId(int icon,int is) const override
62  {
63 #ifdef PZDEBUG
64  if (icon != 0) {
65  DebugStop();
66  }
67 #endif
68  return 0;
69  }
70 
71 
72 
74  virtual int NShapeF() const override;
75 
77  virtual int NConnectShapeF(int inod, int order) const override;
78 
80  virtual int MaxOrder() override;
81 
92  virtual void Shape(TPZVec<REAL> &qsi,TPZFMatrix<REAL> &phi,TPZFMatrix<REAL> &dphi) override;
93 
105  virtual void ShapeX(TPZVec<REAL> &qsi,TPZFMatrix<REAL> &phi,TPZFMatrix<REAL> &dphix, TPZFMatrix<REAL> &axes);
106 
107  //by Agnaldo
108  virtual void ShapeX(TPZVec<REAL> &qsi,TPZMaterialData &data);
109 
110  virtual void ComputeShape(TPZVec<REAL> &qsi,TPZMaterialData &data) override;
111  virtual void ComputeSolution(TPZVec<REAL> &qsi,TPZMaterialData &data) override;
112 
117  virtual void InitMaterialData(TPZMaterialData &data) override;
118 
120  virtual void ComputeRequiredData(TPZMaterialData &data,
121  TPZVec<REAL> &qsi) override;
122 
133  const TPZFMatrix<REAL> &axes, TPZSolVec &sol, TPZGradSolVec &dsol) override;
134 
137 
139  void InitializeElementMatrix(TPZElementMatrix &ef) override;
140 
142  void Write(TPZStream &buf, int withclassid) const override;
143 
145  void Read(TPZStream &buf, void *context) override;
146 
147 
148  virtual void PRefine ( int order ) override {
149  DebugStop();
150  }
151 
152  virtual void SetConnectIndex(int inode, int64_t index) override {
153  DebugStop();
154  }
155 
156  virtual TPZCompEl *Clone(TPZCompMesh &mesh) const override;
157 
158  virtual const TPZIntPoints &GetIntegrationRule() const override
159  {
161  return intel->GetIntegrationRule();
162  }
163 
164  virtual TPZIntPoints &GetIntegrationRule() override
165  {
167  return intel->GetIntegrationRule();
168  }
169 
170  virtual int Dimension() const override {
172  return intel->Dimension();
173  }
174 
175  virtual TPZCompEl * ClonePatchEl (TPZCompMesh &mesh, std::map< int64_t, int64_t > &gl2lcConMap, std::map< int64_t, int64_t > &gl2lcElMap) const override;
176 
177  virtual void BuildCornerConnectList(std::set<int64_t> &connectindexes) const override {
178 
179  }
180 
181  virtual int64_t ConnectIndex(int i) const override {
182  if (i != 0) {
183  DebugStop();
184  }
185  return 0;
186  }
187 
188  virtual void SetPreferredOrder ( int order ) override {
189  PZError <<"This method was not implemented";
190  DebugStop();
191  }
192 
193  void CreateGraphicalElement(TPZGraphMesh &grafgrid, int dimension) override;
194  public:
195 int ClassId() const override;
196 
197 private:
198 
200 };
201 
202 
203 #endif
Represents a graphical mesh used for post processing purposes. Post processing.
Definition: pzgraphmesh.h:34
virtual int NConnectShapeF(int inod, int order) const override
Returns the number of shapefunctions associated with a connect.
virtual void PRefine(int order) override
Change the preferred order for the element and proceed the adjust of the aproximation space taking ...
virtual void ShapeX(TPZVec< REAL > &qsi, TPZFMatrix< REAL > &phi, TPZFMatrix< REAL > &dphix, TPZFMatrix< REAL > &axes)
Computes the shape function set at the point x.
TPZInterpolationSpace * ReferredIntel() const
clarg::argInt dimension("-d", "Matrices dimension M x M", 1000)
void CreateGraphicalElement(TPZGraphMesh &grafgrid, int dimension) override
Creates corresponding graphical element(s) if the dimension matches graphical elements are used to ge...
virtual int Dimension() const =0
Dimension of the element.
Contains declaration of TPZInterpolationSpace class which implements the interface for interpolated c...
virtual int MaxOrder() override
Returns the max order of interpolation.
virtual const TPZIntPoints & GetIntegrationRule() const override=0
Returns a reference to an integration rule suitable for integrating the interior of the element...
virtual TPZCompEl * ClonePatchEl(TPZCompMesh &mesh, std::map< int64_t, int64_t > &gl2lcConMap, std::map< int64_t, int64_t > &gl2lcElMap) const override
Method for creating a copy of the element in a patch mesh.
TPZReducedSpace()
Default constructor.
virtual int NShapeF() const override
It returns the shapes number of the element.
virtual int NSideConnects(int iside) const override
Returns the number of dof nodes along side iside.
void InitializeElementMatrix(TPZElementMatrix &ek, TPZElementMatrix &ef) override
Initialize element matrix in which is computed CalcStiff.
void Write(TPZStream &buf, int withclassid) const override
Save the element data to a stream.
virtual void ComputeRequiredData(TPZMaterialData &data, TPZVec< REAL > &qsi) override
Compute and fill data with requested attributes.
Abstract class defining integration rules. Numerical Integration.
Definition: tpzintpoints.h:19
int ClassId() const override
Define the class id associated with the class.
virtual void SetPreferredOrder(int order) override
Defines the desired order for entire element.
void Read(TPZStream &buf, void *context) override
Read the element data from a stream.
virtual TPZIntPoints & GetIntegrationRule() override
Returns a reference to an integration rule suitable for integrating the interior of the element...
Defines the behaviour of all geometric elements. GeometryTPZGeoEl is the common denominator for all g...
Definition: pzgeoel.h:43
virtual void ComputeSolution(TPZVec< REAL > &qsi, TPZMaterialData &data) override
#define DebugStop()
Returns a message to user put a breakpoint in.
Definition: pzerror.h:20
virtual ~TPZReducedSpace()
Default destructor.
virtual int64_t ConnectIndex(int i) const override
Returns the index of the ith connectivity of the element.
virtual int SideConnectLocId(int icon, int is) const override
Returns the local node number of icon along is.
This class associates an element matrix with the coeficients of its contribution in the global stiffn...
Definition: pzelmat.h:30
Implements the interfaces for TPZCompElDisc, TPZInterfaceElement and TPZInterpolatedElement. Computational element.
virtual void SetConnectIndex(int inode, int64_t index) override
Set the index i to node inode.
virtual void ComputeShape(TPZVec< REAL > &qsi, TPZMaterialData &data) override
Compute shape functions based on master element in the classical FEM manne.
Implements computational mesh. Computational Mesh.
Definition: pzcmesh.h:47
Defines the interface for saving and reading data. Persistency.
Definition: TPZStream.h:50
virtual TPZCompEl * Clone(TPZCompMesh &mesh) const override
Method for creating a copy of the element.
virtual void BuildCornerConnectList(std::set< int64_t > &connectindexes) const override
adds the connect indexes associated with base shape functions to the set
virtual const TPZIntPoints & GetIntegrationRule() const override
Returns a reference to an integration rule suitable for integrating the interior of the element...
virtual int NConnects() const override
Returns the number of nodes of the element.
static void SetAllCreateFunctionsReducedSpace(TPZCompMesh *cmesh)
Defines the interface of a computational element. Computational Element.
Definition: pzcompel.h:59
virtual void Shape(TPZVec< REAL > &qsi, TPZFMatrix< REAL > &phi, TPZFMatrix< REAL > &dphi) override
Computes the shape function set at the point x.
#define PZError
Defines the output device to error messages and the DebugStop() function.
Definition: pzerror.h:15
virtual int Dimension() const override
Dimension of the element.
virtual void InitMaterialData(TPZMaterialData &data) override
Initialize a material data and its attributes based on element dimension, number of state variables a...