avoid division (mod) by zero
This commit is contained in:
parent
1d2a7d0917
commit
a88baf93b2
|
@ -217,8 +217,7 @@ program DAMASK_spectral
|
|||
case('freq','frequency','outputfreq') ! frequency of result writings
|
||||
newLoadCase%outputfrequency = IO_intValue(line,chunkPos,i+1)
|
||||
case('r','restart','restartwrite') ! frequency of writing restart information
|
||||
newLoadCase%restartfrequency = &
|
||||
max(0,IO_intValue(line,chunkPos,i+1))
|
||||
newLoadCase%restartfrequency = IO_intValue(line,chunkPos,i+1)
|
||||
case('guessreset','dropguessing')
|
||||
newLoadCase%followFormerTrajectory = .false. ! do not continue to predict deformation along former trajectory
|
||||
case('euler') ! rotation of load case given in euler angles
|
||||
|
@ -561,8 +560,7 @@ program DAMASK_spectral
|
|||
fileOffset = fileOffset + sum(outputSize) ! forward to current file position
|
||||
call CPFEM_results(totalIncsCounter,time)
|
||||
endif
|
||||
if ( loadCases(currentLoadCase)%restartFrequency > 0 & ! writing of restart info requested ...
|
||||
.and. mod(inc,loadCases(currentLoadCase)%restartFrequency) == 0) then ! ... and at frequency of writing restart information
|
||||
if (mod(inc,loadCases(currentLoadCase)%restartFrequency) == 0) then ! at frequency of writing restart information
|
||||
restartWrite = .true. ! set restart parameter for FEsolving
|
||||
lastRestartWritten = inc ! QUESTION: first call to CPFEM_general will write?
|
||||
endif
|
||||
|
|
|
@ -98,7 +98,7 @@ module spectral_utilities
|
|||
real(pReal) :: time = 0.0_pReal !< length of increment
|
||||
integer :: incs = 0, & !< number of increments
|
||||
outputfrequency = 1, & !< frequency of result writes
|
||||
restartfrequency = 0, & !< frequency of restart writes
|
||||
restartfrequency = huge(0), & !< frequency of restart writes
|
||||
logscale = 0 !< linear/logarithmic time inc flag
|
||||
logical :: followFormerTrajectory = .true. !< follow trajectory of former loadcase
|
||||
integer(kind(FIELD_UNDEFINED_ID)), allocatable :: ID(:)
|
||||
|
|
Loading…
Reference in New Issue