OGS
MaterialLib::Solids::Phasefield Namespace Reference

Classes

class  AT_DegradationDerivative
class  COHESIVE_DegradationDerivative
class  DegradationDerivative

Enumerations

enum class  PhaseFieldModel { AT1 , AT2 , COHESIVE }
enum class  SofteningCurve { Linear , Exponential }
enum class  EnergySplitModel {
  Isotropic , VolDev , Spectral , EffectiveStress ,
  OrthoVolDev , OrthoMasonry
}

Functions

double evaluateHTensSpectral (int const i, int const j, Eigen::Matrix< double, 3, 1 > const &principal_strain)
 H terms in the Spectral decomposition:
double evaluateHCompSpectral (int const i, int const j, Eigen::Matrix< double, 3, 1 > const &principal_strain)
template<>
MathLib::KelvinVector::KelvinMatrixType< 3 > aOdotB< 3 > (MathLib::KelvinVector::KelvinVectorType< 3 > const &A, MathLib::KelvinVector::KelvinVectorType< 3 > const &B)
template<>
MathLib::KelvinVector::KelvinMatrixType< 2 > aOdotB< 2 > (MathLib::KelvinVector::KelvinVectorType< 2 > const &A, MathLib::KelvinVector::KelvinVectorType< 2 > const &B)
template<int DisplacementDim>
MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > aOdotB (MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &A, MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &B)
double heaviside (double const v)
double macaulayTensile (double const v)
double macaulayCompressive (double v)
template<int DisplacementDim>
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > calculateVolDevDegradedStress (double const degradation, double const bulk_modulus, double const mu, MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &eps)
template<int DisplacementDim>
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > calculateSpectralDegradedStress (double const degradation, double const lambda, double const mu, MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &eps)
template<int DisplacementDim>
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > calculateIsotropicDegradedStress (double const degradation, double const bulk_modulus, double const mu, MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &eps)
template<int DisplacementDim>
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > calculateIsotropicDegradedStressWithRankineEnergy (double const degradation, double const bulk_modulus, double const mu, MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &eps)
template<int DisplacementDim>
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > calculateOrthoVolDevDegradedStress (double const degradation, MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &eps, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > const &C_ortho)
template<int DisplacementDim>
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > calculateOrthoMasonryDegradedStress (double const degradation, MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &eps, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > const &C_ortho)
template<int DisplacementDim>
PhaseFieldModel convertStringToPhaseFieldModel (std::string const &phasefield_model)
template<int DisplacementDim>
SofteningCurve convertStringToSofteningCurve (std::optional< std::string > const &softening_curve)
template<int DisplacementDim>
EnergySplitModel convertStringToEnergySplitModel (std::string const &energy_split_model)
template<int DisplacementDim>
std::unique_ptr< DegradationDerivativecreatDegradationDerivative (PhaseFieldModel const &phasefield_model, double const lch, SofteningCurve const &softening_curve)
template<typename T_DNDX, typename T_N, typename T_W, typename T_D, typename T_LOCAL_JAC, typename T_LOCAL_RHS>
void calculateCrackLocalJacobianAndResidual (T_DNDX &dNdx, T_N &N, T_W &w, T_D &d, T_LOCAL_JAC &local_Jac, T_LOCAL_RHS local_rhs, double const gc, double const ls, PhaseFieldModel &phasefield_model)
template<typename T_VECTOR, typename T_MATRIX, int DisplacementDim>
void calculateStress (T_VECTOR &sigma, T_VECTOR &sigma_tensile, T_VECTOR &sigma_compressive, T_VECTOR &eps_tensile, T_MATRIX &D, T_MATRIX &C_tensile, T_MATRIX &C_compressive, double &strain_energy_tensile, double &elastic_energy, double const degradation, T_VECTOR const &eps, EnergySplitModel const &energy_split_model, double const t, ParameterLib::SpatialPosition const &x, MaterialLib::Solids::MechanicsBase< DisplacementDim > const &solid_material)

Enumeration Type Documentation

◆ EnergySplitModel

◆ PhaseFieldModel

◆ SofteningCurve

Function Documentation

◆ aOdotB()

template<int DisplacementDim>
MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > MaterialLib::Solids::Phasefield::aOdotB ( MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const & A,
MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const & B )

Decompose the stiffness into tensile and compressive part. Judging by the physical observations, compression perpendicular to a crack does not cause crack propagation. Thus, the phase-field parameter is only involved into the tensile part to degrade the elastic strain energy.

Referenced by calculateSpectralDegradedStress().

◆ aOdotB< 2 >()

Definition at line 27 of file LinearElasticIsotropicPhaseField.cpp.

113{
115
116 result(0, 0) = A(0) * B(0);
117 result(0, 1) = result(1, 0) = A(3) * B(3) / 2.;
118 result(0, 2) = result(2, 0) = 0;
119 result(0, 3) = result(3, 0) = (A(0) * B(3) + A(3) * B(0)) / 2;
120
121 result(1, 1) = A(1) * B(1);
122 result(1, 2) = result(2, 1) = 0;
123 result(1, 3) = result(3, 1) = (A(1) * B(3) + A(3) * B(1)) / 2.;
124
125 result(2, 2) = A(2) * B(2);
126 result(2, 3) = result(3, 2) = 0;
127
128 result(3, 3) = (A(0) * B(1) + A(1) * B(0) + A(3) * B(3)) / 2.;
129
130 return result;
131}
Eigen::Matrix< double, kelvin_vector_dimensions(DisplacementDim), kelvin_vector_dimensions(DisplacementDim), Eigen::RowMajor > KelvinMatrixType

References heaviside(), and macaulayCompressive().

◆ aOdotB< 3 >()

Double-minor symmetrized tensor product

aOdotB computes the symmetric 4th-order tensor product

\[(A \odot B)_{ijkl} = \tfrac{1}{4} (A_{ik}B_{jl} + A_{il}B_{jk} + A_{jk}B_{il} + A_{jl}B_{ik}), \]

which is symmetric in both index pairs \((i,j)\) and \((k,l)\) (“double-minor symmetry”).

Reference Mehrabadi, M.M., & Cowin, S.C. (1990). Eigentensors of linear anisotropic elastic materials. Q. J. Mech. Appl. Math., 43(1), 15-41.

Definition at line 27 of file LinearElasticIsotropicPhaseField.cpp.

68{
70
71 result(0, 0) = A(0) * B(0);
72 result(0, 1) = result(1, 0) = A(3) * B(3) / 2.;
73 result(0, 2) = result(2, 0) = A(5) * B(5) / 2.;
74 result(0, 3) = result(3, 0) = (A(0) * B(3) + A(3) * B(0)) / 2;
75 result(0, 4) = result(4, 0) =
76 (A(3) * B(5) + A(5) * B(3)) / (2. * std::sqrt(2.));
77 result(0, 5) = result(5, 0) = (A(0) * B(5) + A(5) * B(0)) / 2;
78
79 result(1, 1) = A(1) * B(1);
80 result(1, 2) = result(2, 1) = A(4) * B(4) / 2.;
81 result(1, 3) = result(3, 1) = (A(1) * B(3) + A(3) * B(1)) / 2.;
82 result(1, 4) = result(4, 1) = (A(1) * B(4) + A(4) * B(1)) / 2.;
83 result(1, 5) = result(5, 1) =
84 (A(3) * B(4) + A(4) * B(3)) / (2. * std::sqrt(2.));
85
86 result(2, 2) = A(2) * B(2);
87 result(2, 3) = result(3, 2) =
88 (A(4) * B(5) + A(5) * B(4)) / (2. * std::sqrt(2.));
89 result(2, 4) = result(4, 2) = (A(2) * B(4) + A(4) * B(2)) / 2.;
90 result(2, 5) = result(5, 2) = (A(2) * B(5) + A(5) * B(2)) / 2.;
91
92 result(3, 3) = (A(0) * B(1) + A(1) * B(0) + A(3) * B(3)) / 2.;
93 result(3, 4) = result(4, 3) =
94 (A(3) * B(4) + A(4) * B(3)) / 4. +
95 (A(1) * B(5) + A(5) * B(1)) / (2. * std::sqrt(2.));
96 result(3, 5) = result(5, 3) =
97 (A(3) * B(5) + A(5) * B(3)) / 4. +
98 (A(0) * B(4) + A(4) * B(0)) / (2. * std::sqrt(2.));
99
100 result(4, 4) = (A(1) * B(2) + A(2) * B(1) + A(4) * B(4)) / 2.;
101 result(4, 5) = result(5, 4) =
102 (A(4) * B(5) + A(5) * B(4)) / 4. +
103 (A(2) * B(3) + A(3) * B(2)) / (2. * std::sqrt(2.));
104
105 result(5, 5) = (A(0) * B(2) + A(2) * B(0) + A(5) * B(5)) / 2.;
106 return result;
107}

◆ calculateCrackLocalJacobianAndResidual()

template<typename T_DNDX, typename T_N, typename T_W, typename T_D, typename T_LOCAL_JAC, typename T_LOCAL_RHS>
void MaterialLib::Solids::Phasefield::calculateCrackLocalJacobianAndResidual ( T_DNDX & dNdx,
T_N & N,
T_W & w,
T_D & d,
T_LOCAL_JAC & local_Jac,
T_LOCAL_RHS local_rhs,
double const gc,
double const ls,
PhaseFieldModel & phasefield_model )

Definition at line 291 of file PhaseFieldBase.h.

296{
297 switch (phasefield_model)
298 {
300 {
301 auto const local_Jac_AT1 =
302 (gc * 0.75 * dNdx.transpose() * dNdx * ls * w).eval();
303 local_Jac.noalias() += local_Jac_AT1;
304
305 local_rhs.noalias() -=
306 gc * (-0.375 * N.transpose() / ls) * w + local_Jac_AT1 * d;
307 break;
308 }
310 {
311 auto const local_Jac_AT2 =
312 (gc * (N.transpose() * N / ls + dNdx.transpose() * dNdx * ls) *
313 w)
314 .eval();
315 local_Jac.noalias() += local_Jac_AT2;
316
317 local_rhs.noalias() -=
318 local_Jac_AT2 * d - gc * (N.transpose() / ls) * w;
319 break;
320 }
322 {
323 auto const local_Jac_COHESIVE =
324 (2.0 / std::numbers::pi * gc *
325 (-N.transpose() * N / ls + dNdx.transpose() * dNdx * ls) * w)
326 .eval();
327
328 local_Jac.noalias() += local_Jac_COHESIVE;
329
330 local_rhs.noalias() -= local_Jac_COHESIVE * d;
331 break;
332 }
333 default:
334 {
335 OGS_FATAL("Invalid phase field model specified.");
336 }
337 }
338};
#define OGS_FATAL(...)
Definition Error.h:19

References AT1, AT2, COHESIVE, and OGS_FATAL.

◆ calculateIsotropicDegradedStress()

template<int DisplacementDim>
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > MaterialLib::Solids::Phasefield::calculateIsotropicDegradedStress ( double const degradation,
double const bulk_modulus,
double const mu,
MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const & eps )

Definition at line 267 of file LinearElasticIsotropicPhaseField.h.

272{
273 static int const KelvinVectorSize =
275 using KelvinVector =
277 using KelvinMatrix =
280 // calculation of deviatoric parts
281 auto const& P_dev = Invariants::deviatoric_projection;
282 KelvinVector const epsd_curr = P_dev * eps;
283
284 // Hydrostatic part for the stress and the tangent.
285 double const eps_curr_trace = Invariants::trace(eps);
286
287 KelvinMatrix C_tensile = KelvinMatrix::Zero();
288 KelvinMatrix C_compressive = KelvinMatrix::Zero();
289
290 double const strain_energy_tensile =
291 bulk_modulus / 2 * eps_curr_trace * eps_curr_trace +
292 mu * epsd_curr.transpose() * epsd_curr;
293 double const elastic_energy = degradation * strain_energy_tensile;
294 KelvinVector const sigma_tensile =
295 bulk_modulus * eps_curr_trace * Invariants::identity2 +
296 2 * mu * epsd_curr;
297 C_tensile.template topLeftCorner<3, 3>().setConstant(bulk_modulus);
298 C_tensile.noalias() += 2 * mu * P_dev * KelvinMatrix::Identity();
299 KelvinVector const sigma_real = degradation * sigma_tensile;
300
301 KelvinMatrix const D = degradation * C_tensile + C_compressive;
302
303 return std::make_tuple(sigma_real, sigma_tensile, D, strain_energy_tensile,
304 elastic_energy, C_tensile, C_compressive);
305}
constexpr int kelvin_vector_dimensions(int const displacement_dim)
Kelvin vector dimensions for given displacement dimension.
Eigen::Matrix< double, kelvin_vector_dimensions(DisplacementDim), 1, Eigen::ColMajor > KelvinVectorType

References MathLib::KelvinVector::kelvin_vector_dimensions().

Referenced by calculateStress().

◆ calculateIsotropicDegradedStressWithRankineEnergy()

template<int DisplacementDim>
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > MaterialLib::Solids::Phasefield::calculateIsotropicDegradedStressWithRankineEnergy ( double const degradation,
double const bulk_modulus,
double const mu,
MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const & eps )

Definition at line 320 of file LinearElasticIsotropicPhaseField.h.

325{
326 static int const KelvinVectorSize =
328 using KelvinVector =
330 using KelvinMatrix =
333 // calculation of deviatoric parts
334 auto const& P_dev = Invariants::deviatoric_projection;
335 KelvinVector const epsd_curr = P_dev * eps;
336
337 // Hydrostatic part for the stress and the tangent.
338 double const eps_curr_trace = Invariants::trace(eps);
339
340 KelvinMatrix C_tensile = KelvinMatrix::Zero();
341 KelvinMatrix C_compressive = KelvinMatrix::Zero();
342
343 KelvinVector const sigma_tensile =
344 bulk_modulus * eps_curr_trace * Invariants::identity2 +
345 2 * mu * epsd_curr;
346 // The maximum principal stress
347 auto sigma_tensor =
349 Eigen::SelfAdjointEigenSolver<decltype(sigma_tensor)>
350 selfAdjoint_eigen_solver(sigma_tensor);
351 double const max_principle_stress =
352 selfAdjoint_eigen_solver
353 .eigenvalues()[2]; // selfAdjoint_eigen_solver function gives an
354 // ascending sequence.
355 //
356 double const E0 = 9.0 * mu * bulk_modulus / (3.0 * bulk_modulus + mu);
357 auto hs = [&](double const v) { return heaviside(v); };
358 //
359 double const strain_energy_tensile = 0.5 * max_principle_stress *
360 max_principle_stress *
361 hs(max_principle_stress) / E0;
362 double const elastic_energy =
363 degradation * (bulk_modulus / 2 * eps_curr_trace * eps_curr_trace +
364 mu * epsd_curr.transpose() * epsd_curr);
365 //
366 C_tensile.template topLeftCorner<3, 3>().setConstant(bulk_modulus);
367 C_tensile.noalias() += 2 * mu * P_dev * KelvinMatrix::Identity();
368 KelvinVector const sigma_real = degradation * sigma_tensile;
369
370 KelvinMatrix const D = degradation * C_tensile + C_compressive;
371 return std::make_tuple(sigma_real, sigma_tensile, D, strain_energy_tensile,
372 elastic_energy, C_tensile, C_compressive);
373}
Eigen::Matrix< double, 3, 3 > kelvinVectorToTensor(Eigen::Matrix< double, 4, 1, Eigen::ColMajor, 4, 1 > const &v)

References heaviside(), MathLib::KelvinVector::kelvin_vector_dimensions(), and MathLib::KelvinVector::kelvinVectorToTensor().

◆ calculateOrthoMasonryDegradedStress()

template<int DisplacementDim>
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > MaterialLib::Solids::Phasefield::calculateOrthoMasonryDegradedStress ( double const degradation,
MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const & eps,
MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > const & C_ortho )

Definition at line 124 of file LinearElasticOrthotropicPhaseField.h.

128{
129 using KelvinVector =
131 using KelvinMatrix =
133
134 KelvinMatrix const C = C_ortho;
135
136 // calculation of square root of elasticity tensor
137 Eigen::SelfAdjointEigenSolver<KelvinMatrix> es(C);
138 KelvinMatrix const sqrt_C = es.operatorSqrt();
139 Eigen::SelfAdjointEigenSolver<KelvinMatrix> es_inverse(C.inverse());
140 KelvinMatrix const sqrt_C_inverse = es_inverse.operatorSqrt();
141
142 // strain in a transformed space
143 KelvinVector const epst = sqrt_C * eps;
144
145 // strain tensor in 3D
146 Eigen::Matrix3d const eps_3D =
148
149 Eigen::SelfAdjointEigenSolver<Eigen::Matrix3d> const es_eps_3D(eps_3D);
150 Eigen::Vector3d const eigen_values_eps_3D = es_eps_3D.eigenvalues().real();
151 Eigen::Matrix3d const eigen_vectors_eps_3D = es_eps_3D.eigenvectors();
152 Eigen::Matrix3d const E1_eigenp =
153 eigen_vectors_eps_3D.col(0) * eigen_vectors_eps_3D.col(0).transpose();
154
155 Eigen::Matrix3d const E3_eigenp =
156 eigen_vectors_eps_3D.col(2) * eigen_vectors_eps_3D.col(2).transpose();
157
158 KelvinVector const E1_vec =
160
161 KelvinVector const E3_vec =
163
164 KelvinMatrix const E1oE1 = E1_vec * E1_vec.transpose();
165 KelvinMatrix const E3oE3 = E3_vec * E3_vec.transpose();
166
167 KelvinMatrix I_p = KelvinMatrix::Zero();
168 KelvinMatrix I_n = KelvinMatrix::Zero();
169
170 KelvinMatrix const I_S = KelvinMatrix::Identity();
171 if (DisplacementDim == 2)
172 {
173 if (std::abs(eigen_values_eps_3D(2) - eigen_values_eps_3D(0)) >
174 std::numeric_limits<double>::epsilon())
175 {
176 I_p = (macaulayTensile(eigen_values_eps_3D(0)) -
177 macaulayTensile(eigen_values_eps_3D(2))) /
178 (eigen_values_eps_3D(0) - eigen_values_eps_3D(2)) *
179 (I_S - (E1oE1 + E3oE3)) +
180 (heaviside(eigen_values_eps_3D(0)) * E1oE1 +
181 heaviside(eigen_values_eps_3D(2)) * E3oE3);
182 I_n = (macaulayCompressive(eigen_values_eps_3D(0)) -
183 macaulayCompressive(eigen_values_eps_3D(2))) /
184 (eigen_values_eps_3D(0) - eigen_values_eps_3D(2)) *
185 (I_S - (E1oE1 + E3oE3)) +
186 (heaviside(-eigen_values_eps_3D(0)) * E1oE1 +
187 heaviside(-eigen_values_eps_3D(2)) * E3oE3);
188 }
189 else
190 {
191 I_p = heaviside(eigen_values_eps_3D(0)) * I_S;
192 I_n = heaviside(-eigen_values_eps_3D(0)) * I_S;
193 }
194 }
195
196 // strain tensile / compressive
197 KelvinVector const eps_tensile = sqrt_C_inverse * (I_p * sqrt_C) * eps;
198 KelvinVector const eps_compressive = sqrt_C_inverse * (I_n * sqrt_C) * eps;
199
200 // C tensile / compressive
201 KelvinMatrix const C_tensile = sqrt_C * I_p * sqrt_C;
202 KelvinMatrix const C_compressive = sqrt_C * I_n * sqrt_C;
203
204 // stress tensile / compressive
205 KelvinVector const sigma_tensile = C * eps_tensile;
206 KelvinVector const sigma_compressive = C * eps_compressive;
207
208 // decomposition of strain energy density
209 double const strain_energy_tensile =
210 0.5 * sigma_tensile.adjoint() * eps_tensile;
211 double const strain_energy_compressive =
212 0.5 * sigma_compressive.adjoint() * eps_compressive;
213
214 double const elastic_energy =
215 degradation * strain_energy_tensile + strain_energy_compressive;
216
217 KelvinVector const sigma_real =
218 degradation * sigma_tensile + sigma_compressive;
219
220 KelvinMatrix const D = degradation * C_tensile + C_compressive;
221
222 return std::make_tuple(eps_tensile, sigma_real, sigma_tensile, D,
223 strain_energy_tensile, elastic_energy, C_tensile,
224 C_compressive);
225}
KelvinVectorType< DisplacementDim > tensorToKelvin(Eigen::Matrix< double, 3, 3 > const &m)

References heaviside(), MathLib::KelvinVector::kelvinVectorToTensor(), macaulayCompressive(), macaulayTensile(), and MathLib::KelvinVector::tensorToKelvin().

Referenced by calculateStress().

◆ calculateOrthoVolDevDegradedStress()

template<int DisplacementDim>
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > MaterialLib::Solids::Phasefield::calculateOrthoVolDevDegradedStress ( double const degradation,
MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const & eps,
MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > const & C_ortho )

Definition at line 35 of file LinearElasticOrthotropicPhaseField.h.

39{
40 static constexpr int KelvinVectorSize =
42 using KelvinVector =
44 using KelvinMatrix =
47 // calculation of deviatoric parts
48 auto const& P_dev = Invariants::deviatoric_projection;
49
50 KelvinMatrix const C = C_ortho;
51 // calculation of square root of elasticity tensor
52 Eigen::SelfAdjointEigenSolver<KelvinMatrix> es(C);
53 KelvinMatrix const sqrt_C = es.operatorSqrt();
54 Eigen::SelfAdjointEigenSolver<KelvinMatrix> es_inverse(C.inverse());
55 KelvinMatrix const sqrt_C_inverse = es_inverse.operatorSqrt();
56
57 // strain in a transformed space
58 KelvinVector const epst = sqrt_C * eps;
59 double const epst_curr_trace = Invariants::trace(epst);
60
61 // projection tensors in transformed space
62 KelvinMatrix teps_p = KelvinMatrix::Zero();
63 KelvinMatrix teps_n = KelvinMatrix::Zero();
64 if (epst_curr_trace >= 0) /* QQQ */
65 {
66 teps_p.template topLeftCorner<3, 3>().setConstant(1. / 3);
67 }
68 else
69 {
70 teps_n.template topLeftCorner<3, 3>().setConstant(1. / 3);
71 }
72
73 teps_p.noalias() += P_dev * KelvinMatrix::Identity();
74
75 // strain tensile / compressive
76 KelvinVector const eps_tensile = sqrt_C_inverse * (teps_p * sqrt_C) * eps;
77 KelvinVector const eps_compressive =
78 sqrt_C_inverse * (teps_n * sqrt_C) * eps;
79
80 // projection tensors in original space
81 KelvinMatrix const der_eps_p = sqrt_C_inverse * (teps_p * sqrt_C);
82 KelvinMatrix const der_eps_n = sqrt_C_inverse * (teps_n * sqrt_C);
83 // C tensile / compressive
84 KelvinMatrix const C_tensile = der_eps_p.transpose() * C * der_eps_p;
85 KelvinMatrix const C_compressive = der_eps_n.transpose() * C * der_eps_n;
86
87 // stress tensile / compressive
88 KelvinVector const sigma_tensile = C_tensile * eps;
89 KelvinVector const sigma_compressive = C_compressive * eps;
90
91 // decomposition of strain energy density
92 double const strain_energy_tensile =
93 0.5 * sigma_tensile.adjoint() * eps_tensile;
94 double const strain_energy_compressive =
95 0.5 * sigma_compressive.adjoint() * eps_compressive;
96
97 double const elastic_energy =
98 degradation * strain_energy_tensile + strain_energy_compressive;
99
100 KelvinVector const sigma_real =
101 degradation * sigma_tensile + sigma_compressive;
102 KelvinMatrix const D = degradation * C_tensile + C_compressive;
103
104 return std::make_tuple(eps_tensile, sigma_real, sigma_tensile,
105 sigma_compressive, D, strain_energy_tensile,
106 elastic_energy, C_tensile, C_compressive);
107}

References MathLib::KelvinVector::kelvin_vector_dimensions().

Referenced by calculateStress().

◆ calculateSpectralDegradedStress()

template<int DisplacementDim>
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > MaterialLib::Solids::Phasefield::calculateSpectralDegradedStress ( double const degradation,
double const lambda,
double const mu,
MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const & eps )

Definition at line 146 of file LinearElasticIsotropicPhaseField.h.

151{
152 static int const KelvinVectorSize =
154 using KelvinVector =
156 using KelvinMatrix =
159
160 KelvinMatrix C_tensile = KelvinMatrix::Zero();
161 KelvinMatrix C_compressive = KelvinMatrix::Zero();
162
163 // non-const for Eigen solver.
164 auto eps_tensor = MathLib::KelvinVector::kelvinVectorToTensor(eps);
165
166 Eigen::EigenSolver<decltype(eps_tensor)> eigen_solver(eps_tensor);
167 Eigen::Matrix<double, 3, 1> const principal_strain =
168 eigen_solver.eigenvalues().real();
169 double const sum_strain = principal_strain.sum();
170
171 std::array<KelvinVector, 3> M_kelvin;
172
173 for (int i = 0; i < 3; i++)
174 {
176 eigen_solver.eigenvectors().real().col(i).normalized() *
177 eigen_solver.eigenvectors().real().col(i).normalized().transpose());
178 }
179
180 auto strain_energy_computation = [&](auto&& macaulay)
181 {
182 auto macaulay_squared = [&macaulay](double x)
183 { return boost::math::pow<2>(macaulay(x)); };
184 return lambda / 2 * macaulay_squared(sum_strain) +
185 mu * principal_strain.unaryExpr(macaulay_squared).sum();
186 };
187
188 auto stress_computation = [&](auto&& macaulay)
189 {
190 KelvinVector stress =
191 lambda * macaulay(sum_strain) * Invariants::identity2;
192 for (int i = 0; i < 3; i++)
193 {
194 stress += 2 * mu * macaulay(principal_strain[i]) * M_kelvin[i];
195 }
196 return stress;
197 };
198
199 auto hs = [&](double const v) { return heaviside(v); };
200
201 auto mt = [&](double const v) { return macaulayTensile(v); };
202
203 auto mc = [&](double const v) { return macaulayCompressive(v); };
204
205 double const strain_energy_tensile = strain_energy_computation(mt);
206
207 double const strain_energy_compressive = strain_energy_computation(mc);
208
209 KelvinVector const sigma_tensile = stress_computation(mt);
210
211 KelvinVector const sigma_compressive = stress_computation(mc);
212
213 C_tensile.template topLeftCorner<3, 3>().setConstant(lambda *
214 hs(sum_strain));
215
216 for (int i = 0; i < 3; i++)
217 {
218 C_tensile.noalias() += 2 * mu * hs(principal_strain[i]) * M_kelvin[i] *
219 M_kelvin[i].transpose();
220 for (int j = 0; j < 3; j++)
221 {
222 C_tensile.noalias() +=
223 mu * evaluateHTensSpectral(i, j, principal_strain) *
224 aOdotB<DisplacementDim>(M_kelvin[i], M_kelvin[j]);
225 }
226 }
227
228 C_compressive.template topLeftCorner<3, 3>().setConstant(
229 lambda * (1 - hs(sum_strain)));
230 KelvinMatrix C_temp = KelvinMatrix::Zero();
231 for (int i = 0; i < 3; i++)
232 {
233 C_compressive.noalias() += 2 * mu * (1 - hs(principal_strain[i])) *
234 M_kelvin[i] * M_kelvin[i].transpose();
235 C_temp.noalias() = M_kelvin[i] * M_kelvin[i].transpose();
236 for (int j = 0; j < 3; j++)
237 {
238 C_compressive.noalias() +=
239 mu * evaluateHCompSpectral(i, j, principal_strain) *
240 aOdotB<DisplacementDim>(M_kelvin[i], M_kelvin[j]);
241 }
242 }
243
244 double const elastic_energy =
245 degradation * strain_energy_tensile + strain_energy_compressive;
246
247 KelvinVector sigma_real = degradation * sigma_tensile + sigma_compressive;
248 KelvinMatrix const D = degradation * C_tensile + C_compressive;
249
250 return std::make_tuple(sigma_real, sigma_tensile, D, strain_energy_tensile,
251 elastic_energy, C_tensile, C_compressive);
252}
double evaluateHCompSpectral(int const i, int const j, Eigen::Matrix< double, 3, 1 > const &principal_strain)
MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > aOdotB(MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &A, MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &B)
double evaluateHTensSpectral(int const i, int const j, Eigen::Matrix< double, 3, 1 > const &principal_strain)
H terms in the Spectral decomposition:
KV::KelvinMatrixType< DisplacementDim > KelvinMatrix
KV::KelvinVectorType< DisplacementDim > KelvinVector

References aOdotB(), evaluateHCompSpectral(), evaluateHTensSpectral(), heaviside(), MathLib::KelvinVector::kelvin_vector_dimensions(), MathLib::KelvinVector::kelvinVectorToTensor(), macaulayCompressive(), macaulayTensile(), and MathLib::KelvinVector::tensorToKelvin().

Referenced by calculateStress().

◆ calculateStress()

template<typename T_VECTOR, typename T_MATRIX, int DisplacementDim>
void MaterialLib::Solids::Phasefield::calculateStress ( T_VECTOR & sigma,
T_VECTOR & sigma_tensile,
T_VECTOR & sigma_compressive,
T_VECTOR & eps_tensile,
T_MATRIX & D,
T_MATRIX & C_tensile,
T_MATRIX & C_compressive,
double & strain_energy_tensile,
double & elastic_energy,
double const degradation,
T_VECTOR const & eps,
EnergySplitModel const & energy_split_model,
double const t,
ParameterLib::SpatialPosition const & x,
MaterialLib::Solids::MechanicsBase< DisplacementDim > const & solid_material )

Definition at line 341 of file PhaseFieldBase.h.

349{
350 auto linear_elastic_mp =
352 DisplacementDim> const&>(solid_material)
353 .getMaterialProperties();
354
355 auto const lambda = linear_elastic_mp.lambda(t, x);
356 auto const bulk_modulus = linear_elastic_mp.bulk_modulus(t, x);
357 auto const mu = linear_elastic_mp.mu(t, x);
358 switch (energy_split_model)
359 {
361 {
362 std::tie(sigma, sigma_tensile, D, strain_energy_tensile,
363 elastic_energy, C_tensile, C_compressive) =
366 degradation, bulk_modulus, mu, eps);
367 break;
368 }
370 {
371 std::tie(sigma, sigma_tensile, D, strain_energy_tensile,
372 elastic_energy, C_tensile, C_compressive) =
374 DisplacementDim>(degradation, bulk_modulus, mu, eps);
375 break;
376 }
378 {
379 std::tie(sigma, sigma_tensile, D, strain_energy_tensile,
380 elastic_energy, C_tensile, C_compressive) =
383 degradation, lambda, mu, eps);
384 break;
385 }
387 {
388 std::tie(sigma, sigma_tensile, D, strain_energy_tensile,
389 elastic_energy, C_tensile, C_compressive) =
390 MaterialLib::Solids::Phasefield::
391 calculateIsotropicDegradedStressWithRankineEnergy<
392 DisplacementDim>(degradation, bulk_modulus, mu, eps);
393 break;
394 }
396 {
397 double temperature = 0.;
399 static_cast<MaterialLib::Solids::LinearElasticOrthotropic<
400 DisplacementDim> const&>(solid_material)
401 .getElasticTensor(t, x, temperature);
402
403 std::tie(eps_tensile, sigma, sigma_tensile, sigma_compressive, D,
404 strain_energy_tensile, elastic_energy, C_tensile,
405 C_compressive) = MaterialLib::Solids::Phasefield::
407 degradation, eps, C_ortho);
408 break;
409 }
411 {
412 double temperature = 0.;
414 static_cast<MaterialLib::Solids::LinearElasticOrthotropic<
415 DisplacementDim> const&>(solid_material)
416 .getElasticTensor(t, x, temperature);
417
418 std::tie(eps_tensile, sigma, sigma_tensile, D,
419 strain_energy_tensile, elastic_energy, C_tensile,
420 C_compressive) = MaterialLib::Solids::Phasefield::
422 degradation, eps, C_ortho);
423 break;
424 }
425 default:
426 OGS_FATAL("Invalid energy split model specified.");
427 }
428};
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > calculateOrthoVolDevDegradedStress(double const degradation, MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &eps, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > const &C_ortho)
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > calculateIsotropicDegradedStress(double const degradation, double const bulk_modulus, double const mu, MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &eps)
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > calculateSpectralDegradedStress(double const degradation, double const lambda, double const mu, MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &eps)
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > calculateVolDevDegradedStress(double const degradation, double const bulk_modulus, double const mu, MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &eps)
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > calculateOrthoMasonryDegradedStress(double const degradation, MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const &eps, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > const &C_ortho)

References calculateIsotropicDegradedStress(), calculateOrthoMasonryDegradedStress(), calculateOrthoVolDevDegradedStress(), calculateSpectralDegradedStress(), calculateVolDevDegradedStress(), EffectiveStress, Isotropic, OGS_FATAL, OrthoMasonry, OrthoVolDev, Spectral, and VolDev.

Referenced by ProcessLib::HMPhaseField::IntegrationPointData< BMatricesType, ShapeMatricesType, DisplacementDim >::updateConstitutiveRelation(), and ProcessLib::PhaseField::IntegrationPointData< BMatricesType, ShapeMatricesType, DisplacementDim >::updateConstitutiveRelation().

◆ calculateVolDevDegradedStress()

template<int DisplacementDim>
std::tuple< MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinVectorType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, double, double, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim >, MathLib::KelvinVector::KelvinMatrixType< DisplacementDim > > MaterialLib::Solids::Phasefield::calculateVolDevDegradedStress ( double const degradation,
double const bulk_modulus,
double const mu,
MathLib::KelvinVector::KelvinVectorType< DisplacementDim > const & eps )

Definition at line 69 of file LinearElasticIsotropicPhaseField.h.

72{
73 static int const KelvinVectorSize =
75 using KelvinVector =
77 using KelvinMatrix =
80 // calculation of deviatoric parts
81 auto const& P_dev = Invariants::deviatoric_projection;
82 KelvinVector const epsd_curr = P_dev * eps;
83
84 // Hydrostatic part for the stress and the tangent.
85 double const eps_curr_trace = Invariants::trace(eps);
86
87 KelvinMatrix C_tensile = KelvinMatrix::Zero();
88 KelvinMatrix C_compressive = KelvinMatrix::Zero();
89
90 auto strain_energy_computation_vol = [&](auto&& macaulay)
91 {
92 auto macaulay_squared = [&macaulay](double x)
93 { return boost::math::pow<2>(macaulay(x)); };
94 return bulk_modulus / 2 * macaulay_squared(eps_curr_trace);
95 };
96
97 auto stress_computation_vol = [&](auto&& macaulay)
98 { return bulk_modulus * macaulay(eps_curr_trace) * Invariants::identity2; };
99
100 auto hs = [&](double const v) { return heaviside(v); };
101
102 auto mt = [&](double const v) { return macaulayTensile(v); };
103
104 auto mc = [&](double const v) { return macaulayCompressive(v); };
105
106 double const strain_energy_tensile = strain_energy_computation_vol(mt) +
107 mu * epsd_curr.transpose() * epsd_curr;
108
109 KelvinVector const sigma_tensile =
110 stress_computation_vol(mt) + 2 * mu * epsd_curr;
111
112 KelvinVector const sigma_compressive = stress_computation_vol(mc);
113
114 C_tensile.template topLeftCorner<3, 3>().setConstant(bulk_modulus *
115 hs(eps_curr_trace));
116 C_tensile.noalias() += 2 * mu * P_dev * KelvinMatrix::Identity();
117
118 C_compressive.template topLeftCorner<3, 3>().setConstant(
119 bulk_modulus * (1 - hs(eps_curr_trace)));
120
121 double const elastic_energy =
122 bulk_modulus / 2 * eps_curr_trace * eps_curr_trace +
123 mu * epsd_curr.transpose() * epsd_curr;
124 KelvinVector const sigma_real =
125 degradation * sigma_tensile + sigma_compressive;
126
127 KelvinMatrix const D = degradation * C_tensile + C_compressive;
128
129 return std::make_tuple(sigma_real, sigma_tensile, D, strain_energy_tensile,
130 elastic_energy, C_tensile, C_compressive);
131}

References heaviside(), MathLib::KelvinVector::kelvin_vector_dimensions(), macaulayCompressive(), and macaulayTensile().

Referenced by calculateStress().

◆ convertStringToEnergySplitModel()

template<int DisplacementDim>
EnergySplitModel MaterialLib::Solids::Phasefield::convertStringToEnergySplitModel ( std::string const & energy_split_model)

Definition at line 90 of file PhaseFieldBase.h.

92{
93 if (energy_split_model == "Isotropic")
94 {
96 }
97 if (energy_split_model == "VolumetricDeviatoric")
98 {
100 }
101 if (energy_split_model == "Spectral")
102 {
104 }
105 if (energy_split_model == "EffectiveStress")
106 {
108 }
109 if (energy_split_model == "OrthoVolDev")
110 {
112 }
113 if (energy_split_model == "OrthoMasonry")
114 {
116 }
117 OGS_FATAL(
118 "energy_split_model must be 'Isotropic', 'VolumetricDeviatoric', "
119 "'EffectiveStress', 'OrthoVolDev' or 'OrthoMasonry' but '{}' was given",
120 energy_split_model.c_str());
121};

References EffectiveStress, Isotropic, OGS_FATAL, OrthoMasonry, OrthoVolDev, Spectral, and VolDev.

Referenced by ProcessLib::HMPhaseField::createHMPhaseFieldProcess(), and ProcessLib::PhaseField::createPhaseFieldProcess().

◆ convertStringToPhaseFieldModel()

template<int DisplacementDim>
PhaseFieldModel MaterialLib::Solids::Phasefield::convertStringToPhaseFieldModel ( std::string const & phasefield_model)

Definition at line 30 of file PhaseFieldBase.h.

32{
33 if (phasefield_model == "AT1")
34 {
36 }
37 if (phasefield_model == "AT2")
38 {
40 }
41 if (phasefield_model == "COHESIVE")
42 {
44 }
46 "phasefield_model must be 'AT1', 'AT2' or 'COHESIVE' but '{}' "
47 "was given",
48 phasefield_model.c_str());
49};

References AT1, AT2, COHESIVE, and OGS_FATAL.

Referenced by ProcessLib::HMPhaseField::createHMPhaseFieldProcess(), and ProcessLib::PhaseField::createPhaseFieldProcess().

◆ convertStringToSofteningCurve()

template<int DisplacementDim>
SofteningCurve MaterialLib::Solids::Phasefield::convertStringToSofteningCurve ( std::optional< std::string > const & softening_curve)

Definition at line 58 of file PhaseFieldBase.h.

60{
61 if (softening_curve)
62 {
63 if (*softening_curve == "Linear")
64 {
66 }
67 if (*softening_curve == "Exponential")
68 {
70 }
72 "softening_curve must be 'Linear' or 'Exponential' but '{}' "
73 "was given",
74 softening_curve->c_str());
75 }
76 return SofteningCurve::Linear; // default
77};

References Exponential, Linear, and OGS_FATAL.

Referenced by ProcessLib::HMPhaseField::createHMPhaseFieldProcess(), and ProcessLib::PhaseField::createPhaseFieldProcess().

◆ creatDegradationDerivative()

template<int DisplacementDim>
std::unique_ptr< DegradationDerivative > MaterialLib::Solids::Phasefield::creatDegradationDerivative ( PhaseFieldModel const & phasefield_model,
double const lch,
SofteningCurve const & softening_curve )

Definition at line 275 of file PhaseFieldBase.h.

278{
279 switch (phasefield_model)
280 {
282 return std::make_unique<COHESIVE_DegradationDerivative>(
283 lch, softening_curve);
284 default:
285 return std::make_unique<AT_DegradationDerivative>();
286 }
287};

References COHESIVE.

◆ evaluateHCompSpectral()

double MaterialLib::Solids::Phasefield::evaluateHCompSpectral ( int const i,
int const j,
Eigen::Matrix< double, 3, 1 > const & principal_strain )

Definition at line 27 of file LinearElasticIsotropicPhaseField.cpp.

30{
31 if (i == j)
32 {
33 return 0.0;
34 }
35 double num_zero = 1.e-14;
36
37 if (std::fabs(principal_strain[i] - principal_strain[j]) < num_zero)
38 {
39 return 2 * (1 - heaviside(principal_strain[i]));
40 }
41 return 2 *
42 (macaulayCompressive(principal_strain[i]) -
43 macaulayCompressive(principal_strain[j])) /
44 (principal_strain[i] - principal_strain[j]);
45}

Referenced by calculateSpectralDegradedStress().

◆ evaluateHTensSpectral()

double MaterialLib::Solids::Phasefield::evaluateHTensSpectral ( int const i,
int const j,
Eigen::Matrix< double, 3, 1 > const & principal_strain )

H terms in the Spectral decomposition:

Definition at line 8 of file LinearElasticIsotropicPhaseField.cpp.

11{
12 if (i == j)
13 {
14 return 0.0;
15 }
16 if (std::fabs(principal_strain[i] - principal_strain[j]) <
17 std::numeric_limits<double>::epsilon())
18 {
19 return 2 * heaviside(principal_strain[i]);
20 }
21 return 2 *
22 (macaulayTensile(principal_strain[i]) -
23 macaulayTensile(principal_strain[j])) /
24 (principal_strain[i] - principal_strain[j]);
25}

References heaviside(), and macaulayTensile().

Referenced by calculateSpectralDegradedStress().

◆ heaviside()

double MaterialLib::Solids::Phasefield::heaviside ( double const v)
inline

heaviside function returns 1.0 if the argument is positive and 0.0 if negative

Definition at line 31 of file LinearElasticIsotropicPhaseField.h.

32{
33 return (v < 0) ? 0.0 : 1.0;
34}

Referenced by aOdotB< 2 >(), calculateIsotropicDegradedStressWithRankineEnergy(), calculateOrthoMasonryDegradedStress(), calculateSpectralDegradedStress(), calculateVolDevDegradedStress(), evaluateHTensSpectral(), macaulayCompressive(), and macaulayTensile().

◆ macaulayCompressive()

double MaterialLib::Solids::Phasefield::macaulayCompressive ( double v)
inline

◆ macaulayTensile()

double MaterialLib::Solids::Phasefield::macaulayTensile ( double const v)
inline

Macaulay brackets: positive strain is tensile and negative strain for compressive

Definition at line 38 of file LinearElasticIsotropicPhaseField.h.

39{
40 return v * heaviside(v);
41}

References heaviside().

Referenced by calculateOrthoMasonryDegradedStress(), calculateSpectralDegradedStress(), calculateVolDevDegradedStress(), and evaluateHTensSpectral().