NeoPZ
TPZShapeDisc.cpp
Go to the documentation of this file.
1 
5 #include "TPZShapeDisc.h"
6 #include "pzshapelinear.h"
7 #include "pzreal.h"
8 #include <math.h>
9 #include <stdio.h>
10 #include <stdlib.h>
11 
12 #include <cmath>
13 
14 using namespace std;
15 
17 namespace pzshape {
18 
19  void (*TPZShapeDisc::fOrthogonal)(REAL C, REAL x0, REAL x,int degree, TPZFMatrix<REAL> & phi, TPZFMatrix<REAL> & dphi, int n) = TPZShapeDisc::Polynomial;
20 
21 TPZShapeDisc::TPZShapeDisc(){
22 
23 }
24 
25 TPZShapeDisc::TPZShapeDisc(const TPZShapeDisc &copy){
26 
27 }
28 
29 TPZShapeDisc::~TPZShapeDisc(){
30 
31 }
32 
33 
34 void TPZShapeDisc::IntegratedLegendre(REAL C,REAL x0,REAL x,int degree,TPZFMatrix<REAL> &phi,TPZFMatrix<REAL> &dphi, int n){
35 #ifdef PZDEBUG
36  if(IsZero(C)){
37  DebugStop();
38  }
39 #endif
40  const REAL L = C;
41  if(IsZero(L)){
42  DebugStop();
43  }
44  const REAL b = 2.*(x - x0)/L;
45 
46  if(degree >= 17) DebugStop();
47 
48  REAL shapes[17] = {
49  1,
50  b,
51  pow(b,2)/2.,
52  -b/2. + pow(b,3)/2.,
53  (-3*pow(b,2))/4. + (5*pow(b,4))/8.,
54  (3*b)/8. - (5*pow(b,3))/4. + (7*pow(b,5))/8.,
55  (15*pow(b,2))/16. - (35*pow(b,4))/16. + (21*pow(b,6))/16.,
56  (-5*b)/16. + (35*pow(b,3))/16. - (63*pow(b,5))/16. + (33*pow(b,7))/16.,
57  (-35*pow(b,2))/32. + (315*pow(b,4))/64. - (231*pow(b,6))/32. + (429*pow(b,8))/128.,
58  (35*b)/128. - (105*pow(b,3))/32. + (693*pow(b,5))/64. - (429*pow(b,7))/32. + (715*pow(b,9))/128.,
59  (315*pow(b,2))/256. - (1155*pow(b,4))/128. + (3003*pow(b,6))/128. - (6435*pow(b,8))/256. + (2431*pow(b,10))/256.,
60  (-63*b)/256. + (1155*pow(b,3))/256. - (3003*pow(b,5))/128. + (6435*pow(b,7))/128. - (12155*pow(b,9))/256. + (4199*pow(b,11))/256.,
61  (-693*pow(b,2))/512. + (15015*pow(b,4))/1024. - (15015*pow(b,6))/256. + (109395*pow(b,8))/1024. - (46189*pow(b,10))/512. + (29393*pow(b,12))/1024.,
62  (231*b)/1024. - (3003*pow(b,3))/512. + (45045*pow(b,5))/1024. - (36465*pow(b,7))/256. + (230945*pow(b,9))/1024. - (88179*pow(b,11))/512. + (52003*pow(b,13))/1024.,
63  (3003*pow(b,2))/2048. - (45045*pow(b,4))/2048. + (255255*pow(b,6))/2048. - (692835*pow(b,8))/2048. + (969969*pow(b,10))/2048. - (676039*pow(b,12))/2048. + (185725*pow(b,14))/2048.,
64  (-429*b)/2048. + (15015*pow(b,3))/2048. - (153153*pow(b,5))/2048. + (692835*pow(b,7))/2048. - (1616615*pow(b,9))/2048. + (2028117*pow(b,11))/2048. - (1300075*pow(b,13))/2048. + (334305*pow(b,15))/2048.,
65  (-6435*pow(b,2))/4096. + (255255*pow(b,4))/8192. - (969969*pow(b,6))/4096. + (14549535*pow(b,8))/16384. - (7436429*pow(b,10))/4096. + (16900975*pow(b,12))/8192. -(5014575*pow(b,14))/4096. + (9694845*pow(b,16))/32768.
66  };
67 
68  REAL dshapes[17] = {
69  0,1,b,-0.5 + (3*pow(b,2))/2.,(-3*b)/2. + (5*pow(b,3))/2.,0.375 - (15*pow(b,2))/4. + (35*pow(b,4))/8.,(15*b)/8. - (35*pow(b,3))/4. + (63*pow(b,5))/8.,
70  -0.3125 + (105*pow(b,2))/16. - (315*pow(b,4))/16. + (231*pow(b,6))/16.,(-35*b)/16. + (315*pow(b,3))/16. - (693*pow(b,5))/16. + (429*pow(b,7))/16.,
71  0.2734375 - (315*pow(b,2))/32. + (3465*pow(b,4))/64. - (3003*pow(b,6))/32. + (6435*pow(b,8))/128.,
72  (315*b)/128. - (1155*pow(b,3))/32. + (9009*pow(b,5))/64. - (6435*pow(b,7))/32. + (12155*pow(b,9))/128.,
73  -0.24609375 + (3465*pow(b,2))/256. - (15015*pow(b,4))/128. + (45045*pow(b,6))/128. - (109395*pow(b,8))/256. + (46189*pow(b,10))/256.,
74  (-693*b)/256. + (15015*pow(b,3))/256. - (45045*pow(b,5))/128. + (109395*pow(b,7))/128. - (230945*pow(b,9))/256. + (88179*pow(b,11))/256.,
75  0.2255859375 - (9009*pow(b,2))/512. + (225225*pow(b,4))/1024. - (255255*pow(b,6))/256. + (2078505*pow(b,8))/1024. - (969969*pow(b,10))/512. + (676039*pow(b,12))/1024.,
76  (3003*b)/1024. - (45045*pow(b,3))/512. + (765765*pow(b,5))/1024. - (692835*pow(b,7))/256. + (4849845*pow(b,9))/1024. - (2028117*pow(b,11))/512. + (1300075*pow(b,13))/1024.,
77  -0.20947265625 + (45045*pow(b,2))/2048. - (765765*pow(b,4))/2048. + (4849845*pow(b,6))/2048. - (14549535*pow(b,8))/2048. + (22309287*pow(b,10))/2048. - (16900975*pow(b,12))/2048. +
78  (5014575*pow(b,14))/2048.,(-6435*b)/2048. + (255255*pow(b,3))/2048. - (2909907*pow(b,5))/2048. + (14549535*pow(b,7))/2048. - (37182145*pow(b,9))/2048. + (50702925*pow(b,11))/2048. -
79  (35102025*pow(b,13))/2048. + (9694845*pow(b,15))/2048. };
80 
81  const REAL dbdx = 2./L;
82 
83 
84  if(degree < 0 || n > 1){
85  DebugStop();
86  }
87  phi.Redim(degree+1,1);
88  dphi.Redim(n,degree+1);
89  for(int i = 0; i < degree+1; i++){
90  phi(i,0) = shapes[i];
91  dphi(0,i) = dshapes[i]*dbdx;
92  }
93 
94 }//method
95 
96 void TPZShapeDisc::Polynomial(REAL C,REAL x0,REAL x,int degree,TPZFMatrix<REAL> &phi,TPZFMatrix<REAL> &dphi, int n){
97 #ifdef PZDEBUG
98  if(IsZero(C)){
99  DebugStop();
100  }
101 #endif
102  if(degree < 0){
103  PZError << "TPZShapeDisc::Polynomial the degree of the polynomial cannot be minus, aborting\n";
104  DebugStop();
105  }
106  phi.Redim(degree+1,1);
107  dphi.Redim(n,degree+1);
108  //grau zero ou constante
109  phi(0,0) = 1.0;
110  if(degree == 0) return;
111  //grau 1
112  REAL val = (x-x0)/C;
113  phi(1,0) = val;
114  dphi(0,1) = 1./C;
115  //grau maior que 1
116  int p;
117  degree++;
118  for(p = 2;p < degree; p++) {
119  phi(p,0) = phi(p-1,0)*val;
120  int ideriv;
121  dphi(0,p) = dphi(0,p-1)*val+phi(p-1,0)/C;
122  for(ideriv=2; ideriv<=n; ideriv++) {
123  dphi(ideriv-1,p) = val*dphi(ideriv-1,p-1)+(ideriv/C)*dphi(ideriv-2,p-1);
124  }
125  }
126 }
127 
128 void TPZShapeDisc::PolynomialWithoutScale(REAL C,REAL x0,REAL x,int degree,TPZFMatrix<REAL> & phi,TPZFMatrix<REAL> & dphi, int n){
129 #ifdef PZDEBUG
130  if(IsZero(C)){
131  DebugStop();
132  }
133 #endif
134  if(degree < 0){
135  PZError << "TPZShapeDisc::Polynomial the degree of the polynomial cannot be minus, aborting\n";
136  DebugStop();
137  }
138  phi.Redim(degree+1,1);
139  dphi.Redim(n,degree+1);
140  //grau zero ou constante
141  phi(0,0) = 1.0;
142  if(degree == 0) return;
143  //grau 1
144  REAL val = x;
145  phi(1,0) = val;
146  dphi(0,1) = 1.;
147  //grau maior que 1
148  int p;
149  degree++;
150  for(p = 2;p < degree; p++) {
151  phi(p,0) = phi(p-1,0)*val;
152  int ideriv;
153  dphi(0,p) = dphi(0,p-1)*val + phi(p-1,0)* 1.0;
154  for(ideriv=2; ideriv<=n; ideriv++) {
155  dphi(ideriv-1,p) = val*dphi(ideriv-1,p-1)+(ideriv)*dphi(ideriv-2,p-1);
156  }
157  }
158 }
159 
160 void TPZShapeDisc::Legendre(REAL C,REAL x0,REAL x,int degree,TPZFMatrix<REAL> & phi,TPZFMatrix<REAL> & dphi, int n){
161 #ifdef PZDEBUG
162  if(IsZero(C)){
163  DebugStop();
164  }
165 #endif
166 
167  x = (x - x0) / C;
168  phi.Redim(degree+1,1);
169  dphi.Redim(n,degree+1);
170 
171  TPZShapeLinear::Legendre(x, degree+1, phi, dphi, n);
172 
173  REAL val;
174  for(int ord = 0; ord < degree+1; ord++)
175  for (int ideriv = 0; ideriv < n; ideriv++){
176  val = dphi(ideriv, ord) / pow(C, ideriv+1);
177  dphi.Put(ideriv, ord, val);
178  }
179 
180 } //end of method
181 
182 void TPZShapeDisc::ChebyshevWithoutScale(REAL C,REAL x0,REAL x,int degree,TPZFMatrix<REAL> & phi,TPZFMatrix<REAL> & dphi, int n){
183 #ifdef PZDEBUG
184  if(IsZero(C)){
185  DebugStop();
186  }
187 #endif
188 
189  phi.Redim(degree+1,1);
190  dphi.Redim(n,degree+1);
191 
192  TPZShapeLinear::Chebyshev(x, degree+1, phi, dphi);
193 
194 } //end of method
195 
196 
197 void TPZShapeDisc::LegendreWithoutScale(REAL C,REAL x0,REAL x,int degree,TPZFMatrix<REAL> & phi,TPZFMatrix<REAL> & dphi, int n){
198 #ifdef PZDEBUG
199  if(IsZero(C)){
200  DebugStop();
201  }
202 #endif
203 
204  phi.Redim(degree+1,1);
205  dphi.Redim(n,degree+1);
206 
207  TPZShapeLinear::Legendre(x, degree+1, phi, dphi, n);
208 
209 } //end of method
210 
212  switch (dimension){
213  case(0) :{
214  TPZShapeDisc::Shape0D(C,X0,X,degree,phi,dphi);
215  break;
216  }
217  case(1) : {
218  TPZShapeDisc::Shape1D(C,X0,X,degree,phi,dphi);
219  break;
220  }
221  case(2) : {
222  if(type == ETensorial || type == EOrdemTotal){
223  TPZShapeDisc::Shape2D(C,X0,X,degree,phi,dphi,type);
224  }
225  else{
226  TPZShapeDisc::Shape2DFull(C,X0,X,degree,phi,dphi,type);
227  }
228  break;
229  }
230  case(3) : {
231  TPZShapeDisc::Shape3D(C,X0,X,degree,phi,dphi,type);
232  break;
233  }
234  default:{
235  PZError << "\nFATAL ERROR at " << __PRETTY_FUNCTION__ << "\n";
236  PZError.flush();
237  DebugStop();
238  }
239  }
240 }
241 
243  {
244  REAL C=1;//fator de escala utilizado neste metodo
245  TPZManVector<REAL,3> X0(3,0.);//centro do elemento
246 
247  if(type == ETensorial ||type == EOrdemTotal){
248  TPZShapeDisc::Shape2D(C,X0,X,degree,phi,dphi,type);
249  }
250  else {
251  std::cout<<"Not implement"<<std::endl;
252  DebugStop();
253  }
254 
255 
256 
257  }
258 
259 
260 
261 
262 void TPZShapeDisc::Shape0D(REAL C,TPZVec<REAL> &X0,TPZVec<REAL> &X,int degree,TPZFMatrix<REAL> &phi,TPZFMatrix<REAL> &dphi){
263 
264  if(degree < 0){
265  PZError << "TPZShapeDisc::Polynomial the degree of the polynomial cannot be minus, aborting\n";
266  DebugStop();
267  }
268  int cap = degree+1;
269  phi.Redim(cap,1);
270  for(int i=0;i<cap;i++) phi.PutVal(i,0,1.0);//funÔøΩ unitÔøΩia
271  dphi.Redim(0,0);//nÔøΩ existe a derivada em um ponto: dimensÔøΩ nula
272 }
273 
274 void TPZShapeDisc::Shape1D(REAL C,TPZVec<REAL> &X0,TPZVec<REAL> &X,int degree,TPZFMatrix<REAL> &phi,TPZFMatrix<REAL> &dphi){
275 
276  //suponha a componente nÔøΩ nula sendo a primeira
277  REAL x0 = X0[0];
278  REAL x = X[0];
279 
280  fOrthogonal(C,x0,x,degree,phi,dphi,1);
281 
282 }
283 
284 void TPZShapeDisc::Shape2D(REAL C,TPZVec<REAL> &X0,TPZVec<REAL> &X,int degree,TPZFMatrix<REAL> &phi,TPZFMatrix<REAL> &dphi, MShapeType type){
285 
286  if(degree == 0) {
287  phi(0,0) = 1.;
288  dphi(0,0) = 0.;
289  dphi(1,0) = 0.;
290  return;
291  }
292  REAL x0 = X0[0];
293  REAL y0 = X0[1];
294  REAL x = X[0];
295  REAL y = X[1];
296 
297  TPZFNMatrix<660> phix,phiy,dphix,dphiy;
298 
299  fOrthogonal(C,x0,x,degree,phix,dphix,1);
300  fOrthogonal(C,y0,y,degree,phiy,dphiy,1);
301 
302  int i, j, ix, iy, counter=0, num = degree+1;
303 
304  int nshape = NShapeF(degree,2,type);
305 // int count=num,ind=0;
306  phi.Redim(nshape,1);
307  dphi.Redim(2,nshape);
308  phi.Zero();
309  dphi.Zero();
310 
311  if(type==EOrdemTotal)
312  {
313  //mounts the shape function according to the max order:
314  // ____
315  // |///
316  // |//
317  // |/
318 
319  for(i = 0; i <= degree; i++)
320  {
321  for(j = 0; j <= i; j++)
322  {
323  // notice that ix+iy is always constant for given i
324  ix = j;
325  iy = i - j;
326  phi(counter,0) = phix(ix,0)*phiy(iy,0);
327  dphi(0,counter) = dphix(0,ix)*phiy(iy,0);
328  dphi(1,counter) = phix(ix,0)*dphiy(0,iy);
329  counter++;
330  }
331  }
332  }else{
333  // mounts the shape functions according to each
334  // direction order
335  // The functions are assembled in this sequence:
336  // x functions, y functions, max xy
337  // (horizontal, vertical lines and the 0 in the graph)
338  // _____
339  // |0|||
340  // |-0||
341  // |--0|
342  // |---0
343  // type == ETensorial
344  for(i=0;i<num;i++)
345  {
346  for(j=0;j<i;j++)
347  {
348  ix = j;
349  iy = i;
350  phi(counter,0) = phix(ix,0)*phiy(iy,0);
351  dphi(0,counter) = dphix(0,ix)*phiy(iy,0);
352  dphi(1,counter) = phix(ix,0)*dphiy(0,iy);
353  counter++;
354  }
355  for(j=0;j<i;j++)
356  {
357  ix = i;
358  iy = j;
359  phi(counter,0) = phix(ix,0)*phiy(iy,0);
360  dphi(0,counter) = dphix(0,ix)*phiy(iy,0);
361  dphi(1,counter) = phix(ix,0)*dphiy(0,iy);
362  counter++;
363  }
364 
365  ix = i;
366  iy = i;
367  phi(counter,0) = phix(ix,0)*phiy(iy,0);
368  dphi(0,counter) = dphix(0,ix)*phiy(iy,0);
369  dphi(1,counter) = phix(ix,0)*dphiy(0,iy);
370  counter++;
371  }
372  }
373 
374  if(counter != nshape) {
375  PZError << "TPZShapeDisc::Shape2D wrong shape count\n";
376  }
377  REAL phi0,dphi0[2];
378  phi0 = phi(0,0);//here
379  dphi0[0] = dphi(0,0);
380  dphi0[1] = dphi(1,0);
381  phi(0,0) = phi(nshape-1,0);//here
382  dphi(0,0) = dphi(0,nshape-1);
383  dphi(1,0) = dphi(1,nshape-1);
384 
385  phi(nshape-1,0) = phi0;//here
386  dphi(0,nshape-1) = dphi0[0];
387  dphi(1,nshape-1) = dphi0[1];
388 }
389 
390 void TPZShapeDisc::Shape3D(REAL C,TPZVec<REAL> &X0,TPZVec<REAL> &X,int degree,TPZFMatrix<REAL> &phi,TPZFMatrix<REAL> &dphi, MShapeType type){
391 
392  REAL x0 = X0[0];
393  REAL y0 = X0[1];
394  REAL z0 = X0[2];
395  REAL x = X[0];
396  REAL y = X[1];
397  REAL z = X[2];
398 
399  TPZFNMatrix<1000> phix,phiy,phiz,dphix,dphiy,dphiz;
400 
401  fOrthogonal(C,x0,x,degree,phix,dphix,1);
402  fOrthogonal(C,y0,y,degree,phiy,dphiy,1);
403  fOrthogonal(C,z0,z,degree,phiz,dphiz,1);
404 
405  int i,j,k,nshape = 0,num=degree+1, counter=0;
406  //for(i=0;i<num;i++) nshape += (i+1)*(i+2)/2;
407  nshape = NShapeF(degree,3,type);
408 // int count=num,ind=0;
409  phi.Redim(nshape,1);
410  dphi.Redim(3,nshape);
411  phi.Zero();
412  dphi.Zero();
413 
414  //function value
415  for(i=0;i<num;i++){
416  for(j=0;j<num;j++){
417  if(i+j > degree && type == EOrdemTotal) break;
418  for(k=0;k<num;k++){
419  if(i+j+k > degree && type == EOrdemTotal) break;
420  phi(counter,0) = phix(i,0)*phiy(j,0)*phiz(k,0);
421  dphi(0, counter) = dphix(0,i)*phiy(j,0)*phiz(k,0);
422  dphi(1, counter ) = phix(i,0)*dphiy(0,j)*phiz(k,0);
423  dphi(2, counter ) = phix(i,0)*phiy(j,0)*dphiz(0,k);
424  counter++;
425  }
426  }
427  }
428 
429  REAL phi0,dphi0[3];
430  phi0 = phi(0);
431  dphi0[0] = dphi(0,0);
432  dphi0[1] = dphi(1,0);
433  dphi0[2] = dphi(2,0);
434  phi(0) = phi(nshape-1);
435  dphi(0,0) = dphi(0,nshape-1);
436  dphi(1,0) = dphi(1,nshape-1);
437  dphi(2,0) = dphi(2,nshape-1);
438 
439  phi(nshape-1) = phi0;
440  dphi(0,nshape-1) = dphi0[0];
441  dphi(1,nshape-1) = dphi0[1];
442  dphi(2,nshape-1) = dphi0[2];
443 
444 }
445 
446 
447 void TPZShapeDisc::Shape2DFull(REAL C,TPZVec<REAL> &X0,TPZVec<REAL> &X,int degree,TPZFMatrix<REAL> &phi,TPZFMatrix<REAL> &dphi, MShapeType type){
448 
449  REAL x0 = X0[0];
450  REAL y0 = X0[1];
451  REAL x = X[0];
452  REAL y = X[1];
453 
454 
455  TPZFNMatrix<30> phix(degree+1,1),phiy(degree+1,1),dphix(3,degree+1),dphiy(3,degree+1);
456 
457  fOrthogonal(C,x0,x,degree,phix,dphix,3);
458  fOrthogonal(C,y0,y,degree,phiy,dphiy,3);
459 
460  int i,j,counter=0,num = degree+1;
461 
462  int nshape = NShapeF(degree,2,type);
463 // int count=num,ind=0;
464  phi.Redim(nshape,1);
465  dphi.Redim(8,nshape);
466  phi.Zero();
467  dphi.Zero();
468 
469  //valor da fun�o
470  for(i=0;i<num;i++){
471  for(j=0;j<num;j++){
472  if(i+j > degree && type == EOrdemTotalFull) break;
473  phi(counter,0) = phix(i,0)*phiy(j,0);
474  dphi(0,counter) = dphix(0,i)* phiy(j,0); // dx
475  dphi(1,counter) = phix(i,0)*dphiy(0,j); // dy
476  dphi(2,counter) = dphix(1,i)* phiy(j,0)+ phix(i,0)*dphiy(1,j); // Laplaciano
477  dphi(3,counter) = dphix(2,i)* phiy(j,0)+dphix(0,i)*dphiy(1,j); // D/Dx Laplaciano
478  dphi(4,counter) = dphix(1,i)*dphiy(0,j)+ phix(i,0)*dphiy(2,j); // D/Dy Laplaciano
479  dphi(5,counter) = dphix(1,i)* phiy(j,0); // dxx
480  dphi(6,counter) = phix(i,0)*dphiy(1,j); // dyy
481  dphi(7,counter) = dphix(0,i)*dphiy(0,j); // dxy
482  counter++;
483  }
484  }
485  if(counter != nshape) {
486  PZError << "TPZShapeDisc::Shape2D wrong shape count\n";
487  }
488  REAL phi0,dphi0[8];
489  phi0 = phi(0);
490  for(i=0; i<8; i++) dphi0[i] = dphi(i,0);
491  phi(0) = phi(nshape-1);
492  for(i=0; i<8; i++) dphi(i,0) = dphi(i,nshape-1);
493 
494  phi(nshape-1) = phi0;
495  for(i=0; i<8; i++) dphi(i,nshape-1) = dphi0[i];
496 }
497 
498 int TPZShapeDisc::NShapeF(int degree, int dimension, MShapeType type) {
499  int sum =0,i;
500  switch(dimension) {
501  case 0:
502  return 1;
503  case 1:
504  return degree+1;
505 // break;
506  case 2:
507  if(type == ETensorial || type == ETensorialFull) return (degree+1)*(degree+1);
508  else return (degree+1)*(degree+2)/2;
509 // break;
510  case 3:
511  if(type == ETensorial || type == ETensorialFull) return (degree+1)*(degree+1)*(degree+1);
512  for(i=0;i<(degree+1);i++) sum += (i+1)*(i+2)/2;
513  return sum;
514  // break;
515  default:
516  PZError << "TPZShapeDisc::NShapeF case does not exists\n";
517  return -1;
518  }
519 // return -1;
520 }
521 
522 };
bool IsZero(long double a)
Returns if the value a is close Zero as the allowable tolerance.
Definition: pzreal.h:668
clarg::argInt dimension("-d", "Matrices dimension M x M", 1000)
groups all classes dedicated to the computation of shape functions
Definition: pzshapeextend.h:16
void degree(int root, int adj_num, int adj_row[], int adj[], int mask[], int deg[], int *iccsze, int ls[], int node_num)
Definition: rcm.cpp:875
REAL val(STATE &number)
Returns value of the variable.
Definition: pzartdiff.h:23
Contains TPZShapeLinear class which implements the shape functions of a linear one-dimensional elemen...
int Zero() override
Makes Zero all the elements.
Definition: pzfmatrix.h:651
#define DebugStop()
Returns a message to user put a breakpoint in.
Definition: pzerror.h:20
void Shape(TPZVec< REAL > &pt, TPZVec< int > orders, TPZVec< TPZTransform< REAL > > &transvec, TPZFMatrix< REAL > &phi, TPZFMatrix< REAL > &dphi)
virtual int Put(const int64_t row, const int64_t col, const TVar &value)
Put values with bounds checking if DEBUG variable is defined.
Definition: pzmatrix.h:836
int Redim(const int64_t newRows, const int64_t newCols) override
Redimension a matrix and ZERO your elements.
Definition: pzfmatrix.h:616
TPZFlopCounter pow(const TPZFlopCounter &orig, const TPZFlopCounter &xp)
Returns the power and increments the counter of the power.
Definition: pzreal.h:487
Contains the declaration of the shape function discontinuous.
Contains the declaration of TPZFlopCounter class and TPZCounter struct.
Implements the shape functions discontinuous elements. Shape.
Definition: TPZShapeDisc.h:25
int PutVal(const int64_t row, const int64_t col, const TVar &value) override
Put values without bounds checking This method is faster than "Put" if DEBUG is defined.
Definition: pzfmatrix.h:548
Non abstract class which implements full matrices with preallocated storage with (N+1) entries...
Definition: pzfmatrix.h:716
#define PZError
Defines the output device to error messages and the DebugStop() function.
Definition: pzerror.h:15