Go to the documentation of this file.
21 #ifndef __nonLinearCF_hpp__
22 #define __nonLinearCF_hpp__
29 template<
bool limited=true>
82 auto nElem = Yeff.
size();
84 if(nElem != nu.
size())
87 "sizes of Yeff("<<nElem<<
") and nu("<<nu.
size()<<
") do not match.\n";
91 if(nElem != en.
size())
94 "sizes of Yeff("<<nElem<<
") and en("<<en.
size()<<
") do not match.\n";
99 if(nElem != mu.
size())
102 "sizes of Yeff("<<nElem<<
") and mu("<<mu.
size()<<
") do not match.\n";
112 "sizes of properties do not match a symetric array with size ("<<
119 "size mismatch for porperties. \n";
133 etha_n[i] = -2.2664*
log(en[i])/
143 prop[i] = {Yeff[i], Geff[i], etha_n[i], mu[i]};
154 if constexpr (limited)
156 return "nonLinearLimited";
160 return "nonLinearNonLimited";
178 rho_(
"rho",nMaterial),
182 Kokkos::deep_copy(
rho_,rho);
242 real Reff = 1.0/(1/Ri + 1/Rj);
244 real K_hertz = 4.0/3.0*prop.Yeff_*
sqrt(Reff);
245 real sqrt_meff_K_hertz =
sqrt((mi*mj)/(mi+mj) * K_hertz);
247 FCn = (
static_cast<real>(-4.0/3.0) * prop.Yeff_ *
sqrt(Reff)*
pow(ovrlp_n,
static_cast<real>(1.5)) -
248 sqrt_meff_K_hertz*prop.ethan_*
pow(ovrlp_n,
static_cast<real>(0.25))*vrn)*Nij;
250 FCt = (-
static_cast<real>(8.0) * prop.Geff_ *
sqrt(Reff*ovrlp_n) ) * history.
overlap_t_;
260 if constexpr (limited)
262 real kt =
static_cast<real>(8.0) * prop.Geff_ *
sqrt(Reff*ovrlp_n);
268 FCt = (FCt/ft)*ft_fric;
INLINE_FUNCTION_HD ~nonLinearProperties()=default
#define fatalExit
Fatal exit.
INLINE_FUNCTION_HD ~nonLinear()=default
Vector< T, Allocator > pow(const Vector< T, Allocator > &v1, const Vector< T, Allocator > &v2)
Vector< T, Allocator > sqrt(const Vector< T, Allocator > &v)
INLINE_FUNCTION_HD nonLinear()
auto size() const
Size of the vector.
INLINE_FUNCTION_HD nonLinearProperties(real Yeff, real Geff, real etha_n, real mu)
static bool getN(uint32 nElem, uint32 &n)
NonLinearArrayType nonlinearProperties_
INLINE_FUNCTION_HD T dot(const quadruple< T > &oprnd1, const quadruple< T > &oprnd2)
bool assign(const Vector< T > src)
INLINE_FUNCTION_HD void contactForce(const real dt, const uint32 i, const uint32 j, const uint32 propId_i, const uint32 propId_j, const real Ri, const real Rj, const real ovrlp_n, const realx3 &Vr, const realx3 &Nij, contactForceStorage &history, realx3 &FCn, realx3 &FCt) const
#define fatalErrorInFunction
Report a fatal error and function name and exit the application.
INLINE_FUNCTION_HD T length(const triple< T > &v1)
Vector< T, Allocator > log(const Vector< T, Allocator > &v)
nonLinear(int32 nMaterial, const ViewType1D< real > &rho, const dictionary &dict)
#define ForAll(i, container)
INLINE_FUNCTION_HD nonLinear & operator=(const nonLinear &)=default
static const char * modelName()
Kokkos::View< T *, properties... > ViewType1D
1D veiw as a vector
T getVal(const word &keyword) const
get the value of data entry
bool readNonLinearDictionary(const dictionary &dict)
INLINE_FUNCTION_HD int32 numMaterial() const
#define INLINE_FUNCTION_HD
INLINE_FUNCTION_HD nonLinearProperties & operator=(const nonLinearProperties &)=default
INLINE_FUNCTION_HD nonLinearProperties()
Dictionary holds a set of data entries or sub-dictionaries that are enclosed in a curely braces or ar...