no need for 2 variables
This commit is contained in:
parent
0679fa1713
commit
2429eee079
|
@ -58,7 +58,7 @@ contains
|
||||||
!--------------------------------------------------------------------------------------------------
|
!--------------------------------------------------------------------------------------------------
|
||||||
subroutine source_damage_anisoBrittle_init
|
subroutine source_damage_anisoBrittle_init
|
||||||
|
|
||||||
integer :: Ninstance,source,sourceOffset,NofMyPhase,p
|
integer :: Ninstance,sourceOffset,NofMyPhase,p
|
||||||
character(len=pStringLen) :: &
|
character(len=pStringLen) :: &
|
||||||
extmsg = ''
|
extmsg = ''
|
||||||
|
|
||||||
|
@ -74,9 +74,9 @@ subroutine source_damage_anisoBrittle_init
|
||||||
|
|
||||||
do p = 1, size(config_phase)
|
do p = 1, size(config_phase)
|
||||||
source_damage_anisoBrittle_instance(p) = count(phase_source(:,1:p) == SOURCE_DAMAGE_ANISOBRITTLE_ID)
|
source_damage_anisoBrittle_instance(p) = count(phase_source(:,1:p) == SOURCE_DAMAGE_ANISOBRITTLE_ID)
|
||||||
do source = 1, phase_Nsources(p)
|
do sourceOffset = 1, phase_Nsources(p)
|
||||||
if (phase_source(source,p) == SOURCE_DAMAGE_ANISOBRITTLE_ID) &
|
if (phase_source(sourceOffset,p) == SOURCE_DAMAGE_ANISOBRITTLE_ID) &
|
||||||
source_damage_anisoBrittle_offset(p) = source
|
source_damage_anisoBrittle_offset(p) = sourceOffset
|
||||||
enddo
|
enddo
|
||||||
|
|
||||||
if (all(phase_source(:,p) /= SOURCE_DAMAGE_ANISOBRITTLE_ID)) cycle
|
if (all(phase_source(:,p) /= SOURCE_DAMAGE_ANISOBRITTLE_ID)) cycle
|
||||||
|
@ -116,8 +116,6 @@ subroutine source_damage_anisoBrittle_init
|
||||||
prm%output = config%getStrings('(output)',defaultVal=emptyStringArray)
|
prm%output = config%getStrings('(output)',defaultVal=emptyStringArray)
|
||||||
|
|
||||||
NofMyPhase = count(material_phaseAt==p) * discretization_nIP
|
NofMyPhase = count(material_phaseAt==p) * discretization_nIP
|
||||||
sourceOffset = source_damage_anisoBrittle_offset(p)
|
|
||||||
|
|
||||||
call material_allocateSourceState(p,sourceOffset,NofMyPhase,1,1,0)
|
call material_allocateSourceState(p,sourceOffset,NofMyPhase,1,1,0)
|
||||||
sourceState(p)%p(sourceOffset)%aTolState=prm%aTol
|
sourceState(p)%p(sourceOffset)%aTolState=prm%aTol
|
||||||
|
|
||||||
|
|
|
@ -53,7 +53,7 @@ contains
|
||||||
!--------------------------------------------------------------------------------------------------
|
!--------------------------------------------------------------------------------------------------
|
||||||
subroutine source_damage_anisoDuctile_init
|
subroutine source_damage_anisoDuctile_init
|
||||||
|
|
||||||
integer :: Ninstance,source,sourceOffset,NofMyPhase,p
|
integer :: Ninstance,sourceOffset,NofMyPhase,p
|
||||||
character(len=pStringLen) :: &
|
character(len=pStringLen) :: &
|
||||||
extmsg = ''
|
extmsg = ''
|
||||||
|
|
||||||
|
@ -69,9 +69,9 @@ subroutine source_damage_anisoDuctile_init
|
||||||
|
|
||||||
do p = 1, size(config_phase)
|
do p = 1, size(config_phase)
|
||||||
source_damage_anisoDuctile_instance(p) = count(phase_source(:,1:p) == SOURCE_DAMAGE_ANISODUCTILE_ID)
|
source_damage_anisoDuctile_instance(p) = count(phase_source(:,1:p) == SOURCE_DAMAGE_ANISODUCTILE_ID)
|
||||||
do source = 1, phase_Nsources(p)
|
do sourceOffset = 1, phase_Nsources(p)
|
||||||
if (phase_source(source,p) == SOURCE_DAMAGE_ANISODUCTILE_ID) &
|
if (phase_source(sourceOffset,p) == SOURCE_DAMAGE_ANISODUCTILE_ID) &
|
||||||
source_damage_anisoDuctile_offset(p) = source
|
source_damage_anisoDuctile_offset(p) = sourceOffset
|
||||||
enddo
|
enddo
|
||||||
|
|
||||||
if (all(phase_source(:,p) /= SOURCE_DAMAGE_ANISODUCTILE_ID)) cycle
|
if (all(phase_source(:,p) /= SOURCE_DAMAGE_ANISODUCTILE_ID)) cycle
|
||||||
|
@ -103,8 +103,6 @@ subroutine source_damage_anisoDuctile_init
|
||||||
prm%output = config%getStrings('(output)',defaultVal=emptyStringArray)
|
prm%output = config%getStrings('(output)',defaultVal=emptyStringArray)
|
||||||
|
|
||||||
NofMyPhase=count(material_phaseAt==p) * discretization_nIP
|
NofMyPhase=count(material_phaseAt==p) * discretization_nIP
|
||||||
sourceOffset = source_damage_anisoDuctile_offset(p)
|
|
||||||
|
|
||||||
call material_allocateSourceState(p,sourceOffset,NofMyPhase,1,1,0)
|
call material_allocateSourceState(p,sourceOffset,NofMyPhase,1,1,0)
|
||||||
sourceState(p)%p(sourceOffset)%aTolState=prm%aTol
|
sourceState(p)%p(sourceOffset)%aTolState=prm%aTol
|
||||||
|
|
||||||
|
|
|
@ -48,7 +48,7 @@ contains
|
||||||
!--------------------------------------------------------------------------------------------------
|
!--------------------------------------------------------------------------------------------------
|
||||||
subroutine source_damage_isoBrittle_init
|
subroutine source_damage_isoBrittle_init
|
||||||
|
|
||||||
integer :: Ninstance,source,sourceOffset,NofMyPhase,p
|
integer :: Ninstance,sourceOffset,NofMyPhase,p
|
||||||
character(len=pStringLen) :: &
|
character(len=pStringLen) :: &
|
||||||
extmsg = ''
|
extmsg = ''
|
||||||
|
|
||||||
|
@ -64,9 +64,9 @@ subroutine source_damage_isoBrittle_init
|
||||||
|
|
||||||
do p = 1, size(config_phase)
|
do p = 1, size(config_phase)
|
||||||
source_damage_isoBrittle_instance(p) = count(phase_source(:,1:p) == SOURCE_DAMAGE_ISOBRITTLE_ID)
|
source_damage_isoBrittle_instance(p) = count(phase_source(:,1:p) == SOURCE_DAMAGE_ISOBRITTLE_ID)
|
||||||
do source = 1, phase_Nsources(p)
|
do sourceOffset = 1, phase_Nsources(p)
|
||||||
if (phase_source(source,p) == SOURCE_DAMAGE_ISOBRITTLE_ID) &
|
if (phase_source(sourceOffset,p) == SOURCE_DAMAGE_ISOBRITTLE_ID) &
|
||||||
source_damage_isoBrittle_offset(p) = source
|
source_damage_isoBrittle_offset(p) = sourceOffset
|
||||||
enddo
|
enddo
|
||||||
|
|
||||||
if (all(phase_source(:,p) /= SOURCE_DAMAGE_ISOBRITTLE_ID)) cycle
|
if (all(phase_source(:,p) /= SOURCE_DAMAGE_ISOBRITTLE_ID)) cycle
|
||||||
|
@ -92,8 +92,6 @@ subroutine source_damage_isoBrittle_init
|
||||||
prm%output = config%getStrings('(output)',defaultVal=emptyStringArray)
|
prm%output = config%getStrings('(output)',defaultVal=emptyStringArray)
|
||||||
|
|
||||||
NofMyPhase = count(material_phaseAt==p) * discretization_nIP
|
NofMyPhase = count(material_phaseAt==p) * discretization_nIP
|
||||||
sourceOffset = source_damage_isoBrittle_offset(p)
|
|
||||||
|
|
||||||
call material_allocateSourceState(p,sourceOffset,NofMyPhase,1,1,1)
|
call material_allocateSourceState(p,sourceOffset,NofMyPhase,1,1,1)
|
||||||
sourceState(p)%p(sourceOffset)%aTolState=prm%aTol
|
sourceState(p)%p(sourceOffset)%aTolState=prm%aTol
|
||||||
|
|
||||||
|
|
|
@ -47,7 +47,7 @@ contains
|
||||||
!--------------------------------------------------------------------------------------------------
|
!--------------------------------------------------------------------------------------------------
|
||||||
subroutine source_damage_isoDuctile_init
|
subroutine source_damage_isoDuctile_init
|
||||||
|
|
||||||
integer :: Ninstance,source,sourceOffset,NofMyPhase,p
|
integer :: Ninstance,sourceOffset,NofMyPhase,p
|
||||||
character(len=pStringLen) :: &
|
character(len=pStringLen) :: &
|
||||||
extmsg = ''
|
extmsg = ''
|
||||||
|
|
||||||
|
@ -63,9 +63,9 @@ subroutine source_damage_isoDuctile_init
|
||||||
|
|
||||||
do p = 1, size(config_phase)
|
do p = 1, size(config_phase)
|
||||||
source_damage_isoDuctile_instance(p) = count(phase_source(:,1:p) == SOURCE_DAMAGE_ISODUCTILE_ID)
|
source_damage_isoDuctile_instance(p) = count(phase_source(:,1:p) == SOURCE_DAMAGE_ISODUCTILE_ID)
|
||||||
do source = 1, phase_Nsources(p)
|
do sourceOffset = 1, phase_Nsources(p)
|
||||||
if (phase_source(source,p) == SOURCE_DAMAGE_ISODUCTILE_ID) &
|
if (phase_source(sourceOffset,p) == SOURCE_DAMAGE_ISODUCTILE_ID) &
|
||||||
source_damage_isoDuctile_offset(p) = source
|
source_damage_isoDuctile_offset(p) = sourceOffset
|
||||||
enddo
|
enddo
|
||||||
|
|
||||||
if (all(phase_source(:,p) /= SOURCE_DAMAGE_ISODUCTILE_ID)) cycle
|
if (all(phase_source(:,p) /= SOURCE_DAMAGE_ISODUCTILE_ID)) cycle
|
||||||
|
@ -91,8 +91,6 @@ subroutine source_damage_isoDuctile_init
|
||||||
prm%output = config%getStrings('(output)',defaultVal=emptyStringArray)
|
prm%output = config%getStrings('(output)',defaultVal=emptyStringArray)
|
||||||
|
|
||||||
NofMyPhase=count(material_phaseAt==p) * discretization_nIP
|
NofMyPhase=count(material_phaseAt==p) * discretization_nIP
|
||||||
sourceOffset = source_damage_isoDuctile_offset(p)
|
|
||||||
|
|
||||||
call material_allocateSourceState(p,sourceOffset,NofMyPhase,1,1,0)
|
call material_allocateSourceState(p,sourceOffset,NofMyPhase,1,1,0)
|
||||||
sourceState(p)%p(sourceOffset)%aTolState=prm%aTol
|
sourceState(p)%p(sourceOffset)%aTolState=prm%aTol
|
||||||
|
|
||||||
|
|
|
@ -39,7 +39,7 @@ contains
|
||||||
!--------------------------------------------------------------------------------------------------
|
!--------------------------------------------------------------------------------------------------
|
||||||
subroutine source_thermal_dissipation_init
|
subroutine source_thermal_dissipation_init
|
||||||
|
|
||||||
integer :: Ninstance,source,sourceOffset,NofMyPhase,p
|
integer :: Ninstance,sourceOffset,NofMyPhase,p
|
||||||
|
|
||||||
write(6,'(/,a)') ' <<<+- source_'//SOURCE_thermal_dissipation_label//' init -+>>>'; flush(6)
|
write(6,'(/,a)') ' <<<+- source_'//SOURCE_thermal_dissipation_label//' init -+>>>'; flush(6)
|
||||||
|
|
||||||
|
@ -53,9 +53,9 @@ subroutine source_thermal_dissipation_init
|
||||||
|
|
||||||
do p = 1, size(config_phase)
|
do p = 1, size(config_phase)
|
||||||
source_thermal_dissipation_instance(p) = count(phase_source(:,1:p) == SOURCE_THERMAL_DISSIPATION_ID)
|
source_thermal_dissipation_instance(p) = count(phase_source(:,1:p) == SOURCE_THERMAL_DISSIPATION_ID)
|
||||||
do source = 1, phase_Nsources(p)
|
do sourceOffset = 1, phase_Nsources(p)
|
||||||
if (phase_source(source,p) == SOURCE_THERMAL_DISSIPATION_ID) &
|
if (phase_source(sourceOffset,p) == SOURCE_THERMAL_DISSIPATION_ID) &
|
||||||
source_thermal_dissipation_offset(p) = source
|
source_thermal_dissipation_offset(p) = sourceOffset
|
||||||
enddo
|
enddo
|
||||||
|
|
||||||
if (all(phase_source(:,p) /= SOURCE_THERMAL_DISSIPATION_ID)) cycle
|
if (all(phase_source(:,p) /= SOURCE_THERMAL_DISSIPATION_ID)) cycle
|
||||||
|
@ -65,8 +65,6 @@ subroutine source_thermal_dissipation_init
|
||||||
prm%kappa = config%getFloat('dissipation_coldworkcoeff')
|
prm%kappa = config%getFloat('dissipation_coldworkcoeff')
|
||||||
|
|
||||||
NofMyPhase = count(material_phaseAt==p) * discretization_nIP
|
NofMyPhase = count(material_phaseAt==p) * discretization_nIP
|
||||||
sourceOffset = source_thermal_dissipation_offset(p)
|
|
||||||
|
|
||||||
call material_allocateSourceState(p,sourceOffset,NofMyPhase,0,0,0)
|
call material_allocateSourceState(p,sourceOffset,NofMyPhase,0,0,0)
|
||||||
|
|
||||||
end associate
|
end associate
|
||||||
|
|
|
@ -43,7 +43,7 @@ contains
|
||||||
!--------------------------------------------------------------------------------------------------
|
!--------------------------------------------------------------------------------------------------
|
||||||
subroutine source_thermal_externalheat_init
|
subroutine source_thermal_externalheat_init
|
||||||
|
|
||||||
integer :: Ninstance,source,sourceOffset,NofMyPhase,p
|
integer :: Ninstance,sourceOffset,NofMyPhase,p
|
||||||
|
|
||||||
write(6,'(/,a)') ' <<<+- source_'//SOURCE_thermal_externalheat_label//' init -+>>>'; flush(6)
|
write(6,'(/,a)') ' <<<+- source_'//SOURCE_thermal_externalheat_label//' init -+>>>'; flush(6)
|
||||||
|
|
||||||
|
@ -57,9 +57,9 @@ subroutine source_thermal_externalheat_init
|
||||||
|
|
||||||
do p = 1, size(config_phase)
|
do p = 1, size(config_phase)
|
||||||
source_thermal_externalheat_instance(p) = count(phase_source(:,1:p) == SOURCE_thermal_externalheat_ID)
|
source_thermal_externalheat_instance(p) = count(phase_source(:,1:p) == SOURCE_thermal_externalheat_ID)
|
||||||
do source = 1, phase_Nsources(p)
|
do sourceOffset = 1, phase_Nsources(p)
|
||||||
if (phase_source(source,p) == SOURCE_thermal_externalheat_ID) &
|
if (phase_source(sourceOffset,p) == SOURCE_thermal_externalheat_ID) &
|
||||||
source_thermal_externalheat_offset(p) = source
|
source_thermal_externalheat_offset(p) = sourceOffset
|
||||||
enddo
|
enddo
|
||||||
|
|
||||||
if (all(phase_source(:,p) /= SOURCE_thermal_externalheat_ID)) cycle
|
if (all(phase_source(:,p) /= SOURCE_thermal_externalheat_ID)) cycle
|
||||||
|
@ -72,8 +72,6 @@ subroutine source_thermal_externalheat_init
|
||||||
prm%heat_rate = config%getFloats('externalheat_rate',requiredSize = size(prm%time))
|
prm%heat_rate = config%getFloats('externalheat_rate',requiredSize = size(prm%time))
|
||||||
|
|
||||||
NofMyPhase = count(material_phaseAt==p) * discretization_nIP
|
NofMyPhase = count(material_phaseAt==p) * discretization_nIP
|
||||||
sourceOffset = source_thermal_externalheat_offset(p)
|
|
||||||
|
|
||||||
call material_allocateSourceState(p,sourceOffset,NofMyPhase,1,1,0)
|
call material_allocateSourceState(p,sourceOffset,NofMyPhase,1,1,0)
|
||||||
|
|
||||||
end associate
|
end associate
|
||||||
|
|
Loading…
Reference in New Issue