better have different physics separated

This commit is contained in:
Martin Diehl 2021-07-17 14:06:48 +02:00
parent f9edeb40a5
commit c109d5a37b
4 changed files with 29 additions and 12 deletions

View File

@ -269,7 +269,7 @@ subroutine homogenization_mechanical_response(Delta_t,FEsolving_execIP,FEsolving
call mechanical_partition(homogenization_F(1:3,1:3,ce),ce)
converged = all([(phase_mechanical_constitutive(Delta_t,co,ip,el),co=1,homogenization_Nconstituents(ho))])
converged = converged .and. all([(phase_damage_constitutive(Delta_t,co,ip,el),co=1,homogenization_Nconstituents(ho))])
if (converged) then
doneAndHappy = mechanical_updateState(Delta_t,homogenization_F(1:3,1:3,ce),ce)
converged = all(doneAndHappy)

View File

@ -221,13 +221,11 @@ module phase
end function phase_thermal_constitutive
module function integrateDamageState(Delta_t,co,ce) result(broken)
module function phase_damage_constitutive(Delta_t,co,ip,el) result(converged_)
real(pReal), intent(in) :: Delta_t
integer, intent(in) :: &
ce, &
co
logical :: broken
end function integrateDamageState
integer, intent(in) :: co, ip, el
logical :: converged_
end function phase_damage_constitutive
module function phase_mechanical_constitutive(Delta_t,co,ip,el) result(converged_)
real(pReal), intent(in) :: Delta_t
@ -321,12 +319,12 @@ module phase
crystallite_init, &
phase_mechanical_constitutive, &
phase_thermal_constitutive, &
phase_damage_constitutive, &
phase_mechanical_dPdF, &
crystallite_orientations, &
crystallite_push33ToRef, &
phase_restartWrite, &
phase_restartRead, &
integrateDamageState, &
phase_thermal_setField, &
phase_set_phi, &
phase_P, &

View File

@ -125,6 +125,27 @@ module subroutine damage_init
end subroutine damage_init
!--------------------------------------------------------------------------------------------------
!> @brief calculate stress (P)
!--------------------------------------------------------------------------------------------------
module function phase_damage_constitutive(Delta_t,co,ip,el) result(converged_)
real(pReal), intent(in) :: Delta_t
integer, intent(in) :: &
co, &
ip, &
el
logical :: converged_
integer :: &
ph, en
converged_ = .not. integrateDamageState(Delta_t,co,(el-1)*discretization_nIPs + ip)
end function phase_damage_constitutive
!--------------------------------------------------------------------------------------------------
!> @brief returns the degraded/modified elasticity matrix
!--------------------------------------------------------------------------------------------------
@ -197,7 +218,7 @@ end function phase_f_phi
!> @brief integrate stress, state with adaptive 1st order explicit Euler method
!> using Fixed Point Iteration to adapt the stepsize
!--------------------------------------------------------------------------------------------------
module function integrateDamageState(Delta_t,co,ce) result(broken)
function integrateDamageState(Delta_t,co,ce) result(broken)
real(pReal), intent(in) :: Delta_t
integer, intent(in) :: &

View File

@ -1059,8 +1059,6 @@ module function phase_mechanical_constitutive(Delta_t,co,ip,el) result(converged
enddo cutbackLooping
converged_ = converged_ .and. .not. integrateDamageState(Delta_t,co,(el-1)*discretization_nIPs + ip)
end function phase_mechanical_constitutive