From 77567bd3981094683f4329a5d9338b84ba022151 Mon Sep 17 00:00:00 2001 From: Sharan Roongta Date: Fri, 10 Jul 2020 23:41:56 +0200 Subject: [PATCH] To circumvent Marc internal compiler error --- src/constitutive.f90 | 29 +++++++++++++++++++++++++---- src/constitutive_plastic.f90 | 24 ------------------------ 2 files changed, 25 insertions(+), 28 deletions(-) diff --git a/src/constitutive.f90 b/src/constitutive.f90 index de735fe55..8ecfb1759 100644 --- a/src/constitutive.f90 +++ b/src/constitutive.f90 @@ -131,16 +131,15 @@ module constitutive of end subroutine source_thermal_externalheat_dotState - - module function constitutive_homogenizedC(ipc,ip,el) result(homogenizedC) + module function plastic_dislotwin_homogenizedC(ipc,ip,el) result(homogenizedC) real(pReal), dimension(6,6) :: & homogenizedC integer, intent(in) :: & ipc, & !< component-ID of integration point ip, & !< integration point el !< element - end function constitutive_homogenizedC - + end function plastic_dislotwin_homogenizedC + module subroutine constitutive_plastic_dependentState(F, Fp, ipc, ip, el) integer, intent(in) :: & @@ -430,6 +429,28 @@ subroutine constitutive_init end subroutine constitutive_init +!-------------------------------------------------------------------------------------------------- +!> @brief returns the homogenize elasticity matrix +!> ToDo: homogenizedC66 would be more consistent +!-------------------------------------------------------------------------------------------------- +function constitutive_homogenizedC(ipc,ip,el) + + real(pReal) , dimension(6,6) :: & + constitutive_homogenizedC + integer, intent(in) :: & + ipc, & + ip, & + el + + plasticityType: select case (phase_plasticity(material_phaseAt(ipc,el))) + case (PLASTICITY_DISLOTWIN_ID) plasticityType + constitutive_homogenizedC = plastic_dislotwin_homogenizedC(ipc,ip,el) + case default plasticityType + constitutive_homogenizedC = lattice_C66(1:6,1:6,material_phaseAt(ipc,el)) + end select plasticityType + +end function constitutive_homogenizedC + !-------------------------------------------------------------------------------------------------- !> @brief contains the constitutive equation for calculating the velocity gradient diff --git a/src/constitutive_plastic.f90 b/src/constitutive_plastic.f90 index bfab42833..ad7e5a54b 100644 --- a/src/constitutive_plastic.f90 +++ b/src/constitutive_plastic.f90 @@ -113,15 +113,6 @@ submodule(constitutive) constitutive_plastic el !< current element number end subroutine plastic_nonlocal_LpAndItsTangent - module function plastic_dislotwin_homogenizedC(ipc,ip,el) result(homogenizedC) - real(pReal), dimension(6,6) :: & - homogenizedC - integer, intent(in) :: & - ipc, & !< component-ID of integration point - ip, & !< integration point - el !< element - end function plastic_dislotwin_homogenizedC - module subroutine plastic_dislotwin_dependentState(T,instance,of) integer, intent(in) :: & @@ -176,21 +167,6 @@ module subroutine plastic_init end subroutine plastic_init -!-------------------------------------------------------------------------------------------------- -!> @brief returns the homogenize elasticity matrix -!> ToDo: homogenizedC66 would be more consistent -!-------------------------------------------------------------------------------------------------- -module procedure constitutive_homogenizedC - - plasticityType: select case (phase_plasticity(material_phaseAt(ipc,el))) - case (PLASTICITY_DISLOTWIN_ID) plasticityType - homogenizedC = plastic_dislotwin_homogenizedC(ipc,ip,el) - case default plasticityType - homogenizedC = lattice_C66(1:6,1:6,material_phaseAt(ipc,el)) - end select plasticityType - -end procedure constitutive_homogenizedC - !-------------------------------------------------------------------------------------------------- !> @brief calls microstructure function of the different constitutive models