148 {
151 const auto parameters = material_ptr->getParameters(getFEEntityHandle());
152 const int nb_integration_pts = getGaussPts().size2();
153 auto t_eigenvalues =
dataAtPts->getFTensorEigenVals(nb_integration_pts);
154 dataAtPts->energyAtPts.resize(nb_integration_pts,
false);
155 auto t_energy = getFTensor0FromVec(
dataAtPts->energyAtPts);
156 auto t_weight = getFTensor0IntegrationWeight();
157 double element_energy = 0.;
158 for (int gg = 0; gg != nb_integration_pts; ++gg) {
159
160
162 t_eigenvalues(0), 0., 0., t_eigenvalues(1), 0., t_eigenvalues(2));
163 double energy;
165 t_energy = energy;
166 element_energy += t_weight * energy;
167 ++t_eigenvalues;
168 ++t_energy;
169 ++t_weight;
170 }
174 }
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return()
#define CHKERR
Inline error check.
static boost::shared_ptr< HMHNeohookean > getMaterial(const boost::shared_ptr< DataAtIntegrationPts > &data_ptr)
static MoFEMErrorCode evaluateDirect(const Material::Parameters ¶meters, const Material::SymmetricTensor &t_log_stretch, double &energy, PackedStress *stress_ptr=nullptr, PackedTangent *tangent_ptr=nullptr)