41 template<
class TPo
intType>
53 return integration_method;
62 template<
class TGeometryType>
65 const auto& r_integration_points = rGeometry.IntegrationPoints();
66 const auto number_gp = r_integration_points.size();
68 temp = rGeometry.DeterminantOfJacobian(
temp);
70 for (
unsigned int i = 0;
i < number_gp; ++
i) {
83 template<
class TPo
intType>
90 const auto number_gp = r_integration_points.size();
94 for (
unsigned int i = 0;
i < number_gp; ++
i) {
106 template<
class TPo
intType>
110 const auto& r_integration_points = rGeometry.
IntegrationPoints( integration_method );
113 for (
unsigned int i = 0;
i < r_integration_points.size();
i++ ) {
114 rGeometry.
Jacobian(
J,
i, integration_method);
130 template<
class TPo
intType>
132 const unsigned int DerivativeNodeIndex,
133 const unsigned int DerivativeDirectionIndex,
137 const auto& r_integration_points = rGeometry.
IntegrationPoints( integration_method );
140 Matrix shape_function_local_gradients(rGeometry.
size(), 2), rdNdXDerivative;
141 double detJ_derivative;
144 shape_param.
NodeIndex = DerivativeNodeIndex;
145 shape_param.
Direction = DerivativeDirectionIndex;
147 double area_derivative = 0.0;
148 for (
unsigned int g = 0; g < r_integration_points.size(); g++) {
150 rGeometry.
Jacobian(jacobian, g, integration_method);
153 geometrical_sensitivity_utility.
CalculateSensitivity(shape_param, detJ_derivative, rdNdXDerivative);
155 area_derivative += detJ_derivative * r_integration_points[g].Weight();
158 return area_derivative;
167 template<
class TPo
intType>
171 const auto& r_integration_points = rGeometry.
IntegrationPoints( integration_method );
174 for (
unsigned int i = 0;
i < r_integration_points.size();
i++ ) {
175 rGeometry.
Jacobian(
J,
i, integration_method);
191 template<
class TPo
intType>
193 const unsigned int DerivativeNodeIndex,
194 const unsigned int DerivativeDirectionIndex,
198 const auto& r_integration_points = rGeometry.
IntegrationPoints( integration_method );
201 Matrix shape_function_local_gradients(rGeometry.
size(), 3), rdNdXDerivative;
202 double detJ_derivative;
205 shape_param.
NodeIndex = DerivativeNodeIndex;
206 shape_param.
Direction = DerivativeDirectionIndex;
208 double volume_derivative = 0.0;
209 for (
unsigned int g = 0; g < r_integration_points.size(); g++) {
211 rGeometry.
Jacobian(jacobian, g, integration_method);
214 geometrical_sensitivity_utility.
CalculateSensitivity(shape_param, detJ_derivative, rdNdXDerivative);
216 volume_derivative += detJ_derivative * r_integration_points[g].Weight();
219 return volume_derivative;
Definition: geometrical_sensitivity_utility.h:79
void CalculateSensitivity(ShapeParameter Deriv, double &rDetJ_Deriv, ShapeFunctionsGradientType &rDN_DX_Deriv) const
Definition: geometrical_sensitivity_utility.cpp:52
IntegrationMethod
Definition: geometry_data.h:76
Geometry base class.
Definition: geometry.h:71
SizeType size() const
Definition: geometry.h:518
Vector & DeterminantOfJacobian(Vector &rResult) const
Definition: geometry.h:3154
IntegrationMethod GetDefaultIntegrationMethod() const
Definition: geometry.h:2004
const Matrix & ShapeFunctionLocalGradient(IndexType IntegrationPointIndex) const
Definition: geometry.h:3592
const IntegrationPointsArrayType & IntegrationPoints() const
Definition: geometry.h:2284
JacobiansType & Jacobian(JacobiansType &rResult) const
Definition: geometry.h:2901
Utilities to integrate in different cases.
Definition: integration_utilities.h:33
static double ComputeVolume3DGeometry(const Geometry< TPointType > &rGeometry)
This method calculates and returns the volume of the geometry from a 3D geometry.
Definition: integration_utilities.h:168
static double ComputeArea2DGeometryDerivative(const unsigned int DerivativeNodeIndex, const unsigned int DerivativeDirectionIndex, const Geometry< TPointType > &rGeometry)
This method calculates derivative of the area for a 2D geometry.
Definition: integration_utilities.h:131
static double ComputeDomainSize(const TGeometryType &rGeometry)
This method calculates and returns the domain size of the geometry from any geometry in a generic man...
Definition: integration_utilities.h:63
static double ComputeArea2DGeometry(const Geometry< TPointType > &rGeometry)
This method calculates and returns the volume of the geometry from a 3D geometry.
Definition: integration_utilities.h:107
static double ComputeDomainSize(const Geometry< TPointType > &rGeometry, const typename Geometry< TPointType >::IntegrationMethod IntegrationMethod)
This method calculates and returns the domain size of the geometry from any geometry in a generic man...
Definition: integration_utilities.h:84
static double ComputeVolume3DGeometryDerivative(const unsigned int DerivativeNodeIndex, const unsigned int DerivativeDirectionIndex, const Geometry< TPointType > &rGeometry)
This method calculates derivative of the volume for a 3D geometry.
Definition: integration_utilities.h:192
static GeometryData::IntegrationMethod GetIntegrationMethodForExactMassMatrixEvaluation(const Geometry< TPointType > &rGeometry)
This method returns the integration order for the exact mass matrix evaluation.
Definition: integration_utilities.h:42
static double Det3(const TMatrixType &rA)
Calculates the determinant of a matrix of dimension 3*3 (no check performed on matrix size)
Definition: math_utils.h:562
static double Det2(const TMatrixType &rA)
Calculates the determinant of a matrix of dimension 2x2 (no check performed on matrix size)
Definition: math_utils.h:549
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21
T & noalias(T &TheMatrix)
Definition: amatrix_interface.h:484
int domain_size
Definition: face_heat.py:4
float temp
Definition: rotating_cone.py:85
J
Definition: sensitivityMatrix.py:58
volume
Definition: sp_statistics.py:15
integer i
Definition: TensorModule.f:17
Definition: geometrical_sensitivity_utility.h:33
std::size_t NodeIndex
Definition: geometrical_sensitivity_utility.h:34
std::size_t Direction
Definition: geometrical_sensitivity_utility.h:35