26 double const lower_saturation_limit,
27 double const upper_saturation_limit,
29 : p_(std::move(swelling_pressures)),
30 lambda_(std::move(exponents)),
31 S_min_(lower_saturation_limit),
32 S_max_(upper_saturation_limit),
33 local_coordinate_system_(local_coordinate_system)
40 if (!std::holds_alternative<Phase*>(
scale_))
43 "The property 'SaturationDependentSwelling' is implemented on the "
44 "'phase' scales only.");
46 auto const phase = std::get<Phase*>(
scale_);
47 if (phase->name !=
"Solid")
50 "The property 'SaturationDependentSwelling' must be given in the "
51 "'Solid' phase, not in '{:s}' phase.",
60 double const dt)
const
65 Eigen::Matrix<double, 3, 3>
const e =
67 ? Eigen::Matrix<double, 3, 3>::Identity()
70 Eigen::Matrix<double, 3, 3> delta_sigma_sw =
71 Eigen::Matrix<double, 3, 3>::Zero();
75 return delta_sigma_sw;
79 double const S_eff_prev =
82 double const delta_S_eff = S_eff - S_eff_prev;
84 if (delta_S_eff == 0.)
86 return delta_sigma_sw;
92 for (
int i = 0; i < 3; ++i)
94 Eigen::Matrix<double, 3, 3>
const ei_otimes_ei =
95 e.col(i) * e.col(i).transpose();
101 return (delta_sigma_sw * delta_S_eff / dt).eval();
113 "SaturationDependentSwelling::dValue is implemented for "
114 "derivatives with respect to liquid saturation only.");
120 Eigen::Matrix<double, 3, 3>
const e =
122 ? Eigen::Matrix<double, 3, 3>::Identity()
125 Eigen::Matrix<double, 3, 3> delta_sigma_sw =
126 Eigen::Matrix<double, 3, 3>::Zero();
130 return delta_sigma_sw;
134 double const S_eff_prev =
137 double const delta_S_eff = S_eff - S_eff_prev;
140 if (std::abs(delta_S_eff) <= 0)
142 return delta_sigma_sw;
145 for (
int i = 0; i < 3; ++i)
147 Eigen::Matrix<double, 3, 3>
const ei_otimes_ei =
148 e.col(i) * e.col(i).transpose();
virtual PropertyDataType value() const
std::variant< Medium *, Phase *, Component * > scale_
void checkScale() const override
std::array< double, 3 > const p_
Maximum swelling pressures, one for each spatial dimension.
PropertyDataType dValue(VariableArray const &variable_array, VariableArray const &variable_array_prev, Variable const variable, ParameterLib::SpatialPosition const &pos, double const t, double const dt) const override
ParameterLib::CoordinateSystem const *const local_coordinate_system_
SaturationDependentSwelling(std::string name, std::array< double, 3 > swelling_pressures, std::array< double, 3 > exponents, double const lower_saturation_limit, double const upper_saturation_limit, ParameterLib::CoordinateSystem const *const local_coordinate_system)
std::array< double, 3 > const lambda_
Exponents, one for each spatial dimension.
std::variant< double, Eigen::Matrix< double, 2, 1 >, Eigen::Matrix< double, 3, 1 >, Eigen::Matrix< double, 2, 2 >, Eigen::Matrix< double, 3, 3 >, Eigen::Matrix< double, 4, 1 >, Eigen::Matrix< double, 6, 1 >, Eigen::MatrixXd > PropertyDataType
A local coordinate system used for tensor transformations.
Eigen::Matrix< double, 3, 3 > transformation_3d(SpatialPosition const &pos) const