OGS
NumLib::ShapeTri6 Class Reference

Detailed Description

Shape function for a 6-nodes triangle element

Definition at line 21 of file ShapeTri6.h.

#include <ShapeTri6.h>

Public Types

using MeshElement = MeshLib::Tri6
 

Static Public Member Functions

template<class T_X , class T_N >
static void computeShapeFunction (const T_X &r, T_N &N)
 
template<class T_X , class T_N >
static void computeGradShapeFunction (const T_X &r, T_N &dN)
 

Static Public Attributes

static const unsigned DIM = MeshElement::dimension
 
static const unsigned NPOINTS = MeshElement::n_all_nodes
 
static constexpr int ORDER = 2
 

Member Typedef Documentation

◆ MeshElement

Definition at line 43 of file ShapeTri6.h.

Member Function Documentation

◆ computeGradShapeFunction()

template<class T_X , class T_N >
void NumLib::ShapeTri6::computeGradShapeFunction ( const T_X & r,
T_N & dN )
static

Evaluate derivatives of the shape function at the given point The point coordinates in r are not used.

Parameters
[in]rpoint coordinates
[out]dNa matrix of the derivatives

Definition at line 25 of file ShapeTri6-impl.h.

26{
27 dN[0] = 4. * (r[0] + r[1]) - 3.; // dN1/dL1
28 dN[6] = dN[0]; // dN1/dL2
29
30 dN[1] = 4. * r[0] - 1.; // dN2/dL1
31 dN[7] = 0.; // dN2/dL2
32
33 dN[2] = 0.; // dN3/dL1
34 dN[8] = 4. * r[1] - 1.; // dN3/dL2
35
36 dN[3] = 4. * (1 - 2. * r[0] - r[1]); // dN4/dL1
37 dN[9] = -4. * r[0]; // dN4/dL2
38
39 dN[4] = 4. * r[1]; // dN5/dL1
40 dN[10] = -dN[9]; // dN5/dL2
41
42 dN[5] = -dN[4]; // dN6/dL1
43 dN[11] = 4. * (1 - r[0] - 2. * r[1]); // dN6/dL2
44}

◆ computeShapeFunction()

template<class T_X , class T_N >
void NumLib::ShapeTri6::computeShapeFunction ( const T_X & r,
T_N & N )
static

Evaluate the shape function at the given point

Parameters
[in]rpoint coordinates
[out]Na vector of calculated shape function.

Definition at line 14 of file ShapeTri6-impl.h.

15{
16 N[0] = 2. * (1. - r[0] - r[1]) * (0.5 - r[0] - r[1]);
17 N[1] = r[0] * (2. * r[0] - 1.);
18 N[2] = r[1] * (2. * r[1] - 1.);
19 N[3] = 4. * r[0] * (1. - r[0] - r[1]);
20 N[4] = 4. * r[0] * r[1];
21 N[5] = 4. * r[1] * (1. - r[0] - r[1]);
22}

References NumLib::N.

Member Data Documentation

◆ DIM

const unsigned NumLib::ShapeTri6::DIM = MeshElement::dimension
static

Definition at line 44 of file ShapeTri6.h.

◆ NPOINTS

const unsigned NumLib::ShapeTri6::NPOINTS = MeshElement::n_all_nodes
static

Definition at line 45 of file ShapeTri6.h.

◆ ORDER

constexpr int NumLib::ShapeTri6::ORDER = 2
staticconstexpr

Definition at line 46 of file ShapeTri6.h.


The documentation for this class was generated from the following files: