From c2f81254d0b4b6ea78ac42d02d9cd7e6123d59e6 Mon Sep 17 00:00:00 2001 From: Achal H P Date: Wed, 17 Jan 2024 21:50:22 +0530 Subject: [PATCH] Jan 17 --- src/phase_mechanical_plastic.f90 | 7 ++++ ...phase_mechanical_plastic_phenopowerlaw.f90 | 34 +++++++++++++++++-- 2 files changed, 38 insertions(+), 3 deletions(-) diff --git a/src/phase_mechanical_plastic.f90 b/src/phase_mechanical_plastic.f90 index e3c210336..94c7a61c6 100644 --- a/src/phase_mechanical_plastic.f90 +++ b/src/phase_mechanical_plastic.f90 @@ -204,6 +204,13 @@ submodule(phase:mechanical) plastic en end subroutine plastic_nonlocal_deltaState + !module subroutine plastic_kinematic_deltaFp(Mp,ph,en,twinJump) + ! implicit none + ! + !contains + + !end module subroutine + end interface contains diff --git a/src/phase_mechanical_plastic_phenopowerlaw.f90 b/src/phase_mechanical_plastic_phenopowerlaw.f90 index 4a9406b5d..7a21fea25 100644 --- a/src/phase_mechanical_plastic_phenopowerlaw.f90 +++ b/src/phase_mechanical_plastic_phenopowerlaw.f90 @@ -54,7 +54,8 @@ type :: tIndexDotState xi_sl, & xi_tw, & gamma_sl, & - gamma_tw + gamma_tw, & + f_twin end type tIndexDotState type :: tPhenopowerlawState @@ -62,7 +63,8 @@ type :: tPhenopowerlawState xi_sl, & xi_tw, & gamma_sl, & - gamma_tw + gamma_tw, & + f_twin end type tPhenopowerlawState !-------------------------------------------------------------------------------------------------- @@ -232,7 +234,8 @@ do ph = 1, phases%length ! allocate state arrays Nmembers = count(material_phaseID == ph) sizeDotState = size(['xi_sl ','gamma_sl']) * prm%sum_N_sl & - + size(['xi_tw ','gamma_tw']) * prm%sum_N_tw + + size(['xi_tw ','gamma_tw']) * prm%sum_N_tw & + + size(['xi_tw ','f_twin ']) * prm%sum_N_tw sizeState = sizeDotState call phase_allocateState(plasticState(ph),Nmembers,sizeState,sizeDotState,0) @@ -268,6 +271,14 @@ do ph = 1, phases%length stt%gamma_tw => plasticState(ph)%state(startIndex:endIndex,:) plasticState(ph)%atol(startIndex:endIndex) = pl%get_asFloat('atol_gamma',defaultVal=1.0e-6_pReal) + startIndex = endIndex + 1 + endIndex = endIndex + prm%sum_N_tw + idx_dot%f_twin = [startIndex,endIndex] + deltastate(ph)%f_twin => plasticState(ph)%state(startIndex:endIndex,:) + deltastate(ph)%f_twin = spread(xi_0_tw, 2, Nmembers) + + + end associate !-------------------------------------------------------------------------------------------------- @@ -443,6 +454,23 @@ end if Success_Growth end subroutine plastic_kinematic_deltaFp +!-------------------------------------------------------------------------------------------------- +!> @brief calculates (instantaneous) incremental change of microstructure +!> Satya, Achal +!-------------------------------------------------------------------------------------------------- +subroutine plastic_phenopowerlaw_deltaState(ph,en) +implicit none + +integer, intent(in)::& + ph, & + en + +deltastate(ph)%gamma_sl=0.0_pReal + + +end subroutine plastic_phenopowerlaw_deltaState + + !-------------------------------------------------------------------------------------------------- !> @brief Write results to HDF5 output file. !--------------------------------------------------------------------------------------------------