26 GMatrixType& g_matrix,
27 const bool is_axially_symmetric,
31 static_assert(0 < DisplacementDim && DisplacementDim <= 3,
32 "LinearGMatrix::computeGMatrix: DisplacementDim must be in "
37 switch (DisplacementDim)
44 for (
int i = 0; i < NPOINTS; ++i)
46 auto G_col0 = g_matrix.col(i);
47 auto G_col1 = g_matrix.col(i + NPOINTS);
48 auto G_col2 = g_matrix.col(i + 2 * NPOINTS);
49 auto const dNidx = dNdx.col(i);
51 G_col0.template segment<DisplacementDim>(0).noalias() = dNidx;
52 G_col1.template segment<DisplacementDim>(DisplacementDim)
54 G_col2.template segment<DisplacementDim>(2 * DisplacementDim)
64 for (
int i = 0; i < NPOINTS; ++i)
66 auto G_col0 = g_matrix.col(i);
67 auto G_col1 = g_matrix.col(i + NPOINTS);
68 auto const dNidx = dNdx.col(i);
70 G_col0.template segment<DisplacementDim>(0).noalias() = dNidx;
71 G_col1.template segment<DisplacementDim>(DisplacementDim)
74 if (is_axially_symmetric)
76 G_col0[4] = N[i] / radius;