Mechanics of Defect Evolution Library
Loading...
Searching...
No Matches
src/InclusionMicrostructure/EshelbyInclusionBase.cpp
Go to the documentation of this file.
1/* This file is part of MoDELib, the Mechanics Of Defects Evolution Library.
2 *
3 *
4 * MoDELib is distributed without any warranty under the
5 * GNU General Public License (GPL) v2 <http://www.gnu.org/licenses/>.
6 */
7
8#ifndef model_EshelbyInclusionBase_cpp_
9#define model_EshelbyInclusionBase_cpp_
10
11
13
14namespace model
15{
16
17
18// template <int dim>
19// void EshelbyInclusionBase<dim>::addSlipSystems(const std::vector<std::shared_ptr<SlipSystem>>& slipSystems)
20// {
21//
22// for(const auto& slipSystem : slipSystems)
23// {
24// if(gammaSurfaceMap.find(slipSystem->gammaSurface.get())==gammaSurfaceMap.end())
25// {// current slipSystem gammaSurface not found
26//
27// // GammaSurface temp();
28// //
29// // gammaSurfaceMap.emaplace(slipSystem->gammaSurface.get(),temp);
30// }
31// }
32//
33// }
34
35// template <int dim>
36// double EshelbyInclusionBase<dim>::misfitEnergy(const Eigen::Matrix<double,3,1>& b, const GammaSurface* const matrixGammaSurface) const
37// {
38// const auto iter(gammaSurfaceMap.find(matrixGammaSurface));
39// return iter==gammaSurfaceMap.end()? 0.0 : iter->second(b);
40// }
41
42 /**********************************************************************/
43 template <int dim>
45 const MatrixDim& _eT,
46 const double& _nu,
47 const double& _mu,
48 const double& _mobilityReduction,
49 const int& _phaseID,
50 const std::shared_ptr<SecondPhase<dim>>& sph) :
51 /* init */ nu(_nu)
52 /* init */,mu(_mu)
53 /* init */,lambda(2.0*mu*nu/(1.0-2.0*nu))
54 /* init */,mobilityReduction(_mobilityReduction)
55 /* init */,phaseID(_phaseID)
56 /* init */,secondPhase(sph)
57 /* init */,eT(_eT)
58 /* init */,eTNorm(eT.norm())
59 /* init */,pT(2.0*mu*(eT+nu/(1.0-2.0*nu)*eT.trace()*MatrixDim::Identity()))
60 {
61 assert((_eT-_eT.transpose()).norm()<FLT_EPSILON && "eT is not symmetric.");
62 }
63
64 template <int dim>
66
67 template class EshelbyInclusionBase<3>;
68
69}
70#endif
const std::shared_ptr< SecondPhase< dim > > secondPhase
EshelbyInclusionBase(const MatrixDim &_eT, const double &_nu, const double &_mu, const double &_mobilityReduction, const int &_phaseID, const std::shared_ptr< SecondPhase< dim > > &sph)