gfortran complaint about implicit casting,floating point comparison, and unused imported variables.
additionally changed use of math_invert33 to math_inv33 if det is not needed
This commit is contained in:
parent
5526d2a721
commit
d7b36c2c30
|
@ -3590,7 +3590,6 @@ logical function crystallite_integrateStress(&
|
|||
math_mul99x99, &
|
||||
math_transpose33, &
|
||||
math_inv33, &
|
||||
math_invert33, &
|
||||
math_invert, &
|
||||
math_det33, &
|
||||
math_norm33, &
|
||||
|
@ -3654,8 +3653,7 @@ logical function crystallite_integrateStress(&
|
|||
dLi_dFi3333, &
|
||||
dLp_dT3333, &
|
||||
dLi_dT3333
|
||||
real(pReal) det, & ! determinant
|
||||
detInvFi, &
|
||||
real(pReal) detInvFi, & ! determinant of InvFi
|
||||
steplengthLp0, &
|
||||
steplengthLp, &
|
||||
steplengthLi0, &
|
||||
|
@ -3663,7 +3661,6 @@ logical function crystallite_integrateStress(&
|
|||
dt, & ! time increment
|
||||
aTolLp, &
|
||||
aTolLi
|
||||
logical error ! flag indicating an error
|
||||
integer(pInt) NiterationStressLp, & ! number of stress integrations
|
||||
NiterationStressLi, & ! number of inner stress integrations
|
||||
ierr, & ! error indicator for LAPACK
|
||||
|
@ -3718,7 +3715,7 @@ logical function crystallite_integrateStress(&
|
|||
!* inversion of Fp_current...
|
||||
|
||||
invFp_current = math_inv33(Fp_current)
|
||||
if (all(invFp_current == 0.0_pReal)) then ! ... failed?
|
||||
if (all(invFp_current <= tiny(0.0_pReal))) then ! math_inv33 returns zero when failed, avoid floating point comparison
|
||||
#ifndef _OPENMP
|
||||
if (iand(debug_level(debug_crystallite), debug_levelBasic) /= 0_pInt) then
|
||||
write(6,'(a,i8,1x,a,i8,a,1x,i2,1x,i3)') '<< CRYST >> integrateStress failed on inversion of Fp_current at el (elFE) ip g ',&
|
||||
|
@ -3729,12 +3726,12 @@ logical function crystallite_integrateStress(&
|
|||
#endif
|
||||
return
|
||||
endif
|
||||
A = math_mul33x33(Fg_new,invFp_current) ! intermediate tensor needed later to calculate dFe_dLp
|
||||
A = math_mul33x33(Fg_new,invFp_current) ! intermediate tensor needed later to calculate dFe_dLp
|
||||
|
||||
!* inversion of Fi_current...
|
||||
|
||||
invFi_current = math_inv33(Fi_current)
|
||||
if (all(invFi_current == 0.0_pReal)) then ! ... failed?
|
||||
if (all(invFi_current <= tiny(0.0_pReal))) then ! math_inv33 returns zero when failed, avoid floating point comparison
|
||||
#ifndef _OPENMP
|
||||
if (iand(debug_level(debug_crystallite), debug_levelBasic) /= 0_pInt) then
|
||||
write(6,'(a,i8,1x,a,i8,a,1x,i2,1x,i3)') '<< CRYST >> integrateStress failed on inversion of Fi_current at el (elFE) ip g ',&
|
||||
|
@ -3974,9 +3971,9 @@ logical function crystallite_integrateStress(&
|
|||
!* calculate new plastic and elastic deformation gradient
|
||||
|
||||
invFp_new = math_mul33x33(invFp_current,B)
|
||||
invFp_new = invFp_new / math_det33(invFp_new)**(1.0_pReal/3.0_pReal) ! regularize by det
|
||||
call math_invert33(invFp_new,Fp_new,det,error)
|
||||
if (error .or. any(Fp_new /= Fp_new)) then
|
||||
invFp_new = invFp_new / math_det33(invFp_new)**(1.0_pReal/3.0_pReal) ! regularize by det
|
||||
Fp_new = math_inv33(invFp_new)
|
||||
if (all(Fp_new <= tiny(0.0_pReal))) then ! math_inv33 returns zero when failed, avoid floating point comparison
|
||||
#ifndef _OPENMP
|
||||
if (iand(debug_level(debug_crystallite), debug_levelBasic) /= 0_pInt) then
|
||||
write(6,'(a,i8,1x,a,i8,a,1x,i2,1x,i3,a,i3)') '<< CRYST >> integrateStress failed on invFp_new inversion at el ip g ',&
|
||||
|
|
|
@ -1039,8 +1039,7 @@ subroutine homogenization_RGC_stressPenalty(rPen,nMis,avgF,fDef,ip,el,homID)
|
|||
use constitutive, only: &
|
||||
constitutive_homogenizedC
|
||||
use math, only: &
|
||||
math_civita,&
|
||||
math_invert33
|
||||
math_civita
|
||||
use material, only: &
|
||||
homogenization_maxNgrains,&
|
||||
homogState, &
|
||||
|
|
|
@ -498,9 +498,8 @@ subroutine mesh_init(ip,el)
|
|||
#endif
|
||||
#ifdef Spectral
|
||||
IO_open_file
|
||||
use numerics, only: &
|
||||
divergence_correction
|
||||
#else
|
||||
use numerics, only: &
|
||||
IO_open_InputFile
|
||||
#endif
|
||||
use debug, only: &
|
||||
|
@ -1547,9 +1546,7 @@ function mesh_regrid(adaptive,resNewInput,minRes)
|
|||
integer(pInt), dimension(:), allocatable :: indices
|
||||
real(pReal) :: wgt
|
||||
real(pReal), dimension(3) :: geomSizeNew, geomSize
|
||||
real(pReal), dimension(3,3) :: Favg, Favg_LastInc, &
|
||||
FavgNew, Favg_LastIncNew, &
|
||||
deltaF, deltaF_lastInc
|
||||
real(pReal), dimension(3,3) :: Favg, Favg_LastInc
|
||||
real(pReal), dimension(:,:), allocatable :: &
|
||||
coordinates, coordinatesNew
|
||||
real(pReal), dimension(:,:,:), allocatable :: &
|
||||
|
@ -1559,7 +1556,6 @@ function mesh_regrid(adaptive,resNewInput,minRes)
|
|||
Tstar, TstarNew, &
|
||||
stateConst
|
||||
real(pReal), dimension(:,:,:,:,:), allocatable :: &
|
||||
spectralF33, spectralF33New, &
|
||||
F, FNew, &
|
||||
Fp, FpNew, &
|
||||
Lp, LpNew, &
|
||||
|
|
|
@ -682,8 +682,8 @@ subroutine plastic_dislotwin_init(fileUnit)
|
|||
if (plastic_dislotwin_Qsd(instance) <= 0.0_pReal) &
|
||||
call IO_error(211_pInt,el=instance,ext_msg='Qsd ('//PLASTICITY_DISLOTWIN_label//')')
|
||||
if (sum(plastic_dislotwin_Ntwin(:,instance)) > 0_pInt) then
|
||||
if (plastic_dislotwin_SFE_0K(instance) == 0.0_pReal .and. &
|
||||
plastic_dislotwin_dSFE_dT(instance) == 0.0_pReal .and. &
|
||||
if (plastic_dislotwin_SFE_0K(instance) <= tiny(0.0_pReal) .and. &
|
||||
plastic_dislotwin_dSFE_dT(instance) <= tiny(0.0_pReal) .and. &
|
||||
lattice_structure(phase) == LATTICE_fcc_ID) &
|
||||
call IO_error(211_pInt,el=instance,ext_msg='SFE0K ('//PLASTICITY_DISLOTWIN_label//')')
|
||||
if (plastic_dislotwin_aTolRho(instance) <= 0.0_pReal) &
|
||||
|
@ -708,7 +708,7 @@ subroutine plastic_dislotwin_init(fileUnit)
|
|||
if (plastic_dislotwin_sbVelocity(instance) > 0.0_pReal .and. &
|
||||
plastic_dislotwin_pShearBand(instance) <= 0.0_pReal) &
|
||||
call IO_error(211_pInt,el=instance,ext_msg='pShearBand ('//PLASTICITY_DISLOTWIN_label//')')
|
||||
if (plastic_dislotwin_dipoleFormationFactor(instance) /= 0.0_pReal .and. &
|
||||
if (plastic_dislotwin_dipoleFormationFactor(instance) > tiny(0.0_pReal) .and. &
|
||||
plastic_dislotwin_dipoleFormationFactor(instance) /= 1.0_pReal) &
|
||||
call IO_error(211_pInt,el=instance,ext_msg='dipoleFormationFactor ('//PLASTICITY_DISLOTWIN_label//')')
|
||||
if (plastic_dislotwin_sbVelocity(instance) > 0.0_pReal .and. &
|
||||
|
@ -1016,7 +1016,6 @@ subroutine plastic_dislotwin_stateInit(ph,instance)
|
|||
pi
|
||||
use lattice, only: &
|
||||
lattice_maxNslipFamily, &
|
||||
lattice_structure, &
|
||||
lattice_mu
|
||||
use material, only: &
|
||||
plasticState
|
||||
|
@ -1195,9 +1194,6 @@ function plastic_dislotwin_homogenizedC(ipc,ip,el)
|
|||
subroutine plastic_dislotwin_microstructure(temperature,ipc,ip,el)
|
||||
use math, only: &
|
||||
pi
|
||||
use mesh, only: &
|
||||
mesh_NcpElems, &
|
||||
mesh_maxNips
|
||||
use material, only: &
|
||||
material_phase, &
|
||||
phase_plasticityInstance, &
|
||||
|
@ -1206,9 +1202,7 @@ subroutine plastic_dislotwin_microstructure(temperature,ipc,ip,el)
|
|||
use lattice, only: &
|
||||
lattice_structure, &
|
||||
lattice_mu, &
|
||||
lattice_nu, &
|
||||
lattice_maxNslipFamily
|
||||
|
||||
lattice_nu
|
||||
|
||||
implicit none
|
||||
integer(pInt), intent(in) :: &
|
||||
|
@ -1513,8 +1507,8 @@ subroutine plastic_dislotwin_LpAndItsTangent(Lp,dLp_dTstar99,Tstar_v,Temperature
|
|||
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
! Shear banding (shearband) part
|
||||
if(plastic_dislotwin_sbVelocity(instance) /= 0.0_pReal .and. &
|
||||
plastic_dislotwin_sbResistance(instance) /= 0.0_pReal) then
|
||||
if(plastic_dislotwin_sbVelocity(instance) > tiny(0.0_pReal) .and. &
|
||||
plastic_dislotwin_sbResistance(instance) > tiny(0.0_pReal)) then
|
||||
gdot_sb = 0.0_pReal
|
||||
dgdot_dtausb = 0.0_pReal
|
||||
call math_spectralDecompositionSym33(math_Mandel6to33(Tstar_v),eigValues,eigVectors, error)
|
||||
|
@ -1672,9 +1666,6 @@ subroutine plastic_dislotwin_dotState(Tstar_v,Temperature,ipc,ip,el)
|
|||
tol_math_check
|
||||
use math, only: &
|
||||
pi
|
||||
use mesh, only: &
|
||||
mesh_NcpElems, &
|
||||
mesh_maxNips
|
||||
use material, only: &
|
||||
material_phase, &
|
||||
phase_plasticityInstance, &
|
||||
|
@ -1696,8 +1687,7 @@ subroutine plastic_dislotwin_dotState(Tstar_v,Temperature,ipc,ip,el)
|
|||
lattice_fcc_twinNucleationSlipPair, &
|
||||
lattice_fcc_transNucleationTwinPair, &
|
||||
lattice_fcc_shearCritTrans, &
|
||||
LATTICE_fcc_ID, &
|
||||
LATTICE_bcc_ID
|
||||
LATTICE_fcc_ID
|
||||
|
||||
implicit none
|
||||
real(pReal), dimension(6), intent(in):: &
|
||||
|
@ -1802,7 +1792,7 @@ subroutine plastic_dislotwin_dotState(Tstar_v,Temperature,ipc,ip,el)
|
|||
plastic_dislotwin_CAtomicVolume(instance)*plastic_dislotwin_burgersPerSlipSystem(j,instance)**(3.0_pReal)
|
||||
VacancyDiffusion = &
|
||||
plastic_dislotwin_D0(instance)*exp(-plastic_dislotwin_Qsd(instance)/(kB*Temperature))
|
||||
if (tau_slip(j) == 0.0_pReal) then
|
||||
if (tau_slip(j) <= tiny(0.0_pReal)) then
|
||||
DotRhoEdgeDipClimb(j) = 0.0_pReal
|
||||
else
|
||||
ClimbVelocity(j) = &
|
||||
|
@ -1912,8 +1902,8 @@ subroutine plastic_dislotwin_dotState(Tstar_v,Temperature,ipc,ip,el)
|
|||
b = lattice_fcc_transNucleationTwinPair(2,j)
|
||||
sa = sign(1_pInt, a)
|
||||
sb = sign(1_pInt, b)
|
||||
ssa = sign(1.0_pReal, shearrate_trans(a))
|
||||
ssb = sign(1.0_pReal, shearrate_trans(b))
|
||||
ssa = int(sign(1.0_pReal, shearrate_trans(a)),pInt)
|
||||
ssb = int(sign(1.0_pReal, shearrate_trans(b)),pInt)
|
||||
|
||||
if (sa == ssa .and. sb == ssb) then
|
||||
probrate_trans(j) = (abs(shear_trans(a)*shearrate_trans(b)) + abs(shear_trans(b)*shearrate_trans(a)))
|
||||
|
@ -1949,7 +1939,6 @@ function plastic_dislotwin_postResults(Tstar_v,Temperature,ipc,ip,el)
|
|||
use material, only: &
|
||||
material_phase, &
|
||||
phase_plasticityInstance,&
|
||||
phase_Noutput, &
|
||||
plasticState, &
|
||||
mappingConstitutive
|
||||
use lattice, only: &
|
||||
|
@ -2266,7 +2255,7 @@ function plastic_dislotwin_postResults(Tstar_v,Temperature,ipc,ip,el)
|
|||
endif
|
||||
|
||||
!* Stress exponent
|
||||
if (gdot_slip(j)==0.0_pReal) then
|
||||
if (gdot_slip(j)<=tiny(0.0_pReal)) then
|
||||
plastic_dislotwin_postResults(c+j) = 0.0_pReal
|
||||
else
|
||||
plastic_dislotwin_postResults(c+j) = (tau/gdot_slip(j))*dgdot_dtauslip
|
||||
|
|
|
@ -1413,7 +1413,6 @@ use lattice, only: lattice_maxNslipFamily
|
|||
use math, only: math_sampleGaussVar
|
||||
use mesh, only: mesh_ipVolume, &
|
||||
mesh_NcpElems, &
|
||||
mesh_maxNips, &
|
||||
mesh_element, &
|
||||
FE_Nips, &
|
||||
FE_geomtype
|
||||
|
@ -1424,9 +1423,6 @@ use material, only: material_phase, &
|
|||
material_Nphase, &
|
||||
phase_plasticity ,&
|
||||
PLASTICITY_NONLOCAL_ID
|
||||
use numerics,only: &
|
||||
numerics_integrator
|
||||
|
||||
implicit none
|
||||
|
||||
integer(pInt) :: e, &
|
||||
|
@ -1561,20 +1557,16 @@ use math, only: &
|
|||
math_mul33x3, &
|
||||
math_mul3x3, &
|
||||
math_norm3, &
|
||||
math_invert33, &
|
||||
math_inv33, &
|
||||
math_transpose33
|
||||
use debug, only: &
|
||||
debug_level, &
|
||||
debug_constitutive, &
|
||||
debug_levelBasic, &
|
||||
debug_levelExtensive, &
|
||||
debug_levelSelective, &
|
||||
debug_g, &
|
||||
debug_i, &
|
||||
debug_e
|
||||
use mesh, only: &
|
||||
mesh_NcpElems, &
|
||||
mesh_maxNips, &
|
||||
mesh_element, &
|
||||
mesh_ipNeighborhood, &
|
||||
mesh_ipCoordinates, &
|
||||
|
@ -1586,7 +1578,6 @@ use mesh, only: &
|
|||
FE_geomtype, &
|
||||
FE_celltype
|
||||
use material, only: &
|
||||
homogenization_maxNgrains, &
|
||||
material_phase, &
|
||||
phase_localPlasticity, &
|
||||
plasticState, &
|
||||
|
@ -1629,10 +1620,7 @@ integer(pInt) neighbor_el, & ! element number o
|
|||
n, &
|
||||
nRealNeighbors ! number of really existing neighbors
|
||||
integer(pInt), dimension(2) :: neighbors
|
||||
real(pReal) detFe, &
|
||||
detFp, &
|
||||
FVsize, &
|
||||
temp, &
|
||||
real(pReal) FVsize, &
|
||||
correction, &
|
||||
myRhoForest
|
||||
real(pReal), dimension(2) :: rhoExcessGradient, &
|
||||
|
@ -1664,7 +1652,6 @@ real(pReal), dimension(2,maxval(totalNslip),mesh_maxNipNeighbors) :: &
|
|||
neighbor_rhoTotal ! total density at neighboring material point
|
||||
real(pReal), dimension(3,totalNslip(phase_plasticityInstance(material_phase(1_pInt,ip,el))),2) :: &
|
||||
m ! direction of dislocation motion
|
||||
logical inversionError
|
||||
|
||||
ph = mappingConstitutive(2,1,ip,el)
|
||||
of = mappingConstitutive(1,1,ip,el)
|
||||
|
@ -1725,8 +1712,8 @@ forall (s = 1_pInt:ns) &
|
|||
tauBack = 0.0_pReal
|
||||
|
||||
if (.not. phase_localPlasticity(ph) .and. shortRangeStressCorrection(instance)) then
|
||||
call math_invert33(Fe, invFe, detFe, inversionError)
|
||||
call math_invert33(Fp, invFp, detFp, inversionError)
|
||||
invFe = math_inv33(Fe)
|
||||
invFp = math_inv33(Fp)
|
||||
rhoExcess(1,1:ns) = rhoSgl(1:ns,1) - rhoSgl(1:ns,2)
|
||||
rhoExcess(2,1:ns) = rhoSgl(1:ns,3) - rhoSgl(1:ns,4)
|
||||
FVsize = mesh_ipVolume(ip,el) ** (1.0_pReal/3.0_pReal)
|
||||
|
@ -1806,10 +1793,9 @@ if (.not. phase_localPlasticity(ph) .and. shortRangeStressCorrection(instance))
|
|||
rhoExcessDifferences(dir) = neighbor_rhoExcess(c,s,neighbors(1)) &
|
||||
- neighbor_rhoExcess(c,s,neighbors(2))
|
||||
enddo
|
||||
call math_invert33(connections,invConnections,temp,inversionError)
|
||||
if (inversionError) then
|
||||
invConnections = math_inv33(connections)
|
||||
if (all(invConnections <= tiny(0.0_pReal))) & ! check for failed in version (math_inv33 returns 0) and avoid floating point equality comparison
|
||||
call IO_error(-1_pInt,ext_msg='back stress calculation: inversion error')
|
||||
endif
|
||||
rhoExcessGradient(c) = math_mul3x3(m(1:3,s,c), &
|
||||
math_mul33x3(invConnections,rhoExcessDifferences))
|
||||
enddo
|
||||
|
@ -1867,10 +1853,8 @@ subroutine plastic_nonlocal_kinetics(v, dv_dtau, dv_dtauNS, tau, tauNS, &
|
|||
|
||||
use debug, only: debug_level, &
|
||||
debug_constitutive, &
|
||||
debug_levelBasic, &
|
||||
debug_levelExtensive, &
|
||||
debug_levelSelective, &
|
||||
debug_g, &
|
||||
debug_i, &
|
||||
debug_e
|
||||
use material, only: material_phase, &
|
||||
|
@ -2029,10 +2013,8 @@ use math, only: math_Plain3333to99, &
|
|||
math_Mandel6to33
|
||||
use debug, only: debug_level, &
|
||||
debug_constitutive, &
|
||||
debug_levelBasic, &
|
||||
debug_levelExtensive, &
|
||||
debug_levelSelective, &
|
||||
debug_g, &
|
||||
debug_i, &
|
||||
debug_e
|
||||
use material, only: material_phase, &
|
||||
|
@ -2226,7 +2208,6 @@ use debug, only: debug_level, &
|
|||
debug_levelBasic, &
|
||||
debug_levelExtensive, &
|
||||
debug_levelSelective, &
|
||||
debug_g, &
|
||||
debug_i, &
|
||||
debug_e
|
||||
use math, only: pi, &
|
||||
|
@ -2234,11 +2215,8 @@ use math, only: pi, &
|
|||
use lattice, only: lattice_Sslip_v ,&
|
||||
lattice_mu, &
|
||||
lattice_nu
|
||||
use mesh, only: mesh_NcpElems, &
|
||||
mesh_maxNips, &
|
||||
mesh_ipVolume
|
||||
use material, only: homogenization_maxNgrains, &
|
||||
material_phase, &
|
||||
use mesh, only: mesh_ipVolume
|
||||
use material, only: material_phase, &
|
||||
plasticState, &
|
||||
mappingConstitutive, &
|
||||
phase_plasticityInstance
|
||||
|
@ -2360,7 +2338,7 @@ deltaDUpper = dUpper - dUpperOld
|
|||
!*** dissociation by stress increase
|
||||
deltaRhoDipole2SingleStress = 0.0_pReal
|
||||
forall (c=1_pInt:2_pInt, s=1_pInt:ns, deltaDUpper(s,c) < 0.0_pReal .and. &
|
||||
(dUpperOld(s,c) - dLower(s,c))/= 0.0_pReal) &
|
||||
(dUpperOld(s,c) - dLower(s,c)) > tiny(0.0_pReal)) &
|
||||
deltaRhoDipole2SingleStress(s,8_pInt+c) = rhoDip(s,c) * deltaDUpper(s,c) &
|
||||
/ (dUpperOld(s,c) - dLower(s,c))
|
||||
|
||||
|
@ -2856,11 +2834,11 @@ if (.not. phase_localPlasticity(material_phase(1_pInt,ip,el))) then
|
|||
my_rhoSgl = rhoSgl
|
||||
my_v = v
|
||||
if(numerics_timeSyncing) then
|
||||
if (subfrac(1_pInt,ip,el) == 0.0_pReal) then
|
||||
if (subfrac(1_pInt,ip,el) <= tiny(0.0_pReal)) then
|
||||
my_rhoSgl = rhoSgl0
|
||||
my_v = v0
|
||||
elseif (neighbor_n > 0_pInt) then
|
||||
if (subfrac(1_pInt,neighbor_ip,neighbor_el) == 0.0_pReal) then
|
||||
if (subfrac(1_pInt,neighbor_ip,neighbor_el) <= tiny(0.0_pReal)) then
|
||||
my_rhoSgl = rhoSgl0
|
||||
my_v = v0
|
||||
endif
|
||||
|
@ -3206,7 +3184,7 @@ end subroutine plastic_nonlocal_updateCompatibility
|
|||
function plastic_nonlocal_dislocationstress(Fe, ip, el)
|
||||
use math, only: math_mul33x33, &
|
||||
math_mul33x3, &
|
||||
math_invert33, &
|
||||
math_inv33, &
|
||||
math_transpose33, &
|
||||
pi
|
||||
use mesh, only: mesh_NcpElems, &
|
||||
|
@ -3267,8 +3245,7 @@ real(pReal) x, y, z, &
|
|||
R, Rsquare, Rcube, &
|
||||
denominator, &
|
||||
flipSign, &
|
||||
neighbor_ipVolumeSideLength, &
|
||||
detFe
|
||||
neighbor_ipVolumeSideLength
|
||||
real(pReal), dimension(3) :: connection, & !< connection vector between me and my neighbor in the deformed configuration
|
||||
connection_neighborLattice, & !< connection vector between me and my neighbor in the lattice configuration of my neighbor
|
||||
connection_neighborSlip, & !< connection vector between me and my neighbor in the slip system frame of my neighbor
|
||||
|
@ -3287,7 +3264,6 @@ real(pReal), dimension(2,maxval(totalNslip)) :: &
|
|||
rhoExcessDead
|
||||
real(pReal), dimension(totalNslip(phase_plasticityInstance(material_phase(1_pInt,ip,el))),8) :: &
|
||||
rhoSgl ! single dislocation density (edge+, edge-, screw+, screw-, used edge+, used edge-, used screw+, used screw-)
|
||||
logical inversionError
|
||||
|
||||
ph = material_phase(1_pInt,ip,el)
|
||||
instance = phase_plasticityInstance(ph)
|
||||
|
@ -3295,8 +3271,6 @@ ns = totalNslip(instance)
|
|||
p = mappingConstitutive(2,1,ip,el)
|
||||
o = mappingConstitutive(1,1,ip,el)
|
||||
|
||||
|
||||
|
||||
!*** get basic states
|
||||
|
||||
forall (s = 1_pInt:ns, t = 1_pInt:4_pInt)
|
||||
|
@ -3312,7 +3286,7 @@ endforall
|
|||
plastic_nonlocal_dislocationstress = 0.0_pReal
|
||||
|
||||
if (.not. phase_localPlasticity(ph)) then
|
||||
call math_invert33(Fe(1:3,1:3,1_pInt,ip,el), invFe, detFe, inversionError)
|
||||
invFe = math_inv33(Fe(1:3,1:3,1_pInt,ip,el))
|
||||
|
||||
!* in case of periodic surfaces we have to find out how many periodic images in each direction we need
|
||||
|
||||
|
@ -3335,17 +3309,15 @@ if (.not. phase_localPlasticity(ph)) then
|
|||
!* but only consider nonlocal neighbors within a certain cutoff radius R
|
||||
|
||||
do neighbor_el = 1_pInt,mesh_NcpElems
|
||||
ipLoop: do neighbor_ip = 1_pInt,FE_Nips(FE_geomtype(mesh_element(2,neighbor_el)))
|
||||
ipLoop: do neighbor_ip = 1_pInt,FE_Nips(FE_geomtype(mesh_element(2,neighbor_el)))
|
||||
neighbor_phase = material_phase(1_pInt,neighbor_ip,neighbor_el)
|
||||
np = mappingConstitutive(2,1,neighbor_ip,neighbor_el)
|
||||
no = mappingConstitutive(1,1,neighbor_ip,neighbor_el)
|
||||
|
||||
if (phase_localPlasticity(neighbor_phase)) then
|
||||
cycle
|
||||
endif
|
||||
if (phase_localPlasticity(neighbor_phase)) cycle
|
||||
neighbor_instance = phase_plasticityInstance(neighbor_phase)
|
||||
neighbor_ns = totalNslip(neighbor_instance)
|
||||
call math_invert33(Fe(1:3,1:3,1,neighbor_ip,neighbor_el), neighbor_invFe, detFe, inversionError)
|
||||
neighbor_invFe = math_inv33(Fe(1:3,1:3,1,neighbor_ip,neighbor_el))
|
||||
neighbor_ipVolumeSideLength = mesh_ipVolume(neighbor_ip,neighbor_el) ** (1.0_pReal/3.0_pReal) ! reference volume used here
|
||||
|
||||
forall (s = 1_pInt:neighbor_ns, c = 1_pInt:2_pInt)
|
||||
|
@ -3370,9 +3342,7 @@ ipLoop: do neighbor_ip = 1_pInt,FE_Nips(FE_geomtype(mesh_element(2,neighbor_el))
|
|||
+ [real(deltaX,pReal), real(deltaY,pReal), real(deltaZ,pReal)] * meshSize
|
||||
connection = neighbor_coords - coords
|
||||
distance = sqrt(sum(connection * connection))
|
||||
if (distance > cutoffRadius(instance)) then
|
||||
cycle
|
||||
endif
|
||||
if (distance > cutoffRadius(instance)) cycle
|
||||
|
||||
|
||||
!* the segment length is the minimum of the third root of the control volume and the ip distance
|
||||
|
@ -3424,7 +3394,7 @@ ipLoop: do neighbor_ip = 1_pInt,FE_Nips(FE_geomtype(mesh_element(2,neighbor_el))
|
|||
Rsquare = R * R
|
||||
Rcube = Rsquare * R
|
||||
denominator = R * (R + flipSign * lambda)
|
||||
if (denominator == 0.0_pReal) exit ipLoop
|
||||
if (denominator <= tiny(0.0_pReal)) exit ipLoop
|
||||
|
||||
sigma(1,1) = sigma(1,1) - real(side,pReal) &
|
||||
* flipSign * z / denominator &
|
||||
|
@ -3469,7 +3439,7 @@ ipLoop: do neighbor_ip = 1_pInt,FE_Nips(FE_geomtype(mesh_element(2,neighbor_el))
|
|||
Rsquare = R * R
|
||||
Rcube = Rsquare * R
|
||||
denominator = R * (R + flipSign * lambda)
|
||||
if (denominator == 0.0_pReal) exit ipLoop
|
||||
if (denominator <= tiny(0.0_pReal)) exit ipLoop
|
||||
|
||||
sigma(1,2) = sigma(1,2) - real(side,pReal) * flipSign * z &
|
||||
* (1.0_pReal - lattice_nu(ph)) / denominator &
|
||||
|
@ -3571,8 +3541,7 @@ function plastic_nonlocal_postResults(Tstar_v,Fe,ip,el)
|
|||
material_phase, &
|
||||
mappingConstitutive, &
|
||||
plasticState, &
|
||||
phase_plasticityInstance, &
|
||||
phase_Noutput
|
||||
phase_plasticityInstance
|
||||
use lattice, only: &
|
||||
lattice_Sslip_v, &
|
||||
lattice_sd, &
|
||||
|
|
|
@ -209,7 +209,6 @@ subroutine plastic_titanmod_init(fileUnit)
|
|||
IO_timeStamp, &
|
||||
IO_EOF
|
||||
use material, only: &
|
||||
homogenization_maxNgrains, &
|
||||
phase_plasticity, &
|
||||
phase_plasticityInstance, &
|
||||
phase_Noutput, &
|
||||
|
@ -1074,8 +1073,7 @@ subroutine plastic_titanmod_stateInit(ph,instance)
|
|||
lattice_mu
|
||||
|
||||
use material, only: &
|
||||
plasticState, &
|
||||
mappingConstitutive
|
||||
plasticState
|
||||
|
||||
implicit none
|
||||
integer(pInt), intent(in) :: instance !< number specifying the instance of the plasticity
|
||||
|
@ -1167,11 +1165,7 @@ end subroutine plastic_titanmod_stateInit
|
|||
!> @brief returns the homogenized elasticity matrix
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
function plastic_titanmod_homogenizedC(ipc,ip,el)
|
||||
use mesh, only: &
|
||||
mesh_NcpElems, &
|
||||
mesh_maxNips
|
||||
use material, only: &
|
||||
homogenization_maxNgrains, &
|
||||
material_phase, &
|
||||
phase_plasticityInstance, &
|
||||
plasticState, &
|
||||
|
@ -1347,11 +1341,7 @@ subroutine plastic_titanmod_LpAndItsTangent(Lp,dLp_dTstar99,Tstar_v,temperature,
|
|||
lattice_NtwinSystem, &
|
||||
lattice_structure, &
|
||||
LATTICE_hex_ID
|
||||
use mesh, only: &
|
||||
mesh_NcpElems, &
|
||||
mesh_maxNips
|
||||
use material, only: &
|
||||
homogenization_maxNgrains, &
|
||||
material_phase, &
|
||||
phase_plasticityInstance, &
|
||||
plasticState, &
|
||||
|
@ -1662,11 +1652,7 @@ subroutine plastic_titanmod_dotState(Tstar_v,temperature,ipc,ip,el)
|
|||
lattice_maxNtwinFamily, &
|
||||
lattice_NslipSystem, &
|
||||
lattice_NtwinSystem
|
||||
use mesh, only: &
|
||||
mesh_NcpElems, &
|
||||
mesh_maxNips
|
||||
use material, only: &
|
||||
homogenization_maxNgrains, &
|
||||
material_phase, &
|
||||
phase_plasticityInstance, &
|
||||
plasticState, &
|
||||
|
@ -1782,14 +1768,9 @@ end subroutine plastic_titanmod_dotState
|
|||
!> @brief return array of constitutive results
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
function plastic_titanmod_postResults(ipc,ip,el)
|
||||
use mesh, only: &
|
||||
mesh_NcpElems, &
|
||||
mesh_maxNips
|
||||
use material, only: &
|
||||
homogenization_maxNgrains, &
|
||||
material_phase, &
|
||||
phase_plasticityInstance, &
|
||||
phase_Noutput, &
|
||||
plasticState, &
|
||||
mappingConstitutive
|
||||
|
||||
|
|
Loading…
Reference in New Issue