OGS
ShapeTri3-impl.h
Go to the documentation of this file.
1 
15 namespace NumLib
16 {
17 template <class T_X, class T_N>
18 void ShapeTri3::computeShapeFunction(const T_X& r, T_N& N)
19 {
20  N[0] = 1. - r[0] - r[1];
21  N[1] = r[0];
22  N[2] = r[1];
23 }
24 
25 template <class T_X, class T_N>
26 void ShapeTri3::computeGradShapeFunction(const T_X& /*r*/, T_N& dN)
27 {
28  // dN/dr
29  dN[0] = -1.0;
30  dN[1] = 1.0;
31  dN[2] = 0.0;
32  // dN/ds
33  dN[3] = -1.0;
34  dN[4] = 0.0;
35  dN[5] = 1.0;
36 }
37 
38 } // namespace NumLib
static void computeShapeFunction(const T_X &r, T_N &N)
static void computeGradShapeFunction(const T_X &r, T_N &dN)
static const double r