transitioned remaining real exponents to int
This commit is contained in:
parent
81daebd0e6
commit
a531b7ccae
|
@ -578,7 +578,7 @@ real(pReal) function utilities_divergenceRMS()
|
||||||
do k = 1, grid3; do j = 1, grid(2)
|
do k = 1, grid3; do j = 1, grid(2)
|
||||||
do i = 2, grid1Red -1 ! Has somewhere a conj. complex counterpart. Therefore count it twice.
|
do i = 2, grid1Red -1 ! Has somewhere a conj. complex counterpart. Therefore count it twice.
|
||||||
utilities_divergenceRMS = utilities_divergenceRMS &
|
utilities_divergenceRMS = utilities_divergenceRMS &
|
||||||
+ 2.0_pReal*(sum (real(matmul(tensorField_fourier(1:3,1:3,i,j,k), & ! (sqrt(real(a)**2 + aimag(a)**2))**2 = real(a)**2 + aimag(a)**2. do not take square root and square again
|
+ 2.0_pReal*(sum (real(matmul(tensorField_fourier(1:3,1:3,i,j,k), & ! (sqrt(real(a)**2 + aimag(a)**2))**2 = real(a)**2 + aimag(a)**2, i.e. do not take square root and square again
|
||||||
conjg(-xi1st(1:3,i,j,k))*rescaledGeom))**2) & ! --> sum squared L_2 norm of vector
|
conjg(-xi1st(1:3,i,j,k))*rescaledGeom))**2) & ! --> sum squared L_2 norm of vector
|
||||||
+sum(aimag(matmul(tensorField_fourier(1:3,1:3,i,j,k),&
|
+sum(aimag(matmul(tensorField_fourier(1:3,1:3,i,j,k),&
|
||||||
conjg(-xi1st(1:3,i,j,k))*rescaledGeom))**2))
|
conjg(-xi1st(1:3,i,j,k))*rescaledGeom))**2))
|
||||||
|
|
|
@ -1086,15 +1086,15 @@ function math_eigvalsh33(m)
|
||||||
|
|
||||||
I = math_invariantsSym33(m) ! invariants are coefficients in characteristic polynomial apart for the sign of c0 and c2 in http://arxiv.org/abs/physics/0610206
|
I = math_invariantsSym33(m) ! invariants are coefficients in characteristic polynomial apart for the sign of c0 and c2 in http://arxiv.org/abs/physics/0610206
|
||||||
|
|
||||||
P = I(2)-I(1)**2.0_pReal/3.0_pReal ! different from http://arxiv.org/abs/physics/0610206 (this formulation was in DAMASK)
|
P = I(2)-I(1)**2/3.0_pReal ! different from http://arxiv.org/abs/physics/0610206 (this formulation was in DAMASK)
|
||||||
Q = product(I(1:2))/3.0_pReal &
|
Q = product(I(1:2))/3.0_pReal &
|
||||||
- 2.0_pReal/27.0_pReal*I(1)**3.0_pReal &
|
- 2.0_pReal/27.0_pReal*I(1)**3 &
|
||||||
- I(3) ! different from http://arxiv.org/abs/physics/0610206 (this formulation was in DAMASK)
|
- I(3) ! different from http://arxiv.org/abs/physics/0610206 (this formulation was in DAMASK)
|
||||||
|
|
||||||
if (all(abs([P,Q]) < TOL)) then
|
if (all(abs([P,Q]) < TOL)) then
|
||||||
math_eigvalsh33 = math_eigvalsh(m)
|
math_eigvalsh33 = math_eigvalsh(m)
|
||||||
else
|
else
|
||||||
rho=sqrt(-3.0_pReal*P**3.0_pReal)/9.0_pReal
|
rho=sqrt(-3.0_pReal*P**3)/9.0_pReal
|
||||||
phi=acos(math_clip(-Q/rho*0.5_pReal,-1.0_pReal,1.0_pReal))
|
phi=acos(math_clip(-Q/rho*0.5_pReal,-1.0_pReal,1.0_pReal))
|
||||||
math_eigvalsh33 = 2.0_pReal*rho**(1.0_pReal/3.0_pReal)* &
|
math_eigvalsh33 = 2.0_pReal*rho**(1.0_pReal/3.0_pReal)* &
|
||||||
[cos( phi /3.0_pReal), &
|
[cos( phi /3.0_pReal), &
|
||||||
|
|
|
@ -388,8 +388,7 @@ module function phase_K_phi(co,ce) result(K)
|
||||||
real(pReal), dimension(3,3) :: K
|
real(pReal), dimension(3,3) :: K
|
||||||
real(pReal), parameter :: l = 1.0_pReal
|
real(pReal), parameter :: l = 1.0_pReal
|
||||||
|
|
||||||
K = crystallite_push33ToRef(co,ce,param(material_phaseID(co,ce))%D) &
|
K = crystallite_push33ToRef(co,ce,param(material_phaseID(co,ce))%D) * l**2
|
||||||
* l**2.0_pReal
|
|
||||||
|
|
||||||
end function phase_K_phi
|
end function phase_K_phi
|
||||||
|
|
||||||
|
|
|
@ -129,7 +129,7 @@ module subroutine anisobrittle_dotState(S, ph,en)
|
||||||
traction_t = math_tensordot(S,prm%cleavage_systems(1:3,1:3,2,i))
|
traction_t = math_tensordot(S,prm%cleavage_systems(1:3,1:3,2,i))
|
||||||
traction_n = math_tensordot(S,prm%cleavage_systems(1:3,1:3,3,i))
|
traction_n = math_tensordot(S,prm%cleavage_systems(1:3,1:3,3,i))
|
||||||
|
|
||||||
traction_crit = prm%g_crit(i)*damage_phi(ph,en)**2.0_pReal
|
traction_crit = prm%g_crit(i)*damage_phi(ph,en)**2
|
||||||
|
|
||||||
damageState(ph)%dotState(1,en) = damageState(ph)%dotState(1,en) &
|
damageState(ph)%dotState(1,en) = damageState(ph)%dotState(1,en) &
|
||||||
+ prm%dot_o / prm%s_crit(i) &
|
+ prm%dot_o / prm%s_crit(i) &
|
||||||
|
@ -190,7 +190,7 @@ module subroutine damage_anisobrittle_LiAndItsTangent(Ld, dLd_dTstar, S, ph,en)
|
||||||
dLd_dTstar = 0.0_pReal
|
dLd_dTstar = 0.0_pReal
|
||||||
associate(prm => param(ph))
|
associate(prm => param(ph))
|
||||||
do i = 1,prm%sum_N_cl
|
do i = 1,prm%sum_N_cl
|
||||||
traction_crit = prm%g_crit(i)*damage_phi(ph,en)**2.0_pReal
|
traction_crit = prm%g_crit(i)*damage_phi(ph,en)**2
|
||||||
|
|
||||||
traction_d = math_tensordot(S,prm%cleavage_systems(1:3,1:3,1,i))
|
traction_d = math_tensordot(S,prm%cleavage_systems(1:3,1:3,1,i))
|
||||||
if (abs(traction_d) > traction_crit + tol_math_check) then
|
if (abs(traction_d) > traction_crit + tol_math_check) then
|
||||||
|
|
|
@ -166,7 +166,7 @@ module function plastic_dislotungsten_init() result(myPlasticity)
|
||||||
prm%D = pl%get_asFloat('D')
|
prm%D = pl%get_asFloat('D')
|
||||||
prm%D_0 = pl%get_asFloat('D_0')
|
prm%D_0 = pl%get_asFloat('D_0')
|
||||||
prm%Q_cl = pl%get_asFloat('Q_cl')
|
prm%Q_cl = pl%get_asFloat('Q_cl')
|
||||||
prm%f_at = pl%get_asFloat('f_at') * prm%b_sl**3.0_pReal
|
prm%f_at = pl%get_asFloat('f_at') * prm%b_sl**3
|
||||||
|
|
||||||
prm%dipoleformation = .not. pl%get_asBool('no_dipole_formation', defaultVal = .false.)
|
prm%dipoleformation = .not. pl%get_asBool('no_dipole_formation', defaultVal = .false.)
|
||||||
|
|
||||||
|
@ -498,7 +498,7 @@ pure subroutine kinetics(Mp,T,ph,en, &
|
||||||
* StressRatio_pminus1 / prm%tau_Peierls
|
* StressRatio_pminus1 / prm%tau_Peierls
|
||||||
dtk = -1.0_pReal * t_k / tau_pos
|
dtk = -1.0_pReal * t_k / tau_pos
|
||||||
|
|
||||||
dvel = -1.0_pReal * prm%h * (dtk + dtn) / (t_n + t_k)**2.0_pReal
|
dvel = -1.0_pReal * prm%h * (dtk + dtn) / (t_n + t_k)**2
|
||||||
|
|
||||||
ddot_gamma_dtau_pos = b_rho_half * dvel
|
ddot_gamma_dtau_pos = b_rho_half * dvel
|
||||||
else where significantPositiveTau2
|
else where significantPositiveTau2
|
||||||
|
@ -528,7 +528,7 @@ pure subroutine kinetics(Mp,T,ph,en, &
|
||||||
* StressRatio_pminus1 / prm%tau_Peierls
|
* StressRatio_pminus1 / prm%tau_Peierls
|
||||||
dtk = -1.0_pReal * t_k / tau_neg
|
dtk = -1.0_pReal * t_k / tau_neg
|
||||||
|
|
||||||
dvel = -1.0_pReal * prm%h * (dtk + dtn) / (t_n + t_k)**2.0_pReal
|
dvel = -1.0_pReal * prm%h * (dtk + dtn) / (t_n + t_k)**2
|
||||||
|
|
||||||
ddot_gamma_dtau_neg = b_rho_half * dvel
|
ddot_gamma_dtau_neg = b_rho_half * dvel
|
||||||
else where significantNegativeTau2
|
else where significantNegativeTau2
|
||||||
|
|
|
@ -691,8 +691,8 @@ module subroutine dislotwin_dotState(Mp,T,ph,en)
|
||||||
* (prm%Gamma_sf(1) + prm%Gamma_sf(2) * T) / (mu*prm%b_sl(i)), &
|
* (prm%Gamma_sf(1) + prm%Gamma_sf(2) * T) / (mu*prm%b_sl(i)), &
|
||||||
1.0_pReal, &
|
1.0_pReal, &
|
||||||
prm%ExtendedDislocations)
|
prm%ExtendedDislocations)
|
||||||
v_cl = 2.0_pReal*prm%omega*b_d**2.0_pReal*exp(-prm%Q_cl/(K_B*T)) &
|
v_cl = 2.0_pReal*prm%omega*b_d**2*exp(-prm%Q_cl/(K_B*T)) &
|
||||||
* (exp(abs(sigma_cl)*prm%b_sl(i)**3.0_pReal/(K_B*T)) - 1.0_pReal)
|
* (exp(abs(sigma_cl)*prm%b_sl(i)**3/(K_B*T)) - 1.0_pReal)
|
||||||
|
|
||||||
dot_rho_dip_climb(i) = 4.0_pReal*v_cl*stt%rho_dip(i,en) &
|
dot_rho_dip_climb(i) = 4.0_pReal*v_cl*stt%rho_dip(i,en) &
|
||||||
/ (d_hat-prm%d_caron(i))
|
/ (d_hat-prm%d_caron(i))
|
||||||
|
@ -784,14 +784,14 @@ module subroutine dislotwin_dependentState(T,ph,en)
|
||||||
+ 3.0_pReal*prm%b_tr*mu/(prm%L_tr*prm%b_tr) &
|
+ 3.0_pReal*prm%b_tr*mu/(prm%L_tr*prm%b_tr) &
|
||||||
+ prm%h*prm%delta_G/(3.0_pReal*prm%b_tr)
|
+ prm%h*prm%delta_G/(3.0_pReal*prm%b_tr)
|
||||||
|
|
||||||
dst%V_tw(:,en) = (PI/4.0_pReal)*prm%t_tw*dst%Lambda_tw(:,en)**2.0_pReal
|
dst%V_tw(:,en) = (PI/4.0_pReal)*prm%t_tw*dst%Lambda_tw(:,en)**2
|
||||||
dst%V_tr(:,en) = (PI/4.0_pReal)*prm%t_tr*dst%Lambda_tr(:,en)**2.0_pReal
|
dst%V_tr(:,en) = (PI/4.0_pReal)*prm%t_tr*dst%Lambda_tr(:,en)**2
|
||||||
|
|
||||||
|
|
||||||
x0 = mu*prm%b_tw**2.0_pReal/(Gamma*8.0_pReal*PI)*(2.0_pReal+nu)/(1.0_pReal-nu) ! ToDo: In the paper, this is the Burgers vector for slip
|
x0 = mu*prm%b_tw**2/(Gamma*8.0_pReal*PI)*(2.0_pReal+nu)/(1.0_pReal-nu) ! ToDo: In the paper, this is the Burgers vector for slip
|
||||||
dst%tau_r_tw(:,en) = mu*prm%b_tw/(2.0_pReal*PI)*(1.0_pReal/(x0+prm%x_c_tw)+cos(pi/3.0_pReal)/x0)
|
dst%tau_r_tw(:,en) = mu*prm%b_tw/(2.0_pReal*PI)*(1.0_pReal/(x0+prm%x_c_tw)+cos(pi/3.0_pReal)/x0)
|
||||||
|
|
||||||
x0 = mu*prm%b_tr**2.0_pReal/(Gamma*8.0_pReal*PI)*(2.0_pReal+nu)/(1.0_pReal-nu) ! ToDo: In the paper, this is the Burgers vector for slip
|
x0 = mu*prm%b_tr**2/(Gamma*8.0_pReal*PI)*(2.0_pReal+nu)/(1.0_pReal-nu) ! ToDo: In the paper, this is the Burgers vector for slip
|
||||||
dst%tau_r_tr(:,en) = mu*prm%b_tr/(2.0_pReal*PI)*(1.0_pReal/(x0+prm%x_c_tr)+cos(pi/3.0_pReal)/x0)
|
dst%tau_r_tr(:,en) = mu*prm%b_tr/(2.0_pReal*PI)*(1.0_pReal/(x0+prm%x_c_tr)+cos(pi/3.0_pReal)/x0)
|
||||||
|
|
||||||
end associate
|
end associate
|
||||||
|
@ -917,7 +917,7 @@ pure subroutine kinetics_sl(Mp,T,ph,en, &
|
||||||
/ prm%tau_0
|
/ prm%tau_0
|
||||||
dV_run_inverse_dTau = -1.0_pReal * v_run_inverse/tau_eff
|
dV_run_inverse_dTau = -1.0_pReal * v_run_inverse/tau_eff
|
||||||
dV_dTau = -1.0_pReal * (dV_wait_inverse_dTau+dV_run_inverse_dTau) &
|
dV_dTau = -1.0_pReal * (dV_wait_inverse_dTau+dV_run_inverse_dTau) &
|
||||||
/ (v_wait_inverse+v_run_inverse)**2.0_pReal
|
/ (v_wait_inverse+v_run_inverse)**2
|
||||||
ddot_gamma_dtau = dV_dTau*stt%rho_mob(:,en)*prm%b_sl
|
ddot_gamma_dtau = dV_dTau*stt%rho_mob(:,en)*prm%b_sl
|
||||||
else where significantStress
|
else where significantStress
|
||||||
dot_gamma_sl = 0.0_pReal
|
dot_gamma_sl = 0.0_pReal
|
||||||
|
|
|
@ -578,7 +578,7 @@ pure function om2eu(om) result(eu)
|
||||||
real(pReal) :: zeta
|
real(pReal) :: zeta
|
||||||
|
|
||||||
if (dNeq(abs(om(3,3)),1.0_pReal,1.e-8_pReal)) then
|
if (dNeq(abs(om(3,3)),1.0_pReal,1.e-8_pReal)) then
|
||||||
zeta = 1.0_pReal/sqrt(math_clip(1.0_pReal-om(3,3)**2.0_pReal,1e-64_pReal,1.0_pReal))
|
zeta = 1.0_pReal/sqrt(math_clip(1.0_pReal-om(3,3)**2,1e-64_pReal,1.0_pReal))
|
||||||
eu = [atan2(om(3,1)*zeta,-om(3,2)*zeta), &
|
eu = [atan2(om(3,1)*zeta,-om(3,2)*zeta), &
|
||||||
acos(math_clip(om(3,3),-1.0_pReal,1.0_pReal)), &
|
acos(math_clip(om(3,3),-1.0_pReal,1.0_pReal)), &
|
||||||
atan2(om(1,3)*zeta, om(2,3)*zeta)]
|
atan2(om(1,3)*zeta, om(2,3)*zeta)]
|
||||||
|
|
Loading…
Reference in New Issue