v0.13.2
Searching...
No Matches
PlasticOps.hpp

$\left\{ \begin{array}{ll} \frac{\partial \sigma_{ij}}{\partial x_j} - b_i = 0 & \forall x \in \Omega \\ \varepsilon_{ij} = \frac{1}{2}\left( \frac{\partial u_i}{\partial x_j} + \frac{\partial u_j}{\partial x_i} \right)\\ \sigma_{ij} = D_{ijkl}\left(\varepsilon_{kl}-\varepsilon^p_{kl}\right) \\ \dot{\varepsilon}^p_{kl} - \dot{\tau} \left( \left. \frac{\partial f}{\partial \sigma_{kl}} \right|_{(\sigma,\tau) } \right) = 0 \\ f(\sigma, \tau) \leq 0,\; \dot{\tau} \geq 0,\;\dot{\tau}f(\sigma, \tau)=0\\ u_i = \overline{u}_i & \forall x \in \partial\Omega_u \\ \sigma_{ij}n_j = \overline{t}_i & \forall x \in \partial\Omega_\sigma \\ \Omega_u \cup \Omega_\sigma = \Omega \\ \Omega_u \cap \Omega_\sigma = \emptyset \end{array} \right.$

$\left\{ \begin{array}{ll} \left(\frac{\partial \delta u_i}{\partial x_j},\sigma_{ij}\right)_\Omega-(\delta u_i,b_i)_\Omega -(\delta u_i,\overline{t}_i)_{\partial\Omega_\sigma}=0 & \forall \delta u_i \in H^1(\Omega)\\ \left(\delta\varepsilon^p_{kl} ,D_{ijkl}\left( \dot{\varepsilon}^p_{kl} - \dot{\tau} A_{kl} \right)\right) = 0 & \forall \delta\varepsilon^p_{ij} \in L^2(\Omega) \cap \mathcal{S} \\ \left(\delta\tau,c_n\dot{\tau} - \frac{1}{2}\left\{c_n \dot{\tau} + (f(\pmb\sigma,\tau) - \sigma_y) + \| c_n \dot{\tau} + (f(\pmb\sigma,\tau) - \sigma_y) \|\right\}\right) = 0 & \forall \delta\tau \in L^2(\Omega) \end{array} \right.$

/** \file PlasticOps.hpp
* \example PlasticOps.hpp
\f[
\left\{
\begin{array}{ll}
\frac{\partial \sigma_{ij}}{\partial x_j} - b_i = 0 & \forall x \in \Omega \\
\varepsilon_{ij} = \frac{1}{2}\left( \frac{\partial u_i}{\partial x_j} +
\frac{\partial u_j}{\partial x_i} \right)\\
\sigma_{ij} = D_{ijkl}\left(\varepsilon_{kl}-\varepsilon^p_{kl}\right) \\
\dot{\varepsilon}^p_{kl} - \dot{\tau} \left( \left. \frac{\partial f}{\partial
\sigma_{kl}} \right|_{(\sigma,\tau) } \right) = 0 \\
f(\sigma, \tau) \leq 0,\; \dot{\tau} \geq 0,\;\dot{\tau}f(\sigma, \tau)=0\\
u_i = \overline{u}_i & \forall x \in \partial\Omega_u \\
\sigma_{ij}n_j = \overline{t}_i & \forall x \in \partial\Omega_\sigma \\
\Omega_u \cup \Omega_\sigma = \Omega \\
\Omega_u \cap \Omega_\sigma = \emptyset
\end{array}
\right.
\f]
\f[
\left\{
\begin{array}{ll}
\left(\frac{\partial \delta u_i}{\partial x_j},\sigma_{ij}\right)_\Omega-(\delta
u_i,b_i)_\Omega -(\delta u_i,\overline{t}_i)_{\partial\Omega_\sigma}=0 & \forall
\delta u_i \in H^1(\Omega)\\ \left(\delta\varepsilon^p_{kl} ,D_{ijkl}\left(
\dot{\varepsilon}^p_{kl} - \dot{\tau} A_{kl} \right)\right) = 0
& \forall \delta\varepsilon^p_{ij} \in L^2(\Omega) \cap \mathcal{S} \\
\left(\delta\tau,c_n\dot{\tau} - \frac{1}{2}\left\{c_n \dot{\tau} +
(f(\pmb\sigma,\tau) - \sigma_y) +
\| c_n \dot{\tau} + (f(\pmb\sigma,\tau) - \sigma_y) \|\right\}\right) = 0 &
\forall \delta\tau \in L^2(\Omega) \end{array} \right.
\f]
*/
namespace PlasticOps {
//! [Common data]
struct CommonData : public boost::enable_shared_from_this<CommonData> {
boost::shared_ptr<MatrixDouble> mDPtr;
boost::shared_ptr<MatrixDouble> mDPtr_Axiator;
boost::shared_ptr<MatrixDouble> mDPtr_Deviator;
boost::shared_ptr<MatrixDouble> mStrainPtr;
boost::shared_ptr<MatrixDouble> mStressPtr;
VectorDouble plasticSurface;
MatrixDouble plasticFlow;
VectorDouble plasticTau;
VectorDouble plasticTauDot;
MatrixDouble plasticStrain;
MatrixDouble plasticStrainDot;
VectorDouble resC;
VectorDouble resCdTau;
MatrixDouble resCdStrain;
MatrixDouble resCdStrainDot;
MatrixDouble resFlow;
MatrixDouble resFlowDtau;
MatrixDouble resFlowDstrain;
MatrixDouble resFlowDstrainDot;
std::array<int, 5> activityData;
inline auto getPlasticSurfacePtr() {
return boost::shared_ptr<VectorDouble>(shared_from_this(), &plasticSurface);
}
inline auto getPlasticTauPtr() {
return boost::shared_ptr<VectorDouble>(shared_from_this(), &plasticTau);
}
inline auto getPlasticTauDotPtr() {
return boost::shared_ptr<VectorDouble>(shared_from_this(), &plasticTauDot);
}
inline auto getPlasticStrainPtr() {
return boost::shared_ptr<MatrixDouble>(shared_from_this(), &plasticStrain);
}
inline auto getPlasticStrainDotPtr() {
return boost::shared_ptr<MatrixDouble>(shared_from_this(),
}
inline auto getPlasticFlowPtr() {
return boost::shared_ptr<MatrixDouble>(shared_from_this(), &plasticFlow);
}
};
//! [Common data]
//! [Operators definitions]
struct OpCalculatePlasticSurface : public DomainEleOp {
OpCalculatePlasticSurface(const std::string field_name,
boost::shared_ptr<CommonData> common_data_ptr);
MoFEMErrorCode doWork(int side, EntityType type, EntData &data);
protected:
boost::shared_ptr<CommonData> commonDataPtr;
};
struct OpCalculatePlasticity : public DomainEleOp {
OpCalculatePlasticity(const std::string field_name, MoFEM::Interface &m_field,
boost::shared_ptr<CommonData> common_data_ptr,
boost::shared_ptr<MatrixDouble> m_D_ptr);
MoFEMErrorCode doWork(int side, EntityType type, EntData &data);
protected:
boost::shared_ptr<CommonData> commonDataPtr;
boost::shared_ptr<MatrixDouble> mDPtr;
};
struct OpPlasticStress : public DomainEleOp {
OpPlasticStress(const std::string field_name,
boost::shared_ptr<CommonData> common_data_ptr,
boost::shared_ptr<MatrixDouble> mDPtr,
const double scale = 1);
MoFEMErrorCode doWork(int side, EntityType type, EntData &data);
private:
boost::shared_ptr<MatrixDouble> mDPtr;
const double scaleStress;
boost::shared_ptr<CommonData> commonDataPtr;
};
struct OpCalculatePlasticFlowRhs : public AssemblyDomainEleOp {
OpCalculatePlasticFlowRhs(const std::string field_name,
boost::shared_ptr<CommonData> common_data_ptr,
boost::shared_ptr<MatrixDouble> m_D_ptr);
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &data);
private:
boost::shared_ptr<CommonData> commonDataPtr;
boost::shared_ptr<MatrixDouble> mDPtr;
};
struct OpCalculateConstraintsRhs : public AssemblyDomainEleOp {
OpCalculateConstraintsRhs(const std::string field_name,
boost::shared_ptr<CommonData> common_data_ptr,
boost::shared_ptr<MatrixDouble> m_D_ptr);
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &data);
private:
boost::shared_ptr<CommonData> commonDataPtr;
boost::shared_ptr<MatrixDouble> mDPtr;
};
struct OpCalculatePlasticInternalForceLhs_dEP : public AssemblyDomainEleOp {
OpCalculatePlasticInternalForceLhs_dEP(
const std::string row_field_name, const std::string col_field_name,
boost::shared_ptr<CommonData> common_data_ptr,
boost::shared_ptr<MatrixDouble> m_D_ptr);
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data,
EntitiesFieldData::EntData &col_data);
private:
boost::shared_ptr<CommonData> commonDataPtr;
boost::shared_ptr<MatrixDouble> mDPtr;
};
struct OpCalculatePlasticInternalForceLhs_LogStrain_dEP
OpCalculatePlasticInternalForceLhs_LogStrain_dEP(
const std::string row_field_name, const std::string col_field_name,
boost::shared_ptr<CommonData> common_data_ptr,
boost::shared_ptr<HenckyOps::CommonData> common_henky_data_ptr,
boost::shared_ptr<MatrixDouble> m_D_ptr);
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data,
EntitiesFieldData::EntData &col_data);
private:
boost::shared_ptr<CommonData> commonDataPtr;
boost::shared_ptr<HenckyOps::CommonData> commonHenckyDataPtr;
boost::shared_ptr<MatrixDouble> mDPtr;
MatrixDouble locMat;
MatrixDouble resDiff;
};
struct OpCalculatePlasticFlowLhs_dU : public AssemblyDomainEleOp {
OpCalculatePlasticFlowLhs_dU(const std::string row_field_name,
const std::string col_field_name,
boost::shared_ptr<CommonData> common_data_ptr,
boost::shared_ptr<MatrixDouble> m_D_ptr);
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data,
EntitiesFieldData::EntData &col_data);
private:
boost::shared_ptr<CommonData> commonDataPtr;
boost::shared_ptr<MatrixDouble> mDPtr;
};
struct OpCalculatePlasticFlowLhs_LogStrain_dU : public AssemblyDomainEleOp {
OpCalculatePlasticFlowLhs_LogStrain_dU(
const std::string row_field_name, const std::string col_field_name,
boost::shared_ptr<CommonData> common_data_ptr,
boost::shared_ptr<HenckyOps::CommonData> comman_henky_data_ptr,
boost::shared_ptr<MatrixDouble> m_D_ptr);
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data,
EntitiesFieldData::EntData &col_data);
private:
boost::shared_ptr<CommonData> commonDataPtr;
boost::shared_ptr<HenckyOps::CommonData> commonHenckyDataPtr;
boost::shared_ptr<MatrixDouble> mDPtr;
MatrixDouble resDiff;
};
struct OpCalculatePlasticFlowLhs_dEP : public AssemblyDomainEleOp {
OpCalculatePlasticFlowLhs_dEP(const std::string row_field_name,
const std::string col_field_name,
boost::shared_ptr<CommonData> common_data_ptr,
boost::shared_ptr<MatrixDouble> m_D_ptr);
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data,
EntitiesFieldData::EntData &col_data);
private:
boost::shared_ptr<CommonData> commonDataPtr;
boost::shared_ptr<MatrixDouble> mDPtr;
};
struct OpCalculatePlasticFlowLhs_dTAU : public AssemblyDomainEleOp {
OpCalculatePlasticFlowLhs_dTAU(const std::string row_field_name,
const std::string col_field_name,
boost::shared_ptr<CommonData> common_data_ptr,
boost::shared_ptr<MatrixDouble> m_D_ptr);
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data,
EntitiesFieldData::EntData &col_data);
private:
boost::shared_ptr<CommonData> commonDataPtr;
boost::shared_ptr<MatrixDouble> mDPtr;
};
struct OpCalculateConstraintsLhs_dU : public AssemblyDomainEleOp {
OpCalculateConstraintsLhs_dU(const std::string row_field_name,
const std::string col_field_name,
boost::shared_ptr<CommonData> common_data_ptr,
boost::shared_ptr<MatrixDouble> m_D_ptr);
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data,
EntitiesFieldData::EntData &col_data);
private:
boost::shared_ptr<CommonData> commonDataPtr;
boost::shared_ptr<MatrixDouble> mDPtr;
};
struct OpCalculateConstraintsLhs_LogStrain_dU : public AssemblyDomainEleOp {
OpCalculateConstraintsLhs_LogStrain_dU(
const std::string row_field_name, const std::string col_field_name,
boost::shared_ptr<CommonData> common_data_ptr,
boost::shared_ptr<HenckyOps::CommonData> comman_henky_data_ptr,
boost::shared_ptr<MatrixDouble> m_D_ptr);
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data,
EntitiesFieldData::EntData &col_data);
private:
boost::shared_ptr<CommonData> commonDataPtr;
boost::shared_ptr<HenckyOps::CommonData> commonHenckyDataPtr;
boost::shared_ptr<MatrixDouble> mDPtr;
MatrixDouble resDiff;
};
struct OpCalculateConstraintsLhs_dEP : public AssemblyDomainEleOp {
OpCalculateConstraintsLhs_dEP(const std::string row_field_name,
const std::string col_field_name,
boost::shared_ptr<CommonData> common_data_ptr,
boost::shared_ptr<MatrixDouble> mat_D_ptr);
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data,
EntitiesFieldData::EntData &col_data);
private:
boost::shared_ptr<CommonData> commonDataPtr;
boost::shared_ptr<MatrixDouble> mDPtr;
};
struct OpCalculateConstraintsLhs_dTAU : public AssemblyDomainEleOp {
OpCalculateConstraintsLhs_dTAU(const std::string row_field_name,
const std::string col_field_name,
boost::shared_ptr<CommonData> common_data_ptr);
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data,
EntitiesFieldData::EntData &col_data);
private:
boost::shared_ptr<CommonData> commonDataPtr;
};
//! [Operators definitions]
//! [Lambda functions]
inline auto diff_tensor() {
t_diff(i, j, k, l) = (t_kd(i, k) ^ t_kd(j, l)) / 4.;
return t_diff;
};
inline auto symm_L_tensor() {
t_L(i, j, L) = 0;
if constexpr (SPACE_DIM == 2) {
t_L(0, 0, 0) = 1;
t_L(1, 0, 1) = 1;
t_L(1, 1, 2) = 1;
} else {
t_L(0, 0, 0) = 1;
t_L(1, 0, 1) = 1;
t_L(2, 0, 2) = 1;
t_L(1, 1, 3) = 1;
t_L(2, 1, 4) = 1;
t_L(2, 2, 5) = 1;
}
return t_L;
}
inline auto diff_symmetrize() {
t_diff(i, j, k, l) = 0;
t_diff(0, 0, 0, 0) = 1;
t_diff(1, 1, 1, 1) = 1;
t_diff(1, 0, 1, 0) = 0.5;
t_diff(1, 0, 0, 1) = 0.5;
t_diff(0, 1, 0, 1) = 0.5;
t_diff(0, 1, 1, 0) = 0.5;
if constexpr (SPACE_DIM == 3) {
t_diff(2, 2, 2, 2) = 1;
t_diff(2, 0, 2, 0) = 0.5;
t_diff(2, 0, 0, 2) = 0.5;
t_diff(0, 2, 0, 2) = 0.5;
t_diff(0, 2, 2, 0) = 0.5;
t_diff(2, 1, 2, 1) = 0.5;
t_diff(2, 1, 1, 2) = 0.5;
t_diff(1, 2, 1, 2) = 0.5;
t_diff(1, 2, 2, 1) = 0.5;
}
return t_diff;
};
template <typename T>
constexpr double third = boost::math::constants::third<double>();
if constexpr (SPACE_DIM == 2)
return (t_stress(0, 0) + t_stress(1, 1)) * third;
else
return (t_stress(0, 0) + t_stress(1, 1) + t_stress(2, 2)) * third;
};
template <typename T>
double trace) {
t_dev(I, J) = 0;
for (int ii = 0; ii != SPACE_DIM; ++ii)
for (int jj = ii; jj != SPACE_DIM; ++jj)
t_dev(ii, jj) = t_stress(ii, jj);
t_dev(0, 0) -= trace;
t_dev(1, 1) -= trace;
t_dev(2, 2) -= trace;
return t_dev;
};
inline auto
t_diff_deviator(I, J, k, l) = 0;
for (int ii = 0; ii != SPACE_DIM; ++ii)
for (int jj = ii; jj != SPACE_DIM; ++jj)
for (int kk = 0; kk != SPACE_DIM; ++kk)
for (int ll = kk; ll != SPACE_DIM; ++ll)
t_diff_deviator(ii, jj, kk, ll) = t_diff_stress(ii, jj, kk, ll);
constexpr double third = boost::math::constants::third<double>();
t_diff_deviator(0, 0, 0, 0) -= third;
t_diff_deviator(0, 0, 1, 1) -= third;
t_diff_deviator(1, 1, 0, 0) -= third;
t_diff_deviator(1, 1, 1, 1) -= third;
t_diff_deviator(2, 2, 0, 0) -= third;
t_diff_deviator(2, 2, 1, 1) -= third;
if constexpr (SPACE_DIM == 3) {
t_diff_deviator(0, 0, 2, 2) -= third;
t_diff_deviator(1, 1, 2, 2) -= third;
t_diff_deviator(2, 2, 2, 2) -= third;
}
return t_diff_deviator;
};
/**
*
\f[
\begin{split}
f&=\sqrt{s_{ij}s_{ij}}\\
A_{ij}&=\frac{\partial f}{\partial \sigma_{ij}}=
\frac{1}{f} s_{kl} \frac{\partial s_{kl}}{\partial \sigma_{ij}}\\
\frac{\partial A_{ij}}{\partial \sigma_{kl}}&= \frac{\partial^2 f}{\partial
\sigma_{ij}\partial\sigma_{mn}}= \frac{1}{f} \left( \frac{\partial
s_{kl}}{\partial \sigma_{mn}}\frac{\partial s_{kl}}{\partial \sigma_{ij}}
-A_{mn}A_{ij}
\right)\\
\frac{\partial f}{\partial \varepsilon_{ij}}&=A_{mn}D_{mnij}
\\
\frac{\partial A_{ij}}{\partial \varepsilon_{kl}}&=
\frac{\partial A_{ij}}{\partial \sigma_{mn}} \frac{\partial
\sigma_{mn}}{\partial \varepsilon_{kl}}= \frac{\partial A_{ij}}{\partial
\sigma_{mn}} D_{mnkl}
\end{split}
\f]
*/
inline double
return std::sqrt(1.5 * t_stress_deviator(I, J) * t_stress_deviator(I, J)) +
std::numeric_limits<double>::epsilon();
};
inline auto plastic_flow(long double f,
t_diff_f(k, l) =
(1.5 * (t_dev_stress(I, J) * t_diff_deviator(I, J, k, l))) / f;
return t_diff_f;
};
template <typename T>
t_diff_flow(i, j, k, l) =
(1.5 * (t_diff_deviator(M, N, i, j) * t_diff_deviator(M, N, k, l) -
(2. / 3.) * t_flow(i, j) * t_flow(k, l))) /
f;
return t_diff_flow;
};
template <typename T>
FTensor::Ddg<double, SPACE_DIM, SPACE_DIM> &&t_diff_plastic_flow_dstress) {
t_diff_flow(i, j, k, l) =
t_diff_plastic_flow_dstress(i, j, m, n) * t_D(m, n, k, l);
return t_diff_flow;
};
inline double constrain_diff_sign(double x) {
const auto y = x / zeta;
if (y > std::numeric_limits<float>::max_exponent10 ||
y < std::numeric_limits<float>::min_exponent10) {
return 0;
} else {
const auto e = std::exp(y);
const auto ep1 = e + 1;
return (2 / zeta) * (e / (ep1 * ep1));
}
};
inline double constrian_sign(double x) {
const auto y = x / zeta;
if (y > std::numeric_limits<float>::max_exponent10 ||
y < std::numeric_limits<float>::min_exponent10) {
if (x > 0)
return 1.;
else
return -1.;
} else {
const auto e = std::exp(y);
return (e - 1) / (1 + e);
}
};
inline double constrain_abs(double x) {
const auto y = -x / zeta;
if (y > std::numeric_limits<float>::max_exponent10 ||
y < std::numeric_limits<float>::min_exponent10) {
return std::abs(x);
} else {
const double e = std::exp(y);
return x + 2 * zeta * std::log1p(e);
}
};
inline double w(double eqiv, double dot_tau, double f, double sigma_y) {
return (f - sigma_y) / sigmaY + cn1 * (dot_tau * std::sqrt(eqiv));
};
/**
\f[
\dot{\tau} - \frac{1}{2}\left\{\dot{\tau} + (f(\pmb\sigma) - \sigma_y) +
\| \dot{\tau} + (f(\pmb\sigma) - \sigma_y) \|\right\} = 0 \\
c_n \sigma_y \dot{\tau} - \frac{1}{2}\left\{c_n\sigma_y \dot{\tau} +
(f(\pmb\sigma) - \sigma_y) +
\| c_n \sigma_y \dot{\tau} + (f(\pmb\sigma) - \sigma_y) \|\right\} = 0
\f]
*/
inline double constraint(double eqiv, double dot_tau, double f, double sigma_y,
double abs_w) {
return visH * dot_tau + (sigmaY / 2) * ((cn0 * (dot_tau - eqiv) +
cn1 * (std::sqrt(eqiv) * dot_tau) -
(f - sigma_y) / sigmaY) -
abs_w);
};
inline double diff_constrain_ddot_tau(double sign, double eqiv) {
return visH + (sigmaY / 2) * (cn0 + cn1 * std::sqrt(eqiv) * (1 - sign));
};
inline double diff_constrain_eqiv(double sign, double eqiv, double dot_tau) {
return (sigmaY / 2) *
(-cn0 + cn1 * dot_tau * (0.5 / std::sqrt(eqiv)) * (1 - sign));
};
inline auto diff_constrain_df(double sign) { return (-1 - sign) / 2; };
inline auto diff_constrain_dsigma_y(double sign) { return (1 + sign) / 2; }
template <typename T>
t_diff_constrain_dstress(i, j) = diff_constrain_df * t_plastic_flow(i, j);
return t_diff_constrain_dstress;
};
template <typename T1, typename T2>
inline auto diff_constrain_dstrain(T1 &t_D, T2 &&t_diff_constrain_dstress) {
t_diff_constrain_dstrain(k, l) =
t_diff_constrain_dstress(i, j) * t_D(i, j, k, l);
return t_diff_constrain_dstrain;
};
template <typename T>
constexpr double A = 2. / 3;
return std::sqrt(A * t_plastic_strain_dot(i, j) *
t_plastic_strain_dot(i, j)) +
std::numeric_limits<double>::epsilon();
};
template <typename T1, typename T2, typename T3>
inline auto diff_equivalent_strain_dot(const T1 eqiv, T2 &t_plastic_strain_dot,
T3 &t_diff_plastic_strain) {
constexpr double A = 2. / 3;
t_diff_eqiv(i, j) = A * (t_plastic_strain_dot(k, l) / eqiv) *
t_diff_plastic_strain(k, l, i, j);
return t_diff_eqiv;
};
//! [Lambda functions]
//! [Auxiliary functions functions
static inline auto get_mat_tensor_sym_dvector(size_t rr, MatrixDouble &mat,
&mat(3 * rr + 0, 0), &mat(3 * rr + 0, 1), &mat(3 * rr + 1, 0),
&mat(3 * rr + 1, 1), &mat(3 * rr + 2, 0), &mat(3 * rr + 2, 1)};
}
static inline auto get_mat_tensor_sym_dvector(size_t rr, MatrixDouble &mat,
&mat(6 * rr + 0, 0), &mat(6 * rr + 0, 1), &mat(6 * rr + 0, 2),
&mat(6 * rr + 1, 0), &mat(6 * rr + 1, 1), &mat(6 * rr + 1, 2),
&mat(6 * rr + 2, 0), &mat(6 * rr + 2, 1), &mat(6 * rr + 2, 2),
&mat(6 * rr + 3, 0), &mat(6 * rr + 3, 1), &mat(6 * rr + 3, 2),
&mat(6 * rr + 4, 0), &mat(6 * rr + 4, 1), &mat(6 * rr + 4, 2),
&mat(6 * rr + 5, 0), &mat(6 * rr + 5, 1), &mat(6 * rr + 5, 2)};
}
//! [Auxiliary functions functions
}; // namespace PlasticOps
constexpr double third
constexpr int SPACE_DIM
Kronecker Delta class symmetric.
constexpr auto t_kd
auto diff_constrain_dstress(double diff_constrain_df, FTensor::Tensor2_symmetric< T, SPACE_DIM > &t_plastic_flow)
Definition: PlasticOps.hpp:550
auto symm_L_tensor()
Definition: PlasticOps.hpp:315
auto deviator(FTensor::Tensor2_symmetric< T, SPACE_DIM > &t_stress, double trace)
Definition: PlasticOps.hpp:373
double constrian_sign(double x)
Definition: PlasticOps.hpp:488
double platsic_surface(FTensor::Tensor2_symmetric< double, 3 > &&t_stress_deviator)
Definition: PlasticOps.hpp:440
FTensor::Index< 'p', SPACE_DIM > p
Definition: PlasticOps.hpp:99
FTensor::Index< 'j', SPACE_DIM > j
Definition: PlasticOps.hpp:93
FTensor::Index< 'M', 3 > M
Definition: PlasticOps.hpp:103
auto diff_constrain_dstrain(T1 &t_D, T2 &&t_diff_constrain_dstress)
Definition: PlasticOps.hpp:559
double diff_constrain_eqiv(double sign, double eqiv, double dot_tau)
Definition: PlasticOps.hpp:540
double constrain_diff_sign(double x)
Definition: PlasticOps.hpp:476
auto plastic_flow(long double f, FTensor::Tensor2_symmetric< double, 3 > &&t_dev_stress, FTensor::Ddg< double, 3, SPACE_DIM > &&t_diff_deviator)
Definition: PlasticOps.hpp:445
FTensor::Index< 'O', size_symm > O
Definition: PlasticOps.hpp:107
FTensor::Index< 'L', size_symm > L
Definition: PlasticOps.hpp:106
FTensor::Index< 'l', SPACE_DIM > l
Definition: PlasticOps.hpp:95
FTensor::Index< 'k', SPACE_DIM > k
Definition: PlasticOps.hpp:94
auto diff_tensor()
[Operators definitions]
Definition: PlasticOps.hpp:308
auto diff_constrain_df(double sign)
Definition: PlasticOps.hpp:545
double w(double eqiv, double dot_tau, double f, double sigma_y)
Definition: PlasticOps.hpp:513
FTensor::Index< 'N', 3 > N
Definition: PlasticOps.hpp:104
auto diff_constrain_dsigma_y(double sign)
Definition: PlasticOps.hpp:547
FTensor::Index< 'I', 3 > I
Definition: PlasticOps.hpp:101
auto diff_deviator(FTensor::Ddg< double, SPACE_DIM, SPACE_DIM > &&t_diff_stress)
Definition: PlasticOps.hpp:387
FTensor::Index< 'i', SPACE_DIM > i
[Common data]
Definition: PlasticOps.hpp:92
FTensor::Index< 'o', SPACE_DIM > o
Definition: PlasticOps.hpp:98
FTensor::Index< 'm', SPACE_DIM > m
Definition: PlasticOps.hpp:96
double constrain_abs(double x)
Definition: PlasticOps.hpp:502
FTensor::Index< 'J', 3 > J
Definition: PlasticOps.hpp:102
auto diff_equivalent_strain_dot(const T1 eqiv, T2 &t_plastic_strain_dot, T3 &t_diff_plastic_strain)
Definition: PlasticOps.hpp:576
double trace(FTensor::Tensor2_symmetric< T, SPACE_DIM > &t_stress)
Definition: PlasticOps.hpp:364
auto diff_symmetrize()
Definition: PlasticOps.hpp:333
auto diff_plastic_flow_dstress(long double f, FTensor::Tensor2_symmetric< T, SPACE_DIM > &t_flow, FTensor::Ddg< double, 3, SPACE_DIM > &&t_diff_deviator)
Definition: PlasticOps.hpp:455
auto diff_plastic_flow_dstrain(FTensor::Ddg< T, SPACE_DIM, SPACE_DIM > &t_D, FTensor::Ddg< double, SPACE_DIM, SPACE_DIM > &&t_diff_plastic_flow_dstress)
Definition: PlasticOps.hpp:467
double constraint(double eqiv, double dot_tau, double f, double sigma_y, double abs_w)
Definition: PlasticOps.hpp:528
double diff_constrain_ddot_tau(double sign, double eqiv)
Definition: PlasticOps.hpp:536
auto equivalent_strain_dot(FTensor::Tensor2_symmetric< T, SPACE_DIM > &t_plastic_strain_dot)
Definition: PlasticOps.hpp:567
FTensor::Index< 'n', SPACE_DIM > n
Definition: PlasticOps.hpp:97
static auto get_mat_tensor_sym_dvector(size_t rr, MatrixDouble &mat, FTensor::Number< 2 >)
[Lambda functions]
Definition: PlasticOps.hpp:588
constexpr AssemblyType A
double visH
Definition: plastic.cpp:104
double scale
Definition: plastic.cpp:97
double zeta
Definition: plastic.cpp:107
double cn0
Definition: plastic.cpp:105
double sigmaY
Definition: plastic.cpp:102
double cn1
Definition: plastic.cpp:106
constexpr auto field_name
Deprecated interface functions.
Data on single entity (This is passed as argument to DataOperator::doWork)
boost::shared_ptr< MatrixDouble > mStrainPtr
Definition: PlasticOps.hpp:48
MatrixDouble resFlowDstrainDot
Definition: PlasticOps.hpp:65
VectorDouble resCdTau
Definition: PlasticOps.hpp:59
MatrixDouble resCdStrain
Definition: PlasticOps.hpp:60
boost::shared_ptr< MatrixDouble > mGradPtr
Definition: PlasticOps.hpp:47
MatrixDouble resFlow
Definition: PlasticOps.hpp:62
VectorDouble plasticTauDot
Definition: PlasticOps.hpp:54
boost::shared_ptr< MatrixDouble > mDPtr
Definition: PlasticOps.hpp:44
VectorDouble plasticSurface
Definition: PlasticOps.hpp:51
boost::shared_ptr< MatrixDouble > mDPtr_Axiator
Definition: PlasticOps.hpp:45
MatrixDouble resFlowDtau
Definition: PlasticOps.hpp:63
MatrixDouble resCdStrainDot
Definition: PlasticOps.hpp:61
MatrixDouble plasticStrain
Definition: PlasticOps.hpp:55
boost::shared_ptr< MatrixDouble > mStressPtr
Definition: PlasticOps.hpp:49
MatrixDouble plasticFlow
Definition: PlasticOps.hpp:52
MatrixDouble plasticStrainDot
Definition: PlasticOps.hpp:56
VectorDouble plasticTau
Definition: PlasticOps.hpp:53
MatrixDouble resFlowDstrain
Definition: PlasticOps.hpp:64
boost::shared_ptr< MatrixDouble > mDPtr_Deviator
Definition: PlasticOps.hpp:46
std::array< int, 5 > activityData
Definition: PlasticOps.hpp:67
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data, EntitiesFieldData::EntData &col_data)
boost::shared_ptr< MatrixDouble > mDPtr
Definition: PlasticOps.hpp:277
boost::shared_ptr< CommonData > commonDataPtr
Definition: PlasticOps.hpp:275
boost::shared_ptr< HenckyOps::CommonData > commonHenckyDataPtr
Definition: PlasticOps.hpp:276
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data, EntitiesFieldData::EntData &col_data)
boost::shared_ptr< CommonData > commonDataPtr
Definition: PlasticOps.hpp:290
boost::shared_ptr< MatrixDouble > mDPtr
Definition: PlasticOps.hpp:291
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data, EntitiesFieldData::EntData &col_data)
boost::shared_ptr< CommonData > commonDataPtr
Definition: PlasticOps.hpp:302
boost::shared_ptr< CommonData > commonDataPtr
Definition: PlasticOps.hpp:261
boost::shared_ptr< MatrixDouble > mDPtr
Definition: PlasticOps.hpp:262
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data, EntitiesFieldData::EntData &col_data)
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &data)
boost::shared_ptr< CommonData > commonDataPtr
Definition: PlasticOps.hpp:162
boost::shared_ptr< MatrixDouble > mDPtr
Definition: PlasticOps.hpp:163
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data, EntitiesFieldData::EntData &col_data)
boost::shared_ptr< MatrixDouble > mDPtr
Definition: PlasticOps.hpp:222
boost::shared_ptr< HenckyOps::CommonData > commonHenckyDataPtr
Definition: PlasticOps.hpp:221
boost::shared_ptr< CommonData > commonDataPtr
Definition: PlasticOps.hpp:220
boost::shared_ptr< MatrixDouble > mDPtr
Definition: PlasticOps.hpp:236
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data, EntitiesFieldData::EntData &col_data)
boost::shared_ptr< CommonData > commonDataPtr
Definition: PlasticOps.hpp:235
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data, EntitiesFieldData::EntData &col_data)
boost::shared_ptr< CommonData > commonDataPtr
Definition: PlasticOps.hpp:248
boost::shared_ptr< MatrixDouble > mDPtr
Definition: PlasticOps.hpp:249
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data, EntitiesFieldData::EntData &col_data)
boost::shared_ptr< MatrixDouble > mDPtr
Definition: PlasticOps.hpp:207
boost::shared_ptr< CommonData > commonDataPtr
Definition: PlasticOps.hpp:206
boost::shared_ptr< MatrixDouble > mDPtr
Definition: PlasticOps.hpp:152
boost::shared_ptr< CommonData > commonDataPtr
Definition: PlasticOps.hpp:151
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &data)
boost::shared_ptr< HenckyOps::CommonData > commonHenckyDataPtr
Definition: PlasticOps.hpp:191
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data, EntitiesFieldData::EntData &col_data)
MoFEMErrorCode iNtegrate(EntitiesFieldData::EntData &row_data, EntitiesFieldData::EntData &col_data)
boost::shared_ptr< CommonData > commonDataPtr
Definition: PlasticOps.hpp:175
boost::shared_ptr< MatrixDouble > mDPtr
Definition: PlasticOps.hpp:176
MoFEMErrorCode doWork(int side, EntityType type, EntData &data)
Operator for linear form, usually to calculate values on right hand side.
boost::shared_ptr< CommonData > commonDataPtr
Definition: PlasticOps.hpp:116
boost::shared_ptr< CommonData > commonDataPtr
Definition: PlasticOps.hpp:127
boost::shared_ptr< MatrixDouble > mDPtr
Definition: PlasticOps.hpp:128
MoFEMErrorCode doWork(int side, EntityType type, EntData &data)
Operator for linear form, usually to calculate values on right hand side.
boost::shared_ptr< CommonData > commonDataPtr
Definition: PlasticOps.hpp:141
MoFEMErrorCode doWork(int side, EntityType type, EntData &data)
[Calculate stress]
boost::shared_ptr< MatrixDouble > mDPtr
Definition: PlasticOps.hpp:139