Merge remote-tracking branch 'origin/development' into simplify-cmake

This commit is contained in:
Martin Diehl 2021-05-23 10:39:13 +02:00
commit 62c9761a05
22 changed files with 266 additions and 152 deletions

@ -1 +1 @@
Subproject commit 3014c71db7288217b3bde41e8d891485f23e040a Subproject commit 0744cf7f93dbd06423baaae97a67959f11c3e6a5

View File

@ -1 +1 @@
v3.0.0-alpha3-89-g4ba4ca133 v3.0.0-alpha3-137-g0b80252d9

View File

@ -1,8 +1,11 @@
N_cl: [3]
dot_o: 1e-3
g_crit: [0.50e7]
q: 20
s_crit: [0.006666]
type: anisobrittle type: anisobrittle
N_cl: [3]
g_crit: [0.50e7]
s_crit: [0.006666]
dot_o: 1e-3
q: 20
output: [f_phi]
D_11: 1.0 D_11: 1.0
M: 0.001 M: 0.001

View File

@ -0,0 +1,9 @@
type: isobrittle
W_crit: 1400000.0
m: 1.0
isoBrittle_atol: 0.01
output: [f_phi]
D_11: 1.0
M: 0.001

View File

@ -1,15 +1,15 @@
homogenization: homogenization:
SX: SX:
N_constituents: 1 N_constituents: 1
mechanics: {type: pass} mechanical: {type: pass}
phase: phase:
Aluminum: Aluminum:
lattice: cF lattice: cF
mechanics: mechanical:
output: [F, P, F_e, F_p, L_p] output: [F, P, F_e, F_p, L_p]
elasticity: {type: Hooke, C_11: 106.75e9, C_12: 60.41e9, C_44: 28.34e9} elastic: {type: Hooke, C_11: 106.75e9, C_12: 60.41e9, C_44: 28.34e9}
plasticity: plastic:
type: phenopowerlaw type: phenopowerlaw
N_sl: [12] N_sl: [12]
a_sl: 2.25 a_sl: 2.25

View File

@ -503,7 +503,7 @@ then
PROFILE=" $PROFILE -pg" PROFILE=" $PROFILE -pg"
fi fi
FORT_OPT="-c -implicitnone -stand f08 -standard-semantics -assume nostd_mod_proc_name -safe_cray_ptr -mp1 -WB -fp-model source" FORT_OPT="-c -implicitnone -stand f18 -standard-semantics -assume nostd_mod_proc_name -safe_cray_ptr -mp1 -WB -fp-model source"
if test "$MTHREAD" = "OPENMP" if test "$MTHREAD" = "OPENMP"
then then
FORT_OPT=" $FORT_OPT -qopenmp" FORT_OPT=" $FORT_OPT -qopenmp"
@ -541,15 +541,15 @@ fi
# DAMASK compiler calls: additional flags are in line 2 OpenMP flags in line 3 # DAMASK compiler calls: additional flags are in line 2 OpenMP flags in line 3
DFORTLOWMP="$FCOMP -c -O0 -qno-offload -implicitnone -stand f08 -standard-semantics -assume nostd_mod_proc_name -safe_cray_ptr $PROFILE -zero -mp1 -WB $I8FFLAGS -I$MARC_SOURCE/common \ DFORTLOWMP="$FCOMP -c -O0 -qno-offload -implicitnone -stand f18 -standard-semantics -assume nostd_mod_proc_name -safe_cray_ptr $PROFILE -zero -mp1 -WB $I8FFLAGS -I$MARC_SOURCE/common \
-fpp -ftz -diag-disable 5268 -warn declarations -warn general -warn usage -warn interfaces -warn ignore_loc -warn alignments -DMarc4DAMASK=2020 -DDAMASKVERSION=$DAMASKVERSION \ -fpp -ftz -diag-disable 5268 -warn declarations -warn general -warn usage -warn interfaces -warn ignore_loc -warn alignments -DMarc4DAMASK=2020 -DDAMASKVERSION=$DAMASKVERSION \
-qopenmp -qopenmp-threadprivate=compat\ -qopenmp -qopenmp-threadprivate=compat\
$MUMPS_INCLUDE $I8DEFINES -DLinux -DLINUX -DLinux_intel $FDEFINES $DDM $SOLVERFLAGS -I$KDTREE2_MOD" $MUMPS_INCLUDE $I8DEFINES -DLinux -DLINUX -DLinux_intel $FDEFINES $DDM $SOLVERFLAGS -I$KDTREE2_MOD"
DFORTRANMP="$FCOMP -c -O1 -qno-offload -implicitnone -stand f08 -standard-semantics -assume nostd_mod_proc_name -safe_cray_ptr $PROFILE -zero -mp1 -WB $I8FFLAGS -I$MARC_SOURCE/common \ DFORTRANMP="$FCOMP -c -O1 -qno-offload -implicitnone -stand f18 -standard-semantics -assume nostd_mod_proc_name -safe_cray_ptr $PROFILE -zero -mp1 -WB $I8FFLAGS -I$MARC_SOURCE/common \
-fpp -ftz -diag-disable 5268 -warn declarations -warn general -warn usage -warn interfaces -warn ignore_loc -warn alignments -DMarc4DAMASK=2020 -DDAMASKVERSION=$DAMASKVERSION \ -fpp -ftz -diag-disable 5268 -warn declarations -warn general -warn usage -warn interfaces -warn ignore_loc -warn alignments -DMarc4DAMASK=2020 -DDAMASKVERSION=$DAMASKVERSION \
-qopenmp -qopenmp-threadprivate=compat\ -qopenmp -qopenmp-threadprivate=compat\
$MUMPS_INCLUDE $I8DEFINES -DLinux -DLINUX -DLinux_intel $FDEFINES $DDM $SOLVERFLAGS -I$KDTREE2_MOD" $MUMPS_INCLUDE $I8DEFINES -DLinux -DLINUX -DLinux_intel $FDEFINES $DDM $SOLVERFLAGS -I$KDTREE2_MOD"
DFORTHIGHMP="$FCOMP -c -O3 -qno-offload -implicitnone -stand f08 -standard-semantics -assume nostd_mod_proc_name -safe_cray_ptr $PROFILE -zero -mp1 -WB $I8FFLAGS -I$MARC_SOURCE/common \ DFORTHIGHMP="$FCOMP -c -O3 -qno-offload -implicitnone -stand f18 -standard-semantics -assume nostd_mod_proc_name -safe_cray_ptr $PROFILE -zero -mp1 -WB $I8FFLAGS -I$MARC_SOURCE/common \
-fpp -ftz -diag-disable 5268 -warn declarations -warn general -warn usage -warn interfaces -warn ignore_loc -warn alignments -DMarc4DAMASK=2020 -DDAMASKVERSION=$DAMASKVERSION \ -fpp -ftz -diag-disable 5268 -warn declarations -warn general -warn usage -warn interfaces -warn ignore_loc -warn alignments -DMarc4DAMASK=2020 -DDAMASKVERSION=$DAMASKVERSION \
-qopenmp -qopenmp-threadprivate=compat\ -qopenmp -qopenmp-threadprivate=compat\
$MUMPS_INCLUDE $I8DEFINES -DLinux -DLINUX -DLinux_intel $FDEFINES $DDM $SOLVERFLAGS -I$KDTREE2_MOD" $MUMPS_INCLUDE $I8DEFINES -DLinux -DLINUX -DLinux_intel $FDEFINES $DDM $SOLVERFLAGS -I$KDTREE2_MOD"

View File

@ -63,6 +63,30 @@ kinematics = {
[+1,-1,+1 , -1,+1,+2], [+1,-1,+1 , -1,+1,+2],
[-1,+1,+1 , +1,-1,+2], [-1,+1,+1 , +1,-1,+2],
[+1,+1,+1 , +1,+1,-2], [+1,+1,+1 , +1,+1,-2],
[+1,+1,-1 , +1,+2,+3],
[+1,-1,+1 , -1,+2,+3],
[-1,+1,+1 , +1,-2,+3],
[+1,+1,+1 , +1,+2,-3],
[+1,-1,+1 , +1,+3,+2],
[+1,+1,-1 , -1,+3,+2],
[+1,+1,+1 , +1,-3,+2],
[-1,+1,+1 , +1,+3,-2],
[+1,+1,-1 , +2,+1,+3],
[+1,-1,+1 , -2,+1,+3],
[-1,+1,+1 , +2,-1,+3],
[+1,+1,+1 , +2,+1,-3],
[+1,-1,+1 , +2,+3,+1],
[+1,+1,-1 , -2,+3,+1],
[+1,+1,+1 , +2,-3,+1],
[-1,+1,+1 , +2,+3,-1],
[-1,+1,+1 , +3,+1,+2],
[+1,+1,+1 , -3,+1,+2],
[+1,+1,-1 , +3,-1,+2],
[+1,-1,+1 , +3,+1,-2],
[-1,+1,+1 , +3,+2,+1],
[+1,+1,+1 , -3,+2,+1],
[+1,+1,-1 , +3,-2,+1],
[+1,-1,+1 , +3,+2,-1],
],'d'), ],'d'),
'twin' : _np.array([ 'twin' : _np.array([
[-1, 1, 1, 2, 1, 1], [-1, 1, 1, 2, 1, 1],

View File

@ -384,7 +384,7 @@ class Table:
Returns Returns
------- -------
udated : damask.Table updated : damask.Table
Updated table. Updated table.
""" """
@ -412,7 +412,7 @@ class Table:
Returns Returns
------- -------
udated : damask.Table updated : damask.Table
Updated table. Updated table.
""" """
@ -435,7 +435,7 @@ class Table:
Returns Returns
------- -------
udated : damask.Table updated : damask.Table
Updated table. Updated table.
""" """
@ -461,7 +461,7 @@ class Table:
Returns Returns
------- -------
udated : damask.Table updated : damask.Table
Updated table. Updated table.
""" """
@ -494,7 +494,7 @@ class Table:
Returns Returns
------- -------
udated : damask.Table updated : damask.Table
Updated table. Updated table.
""" """
@ -519,7 +519,7 @@ class Table:
Returns Returns
------- -------
udated : damask.Table updated : damask.Table
Updated table. Updated table.
""" """

View File

@ -23,3 +23,27 @@
-0.2357022603955159 0.2357022603955159 0.4714045207910318 0.23570226039551587 -0.23570226039551587 -0.47140452079103173 -0.2357022603955159 0.2357022603955159 0.4714045207910318 -0.2357022603955159 0.2357022603955159 0.4714045207910318 0.23570226039551587 -0.23570226039551587 -0.47140452079103173 -0.2357022603955159 0.2357022603955159 0.4714045207910318
-0.2357022603955158 0.2357022603955158 -0.4714045207910316 0.2357022603955159 -0.2357022603955159 0.4714045207910318 0.2357022603955159 -0.2357022603955159 0.4714045207910318 -0.2357022603955158 0.2357022603955158 -0.4714045207910316 0.2357022603955159 -0.2357022603955159 0.4714045207910318 0.2357022603955159 -0.2357022603955159 0.4714045207910318
0.2357022603955159 0.23570226039551587 -0.4714045207910318 0.2357022603955159 0.23570226039551587 -0.4714045207910318 0.2357022603955159 0.23570226039551587 -0.4714045207910318 0.2357022603955159 0.23570226039551587 -0.4714045207910318 0.2357022603955159 0.23570226039551587 -0.4714045207910318 0.2357022603955159 0.23570226039551587 -0.4714045207910318
0.1543033499620919 0.3086066999241838 0.4629100498862757 0.1543033499620919 0.3086066999241838 0.4629100498862757 -0.15430334996209194 -0.3086066999241839 -0.4629100498862758
-0.15430334996209194 0.3086066999241839 0.4629100498862758 0.1543033499620919 -0.3086066999241838 -0.4629100498862757 -0.15430334996209194 0.3086066999241839 0.4629100498862758
-0.15430334996209188 0.30860669992418377 -0.46291004988627565 0.15430334996209194 -0.3086066999241839 0.4629100498862758 0.15430334996209194 -0.3086066999241839 0.4629100498862758
0.15430334996209194 0.3086066999241839 -0.4629100498862758 0.15430334996209194 0.3086066999241839 -0.4629100498862758 0.15430334996209194 0.3086066999241839 -0.4629100498862758
0.15430334996209194 0.4629100498862758 0.3086066999241838 -0.1543033499620919 -0.4629100498862757 -0.30860669992418377 0.15430334996209194 0.4629100498862758 0.3086066999241838
-0.1543033499620919 0.4629100498862757 0.30860669992418377 -0.1543033499620919 0.4629100498862757 0.30860669992418377 0.15430334996209194 -0.4629100498862758 -0.3086066999241838
0.15430334996209194 -0.4629100498862758 0.3086066999241839 0.15430334996209194 -0.4629100498862758 0.3086066999241839 0.15430334996209194 -0.4629100498862758 0.3086066999241839
-0.15430334996209188 -0.46291004988627565 0.30860669992418377 0.15430334996209194 0.4629100498862758 -0.3086066999241839 0.15430334996209194 0.4629100498862758 -0.3086066999241839
0.3086066999241838 0.15430334996209188 0.4629100498862757 0.3086066999241838 0.15430334996209188 0.4629100498862757 -0.3086066999241839 -0.1543033499620919 -0.4629100498862758
-0.3086066999241839 0.15430334996209197 0.4629100498862758 0.3086066999241838 -0.15430334996209194 -0.4629100498862757 -0.3086066999241839 0.15430334996209197 0.4629100498862758
-0.30860669992418377 0.1543033499620919 -0.46291004988627565 0.3086066999241839 -0.15430334996209197 0.4629100498862758 0.3086066999241839 -0.15430334996209197 0.4629100498862758
0.3086066999241839 0.1543033499620919 -0.4629100498862758 0.3086066999241839 0.1543033499620919 -0.4629100498862758 0.3086066999241839 0.1543033499620919 -0.4629100498862758
0.3086066999241839 0.4629100498862758 0.15430334996209188 -0.3086066999241838 -0.4629100498862757 -0.15430334996209186 0.3086066999241839 0.4629100498862758 0.15430334996209188
-0.3086066999241838 0.4629100498862757 0.15430334996209188 -0.3086066999241838 0.4629100498862757 0.15430334996209188 0.3086066999241839 -0.4629100498862758 -0.1543033499620919
0.3086066999241839 -0.4629100498862758 0.15430334996209194 0.3086066999241839 -0.4629100498862758 0.15430334996209194 0.3086066999241839 -0.4629100498862758 0.15430334996209194
-0.30860669992418377 -0.46291004988627565 0.15430334996209194 0.3086066999241839 0.4629100498862758 -0.154303349962092 0.3086066999241839 0.4629100498862758 -0.154303349962092
-0.46291004988627565 -0.15430334996209186 -0.3086066999241837 0.4629100498862758 0.1543033499620919 0.3086066999241838 0.4629100498862758 0.1543033499620919 0.3086066999241838
-0.4629100498862758 0.15430334996209197 0.3086066999241839 -0.4629100498862758 0.15430334996209197 0.3086066999241839 -0.4629100498862758 0.15430334996209197 0.3086066999241839
0.4629100498862757 -0.15430334996209194 0.30860669992418377 0.4629100498862757 -0.15430334996209194 0.30860669992418377 -0.4629100498862758 0.15430334996209197 -0.3086066999241838
0.4629100498862758 0.1543033499620919 -0.3086066999241839 -0.4629100498862757 -0.15430334996209188 0.3086066999241838 0.4629100498862758 0.1543033499620919 -0.3086066999241839
-0.46291004988627565 -0.3086066999241837 -0.1543033499620918 0.4629100498862758 0.3086066999241838 0.15430334996209188 0.4629100498862758 0.3086066999241838 0.15430334996209188
-0.4629100498862758 0.3086066999241839 0.15430334996209194 -0.4629100498862758 0.3086066999241839 0.15430334996209194 -0.4629100498862758 0.3086066999241839 0.15430334996209194
0.4629100498862757 -0.3086066999241838 0.1543033499620919 0.4629100498862757 -0.3086066999241838 0.1543033499620919 -0.4629100498862758 0.3086066999241839 -0.15430334996209194
0.4629100498862758 0.3086066999241838 -0.154303349962092 -0.4629100498862757 -0.30860669992418377 0.15430334996209197 0.4629100498862758 0.3086066999241838 -0.154303349962092

View File

@ -104,7 +104,7 @@ module lattice
!-------------------------------------------------------------------------------------------------- !--------------------------------------------------------------------------------------------------
! body centered cubic (cI) ! body centered cubic (cI)
integer, dimension(*), parameter :: & integer, dimension(*), parameter :: &
BCC_NSLIPSYSTEM = [12, 12] !< # of slip systems per family for bcc BCC_NSLIPSYSTEM = [12, 12, 24] !< # of slip systems per family for bcc
integer, dimension(*), parameter :: & integer, dimension(*), parameter :: &
BCC_NTWINSYSTEM = [12] !< # of twin systems per family for bcc BCC_NTWINSYSTEM = [12] !< # of twin systems per family for bcc
@ -144,7 +144,32 @@ module lattice
1, 1,-1, 1, 1, 2, & ! C-2 1, 1,-1, 1, 1, 2, & ! C-2
1,-1, 1, -1, 1, 2, & ! D-1 1,-1, 1, -1, 1, 2, & ! D-1
-1, 1, 1, 1,-1, 2, & ! A-8 -1, 1, 1, 1,-1, 2, & ! A-8
1, 1, 1, 1, 1,-2 & ! B-7 1, 1, 1, 1, 1,-2, & ! B-7
! Slip system <111>{123}
1, 1,-1, 1, 2, 3, &
1,-1, 1, -1, 2, 3, &
-1, 1, 1, 1,-2, 3, &
1, 1, 1, 1, 2,-3, &
1,-1, 1, 1, 3, 2, &
1, 1,-1, -1, 3, 2, &
1, 1, 1, 1,-3, 2, &
-1, 1, 1, 1, 3,-2, &
1, 1,-1, 2, 1, 3, &
1,-1, 1, -2, 1, 3, &
-1, 1, 1, 2,-1, 3, &
1, 1, 1, 2, 1,-3, &
1,-1, 1, 2, 3, 1, &
1, 1,-1, -2, 3, 1, &
1, 1, 1, 2,-3, 1, &
-1, 1, 1, 2, 3,-1, &
-1, 1, 1, 3, 1, 2, &
1, 1, 1, -3, 1, 2, &
1, 1,-1, 3,-1, 2, &
1,-1, 1, 3, 1,-2, &
-1, 1, 1, 3, 2, 1, &
1, 1, 1, -3, 2, 1, &
1, 1,-1, 3,-2, 1, &
1,-1, 1, 3, 2,-1 &
],pReal),shape(BCC_SYSTEMSLIP)) !< bcc slip systems ],pReal),shape(BCC_SYSTEMSLIP)) !< bcc slip systems
real(pReal), dimension(3+3,BCC_NTWIN), parameter :: & real(pReal), dimension(3+3,BCC_NTWIN), parameter :: &
@ -770,31 +795,56 @@ function lattice_interaction_SlipBySlip(Nslip,interactionValues,structure) resul
integer, dimension(BCC_NSLIP,BCC_NSLIP), parameter :: & integer, dimension(BCC_NSLIP,BCC_NSLIP), parameter :: &
BCC_INTERACTIONSLIPSLIP = reshape( [& BCC_INTERACTIONSLIPSLIP = reshape( [&
1, 3, 6, 6, 7, 5, 4, 2, 4, 2, 7, 5, 18,18,11, 8, 9,13,17,14,13, 9,17,14, & ! -----> acting (forest) 1, 3, 6, 6, 7, 5, 4, 2, 4, 2, 7, 5, 18, 18, 11, 8, 9, 13, 17, 14, 13, 9, 17, 14, 28, 25, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 25, 28, 28, 28, 28, 28, 28, 25, 28, 28, 28, 25, &! -----> acting (forest)
3, 1, 6, 6, 4, 2, 7, 5, 7, 5, 4, 2, 18,18, 8,11,13, 9,14,17, 9,13,14,17, & ! | 3, 1, 6, 6, 4, 2, 7, 5, 7, 5, 4, 2, 18, 18, 8, 11, 13, 9, 14, 17, 9, 13, 14, 17, 25, 28, 28, 28, 28, 25, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 28, 25, 28, &! |
6, 6, 1, 3, 5, 7, 2, 4, 5, 7, 2, 4, 11, 8,18,18,17,14, 9,13,17,14,13, 9, & ! | 6, 6, 1, 3, 5, 7, 2, 4, 5, 7, 2, 4, 11, 8, 18, 18, 17, 14, 9, 13, 17, 14, 13, 9, 28, 28, 28, 25, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 25, 28, 28, 25, 28, 28, 28, 25, 28, 28, &! |
6, 6, 3, 1, 2, 4, 5, 7, 2, 4, 5, 7, 8,11,18,18,14,17,13, 9,14,17, 9,13, & ! v 6, 6, 3, 1, 2, 4, 5, 7, 2, 4, 5, 7, 8, 11, 18, 18, 14, 17, 13, 9, 14, 17, 9, 13, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 25, 28, 28, 28, 28, 25, 25, 28, 28, 28, 25, 28, 28, 28, &! v
7, 5, 4, 2, 1, 3, 6, 6, 2, 4, 7, 5, 9,17,13,14,18,11,18, 8,13,17, 9,14, & ! reacting (primary) 7, 5, 4, 2, 1, 3, 6, 6, 2, 4, 7, 5, 9, 17, 13, 14, 18, 11, 18, 8, 13, 17, 9, 14, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 25, 28, 28, 28, 28, 25, 25, 28, 28, 28, 25, 28, 28, 28, &! reacting (primary)
4, 2, 7, 5, 3, 1, 6, 6, 5, 7, 4, 2, 13,14, 9,17,18, 8,18,11, 9,14,13,17, & 4, 2, 7, 5, 3, 1, 6, 6, 5, 7, 4, 2, 13, 14, 9, 17, 18, 8, 18, 11, 9, 14, 13, 17, 25, 28, 28, 28, 28, 25, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 28, 25, 28, &
5, 7, 2, 4, 6, 6, 1, 3, 7, 5, 2, 4, 17, 9,14,13,11,18, 8,18,17,13,14, 9, & 5, 7, 2, 4, 6, 6, 1, 3, 7, 5, 2, 4, 17, 9, 14, 13, 11, 18, 8, 18, 17, 13, 14, 9, 28, 28, 28, 25, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 25, 28, 28, 25, 28, 28, 28, 25, 28, 28, &
2, 4, 5, 7, 6, 6, 3, 1, 4, 2, 5, 7, 14,13,17, 9, 8,18,11,18,14, 9,17,13, & 2, 4, 5, 7, 6, 6, 3, 1, 4, 2, 5, 7, 14, 13, 17, 9, 8, 18, 11, 18, 14, 9, 17, 13, 28, 25, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 25, 28, 28, 28, 28, 28, 28, 25, 28, 28, 28, 25, &
5, 7, 4, 2, 2, 4, 7, 5, 1, 3, 6, 6, 9,17,14,13,13,17,14, 9,18,11, 8,18, & 5, 7, 4, 2, 2, 4, 7, 5, 1, 3, 6, 6, 9, 17, 14, 13, 13, 17, 14, 9, 18, 11, 8, 18, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 25, 28, 28, 28, 28, 25, 25, 28, 28, 28, 25, 28, 28, 28, &
2, 4, 7, 5, 5, 7, 4, 2, 3, 1, 6, 6, 13,14,17, 9, 9,14,17,13,18, 8,11,18, & 2, 4, 7, 5, 5, 7, 4, 2, 3, 1, 6, 6, 13, 14, 17, 9, 9, 14, 17, 13, 18, 8, 11, 18, 28, 25, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 25, 28, 28, 28, 28, 28, 28, 25, 28, 28, 28, 25, &
7, 5, 2, 4, 7, 5, 2, 4, 6, 6, 1, 3, 17, 9,13,14,17,13, 9,14,11,18,18, 8, & 7, 5, 2, 4, 7, 5, 2, 4, 6, 6, 1, 3, 17, 9, 13, 14, 17, 13, 9, 14, 11, 18, 18, 8, 28, 28, 28, 25, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 25, 28, 28, 25, 28, 28, 28, 25, 28, 28, &
4, 2, 5, 7, 4, 2, 5, 7, 6, 6, 3, 1, 14,13, 9,17,14, 9,13,17, 8,18,18,11, & 4, 2, 5, 7, 4, 2, 5, 7, 6, 6, 3, 1, 14, 13, 9, 17, 14, 9, 13, 17, 8, 18, 18, 11, 25, 28, 28, 28, 28, 25, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 28, 28, 25, 28, 28, 28, 25, 28, &
! !
19,19,10, 8, 9,12,16,15, 9,12,16,15, 1,20,24,24,23,22,21, 2,23,22, 2,21, & 19, 19, 10, 8, 9, 12, 16, 15, 9, 12, 16, 15, 1, 20, 24, 24, 23, 22, 21, 2, 23, 22, 2, 21, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 28, 26, 26, 28, 28, 28, 26, 28, 28, 28, &
19,19, 8,10,16,15, 9,12,16,15, 9,12, 20, 1,24,24,22,23, 2,21,22,23,21, 2, & 19, 19, 8, 10, 16, 15, 9, 12, 16, 15, 9, 12, 20, 1, 24, 24, 22, 23, 2, 21, 22, 23, 21, 2, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 26, 28, 28, 28, 26, 28, 28, &
10, 8,19,19,12, 9,15,16,15,16,12, 9, 24,24, 1,20,21, 2,23,22, 2,21,23,22, & 10, 8, 19, 19, 12, 9, 15, 16, 15, 16, 12, 9, 24, 24, 1, 20, 21, 2, 23, 22, 2, 21, 23, 22, 26, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 26, 28, &
8,10,19,19,15,16,12, 9,12, 9,15,16, 24,24,20, 1, 2,21,22,23,21, 2,22,23, & 8, 10, 19, 19, 15, 16, 12, 9, 12, 9, 15, 16, 24, 24, 20, 1, 2, 21, 22, 23, 21, 2, 22, 23, 28, 26, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 28, 28, 28, 26, 28, 28, 28, 26, &
9,12,16,15,19,19,10, 8,12, 9,16,15, 23,21,22, 2, 1,24,20,24,23, 2,22,21, & 9, 12, 16, 15, 19, 19, 10, 8, 12, 9, 16, 15, 23, 21, 22, 2, 1, 24, 20, 24, 23, 2, 22, 21, 28, 26, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 28, 28, 28, 26, 28, 28, 28, 26, &
12, 9,15,16,10, 8,19,19,16,15,12, 9, 21,23, 2,21,24, 1,24,20, 2,23,21,22, & 12, 9, 15, 16, 10, 8, 19, 19, 16, 15, 12, 9, 21, 23, 2, 21, 24, 1, 24, 20, 2, 23, 21, 22, 26, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 26, 28, &
16,15, 9,12,19,19, 8,10,15,16, 9,12, 22, 2,23,22,20,24, 1,24,22,21,23, 2, & 16, 15, 9, 12, 19, 19, 8, 10, 15, 16, 9, 12, 22, 2, 23, 22, 20, 24, 1, 24, 22, 21, 23, 2, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 26, 28, 28, 28, 26, 28, 28, &
15,16,12, 9, 8,10,19,19, 9,12,15,16, 2,22,21,23,24,20,24, 1,21,22, 2,23, & 15, 16, 12, 9, 8, 10, 19, 19, 9, 12, 15, 16, 2, 22, 21, 23, 24, 20, 24, 1, 21, 22, 2, 23, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 28, 26, 26, 28, 28, 28, 26, 28, 28, 28, &
12, 9,16,15,12, 9,16,15,19,19,10, 8, 23,21, 2,22,23, 2,21,22, 1,24,24,20, & 12, 9, 16, 15, 12, 9, 16, 15, 19, 19, 10, 8, 23, 21, 2, 22, 23, 2, 21, 22, 1, 24, 24, 20, 26, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 26, 28, &
9,12,15,16,16,15,12, 9,10, 8,19,19, 21,23,22, 2, 2,23,22,21,24, 1,20,24, & 9, 12, 15, 16, 16, 15, 12, 9, 10, 8, 19, 19, 21, 23, 22, 2, 2, 23, 22, 21, 24, 1, 20, 24, 28, 26, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 28, 28, 28, 26, 28, 28, 28, 26, &
16,15,12, 9, 9,12,15,16, 8,10,19,19, 2,22,23,21,21,22,23, 2,24,20, 1,24, & 16, 15, 12, 9, 9, 12, 15, 16, 8, 10, 19, 19, 2, 22, 23, 21, 21, 22, 23, 2, 24, 20, 1, 24, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 28, 26, 26, 28, 28, 28, 26, 28, 28, 28, &
15,16, 9,12,15,16, 9,12,19,19, 8,10, 22, 2,21,23,22,21, 2,23,20,24,24, 1 & 15, 16, 9, 12, 15, 16, 9, 12, 19, 19, 8, 10, 22, 2, 21, 23, 22, 21, 2, 23, 20, 24, 24, 1, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 26, 28, 28, 28, 26, 28, 28, &
!
28, 25, 28, 28, 28, 25, 28, 28, 28, 28, 28, 25, 28, 28, 26, 28, 28, 26, 28, 28, 26, 28, 28, 28, 1, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 28, 27, 28, &
25, 28, 28, 28, 28, 28, 28, 25, 28, 25, 28, 28, 28, 28, 28, 26, 26, 28, 28, 28, 28, 26, 28, 28, 28, 1, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 28, 28, 27, 28, 28, 28, 27, &
28, 28, 28, 25, 25, 28, 28, 28, 25, 28, 28, 28, 26, 28, 28, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 1, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 27, 27, 28, 28, 28, 27, 28, 28, 28, &
28, 28, 25, 28, 28, 28, 25, 28, 28, 28, 25, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 1, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 27, 28, 28, 28, 27, 28, 28, &
25, 28, 28, 28, 28, 28, 28, 25, 28, 25, 28, 28, 28, 28, 28, 26, 26, 28, 28, 28, 28, 26, 28, 28, 28, 27, 28, 28, 1, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 28, 28, 27, 28, 28, 28, 27, &
28, 25, 28, 28, 28, 25, 28, 28, 28, 28, 28, 25, 28, 28, 26, 28, 28, 26, 28, 28, 26, 28, 28, 28, 27, 28, 28, 28, 28, 1, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 28, 27, 28, &
28, 28, 25, 28, 28, 28, 25, 28, 28, 28, 25, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 27, 28, 28, 1, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 27, 28, 28, 28, 27, 28, 28, &
28, 28, 28, 25, 25, 28, 28, 28, 25, 28, 28, 28, 26, 28, 28, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 27, 28, 28, 28, 28, 1, 28, 28, 27, 28, 28, 28, 28, 27, 27, 28, 28, 28, 27, 28, 28, 28, &
28, 25, 28, 28, 28, 25, 28, 28, 28, 28, 28, 25, 28, 28, 26, 28, 28, 26, 28, 28, 26, 28, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 1, 28, 28, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 28, 27, 28, &
25, 28, 28, 28, 28, 28, 28, 25, 28, 25, 28, 28, 28, 28, 28, 26, 26, 28, 28, 28, 28, 26, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 1, 28, 28, 27, 28, 28, 28, 28, 28, 28, 27, 28, 28, 28, 27, &
28, 28, 28, 25, 25, 28, 28, 28, 25, 28, 28, 28, 26, 28, 28, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 1, 28, 28, 28, 28, 27, 27, 28, 28, 28, 27, 28, 28, 28, &
28, 28, 25, 28, 28, 28, 25, 28, 28, 28, 25, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 1, 28, 28, 27, 28, 28, 27, 28, 28, 28, 27, 28, 28, &
25, 28, 28, 28, 28, 28, 28, 25, 28, 25, 28, 28, 28, 28, 28, 26, 26, 28, 28, 28, 28, 26, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 1, 28, 28, 28, 28, 28, 28, 27, 28, 28, 28, 27, &
28, 25, 28, 28, 28, 25, 28, 28, 28, 28, 28, 25, 28, 28, 26, 28, 28, 26, 28, 28, 26, 28, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 1, 28, 28, 28, 28, 27, 28, 28, 28, 27, 28, &
28, 28, 25, 28, 28, 28, 25, 28, 28, 28, 25, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 1, 28, 28, 27, 28, 28, 28, 27, 28, 28, &
28, 28, 28, 25, 25, 28, 28, 28, 25, 28, 28, 28, 26, 28, 28, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 1, 27, 28, 28, 28, 27, 28, 28, 28, &
28, 28, 28, 25, 25, 28, 28, 28, 25, 28, 28, 28, 26, 28, 28, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 27, 1, 28, 28, 28, 27, 28, 28, 28, &
28, 28, 25, 28, 28, 28, 25, 28, 28, 28, 25, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 1, 28, 28, 28, 27, 28, 28, &
28, 25, 28, 28, 28, 25, 28, 28, 28, 28, 28, 25, 28, 28, 26, 28, 28, 26, 28, 28, 26, 28, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 28, 28, 1, 28, 28, 28, 27, 28, &
25, 28, 28, 28, 28, 28, 28, 25, 28, 25, 28, 28, 28, 28, 28, 26, 26, 28, 28, 28, 28, 26, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 28, 28, 1, 28, 28, 28, 27, &
28, 28, 28, 25, 25, 28, 28, 28, 25, 28, 28, 28, 26, 28, 28, 28, 28, 28, 28, 26, 28, 28, 26, 28, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 27, 27, 28, 28, 28, 1, 28, 28, 28, &
28, 28, 25, 28, 28, 28, 25, 28, 28, 28, 25, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 28, 26, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 27, 28, 28, 28, 1, 28, 28, &
28, 25, 28, 28, 28, 25, 28, 28, 28, 28, 28, 25, 28, 28, 26, 28, 28, 26, 28, 28, 26, 28, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 28, 1, 28, &
25, 28, 28, 28, 28, 28, 28, 25, 28, 25, 28, 28, 28, 28, 28, 26, 26, 28, 28, 28, 28, 26, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 27, 28, 28, 27, 28, 28, 28, 28, 28, 28, 27, 28, 28, 28, 1 &
],shape(BCC_INTERACTIONSLIPSLIP)) !< Slip-slip interaction types for bcc / Madec 2017 (https://doi.org/10.1016/j.actamat.2016.12.040) ],shape(BCC_INTERACTIONSLIPSLIP)) !< Slip-slip interaction types for bcc / Madec 2017 (https://doi.org/10.1016/j.actamat.2016.12.040)
!< 1: self interaction --> alpha 0 !< 1: self interaction --> alpha 0
!< 2: collinear interaction --> alpha 1 !< 2: collinear interaction --> alpha 1
@ -803,6 +853,10 @@ function lattice_interaction_SlipBySlip(Nslip,interactionValues,structure) resul
!< 8: {110}-{112}, collinear and perpendicular planes --> alpha 6 !< 8: {110}-{112}, collinear and perpendicular planes --> alpha 6
!< 9: {110}-{112}, just collinear --> alpha 7 !< 9: {110}-{112}, just collinear --> alpha 7
!< 10-24: other coefficients !< 10-24: other coefficients
!< 25: {110}-{123}, just collinear
!< 26: {112}-{123}, just collinear
!< 27: {123}-{123}, just collinear
!< 28: other interaction
integer, dimension(HEX_NSLIP,HEX_NSLIP), parameter :: & integer, dimension(HEX_NSLIP,HEX_NSLIP), parameter :: &
HEX_INTERACTIONSLIPSLIP = reshape( [& HEX_INTERACTIONSLIPSLIP = reshape( [&
@ -1144,11 +1198,38 @@ function lattice_interaction_SlipByTwin(Nslip,Ntwin,interactionValues,structure)
3,3,2,3,3,2,3,3,1,3,3,3, & 3,3,2,3,3,2,3,3,1,3,3,3, &
3,3,3,2,2,3,3,3,3,1,3,3, & 3,3,3,2,2,3,3,3,3,1,3,3, &
2,3,3,3,3,3,3,2,3,3,1,3, & 2,3,3,3,3,3,3,2,3,3,1,3, &
3,2,3,3,3,3,2,3,3,3,3,1 & 3,2,3,3,3,3,2,3,3,3,3,1, &
!
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4, &
4,4,4,4,4,4,4,4,4,4,4,4 &
],shape(BCC_INTERACTIONSLIPTWIN)) !< Slip-twin interaction types for bcc ],shape(BCC_INTERACTIONSLIPTWIN)) !< Slip-twin interaction types for bcc
!< 1: coplanar interaction !< 1: coplanar interaction
!< 2: screw trace between slip system and twin habit plane (easy cross slip) !< 2: screw trace between slip system and twin habit plane (easy cross slip)
!< 3: other interaction !< 3: other interaction
!< 4: other interaction with slip family {123}
integer, dimension(HEX_NTWIN,HEX_NSLIP), parameter :: & integer, dimension(HEX_NTWIN,HEX_NSLIP), parameter :: &
HEX_INTERACTIONSLIPTWIN = reshape( [& HEX_INTERACTIONSLIPTWIN = reshape( [&
1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, & ! ----> twin (acting) 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, & ! ----> twin (acting)

View File

@ -67,10 +67,6 @@ module phase
damageState damageState
integer, public, protected :: &
phase_plasticity_maxSizeDotState, &
phase_source_maxSizeDotState
interface interface
! == cleaned:begin ================================================================================= ! == cleaned:begin =================================================================================
@ -235,11 +231,16 @@ module phase
logical :: converged_ logical :: converged_
end function crystallite_stress end function crystallite_stress
!ToDo: Try to merge the all stiffness functions
module function phase_homogenizedC(ph,en) result(C) module function phase_homogenizedC(ph,en) result(C)
integer, intent(in) :: ph, en integer, intent(in) :: ph, en
real(pReal), dimension(6,6) :: C real(pReal), dimension(6,6) :: C
end function phase_homogenizedC end function phase_homogenizedC
module function phase_damage_C(C_homogenized,ph,en) result(C)
real(pReal), dimension(3,3,3,3), intent(in) :: C_homogenized
integer, intent(in) :: ph,en
real(pReal), dimension(3,3,3,3) :: C
end function phase_damage_C
module function phase_f_phi(phi,co,ce) result(f) module function phase_f_phi(phi,co,ce) result(f)
integer, intent(in) :: ce,co integer, intent(in) :: ce,co
@ -372,19 +373,6 @@ subroutine phase_init
call damage_init call damage_init
call thermal_init(phases) call thermal_init(phases)
phase_source_maxSizeDotState = 0
PhaseLoop2:do ph = 1,phases%length
!--------------------------------------------------------------------------------------------------
! partition and initialize state
plasticState(ph)%state = plasticState(ph)%state0
if(damageState(ph)%sizeState > 0) &
damageState(ph)%state = damageState(ph)%state0
enddo PhaseLoop2
phase_source_maxSizeDotState = maxval(damageState%sizeDotState)
phase_plasticity_maxSizeDotState = maxval(plasticState%sizeDotState)
end subroutine phase_init end subroutine phase_init
@ -540,8 +528,7 @@ subroutine crystallite_init()
phases => config_material%get('phase') phases => config_material%get('phase')
do ph = 1, phases%length do ph = 1, phases%length
if (damageState(ph)%sizeState > 0) & if (damageState(ph)%sizeState > 0) allocate(damageState(ph)%subState0,source=damageState(ph)%state0) ! ToDo: hack
allocate(damageState(ph)%subState0,source=damageState(ph)%state0) ! ToDo: hack
enddo enddo
print'(a42,1x,i10)', ' # of elements: ', eMax print'(a42,1x,i10)', ' # of elements: ', eMax

View File

@ -15,13 +15,15 @@ submodule(phase) damage
DAMAGE_ANISOBRITTLE_ID DAMAGE_ANISOBRITTLE_ID
end enum end enum
integer :: phase_damage_maxSizeDotState
type :: tDataContainer type :: tDataContainer
real(pReal), dimension(:), allocatable :: phi, d_phi_d_dot_phi real(pReal), dimension(:), allocatable :: phi, d_phi_d_dot_phi
end type tDataContainer end type tDataContainer
integer(kind(DAMAGE_UNDEFINED_ID)), dimension(:), allocatable :: & integer(kind(DAMAGE_UNDEFINED_ID)), dimension(:), allocatable :: &
phase_source !< active sources mechanisms of each phase phase_damage !< active sources mechanisms of each phase
type(tDataContainer), dimension(:), allocatable :: current type(tDataContainer), dimension(:), allocatable :: current
@ -126,17 +128,38 @@ module subroutine damage_init
enddo enddo
allocate(phase_source(phases%length), source = DAMAGE_UNDEFINED_ID) allocate(phase_damage(phases%length), source = DAMAGE_UNDEFINED_ID)
if (damage_active) then if (damage_active) then
where(isobrittle_init() ) phase_source = DAMAGE_ISOBRITTLE_ID where(isobrittle_init() ) phase_damage = DAMAGE_ISOBRITTLE_ID
where(isoductile_init() ) phase_source = DAMAGE_ISODUCTILE_ID where(isoductile_init() ) phase_damage = DAMAGE_ISODUCTILE_ID
where(anisobrittle_init()) phase_source = DAMAGE_ANISOBRITTLE_ID where(anisobrittle_init()) phase_damage = DAMAGE_ANISOBRITTLE_ID
endif endif
phase_damage_maxSizeDotState = maxval(damageState%sizeDotState)
end subroutine damage_init end subroutine damage_init
!--------------------------------------------------------------------------------------------------
!> @brief returns the degraded/modified elasticity matrix
!--------------------------------------------------------------------------------------------------
module function phase_damage_C(C_homogenized,ph,en) result(C)
real(pReal), dimension(3,3,3,3), intent(in) :: C_homogenized
integer, intent(in) :: ph,en
real(pReal), dimension(3,3,3,3) :: C
damageType: select case (phase_damage(ph))
case (DAMAGE_ISOBRITTLE_ID) damageType
C = C_homogenized * damage_phi(ph,en)**2
case default damageType
C = C_homogenized
end select damageType
end function phase_damage_C
!---------------------------------------------------------------------------------------------- !----------------------------------------------------------------------------------------------
!< @brief returns local part of nonlocal damage driving force !< @brief returns local part of nonlocal damage driving force
!---------------------------------------------------------------------------------------------- !----------------------------------------------------------------------------------------------
@ -155,7 +178,7 @@ module function phase_f_phi(phi,co,ce) result(f)
ph = material_phaseID(co,ce) ph = material_phaseID(co,ce)
en = material_phaseEntry(co,ce) en = material_phaseEntry(co,ce)
select case(phase_source(ph)) select case(phase_damage(ph))
case(DAMAGE_ISOBRITTLE_ID,DAMAGE_ISODUCTILE_ID,DAMAGE_ANISOBRITTLE_ID) case(DAMAGE_ISOBRITTLE_ID,DAMAGE_ISODUCTILE_ID,DAMAGE_ANISOBRITTLE_ID)
f = 1.0_pReal & f = 1.0_pReal &
- phi*damageState(ph)%state(1,en) - phi*damageState(ph)%state(1,en)
@ -187,9 +210,9 @@ module function integrateDamageState(dt,co,ip,el) result(broken)
size_so size_so
real(pReal) :: & real(pReal) :: &
zeta zeta
real(pReal), dimension(phase_source_maxSizeDotState) :: & real(pReal), dimension(phase_damage_maxSizeDotState) :: &
r ! state residuum r ! state residuum
real(pReal), dimension(phase_source_maxSizeDotState,2) :: source_dotState real(pReal), dimension(phase_damage_maxSizeDotState,2) :: source_dotState
logical :: & logical :: &
converged_ converged_
@ -275,10 +298,10 @@ module subroutine damage_results(group,ph)
integer, intent(in) :: ph integer, intent(in) :: ph
if (phase_source(ph) /= DAMAGE_UNDEFINED_ID) & if (phase_damage(ph) /= DAMAGE_UNDEFINED_ID) &
call results_closeGroup(results_addGroup(group//'damage')) call results_closeGroup(results_addGroup(group//'damage'))
sourceType: select case (phase_source(ph)) sourceType: select case (phase_damage(ph))
case (DAMAGE_ISOBRITTLE_ID) sourceType case (DAMAGE_ISOBRITTLE_ID) sourceType
call isobrittle_results(ph,group//'damage/') call isobrittle_results(ph,group//'damage/')
@ -309,7 +332,7 @@ function phase_damage_collectDotState(ph,me) result(broken)
if (damageState(ph)%sizeState > 0) then if (damageState(ph)%sizeState > 0) then
sourceType: select case (phase_source(ph)) sourceType: select case (phase_damage(ph))
case (DAMAGE_ISODUCTILE_ID) sourceType case (DAMAGE_ISODUCTILE_ID) sourceType
call isoductile_dotState(ph,me) call isoductile_dotState(ph,me)
@ -376,7 +399,7 @@ function phase_damage_deltaState(Fe, ph, me) result(broken)
if (damageState(ph)%sizeState == 0) return if (damageState(ph)%sizeState == 0) return
sourceType: select case (phase_source(ph)) sourceType: select case (phase_damage(ph))
case (DAMAGE_ISOBRITTLE_ID) sourceType case (DAMAGE_ISOBRITTLE_ID) sourceType
call isobrittle_deltaState(phase_homogenizedC(ph,me), Fe, ph,me) call isobrittle_deltaState(phase_homogenizedC(ph,me), Fe, ph,me)

View File

@ -66,14 +66,14 @@ module function isobrittle_init() result(mySources)
Nmembers = count(material_phaseID==ph) Nmembers = count(material_phaseID==ph)
call phase_allocateState(damageState(ph),Nmembers,1,1,1) call phase_allocateState(damageState(ph),Nmembers,1,1,1)
damageState(ph)%atol = src%get_asFloat('isoBrittle_atol',defaultVal=1.0e-3_pReal) damageState(ph)%atol = src%get_asFloat('isobrittle_atol',defaultVal=1.0e-3_pReal)
if(any(damageState(ph)%atol < 0.0_pReal)) extmsg = trim(extmsg)//' isobrittle_atol' if(any(damageState(ph)%atol < 0.0_pReal)) extmsg = trim(extmsg)//' isobrittle_atol'
end associate end associate
!-------------------------------------------------------------------------------------------------- !--------------------------------------------------------------------------------------------------
! exit if any parameter is out of range ! exit if any parameter is out of range
if (extmsg /= '') call IO_error(211,ext_msg=trim(extmsg)//'(damage_isoBrittle)') if (extmsg /= '') call IO_error(211,ext_msg=trim(extmsg)//'(damage_isobrittle)')
endif endif
enddo enddo

View File

@ -70,14 +70,14 @@ module function isoductile_init() result(mySources)
Nmembers=count(material_phaseID==ph) Nmembers=count(material_phaseID==ph)
call phase_allocateState(damageState(ph),Nmembers,1,1,0) call phase_allocateState(damageState(ph),Nmembers,1,1,0)
damageState(ph)%atol = src%get_asFloat('isoDuctile_atol',defaultVal=1.0e-3_pReal) damageState(ph)%atol = src%get_asFloat('isoductile_atol',defaultVal=1.0e-3_pReal)
if(any(damageState(ph)%atol < 0.0_pReal)) extmsg = trim(extmsg)//' isoductile_atol' if(any(damageState(ph)%atol < 0.0_pReal)) extmsg = trim(extmsg)//' isoductile_atol'
end associate end associate
!-------------------------------------------------------------------------------------------------- !--------------------------------------------------------------------------------------------------
! exit if any parameter is out of range ! exit if any parameter is out of range
if (extmsg /= '') call IO_error(211,ext_msg=trim(extmsg)//'(damage_isoDuctile)') if (extmsg /= '') call IO_error(211,ext_msg=trim(extmsg)//'(damage_isoductile)')
endif endif
enddo enddo

View File

@ -41,6 +41,7 @@ submodule(phase) mechanical
integer(kind(PLASTICITY_undefined_ID)), dimension(:), allocatable :: & integer(kind(PLASTICITY_undefined_ID)), dimension(:), allocatable :: &
phase_plasticity !< plasticity of each phase phase_plasticity !< plasticity of each phase
integer :: phase_plasticity_maxSizeDotState
interface interface
@ -294,6 +295,11 @@ module subroutine mechanical_init(materials,phases)
call plastic_init() call plastic_init()
do ph = 1,phases%length
plasticState(ph)%state0 = plasticState(ph)%state
enddo
phase_plasticity_maxSizeDotState = maxval(plasticState%sizeDotState)
num_crystallite => config_numerics%get('crystallite',defaultVal=emptyDict) num_crystallite => config_numerics%get('crystallite',defaultVal=emptyDict)

View File

@ -2,18 +2,11 @@ submodule(phase:mechanical) elastic
enum, bind(c); enumerator :: & enum, bind(c); enumerator :: &
ELASTICITY_UNDEFINED_ID, & ELASTICITY_UNDEFINED_ID, &
ELASTICITY_HOOKE_ID, & ELASTICITY_HOOKE_ID
STIFFNESS_DEGRADATION_UNDEFINED_ID, &
STIFFNESS_DEGRADATION_DAMAGE_ID
end enum end enum
integer, dimension(:), allocatable :: &
phase_NstiffnessDegradations
integer(kind(ELASTICITY_UNDEFINED_ID)), dimension(:), allocatable :: & integer(kind(ELASTICITY_UNDEFINED_ID)), dimension(:), allocatable :: &
phase_elasticity !< elasticity of each phase phase_elasticity !< elasticity of each phase
integer(kind(STIFFNESS_DEGRADATION_UNDEFINED_ID)), dimension(:,:), allocatable :: &
phase_stiffnessDegradation !< active stiffness degradation mechanisms of each phase
contains contains
@ -24,18 +17,15 @@ module subroutine elastic_init(phases)
phases phases
integer :: & integer :: &
ph, & ph
stiffDegradationCtr
class(tNode), pointer :: & class(tNode), pointer :: &
phase, & phase, &
mech, & mech, &
elastic, & elastic
stiffDegradation
print'(/,a)', ' <<<+- phase:mechanical:elastic init -+>>>' print'(/,a)', ' <<<+- phase:mechanical:elastic init -+>>>'
allocate(phase_elasticity(phases%length), source = ELASTICITY_undefined_ID) allocate(phase_elasticity(phases%length), source = ELASTICITY_undefined_ID)
allocate(phase_NstiffnessDegradations(phases%length),source=0)
do ph = 1, phases%length do ph = 1, phases%length
phase => phases%get(ph) phase => phases%get(ph)
@ -46,25 +36,8 @@ module subroutine elastic_init(phases)
else else
call IO_error(200,ext_msg=elastic%get_asString('type')) call IO_error(200,ext_msg=elastic%get_asString('type'))
endif endif
stiffDegradation => mech%get('stiffness_degradation',defaultVal=emptyList) ! check for stiffness degradation mechanisms
phase_NstiffnessDegradations(ph) = stiffDegradation%length
enddo enddo
allocate(phase_stiffnessDegradation(maxval(phase_NstiffnessDegradations),phases%length), &
source=STIFFNESS_DEGRADATION_undefined_ID)
if(maxVal(phase_NstiffnessDegradations)/=0) then
do ph = 1, phases%length
phase => phases%get(ph)
mech => phase%get('mechanical')
stiffDegradation => mech%get('stiffness_degradation',defaultVal=emptyList)
do stiffDegradationCtr = 1, stiffDegradation%length
if(stiffDegradation%get_asString(stiffDegradationCtr) == 'damage') &
phase_stiffnessDegradation(stiffDegradationCtr,ph) = STIFFNESS_DEGRADATION_damage_ID
enddo
enddo
endif
end subroutine elastic_init end subroutine elastic_init
@ -94,13 +67,7 @@ module subroutine phase_hooke_SandItsTangents(S, dS_dFe, dS_dFi, &
i, j i, j
C = math_66toSym3333(phase_homogenizedC(ph,en)) C = math_66toSym3333(phase_homogenizedC(ph,en))
C = phase_damage_C(C,ph,en)
DegradationLoop: do d = 1, phase_NstiffnessDegradations(ph)
degradationType: select case(phase_stiffnessDegradation(d,ph))
case (STIFFNESS_DEGRADATION_damage_ID) degradationType
C = C * damage_phi(ph,en)**2
end select degradationType
enddo DegradationLoop
E = 0.5_pReal*(matmul(transpose(Fe),Fe)-math_I3) !< Green-Lagrange strain in unloaded configuration E = 0.5_pReal*(matmul(transpose(Fe),Fe)-math_I3) !< Green-Lagrange strain in unloaded configuration
S = math_mul3333xx33(C,matmul(matmul(transpose(Fi),E),Fi)) !< 2PK stress in lattice configuration in work conjugate with GL strain pulled back to lattice configuration S = math_mul3333xx33(C,matmul(matmul(transpose(Fi),E),Fi)) !< 2PK stress in lattice configuration in work conjugate with GL strain pulled back to lattice configuration

View File

@ -254,8 +254,6 @@ module function plastic_dislotungsten_init() result(myPlasticity)
allocate(dst%Lambda_sl(prm%sum_N_sl,Nmembers), source=0.0_pReal) allocate(dst%Lambda_sl(prm%sum_N_sl,Nmembers), source=0.0_pReal)
allocate(dst%threshold_stress(prm%sum_N_sl,Nmembers), source=0.0_pReal) allocate(dst%threshold_stress(prm%sum_N_sl,Nmembers), source=0.0_pReal)
plasticState(ph)%state0 = plasticState(ph)%state ! ToDo: this could be done centrally
end associate end associate
!-------------------------------------------------------------------------------------------------- !--------------------------------------------------------------------------------------------------
@ -414,7 +412,7 @@ module subroutine plastic_dislotungsten_results(ph,group)
'mobile dislocation density','1/m²') 'mobile dislocation density','1/m²')
case('rho_dip') case('rho_dip')
if(prm%sum_N_sl>0) call results_writeDataset(group,stt%rho_dip,trim(prm%output(o)), & if(prm%sum_N_sl>0) call results_writeDataset(group,stt%rho_dip,trim(prm%output(o)), &
'dislocation dipole density''1/m²') 'dislocation dipole density','1/m²')
case('gamma_sl') case('gamma_sl')
if(prm%sum_N_sl>0) call results_writeDataset(group,stt%gamma_sl,trim(prm%output(o)), & if(prm%sum_N_sl>0) call results_writeDataset(group,stt%gamma_sl,trim(prm%output(o)), &
'plastic shear','1') 'plastic shear','1')

View File

@ -467,8 +467,6 @@ module function plastic_dislotwin_init() result(myPlasticity)
allocate(dst%tau_r_tr (prm%sum_N_tr,Nmembers),source=0.0_pReal) allocate(dst%tau_r_tr (prm%sum_N_tr,Nmembers),source=0.0_pReal)
allocate(dst%V_tr (prm%sum_N_tr,Nmembers),source=0.0_pReal) allocate(dst%V_tr (prm%sum_N_tr,Nmembers),source=0.0_pReal)
plasticState(ph)%state0 = plasticState(ph)%state ! ToDo: this could be done centrally
end associate end associate
!-------------------------------------------------------------------------------------------------- !--------------------------------------------------------------------------------------------------

View File

@ -140,8 +140,6 @@ module function plastic_isotropic_init() result(myPlasticity)
! global alias ! global alias
plasticState(ph)%slipRate => plasticState(ph)%dotState(2:2,:) plasticState(ph)%slipRate => plasticState(ph)%dotState(2:2,:)
plasticState(ph)%state0 = plasticState(ph)%state ! ToDo: this could be done centrally
end associate end associate
!-------------------------------------------------------------------------------------------------- !--------------------------------------------------------------------------------------------------

View File

@ -213,8 +213,6 @@ module function plastic_kinehardening_init() result(myPlasticity)
stt%gamma0 => plasticState(ph)%state (startIndex :endIndex ,:) stt%gamma0 => plasticState(ph)%state (startIndex :endIndex ,:)
dlt%gamma0 => plasticState(ph)%deltaState(startIndex-o:endIndex-o,:) dlt%gamma0 => plasticState(ph)%deltaState(startIndex-o:endIndex-o,:)
plasticState(ph)%state0 = plasticState(ph)%state ! ToDo: this could be done centrally
end associate end associate
!-------------------------------------------------------------------------------------------------- !--------------------------------------------------------------------------------------------------

View File

@ -1767,22 +1767,22 @@ end subroutine kinetics
!> @brief returns copy of current dislocation densities from state !> @brief returns copy of current dislocation densities from state
!> @details raw values is rectified !> @details raw values is rectified
!-------------------------------------------------------------------------------------------------- !--------------------------------------------------------------------------------------------------
pure function getRho(ph,en) pure function getRho(ph,en) result(rho)
integer, intent(in) :: ph, en integer, intent(in) :: ph, en
real(pReal), dimension(param(ph)%sum_N_sl,10) :: getRho real(pReal), dimension(param(ph)%sum_N_sl,10) :: rho
associate(prm => param(ph)) associate(prm => param(ph))
getRho = reshape(state(ph)%rho(:,en),[prm%sum_N_sl,10]) rho = reshape(state(ph)%rho(:,en),[prm%sum_N_sl,10])
! ensure positive densities (not for imm, they have a sign) ! ensure positive densities (not for imm, they have a sign)
getRho(:,mob) = max(getRho(:,mob),0.0_pReal) rho(:,mob) = max(rho(:,mob),0.0_pReal)
getRho(:,dip) = max(getRho(:,dip),0.0_pReal) rho(:,dip) = max(rho(:,dip),0.0_pReal)
where(abs(getRho) < max(prm%rho_min/geom(ph)%V_0(en)**(2.0_pReal/3.0_pReal),prm%rho_significant)) & where(abs(rho) < max(prm%rho_min/geom(ph)%V_0(en)**(2.0_pReal/3.0_pReal),prm%rho_significant)) &
getRho = 0.0_pReal rho = 0.0_pReal
end associate end associate
@ -1793,22 +1793,22 @@ end function getRho
!> @brief returns copy of current dislocation densities from state !> @brief returns copy of current dislocation densities from state
!> @details raw values is rectified !> @details raw values is rectified
!-------------------------------------------------------------------------------------------------- !--------------------------------------------------------------------------------------------------
pure function getRho0(ph,en) pure function getRho0(ph,en) result(rho0)
integer, intent(in) :: ph, en integer, intent(in) :: ph, en
real(pReal), dimension(param(ph)%sum_N_sl,10) :: getRho0 real(pReal), dimension(param(ph)%sum_N_sl,10) :: rho0
associate(prm => param(ph)) associate(prm => param(ph))
getRho0 = reshape(state0(ph)%rho(:,en),[prm%sum_N_sl,10]) rho0 = reshape(state0(ph)%rho(:,en),[prm%sum_N_sl,10])
! ensure positive densities (not for imm, they have a sign) ! ensure positive densities (not for imm, they have a sign)
getRho0(:,mob) = max(getRho0(:,mob),0.0_pReal) rho0(:,mob) = max(rho0(:,mob),0.0_pReal)
getRho0(:,dip) = max(getRho0(:,dip),0.0_pReal) rho0(:,dip) = max(rho0(:,dip),0.0_pReal)
where (abs(getRho0) < max(prm%rho_min/geom(ph)%V_0(en)**(2.0_pReal/3.0_pReal),prm%rho_significant)) & where (abs(rho0) < max(prm%rho_min/geom(ph)%V_0(en)**(2.0_pReal/3.0_pReal),prm%rho_significant)) &
getRho0 = 0.0_pReal rho0 = 0.0_pReal
end associate end associate

View File

@ -265,8 +265,6 @@ module function plastic_phenopowerlaw_init() result(myPlasticity)
plasticState(ph)%atol(startIndex:endIndex) = pl%get_asFloat('atol_gamma',defaultVal=1.0e-6_pReal) plasticState(ph)%atol(startIndex:endIndex) = pl%get_asFloat('atol_gamma',defaultVal=1.0e-6_pReal)
if(any(plasticState(ph)%atol(startIndex:endIndex) < 0.0_pReal)) extmsg = trim(extmsg)//' atol_gamma' if(any(plasticState(ph)%atol(startIndex:endIndex) < 0.0_pReal)) extmsg = trim(extmsg)//' atol_gamma'
plasticState(ph)%state0 = plasticState(ph)%state ! ToDo: this could be done centrally
end associate end associate
!-------------------------------------------------------------------------------------------------- !--------------------------------------------------------------------------------------------------