26 #ifndef MFEM_THREAD_SAFE 34 for (
int i = 1; i <
p; i++)
45 #ifdef MFEM_THREAD_SAFE 51 shape(0) = shape_x(0);
52 shape(1) = shape_x(
p);
53 for (
int i = 1; i <
p; i++)
55 shape(i+1) = shape_x(i);
64 #ifdef MFEM_THREAD_SAFE 70 dshape(0,0) = dshape_x(0);
71 dshape(1,0) = dshape_x(
p);
72 for (
int i = 1; i <
p; i++)
74 dshape(i+1,0) = dshape_x(i);
83 #ifdef MFEM_THREAD_SAFE 84 Vector shape_x(
p+1), dshape_x(
p+1), d2shape_x(
p+1);
89 Hessian(0,0) = d2shape_x(0);
90 Hessian(1,0) = d2shape_x(
p);
91 for (
int i = 1; i <
p; i++)
93 Hessian(i+1,0) = d2shape_x(i);
107 for (
int i = 1; i <
p; i++)
116 for (
int i = 1; i <
p; i++)
130 #ifndef MFEM_THREAD_SAFE 131 const int p1 =
p + 1;
142 for (
int j = 0; j <=
p; j++)
144 for (
int i = 0; i <=
p; i++)
156 #ifdef MFEM_THREAD_SAFE 163 for (
int o = 0, j = 0; j <=
p; j++)
164 for (
int i = 0; i <=
p; i++)
166 shape(
dof_map[o++]) = shape_x(i)*shape_y(j);
175 #ifdef MFEM_THREAD_SAFE 176 Vector shape_x(
p+1), shape_y(
p+1), dshape_x(
p+1), dshape_y(
p+1);
182 for (
int o = 0, j = 0; j <=
p; j++)
184 for (
int i = 0; i <=
p; i++)
186 dshape(
dof_map[o],0) = dshape_x(i)* shape_y(j);
187 dshape(
dof_map[o],1) = shape_x(i)*dshape_y(j); o++;
197 #ifdef MFEM_THREAD_SAFE 198 Vector shape_x(
p+1), shape_y(
p+1), dshape_x(
p+1), dshape_y(
p+1),
199 d2shape_x(
p+1), d2shape_y(
p+1);
205 for (
int o = 0, j = 0; j <=
p; j++)
207 for (
int i = 0; i <=
p; i++)
209 Hessian(
dof_map[o],0) = d2shape_x(i)* shape_y(j);
210 Hessian(
dof_map[o],1) = dshape_x(i)* dshape_y(j);
211 Hessian(
dof_map[o],2) = shape_x(i)*d2shape_y(j); o++;
221 #ifdef MFEM_THREAD_SAFE 225 for (
int i = 0; i <=
p; i++)
234 for (
int o = 0, j = 0; j <=
p; j++)
235 for (
int i = 0; i <=
p; i++)
237 dofs(
dof_map[o++]) = shape_x(i)*shape_x(j);
241 for (
int o = 0, j = 0; j <=
p; j++)
242 for (
int i = 0; i <=
p; i++)
244 dofs(
dof_map[o++]) = shape_y(i)*shape_x(j);
248 for (
int o = 0, j = 0; j <=
p; j++)
249 for (
int i = 0; i <=
p; i++)
251 dofs(
dof_map[o++]) = shape_y(i)*shape_y(j);
255 for (
int o = 0, j = 0; j <=
p; j++)
256 for (
int i = 0; i <=
p; i++)
258 dofs(
dof_map[o++]) = shape_x(i)*shape_y(j);
270 #ifndef MFEM_THREAD_SAFE 271 const int p1 =
p + 1;
285 for (
int k = 0; k <=
p; k++)
286 for (
int j = 0; j <=
p; j++)
287 for (
int i = 0; i <=
p; i++)
298 #ifdef MFEM_THREAD_SAFE 299 Vector shape_x(
p+1), shape_y(
p+1), shape_z(
p+1);
306 for (
int o = 0, k = 0; k <=
p; k++)
307 for (
int j = 0; j <=
p; j++)
308 for (
int i = 0; i <=
p; i++)
310 shape(
dof_map[o++]) = shape_x(i)*shape_y(j)*shape_z(k);
319 #ifdef MFEM_THREAD_SAFE 320 Vector shape_x(
p+1), shape_y(
p+1), shape_z(
p+1);
321 Vector dshape_x(
p+1), dshape_y(
p+1), dshape_z(
p+1);
328 for (
int o = 0, k = 0; k <=
p; k++)
329 for (
int j = 0; j <=
p; j++)
330 for (
int i = 0; i <=
p; i++)
332 dshape(
dof_map[o],0) = dshape_x(i)* shape_y(j)* shape_z(k);
333 dshape(
dof_map[o],1) = shape_x(i)*dshape_y(j)* shape_z(k);
334 dshape(
dof_map[o],2) = shape_x(i)* shape_y(j)*dshape_z(k); o++;
343 #ifdef MFEM_THREAD_SAFE 344 Vector shape_x(
p+1), shape_y(
p+1), shape_z(
p+1);
345 Vector dshape_x(
p+1), dshape_y(
p+1), dshape_z(
p+1);
346 Vector d2shape_x(
p+1), d2shape_y(
p+1), d2shape_z(
p+1);
353 for (
int o = 0, k = 0; k <=
p; k++)
354 for (
int j = 0; j <=
p; j++)
355 for (
int i = 0; i <=
p; i++)
357 Hessian(
dof_map[o],0) = d2shape_x(i)* shape_y(j)* shape_z(k);
358 Hessian(
dof_map[o],1) = dshape_x(i)* dshape_y(j)* shape_z(k);
359 Hessian(
dof_map[o],2) = dshape_x(i)* shape_y(j)* dshape_z(k);
360 Hessian(
dof_map[o],3) = shape_x(i)*d2shape_y(j)* shape_z(k);
361 Hessian(
dof_map[o],4) = shape_x(i)* dshape_y(j)* dshape_z(k);
362 Hessian(
dof_map[o],5) = shape_x(i)* shape_y(j)*d2shape_z(k);
372 #ifdef MFEM_THREAD_SAFE 376 for (
int i = 0; i <=
p; i++)
385 for (
int o = 0, k = 0; k <=
p; k++)
386 for (
int j = 0; j <=
p; j++)
387 for (
int i = 0; i <=
p; i++)
389 dofs(
dof_map[o++]) = shape_x(i)*shape_x(j)*shape_x(k);
393 for (
int o = 0, k = 0; k <=
p; k++)
394 for (
int j = 0; j <=
p; j++)
395 for (
int i = 0; i <=
p; i++)
397 dofs(
dof_map[o++]) = shape_y(i)*shape_x(j)*shape_x(k);
401 for (
int o = 0, k = 0; k <=
p; k++)
402 for (
int j = 0; j <=
p; j++)
403 for (
int i = 0; i <=
p; i++)
405 dofs(
dof_map[o++]) = shape_y(i)*shape_y(j)*shape_x(k);
409 for (
int o = 0, k = 0; k <=
p; k++)
410 for (
int j = 0; j <=
p; j++)
411 for (
int i = 0; i <=
p; i++)
413 dofs(
dof_map[o++]) = shape_x(i)*shape_y(j)*shape_x(k);
417 for (
int o = 0, k = 0; k <=
p; k++)
418 for (
int j = 0; j <=
p; j++)
419 for (
int i = 0; i <=
p; i++)
421 dofs(
dof_map[o++]) = shape_x(i)*shape_x(j)*shape_y(k);
425 for (
int o = 0, k = 0; k <=
p; k++)
426 for (
int j = 0; j <=
p; j++)
427 for (
int i = 0; i <=
p; i++)
429 dofs(
dof_map[o++]) = shape_y(i)*shape_x(j)*shape_y(k);
433 for (
int o = 0, k = 0; k <=
p; k++)
434 for (
int j = 0; j <=
p; j++)
435 for (
int i = 0; i <=
p; i++)
437 dofs(
dof_map[o++]) = shape_y(i)*shape_y(j)*shape_y(k);
441 for (
int o = 0, k = 0; k <=
p; k++)
442 for (
int j = 0; j <=
p; j++)
443 for (
int i = 0; i <=
p; i++)
445 dofs(
dof_map[o++]) = shape_x(i)*shape_y(j)*shape_y(k);
457 #ifndef MFEM_THREAD_SAFE 471 Vector shape_x(
p + 1), shape_y(
p + 1), shape_l(
p + 1);
475 auto idx = [p2p3](
int i,
int j) {
return ((p2p3-j)*j)/2+i; };
488 for (
int i = 1; i <
p; i++)
493 for (
int i = 1; i <
p; i++)
498 for (
int i = 1; i <
p; i++)
505 for (
int j = 1; j <
p; j++)
506 for (
int i = 1; i + j <
p; i++)
508 const double w = cp[i] + cp[j] + cp[
p-i-j];
514 for (
int k = 0; k <
dof; k++)
522 for (
int j = 0; j <=
p; j++)
523 for (
int i = 0; i + j <=
p; i++)
525 T(o++, k) = shape_x(i)*shape_y(j)*shape_l(
p-i-j);
538 #ifdef MFEM_THREAD_SAFE 539 Vector shape_x(
p + 1), shape_y(
p + 1), shape_l(
p + 1), u(
dof);
546 for (
int o = 0, j = 0; j <=
p; j++)
547 for (
int i = 0; i + j <=
p; i++)
549 u(o++) = shape_x(i)*shape_y(j)*shape_l(
p-i-j);
560 #ifdef MFEM_THREAD_SAFE 561 Vector shape_x(
p + 1), shape_y(
p + 1), shape_l(
p + 1);
562 Vector dshape_x(
p + 1), dshape_y(
p + 1), dshape_l(
p + 1);
570 for (
int o = 0, j = 0; j <=
p; j++)
571 for (
int i = 0; i + j <=
p; i++)
574 du(o,0) = ((dshape_x(i)* shape_l(k)) -
575 ( shape_x(i)*dshape_l(k)))*shape_y(j);
576 du(o,1) = ((dshape_y(j)* shape_l(k)) -
577 ( shape_y(j)*dshape_l(k)))*shape_x(i);
588 #ifdef MFEM_THREAD_SAFE 589 Vector shape_x(
p + 1), shape_y(
p + 1), shape_l(
p + 1);
590 Vector dshape_x(
p + 1), dshape_y(
p + 1), dshape_l(
p + 1);
591 Vector ddshape_x(
p + 1), ddshape_y(
p + 1), ddshape_l(
p + 1);
599 for (
int o = 0, j = 0; j <=
p; j++)
600 for (
int i = 0; i + j <=
p; i++)
604 ddu(o,0) = ((ddshape_x(i) * shape_l(k)) - 2. * (dshape_x(i) * dshape_l(k)) +
605 (shape_x(i) * ddshape_l(k))) * shape_y(j);
606 ddu(o,1) = (((shape_x(i) * ddshape_l(k)) - dshape_x(i) * dshape_l(k)) * shape_y(
607 j)) + (((dshape_x(i) * shape_l(k)) - (shape_x(i) * dshape_l(k))) * dshape_y(j));
608 ddu(o,2) = ((ddshape_y(j) * shape_l(k)) - 2. * (dshape_y(j) * dshape_l(k)) +
609 (shape_y(j) * ddshape_l(k))) * shape_x(i);
613 Ti.
Mult(ddu, ddshape);
623 #ifndef MFEM_THREAD_SAFE 640 Vector shape_x(
p + 1), shape_y(
p + 1), shape_z(
p + 1), shape_l(
p + 1);
643 auto tri = [](
int k) {
return (k*(k + 1))/2; };
644 auto tet = [](
int k) {
return (k*(k + 1)*(k + 2))/6; };
646 auto idx = [tri, tet,
p, ndof](
int i,
int j,
int k)
648 return ndof - tet(
p - k) - tri(
p + 1 - k - j) + i;
665 for (
int i = 1; i <
p; i++)
670 for (
int i = 1; i <
p; i++)
675 for (
int i = 1; i <
p; i++)
680 for (
int i = 1; i <
p; i++)
685 for (
int i = 1; i <
p; i++)
690 for (
int i = 1; i <
p; i++)
697 for (
int j = 1; j <
p; j++)
698 for (
int i = 1; i + j <
p; i++)
701 double w = cp[i] + cp[j] + cp[
p-i-j];
704 for (
int j = 1; j <
p; j++)
705 for (
int i = 1; i + j <
p; i++)
708 double w = cp[i] + cp[j] + cp[
p-i-j];
711 for (
int j = 1; j <
p; j++)
712 for (
int i = 1; i + j <
p; i++)
715 double w = cp[i] + cp[j] + cp[
p-i-j];
718 for (
int j = 1; j <
p; j++)
719 for (
int i = 1; i + j <
p; i++)
722 double w = cp[i] + cp[j] + cp[
p-i-j];
727 for (
int k = 1; k <
p; k++)
728 for (
int j = 1; j + k <
p; j++)
729 for (
int i = 1; i + j + k <
p; i++)
732 double w = cp[i] + cp[j] + cp[k] + cp[
p-i-j-k];
737 for (
int m = 0; m <
dof; m++)
746 for (
int k = 0; k <=
p; k++)
747 for (
int j = 0; j + k <=
p; j++)
748 for (
int i = 0; i + j + k <=
p; i++)
750 T(o++, m) = shape_x(i)*shape_y(j)*shape_z(k)*shape_l(
p-i-j-k);
763 #ifdef MFEM_THREAD_SAFE 764 Vector shape_x(
p + 1), shape_y(
p + 1), shape_z(
p + 1), shape_l(
p + 1);
773 for (
int o = 0, k = 0; k <=
p; k++)
774 for (
int j = 0; j + k <=
p; j++)
775 for (
int i = 0; i + j + k <=
p; i++)
777 u(o++) = shape_x(i)*shape_y(j)*shape_z(k)*shape_l(
p-i-j-k);
788 #ifdef MFEM_THREAD_SAFE 789 Vector shape_x(
p + 1), shape_y(
p + 1), shape_z(
p + 1), shape_l(
p + 1);
790 Vector dshape_x(
p + 1), dshape_y(
p + 1), dshape_z(
p + 1), dshape_l(
p + 1);
799 for (
int o = 0, k = 0; k <=
p; k++)
800 for (
int j = 0; j + k <=
p; j++)
801 for (
int i = 0; i + j + k <=
p; i++)
803 int l =
p - i - j - k;
804 du(o,0) = ((dshape_x(i)* shape_l(l)) -
805 ( shape_x(i)*dshape_l(l)))*shape_y(j)*shape_z(k);
806 du(o,1) = ((dshape_y(j)* shape_l(l)) -
807 ( shape_y(j)*dshape_l(l)))*shape_x(i)*shape_z(k);
808 du(o,2) = ((dshape_z(k)* shape_l(l)) -
809 ( shape_z(k)*dshape_l(l)))*shape_x(i)*shape_y(j);
821 #ifdef MFEM_THREAD_SAFE 822 Vector shape_x(
p + 1), shape_y(
p + 1), shape_z(
p + 1), shape_l(
p + 1);
823 Vector dshape_x(
p + 1), dshape_y(
p + 1), dshape_z(
p + 1), dshape_l(
p + 1);
824 Vector ddshape_x(
p + 1), ddshape_y(
p + 1), ddshape_z(
p + 1), ddshape_l(
p + 1);
833 for (
int o = 0, k = 0; k <=
p; k++)
834 for (
int j = 0; j + k <=
p; j++)
835 for (
int i = 0; i + j + k <=
p; i++)
838 int l =
p - i - j - k;
839 ddu(o,0) = ((ddshape_x(i) * shape_l(l)) - 2. * (dshape_x(i) * dshape_l(l)) +
840 (shape_x(i) * ddshape_l(l))) * shape_y(j) * shape_z(k);
841 ddu(o,1) = ((dshape_y(j) * ((dshape_x(i) * shape_l(l)) -
842 (shape_x(i) * dshape_l(l)))) +
843 (shape_y(j) * ((ddshape_l(l) * shape_x(i)) -
844 (dshape_x(i) * dshape_l(l)))))* shape_z(k);
845 ddu(o,2) = ((dshape_z(k) * ((dshape_x(i) * shape_l(l)) -
846 (shape_x(i) * dshape_l(l)))) +
847 (shape_z(k) * ((ddshape_l(l) * shape_x(i)) -
848 (dshape_x(i) * dshape_l(l)))))* shape_y(j);
849 ddu(o,3) = ((ddshape_y(j) * shape_l(l)) - 2. * (dshape_y(j) * dshape_l(l)) +
850 (shape_y(j) * ddshape_l(l))) * shape_x(i) * shape_z(k);
851 ddu(o,4) = ((dshape_z(k) * ((dshape_y(j) * shape_l(l)) -
852 (shape_y(j)*dshape_l(l))) ) +
853 (shape_z(k)* ((ddshape_l(l)*shape_y(j)) -
854 (dshape_y(j) * dshape_l(l)) ) ) )* shape_x(i);
855 ddu(o,5) = ((ddshape_z(k) * shape_l(l)) - 2. * (dshape_z(k) * dshape_l(l)) +
856 (shape_z(k) * ddshape_l(l))) * shape_y(j) * shape_x(i);
859 Ti.
Mult(ddu, ddshape);
870 #ifndef MFEM_THREAD_SAFE 880 int p2p3 = 2*
p + 3, ntri = ((
p + 1)*(
p + 2))/2;
881 auto idx = [p2p3,ntri](
int i,
int j,
int k)
883 return k*ntri + ((p2p3-j)*j)/2+i;
896 t_dof[0] = 0; s_dof[0] = 0;
897 t_dof[1] = 1; s_dof[1] = 0;
898 t_dof[2] = 2; s_dof[2] = 0;
899 t_dof[3] = 0; s_dof[3] = 1;
900 t_dof[4] = 1; s_dof[4] = 1;
901 t_dof[5] = 2; s_dof[5] = 1;
906 for (
int i=1; i<
p; i++)
917 t_dof[5 + 0 * ne + i] = 2 + 0 * ne + i; s_dof[5 + 0 * ne + i] = 0;
918 t_dof[5 + 1 * ne + i] = 2 + 1 * ne + i; s_dof[5 + 1 * ne + i] = 0;
919 t_dof[5 + 2 * ne + i] = 2 + 2 * ne + i; s_dof[5 + 2 * ne + i] = 0;
920 t_dof[5 + 3 * ne + i] = 2 + 0 * ne + i; s_dof[5 + 3 * ne + i] = 1;
921 t_dof[5 + 4 * ne + i] = 2 + 1 * ne + i; s_dof[5 + 4 * ne + i] = 1;
922 t_dof[5 + 5 * ne + i] = 2 + 2 * ne + i; s_dof[5 + 5 * ne + i] = 1;
923 t_dof[5 + 6 * ne + i] = 0; s_dof[5 + 6 * ne + i] = i + 1;
924 t_dof[5 + 7 * ne + i] = 1; s_dof[5 + 7 * ne + i] = i + 1;
925 t_dof[5 + 8 * ne + i] = 2; s_dof[5 + 8 * ne + i] = i + 1;
932 int nt = (
p-1)*(
p-2)/2;
933 for (
int j=1; j<
p; j++)
935 for (
int i=1; i<
p-j; i++)
937 int l = j -
p + (((2 *
p - 1) - i) * i) / 2;
940 t_dof[6 + 9 * ne + k] = 3 *
p + l; s_dof[6 + 9 * ne + k] = 0;
941 t_dof[6 + 9 * ne + nt + k] = 3 *
p + k; s_dof[6 + 9 * ne + nt + k] = 1;
949 int nq = (
p-1)*(
p-1);
950 for (
int j=1; j<
p; j++)
952 for (
int i=1; i<
p; i++)
958 t_dof[6 + 9 * ne + 2 * nt + 0 * nq + k] = 2 + 0 * ne + i;
959 t_dof[6 + 9 * ne + 2 * nt + 1 * nq + k] = 2 + 1 * ne + i;
960 t_dof[6 + 9 * ne + 2 * nt + 2 * nq + k] = 2 + 2 * ne + i;
962 s_dof[6 + 9 * ne + 2 * nt + 0 * nq + k] = 1 + j;
963 s_dof[6 + 9 * ne + 2 * nt + 1 * nq + k] = 1 + j;
964 s_dof[6 + 9 * ne + 2 * nt + 2 * nq + k] = 1 + j;
976 for (
int j=1; j<
p; j++)
978 for (
int i=1; i+j<
p; i++)
981 t_dof[6 + 9 * ne + 2 * nt + 3 * nq + m] = 3 *
p + l;
982 s_dof[6 + 9 * ne + 2 * nt + 3 * nq + m] = 1 + k;
991 for (
int i=0; i<
dof; i++)
1002 #ifdef MFEM_THREAD_SAFE 1012 for (
int i=0; i<
dof; i++)
1014 shape[i] = t_shape[t_dof[i]] * s_shape[s_dof[i]];
1021 #ifdef MFEM_THREAD_SAFE 1035 for (
int i=0; i<
dof; i++)
1037 dshape(i, 0) = t_dshape(t_dof[i],0) * s_shape[s_dof[i]];
1038 dshape(i, 1) = t_dshape(t_dof[i],1) * s_shape[s_dof[i]];
1039 dshape(i, 2) = t_shape[t_dof[i]] * s_dshape(s_dof[i],0);
virtual void CalcDShape(const IntegrationPoint &ip, DenseMatrix &dshape) const
Evaluate the gradients of all shape functions of a scalar finite element in reference space at the gi...
Array< int > lex_ordering
Class for an integration rule - an Array of IntegrationPoint.
static double CalcDelta(const int p, const double x)
Evaluate a representation of a Delta function at point x.
virtual void ProjectDelta(int vertex, Vector &dofs) const
Project a delta function centered on the given vertex in the local finite dimensional space represent...
virtual void CalcDShape(const IntegrationPoint &ip, DenseMatrix &dshape) const
Evaluate the gradients of all shape functions of a scalar finite element in reference space at the gi...
Linear1DFiniteElement SegmentFE
void Mult(const double *x, double *y) const
Matrix vector multiplication with the inverse of dense matrix.
void SetSize(int s)
Resize the vector to size s.
int dim
Dimension of reference space.
Data type dense matrix using column-major storage.
void Eval(const double x, Vector &u) const
Evaluate the basis functions at point x in [0,1].
void Factor()
Factor the current DenseMatrix, *a.
virtual void CalcDShape(const IntegrationPoint &ip, DenseMatrix &dshape) const
Evaluate the gradients of all shape functions of a scalar finite element in reference space at the gi...
const double * ClosedPoints(const int p, const int btype=BasisType::GaussLobatto)
Get coordinates of a closed (GaussLegendre) set of points if degree p.
virtual void CalcDShape(const IntegrationPoint &ip, DenseMatrix &dshape) const
Evaluate the gradients of all shape functions of a scalar finite element in reference space at the gi...
virtual void CalcHessian(const IntegrationPoint &ip, DenseMatrix &Hessian) const
Evaluate the Hessians of all shape functions of a scalar finite element in reference space at the giv...
H1_HexahedronElement(const int p, const int btype=BasisType::GaussLobatto)
Construct the H1_HexahedronElement of order p and BasisType btype.
virtual void ProjectDelta(int vertex, Vector &dofs) const
Project a delta function centered on the given vertex in the local finite dimensional space represent...
static void CalcBasis(const int p, const double x, double *u)
Evaluate the values of a hierarchical 1D basis at point x hierarchical = k-th basis function is degre...
virtual void CalcShape(const IntegrationPoint &ip, Vector &shape) const
Evaluate the values of all shape functions of a scalar finite element in reference space at the given...
Class for standard nodal finite elements.
IntegrationPoint & IntPoint(int i)
Returns a reference to the i-th integration point.
virtual void CalcHessian(const IntegrationPoint &ip, DenseMatrix &ddshape) const
Evaluate the Hessians of all shape functions of a scalar finite element in reference space at the giv...
virtual void CalcShape(const IntegrationPoint &ip, Vector &shape) const
Evaluate the values of all shape functions of a scalar finite element in reference space at the given...
virtual void CalcDShape(const IntegrationPoint &ip, DenseMatrix &dshape) const
Evaluate the gradients of all shape functions of a scalar finite element in reference space at the gi...
H1_QuadrilateralElement(const int p, const int btype=BasisType::GaussLobatto)
Construct the H1_QuadrilateralElement of order p and BasisType btype.
virtual void CalcDShape(const IntegrationPoint &ip, DenseMatrix &dshape) const
Evaluate the gradients of all shape functions of a scalar finite element in reference space at the gi...
H1_SegmentElement(const int p, const int btype=BasisType::GaussLobatto)
Construct the H1_SegmentElement of order p and BasisType btype.
void Set2(const double x1, const double x2)
virtual void CalcHessian(const IntegrationPoint &ip, DenseMatrix &Hessian) const
Evaluate the Hessians of all shape functions of a scalar finite element in reference space at the giv...
void Set3(const double x1, const double x2, const double x3)
double p(const Vector &x, double t)
virtual void CalcShape(const IntegrationPoint &ip, Vector &shape) const
Evaluate the values of all shape functions of a scalar finite element in reference space at the given...
void SetSize(int nsize)
Change the logical size of the array, keep existing entries.
H1_TetrahedronElement(const int p, const int btype=BasisType::GaussLobatto)
Construct the H1_TetrahedronElement of order p and BasisType btype.
int GetDof() const
Returns the number of degrees of freedom in the finite element.
virtual void CalcHessian(const IntegrationPoint &ip, DenseMatrix &ddshape) const
Evaluate the Hessians of all shape functions of a scalar finite element in reference space at the giv...
MFEM_EXPORT Linear2DFiniteElement TriangleFE
virtual void CalcShape(const IntegrationPoint &ip, Vector &shape) const
Evaluate the values of all shape functions of a scalar finite element in reference space at the given...
virtual void CalcHessian(const IntegrationPoint &ip, DenseMatrix &Hessian) const
Evaluate the Hessians of all shape functions of a scalar finite element in reference space at the giv...
H1_TriangleElement(const int p, const int btype=BasisType::GaussLobatto)
Construct the H1_TriangleElement of order p and BasisType btype.
virtual void CalcShape(const IntegrationPoint &ip, Vector &shape) const
Evaluate the values of all shape functions of a scalar finite element in reference space at the given...
Class for integration point with weight.
int dof
Number of degrees of freedom.
virtual void CalcShape(const IntegrationPoint &ip, Vector &shape) const
Evaluate the values of all shape functions of a scalar finite element in reference space at the given...
H1_WedgeElement(const int p, const int btype=BasisType::GaussLobatto)
Construct the H1_WedgeElement of order p and BasisType btype.
static int VerifyClosed(int b_type)
Ensure that the BasisType of b_type is closed (has Quadrature1D points on the boundary).
static int VerifyNodal(int b_type)
Ensure that the BasisType of b_type nodal (satisfies the interpolation property). ...
Describes the function space on each element.
virtual void ProjectDelta(int vertex, Vector &dofs) const
Project a delta function centered on the given vertex in the local finite dimensional space represent...
double u(const Vector &xvec)
void SetSize(int s)
Change the size of the DenseMatrix to s x s.
const IntegrationRule & GetNodes() const
Get a const reference to the nodes of the element.
int order
Order/degree of the shape functions.