From 13630325c37fc7643bcccc38c23c16149b5a31e7 Mon Sep 17 00:00:00 2001 From: Martin Diehl Date: Fri, 10 Mar 2023 00:20:25 +0100 Subject: [PATCH] notation following paper https://doi.org/10.1016/j.jmps.2016.10.012 DAMASK paper --- PRIVATE | 2 +- .../phase/damage/anisobrittle_cubic.yaml | 4 +- src/phase.f90 | 8 +-- src/phase_damage.f90 | 6 +-- src/phase_damage_anisobrittle.f90 | 54 +++++++++---------- 5 files changed, 37 insertions(+), 37 deletions(-) diff --git a/PRIVATE b/PRIVATE index 9685fa71b..8fbc1dd8a 160000 --- a/PRIVATE +++ b/PRIVATE @@ -1 +1 @@ -Subproject commit 9685fa71bac2d56e6fd73d40160007f09fdae8db +Subproject commit 8fbc1dd8a26bf359b72bc076dac8ea3edef3be6d diff --git a/examples/config/phase/damage/anisobrittle_cubic.yaml b/examples/config/phase/damage/anisobrittle_cubic.yaml index 4f8db50ee..a7986a190 100644 --- a/examples/config/phase/damage/anisobrittle_cubic.yaml +++ b/examples/config/phase/damage/anisobrittle_cubic.yaml @@ -6,8 +6,8 @@ N_cl: [3] g_crit: [0.5e+7] s_crit: [0.006666] -dot_o: 1.e-3 -q: 20 +dot_o_0: 1.e-3 +p: 20 l_c: 1.0 mu: 0.001 diff --git a/src/phase.f90 b/src/phase.f90 index 08027ebe7..11795f3d6 100644 --- a/src/phase.f90 +++ b/src/phase.f90 @@ -314,14 +314,14 @@ module phase end subroutine plastic_dependentState - module subroutine damage_anisobrittle_LiAndItsTangent(Ld, dLd_dTstar, S, ph,en) + module subroutine damage_anisobrittle_LiAndItsTangent(L_i, dL_i_dM_i, M_i, ph,en) integer, intent(in) :: ph, en real(pReal), intent(in), dimension(3,3) :: & - S + M_i real(pReal), intent(out), dimension(3,3) :: & - Ld !< damage velocity gradient + L_i !< damage velocity gradient real(pReal), intent(out), dimension(3,3,3,3) :: & - dLd_dTstar !< derivative of Ld with respect to Tstar (4th-order tensor) + dL_i_dM_i !< derivative of L_i with respect to M_i end subroutine damage_anisobrittle_LiAndItsTangent end interface diff --git a/src/phase_damage.f90 b/src/phase_damage.f90 index e5909cb22..df5e00575 100644 --- a/src/phase_damage.f90 +++ b/src/phase_damage.f90 @@ -49,10 +49,10 @@ submodule(phase) damage end subroutine isobrittle_deltaState - module subroutine anisobrittle_dotState(S, ph, en) + module subroutine anisobrittle_dotState(M_i, ph, en) integer, intent(in) :: ph,en real(pReal), intent(in), dimension(3,3) :: & - S + M_i end subroutine anisobrittle_dotState @@ -384,7 +384,7 @@ function phase_damage_collectDotState(ph,en) result(broken) sourceType: select case (phase_damage(ph)) case (DAMAGE_ANISOBRITTLE_ID) sourceType - call anisobrittle_dotState(mechanical_S(ph,en), ph,en) ! correct stress? + call anisobrittle_dotState(mechanical_S(ph,en), ph,en) ! ToDo: use M_d end select sourceType diff --git a/src/phase_damage_anisobrittle.f90 b/src/phase_damage_anisobrittle.f90 index f04dbf950..8b9f54e74 100644 --- a/src/phase_damage_anisobrittle.f90 +++ b/src/phase_damage_anisobrittle.f90 @@ -8,8 +8,8 @@ submodule (phase:damage) anisobrittle type :: tParameters !< container type for internal constitutive parameters real(pReal) :: & - dot_o, & !< opening rate of cleavage planes - q !< damage rate sensitivity + dot_o_0, & !< opening rate of cleavage planes + p !< damage rate sensitivity real(pReal), dimension(:), allocatable :: & s_crit, & !< critical displacement g_crit !< critical load @@ -71,8 +71,8 @@ module function anisobrittle_init() result(mySources) N_cl = src%get_as1dInt('N_cl',defaultVal=emptyIntArray) prm%sum_N_cl = sum(abs(N_cl)) - prm%q = src%get_asFloat('q') - prm%dot_o = src%get_asFloat('dot_o') + prm%p = src%get_asFloat('p') + prm%dot_o_0 = src%get_asFloat('dot_o_0') prm%s_crit = src%get_as1dFloat('s_crit', requiredSize=size(N_cl)) prm%g_crit = src%get_as1dFloat('g_crit', requiredSize=size(N_cl)) @@ -90,8 +90,8 @@ module function anisobrittle_init() result(mySources) #endif ! sanity checks - if (prm%q <= 0.0_pReal) extmsg = trim(extmsg)//' q' - if (prm%dot_o <= 0.0_pReal) extmsg = trim(extmsg)//' dot_o' + if (prm%p <= 0.0_pReal) extmsg = trim(extmsg)//' p' + if (prm%dot_o_0 <= 0.0_pReal) extmsg = trim(extmsg)//' dot_o_0' if (any(prm%g_crit < 0.0_pReal)) extmsg = trim(extmsg)//' g_crit' if (any(prm%s_crit < 0.0_pReal)) extmsg = trim(extmsg)//' s_crit' @@ -113,12 +113,12 @@ end function anisobrittle_init !-------------------------------------------------------------------------------------------------- !> @brief !-------------------------------------------------------------------------------------------------- -module subroutine anisobrittle_dotState(S, ph,en) +module subroutine anisobrittle_dotState(M_i, ph,en) integer, intent(in) :: & ph,en real(pReal), intent(in), dimension(3,3) :: & - S + M_i integer :: & a, i @@ -129,13 +129,13 @@ module subroutine anisobrittle_dotState(S, ph,en) associate(prm => param(ph)) damageState(ph)%dotState(1,en) = 0.0_pReal do a = 1, prm%sum_N_cl - traction_crit = prm%g_crit(a)*damage_phi(ph,en)**2 + traction_crit = damage_phi(ph,en)**2 * prm%g_crit(a) do i = 1,3 - traction = math_tensordot(S,prm%cleavage_systems(1:3,1:3,i,a)) + traction = math_tensordot(M_i,prm%cleavage_systems(1:3,1:3,i,a)) damageState(ph)%dotState(1,en) = damageState(ph)%dotState(1,en) & - + prm%dot_o / prm%s_crit(a) & - * (max(0.0_pReal, abs(traction) - traction_crit)/traction_crit)**prm%q + + prm%dot_o_0 / prm%s_crit(a) & + * (max(0.0_pReal, abs(traction) - traction_crit)/traction_crit)**prm%p end do end do end associate @@ -157,8 +157,8 @@ module subroutine anisobrittle_result(phase,group) associate(prm => param(phase), stt => damageState(phase)%state) outputsLoop: do o = 1,size(prm%output) select case(trim(prm%output(o))) - case ('f_phi') - call result_writeDataset(stt,group,trim(prm%output(o)),'driving force','-') + case ('Psi_D') + call result_writeDataset(stt,group,trim(prm%output(o)),'damage energy density','-') end select end do outputsLoop end associate @@ -169,16 +169,16 @@ end subroutine anisobrittle_result !-------------------------------------------------------------------------------------------------- !> @brief contains the constitutive equation for calculating the velocity gradient !-------------------------------------------------------------------------------------------------- -module subroutine damage_anisobrittle_LiAndItsTangent(Ld, dLd_dTstar, S, ph,en) +module subroutine damage_anisobrittle_LiAndItsTangent(L_i, dL_i_dM_i, M_i, ph,en) integer, intent(in) :: & ph,en real(pReal), intent(in), dimension(3,3) :: & - S + M_i real(pReal), intent(out), dimension(3,3) :: & - Ld !< damage velocity gradient + L_i !< damage velocity gradient real(pReal), intent(out), dimension(3,3,3,3) :: & - dLd_dTstar !< derivative of Ld with respect to Tstar (4th-order tensor) + dL_i_dM_i !< derivative of L_i with respect to M_i integer :: & a, k, l, m, n, i @@ -187,21 +187,21 @@ module subroutine damage_anisobrittle_LiAndItsTangent(Ld, dLd_dTstar, S, ph,en) udot, dudot_dt - Ld = 0.0_pReal - dLd_dTstar = 0.0_pReal + L_i = 0.0_pReal + dL_i_dM_i = 0.0_pReal associate(prm => param(ph)) do a = 1,prm%sum_N_cl - traction_crit = prm%g_crit(a)*damage_phi(ph,en)**2 + traction_crit = damage_phi(ph,en)**2 * prm%g_crit(a) do i = 1, 3 - traction = math_tensordot(S,prm%cleavage_systems(1:3,1:3,i,a)) + traction = math_tensordot(M_i,prm%cleavage_systems(1:3,1:3,i,a)) if (abs(traction) > traction_crit + tol_math_check) then - udot = sign(1.0_pReal,traction)* prm%dot_o * ((abs(traction) - traction_crit)/traction_crit)**prm%q - Ld = Ld + udot*prm%cleavage_systems(1:3,1:3,i,a) - dudot_dt = sign(1.0_pReal,traction)*udot*prm%q / (abs(traction) - traction_crit) + udot = sign(1.0_pReal,traction)* prm%dot_o_0 * ((abs(traction) - traction_crit)/traction_crit)**prm%p + L_i = L_i + udot*prm%cleavage_systems(1:3,1:3,i,a) + dudot_dt = sign(1.0_pReal,traction)*udot*prm%p / (abs(traction) - traction_crit) forall (k=1:3,l=1:3,m=1:3,n=1:3) & - dLd_dTstar(k,l,m,n) = dLd_dTstar(k,l,m,n) & - + dudot_dt*prm%cleavage_systems(k,l,i,a) * prm%cleavage_systems(m,n,i,a) + dL_i_dM_i(k,l,m,n) = dL_i_dM_i(k,l,m,n) & + + dudot_dt*prm%cleavage_systems(k,l,i,a) * prm%cleavage_systems(m,n,i,a) end if end do end do