VTK  9.7.20260918
HexGnBasis.h
Go to the documentation of this file.
1WORKSPACE(RealT, rterm, order + 1);
2WORKSPACE(RealT, sterm, order + 1);
3WORKSPACE(RealT, tterm, order + 1);
4
5// Since the order is the same along each axis, we can use one loop to compute terms.
6for (int ii = 0; ii <= order; ++ii)
7{
8 rterm[ii] = 1.;
9 sterm[ii] = 1.;
10 tterm[ii] = 1.;
11 for (int jj = 0; jj <= order; ++jj)
12 {
13 if (ii == jj)
14 {
15 continue;
16 }
17 rterm[ii] *= (rr - gaussPoint(order, jj)) / (gaussPoint(order, ii) - gaussPoint(order, jj));
18 sterm[ii] *= (ss - gaussPoint(order, jj)) / (gaussPoint(order, ii) - gaussPoint(order, jj));
19 tterm[ii] *= (tt - gaussPoint(order, jj)) / (gaussPoint(order, ii) - gaussPoint(order, jj));
20 }
21}
22
23int term = 0;
24// Now apply terms to compute basis functions
25for (int kk = 0; kk <= order; ++kk)
26{
27 for (int jj = 0; jj <= order; ++jj)
28 {
29 for (int ii = 0; ii <= order; ++ii)
30 {
31 basis[term++] = rterm[ii] * sterm[jj] * tterm[kk];
32 }
33 }
34}
basis[0]
Definition CellC0Basis.h:1
int term
Definition HexGnBasis.h:23
WORKSPACE(RealT, rterm, order+1)