using norm2 function as L2 norm (vector, math_norm3) and Frobenius norm (tensor, math_norm33)
This commit is contained in:
parent
53d07215a9
commit
519cd29c6f
|
@ -3512,7 +3512,6 @@ logical function crystallite_integrateStress(&
|
||||||
math_inv33, &
|
math_inv33, &
|
||||||
math_invert, &
|
math_invert, &
|
||||||
math_det33, &
|
math_det33, &
|
||||||
math_norm33, &
|
|
||||||
math_I3, &
|
math_I3, &
|
||||||
math_identity2nd, &
|
math_identity2nd, &
|
||||||
math_Mandel66to3333, &
|
math_Mandel66to3333, &
|
||||||
|
@ -3743,7 +3742,7 @@ logical function crystallite_integrateStress(&
|
||||||
|
|
||||||
!* update current residuum and check for convergence of loop
|
!* update current residuum and check for convergence of loop
|
||||||
|
|
||||||
aTolLp = max(rTol_crystalliteStress * max(math_norm33(Lpguess),math_norm33(Lp_constitutive)), & ! absolute tolerance from largest acceptable relative error
|
aTolLp = max(rTol_crystalliteStress * max(norm2(Lpguess),norm2(Lp_constitutive)), & ! absolute tolerance from largest acceptable relative error
|
||||||
aTol_crystalliteStress) ! minimum lower cutoff
|
aTol_crystalliteStress) ! minimum lower cutoff
|
||||||
residuumLp = Lpguess - Lp_constitutive
|
residuumLp = Lpguess - Lp_constitutive
|
||||||
|
|
||||||
|
@ -3756,10 +3755,10 @@ logical function crystallite_integrateStress(&
|
||||||
' >> returning..!'
|
' >> returning..!'
|
||||||
#endif
|
#endif
|
||||||
return ! ...me = .false. to inform integrator about problem
|
return ! ...me = .false. to inform integrator about problem
|
||||||
elseif (math_norm33(residuumLp) < aTolLp) then ! converged if below absolute tolerance
|
elseif (norm2(residuumLp) < aTolLp) then ! converged if below absolute tolerance
|
||||||
exit LpLoop ! ...leave iteration loop
|
exit LpLoop ! ...leave iteration loop
|
||||||
elseif ( NiterationStressLp == 1_pInt &
|
elseif ( NiterationStressLp == 1_pInt &
|
||||||
.or. math_norm33(residuumLp) < math_norm33(residuumLp_old)) then ! not converged, but improved norm of residuum (always proceed in first iteration)...
|
.or. norm2(residuumLp) < norm2(residuumLp_old)) then ! not converged, but improved norm of residuum (always proceed in first iteration)...
|
||||||
residuumLp_old = residuumLp ! ...remember old values and...
|
residuumLp_old = residuumLp ! ...remember old values and...
|
||||||
Lpguess_old = Lpguess
|
Lpguess_old = Lpguess
|
||||||
steplengthLp = steplengthLp0 ! ...proceed with normal step length (calculate new search direction)
|
steplengthLp = steplengthLp0 ! ...proceed with normal step length (calculate new search direction)
|
||||||
|
@ -3838,15 +3837,15 @@ logical function crystallite_integrateStress(&
|
||||||
#endif
|
#endif
|
||||||
!* update current residuum and check for convergence of loop
|
!* update current residuum and check for convergence of loop
|
||||||
|
|
||||||
aTolLi = max(rTol_crystalliteStress * max(math_norm33(Liguess),math_norm33(Li_constitutive)), & ! absolute tolerance from largest acceptable relative error
|
aTolLi = max(rTol_crystalliteStress * max(norm2(Liguess),norm2(Li_constitutive)), & ! absolute tolerance from largest acceptable relative error
|
||||||
aTol_crystalliteStress) ! minimum lower cutoff
|
aTol_crystalliteStress) ! minimum lower cutoff
|
||||||
residuumLi = Liguess - Li_constitutive
|
residuumLi = Liguess - Li_constitutive
|
||||||
if (any(prec_isNaN(residuumLi))) then ! NaN in residuum...
|
if (any(prec_isNaN(residuumLi))) then ! NaN in residuum...
|
||||||
return ! ...me = .false. to inform integrator about problem
|
return ! ...me = .false. to inform integrator about problem
|
||||||
elseif (math_norm33(residuumLi) < aTolLi) then ! converged if below absolute tolerance
|
elseif (norm2(residuumLi) < aTolLi) then ! converged if below absolute tolerance
|
||||||
exit LiLoop ! ...leave iteration loop
|
exit LiLoop ! ...leave iteration loop
|
||||||
elseif ( NiterationStressLi == 1_pInt &
|
elseif ( NiterationStressLi == 1_pInt &
|
||||||
.or. math_norm33(residuumLi) < math_norm33(residuumLi_old)) then ! not converged, but improved norm of residuum (always proceed in first iteration)...
|
.or. norm2(residuumLi) < norm2(residuumLi_old)) then ! not converged, but improved norm of residuum (always proceed in first iteration)...
|
||||||
residuumLi_old = residuumLi ! ...remember old values and...
|
residuumLi_old = residuumLi ! ...remember old values and...
|
||||||
Liguess_old = Liguess
|
Liguess_old = Liguess
|
||||||
steplengthLi = steplengthLi0 ! ...proceed with normal step length (calculate new search direction)
|
steplengthLi = steplengthLi0 ! ...proceed with normal step length (calculate new search direction)
|
||||||
|
|
|
@ -1140,7 +1140,6 @@ subroutine plastic_disloUCLA_LpAndItsTangent(Lp,dLp_dTstar99,Tstar_v,Temperature
|
||||||
math_Mandel6to33, &
|
math_Mandel6to33, &
|
||||||
math_Mandel33to6, &
|
math_Mandel33to6, &
|
||||||
math_spectralDecompositionSym33, &
|
math_spectralDecompositionSym33, &
|
||||||
math_tensorproduct, &
|
|
||||||
math_symmetric33, &
|
math_symmetric33, &
|
||||||
math_mul33x3
|
math_mul33x3
|
||||||
use material, only: &
|
use material, only: &
|
||||||
|
|
|
@ -1558,7 +1558,6 @@ use math, only: &
|
||||||
pi, &
|
pi, &
|
||||||
math_mul33x3, &
|
math_mul33x3, &
|
||||||
math_mul3x3, &
|
math_mul3x3, &
|
||||||
math_norm3, &
|
|
||||||
math_inv33, &
|
math_inv33, &
|
||||||
math_transpose33
|
math_transpose33
|
||||||
use debug, only: &
|
use debug, only: &
|
||||||
|
@ -2398,8 +2397,7 @@ use debug, only: debug_level, &
|
||||||
debug_g, &
|
debug_g, &
|
||||||
debug_i, &
|
debug_i, &
|
||||||
debug_e
|
debug_e
|
||||||
use math, only: math_norm3, &
|
use math, only: math_mul6x6, &
|
||||||
math_mul6x6, &
|
|
||||||
math_mul3x3, &
|
math_mul3x3, &
|
||||||
math_mul33x3, &
|
math_mul33x3, &
|
||||||
math_mul33x33, &
|
math_mul33x33, &
|
||||||
|
@ -2788,8 +2786,8 @@ if (.not. phase_localPlasticity(material_phase(1_pInt,ip,el))) then
|
||||||
mesh_ipAreaNormal(1:3,neighbor_n,neighbor_ip,neighbor_el)) ! calculate the normal of the interface in (average) deformed configuration (now pointing from my neighbor to me!!!)
|
mesh_ipAreaNormal(1:3,neighbor_n,neighbor_ip,neighbor_el)) ! calculate the normal of the interface in (average) deformed configuration (now pointing from my neighbor to me!!!)
|
||||||
normal_neighbor2me = math_mul33x3(transpose(neighbor_Fe), normal_neighbor2me_defConf) &
|
normal_neighbor2me = math_mul33x3(transpose(neighbor_Fe), normal_neighbor2me_defConf) &
|
||||||
/ math_det33(neighbor_Fe) ! interface normal in the lattice configuration of my neighbor
|
/ math_det33(neighbor_Fe) ! interface normal in the lattice configuration of my neighbor
|
||||||
area = mesh_ipArea(neighbor_n,neighbor_ip,neighbor_el) * math_norm3(normal_neighbor2me)
|
area = mesh_ipArea(neighbor_n,neighbor_ip,neighbor_el) * norm2(normal_neighbor2me)
|
||||||
normal_neighbor2me = normal_neighbor2me / math_norm3(normal_neighbor2me) ! normalize the surface normal to unit length
|
normal_neighbor2me = normal_neighbor2me / norm2(normal_neighbor2me) ! normalize the surface normal to unit length
|
||||||
do s = 1_pInt,ns
|
do s = 1_pInt,ns
|
||||||
do t = 1_pInt,4_pInt
|
do t = 1_pInt,4_pInt
|
||||||
c = (t + 1_pInt) / 2
|
c = (t + 1_pInt) / 2
|
||||||
|
@ -2851,8 +2849,8 @@ if (.not. phase_localPlasticity(material_phase(1_pInt,ip,el))) then
|
||||||
mesh_ipAreaNormal(1:3,n,ip,el)) ! calculate the normal of the interface in (average) deformed configuration (pointing from me to my neighbor!!!)
|
mesh_ipAreaNormal(1:3,n,ip,el)) ! calculate the normal of the interface in (average) deformed configuration (pointing from me to my neighbor!!!)
|
||||||
normal_me2neighbor = math_mul33x3(math_transpose33(my_Fe), normal_me2neighbor_defConf) &
|
normal_me2neighbor = math_mul33x3(math_transpose33(my_Fe), normal_me2neighbor_defConf) &
|
||||||
/ math_det33(my_Fe) ! interface normal in my lattice configuration
|
/ math_det33(my_Fe) ! interface normal in my lattice configuration
|
||||||
area = mesh_ipArea(n,ip,el) * math_norm3(normal_me2neighbor)
|
area = mesh_ipArea(n,ip,el) * norm2(normal_me2neighbor)
|
||||||
normal_me2neighbor = normal_me2neighbor / math_norm3(normal_me2neighbor) ! normalize the surface normal to unit length
|
normal_me2neighbor = normal_me2neighbor / norm2(normal_me2neighbor) ! normalize the surface normal to unit length
|
||||||
do s = 1_pInt,ns
|
do s = 1_pInt,ns
|
||||||
do t = 1_pInt,4_pInt
|
do t = 1_pInt,4_pInt
|
||||||
c = (t + 1_pInt) / 2_pInt
|
c = (t + 1_pInt) / 2_pInt
|
||||||
|
|
Loading…
Reference in New Issue