reverted handling of NaN in converged reason, seems to be a compiler bug
This commit is contained in:
parent
dc990a88d6
commit
88999c847a
|
@ -253,6 +253,8 @@ end subroutine AL_init
|
|||
!--------------------------------------------------------------------------------------------------
|
||||
type(tSolutionState) function &
|
||||
AL_solution(incInfoIn,guess,timeinc,timeinc_old,loadCaseTime,P_BC,F_BC,rotation_BC)
|
||||
use IO, only: &
|
||||
IO_error
|
||||
use numerics, only: &
|
||||
update_gamma
|
||||
use math, only: &
|
||||
|
@ -317,9 +319,8 @@ type(tSolutionState) function &
|
|||
CHKERRQ(ierr)
|
||||
AL_solution%termIll = terminallyIll
|
||||
terminallyIll = .false.
|
||||
AL_solution%converged = .true.
|
||||
|
||||
if (reason < 1 .and. reason /= -4) AL_solution%converged = .false. ! reason -4 (SNES_DIVERGED_FNORM_NAN) happens in case of homogeneous solution
|
||||
if (reason == -4) call IO_error(893_pInt)
|
||||
if (reason < 1) AL_solution%converged = .false.
|
||||
AL_solution%iterationsNeeded = totalIter
|
||||
|
||||
end function AL_solution
|
||||
|
|
|
@ -224,11 +224,12 @@ end subroutine basicPETSc_init
|
|||
!--------------------------------------------------------------------------------------------------
|
||||
!> @brief solution for the Basic PETSC scheme with internal iterations
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
type(tSolutionState) function basicPETSc_solution( &
|
||||
incInfoIn,guess,timeinc,timeinc_old,loadCaseTime,P_BC,F_BC,rotation_BC)
|
||||
type(tSolutionState) function &
|
||||
basicPETSc_solution(incInfoIn,guess,timeinc,timeinc_old,loadCaseTime,P_BC,F_BC,rotation_BC)
|
||||
use IO, only: &
|
||||
IO_error
|
||||
use numerics, only: &
|
||||
update_gamma, &
|
||||
itmax
|
||||
update_gamma
|
||||
use DAMASK_spectral_Utilities, only: &
|
||||
tBoundaryCondition, &
|
||||
Utilities_maskedCompliance, &
|
||||
|
@ -286,8 +287,8 @@ type(tSolutionState) function basicPETSc_solution( &
|
|||
basicPETSc_solution%termIll = terminallyIll
|
||||
terminallyIll = .false.
|
||||
BasicPETSc_solution%converged =.true.
|
||||
|
||||
if (reason < 1 .and. reason /= -4) basicPETSC_solution%converged = .false. ! reason -4 (SNES_DIVERGED_FNORM_NAN) happens in case of homogeneous solution
|
||||
if (reason == -4) call IO_error(893_pInt)
|
||||
if (reason < 1) basicPETSC_solution%converged = .false.
|
||||
basicPETSC_solution%iterationsNeeded = totalIter
|
||||
|
||||
end function BasicPETSc_solution
|
||||
|
@ -372,7 +373,7 @@ subroutine BasicPETSC_formResidual(in,x_scal,f_scal,dummy,ierr)
|
|||
F_aim_lastIter = F_aim
|
||||
F_aim = F_aim - math_mul3333xx33(S, ((P_av - params%P_BC))) ! S = 0.0 for no bc
|
||||
err_stress = maxval(abs(mask_stress * (P_av - params%P_BC))) ! mask = 0.0 for no bc
|
||||
|
||||
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
! updated deformation gradient using fix point algorithm of basic scheme
|
||||
tensorField_real = 0.0_pReal
|
||||
|
|
|
@ -252,6 +252,8 @@ end subroutine Polarisation_init
|
|||
!--------------------------------------------------------------------------------------------------
|
||||
type(tSolutionState) function &
|
||||
Polarisation_solution(incInfoIn,guess,timeinc,timeinc_old,loadCaseTime,P_BC,F_BC,rotation_BC)
|
||||
use IO, only: &
|
||||
IO_error
|
||||
use numerics, only: &
|
||||
update_gamma
|
||||
use math, only: &
|
||||
|
@ -316,9 +318,8 @@ type(tSolutionState) function &
|
|||
CHKERRQ(ierr)
|
||||
Polarisation_solution%termIll = terminallyIll
|
||||
terminallyIll = .false.
|
||||
Polarisation_solution%converged = .true.
|
||||
|
||||
if (reason < 1 .and. reason /= -4) Polarisation_solution%converged = .false. ! reason -4 (SNES_DIVERGED_FNORM_NAN) happens in case of homogeneous solution
|
||||
if (reason == -4) call IO_error(893_pInt)
|
||||
if (reason < 1) Polarisation_solution%converged = .false.
|
||||
Polarisation_solution%iterationsNeeded = totalIter
|
||||
|
||||
end function Polarisation_solution
|
||||
|
|
|
@ -766,6 +766,8 @@ end function utilities_curlRMS
|
|||
!> @brief calculates mask compliance tensor used to adjust F to fullfill stress BC
|
||||
!--------------------------------------------------------------------------------------------------
|
||||
function utilities_maskedCompliance(rot_BC,mask_stress,C)
|
||||
use prec, only: &
|
||||
prec_isNaN
|
||||
use IO, only: &
|
||||
IO_error
|
||||
use numerics, only: &
|
||||
|
@ -799,7 +801,6 @@ function utilities_maskedCompliance(rot_BC,mask_stress,C)
|
|||
allocate (c_reduced(size_reduced,size_reduced), source =0.0_pReal)
|
||||
allocate (s_reduced(size_reduced,size_reduced), source =0.0_pReal)
|
||||
allocate (sTimesC(size_reduced,size_reduced), source =0.0_pReal)
|
||||
|
||||
temp99_Real = math_Plain3333to99(math_rotate_forward3333(C,rot_BC))
|
||||
|
||||
if(debugGeneral .and. worldrank == 0_pInt) then
|
||||
|
@ -820,6 +821,7 @@ function utilities_maskedCompliance(rot_BC,mask_stress,C)
|
|||
endif; enddo; endif; enddo
|
||||
|
||||
call math_invert(size_reduced, c_reduced, s_reduced, errmatinv) ! invert reduced stiffness
|
||||
if (any(prec_isNaN(s_reduced))) errmatinv = .true.
|
||||
if(errmatinv) call IO_error(error_ID=400_pInt,ext_msg='utilities_maskedCompliance')
|
||||
temp99_Real = 0.0_pReal ! fill up compliance with zeros
|
||||
k = 0_pInt
|
||||
|
|
|
@ -1605,6 +1605,8 @@ subroutine IO_error(error_ID,el,ip,g,ext_msg)
|
|||
msg = 'Polar decomposition error'
|
||||
case (409_pInt)
|
||||
msg = 'math_check: R*v == q*v failed'
|
||||
case (410_pInt)
|
||||
msg = 'eigenvalues computation error'
|
||||
case (450_pInt)
|
||||
msg = 'unknown symmetry type specified'
|
||||
|
||||
|
@ -1669,6 +1671,8 @@ subroutine IO_error(error_ID,el,ip,g,ext_msg)
|
|||
msg = 'unknown solver type selected'
|
||||
case (892_pInt)
|
||||
msg = 'unknown filter type selected'
|
||||
case (893_pInt)
|
||||
msg = 'PETSc: SNES_DIVERGED_FNORM_NAN'
|
||||
|
||||
!-------------------------------------------------------------------------------------------------
|
||||
! error messages related to parsing of Abaqus input file
|
||||
|
|
Loading…
Reference in New Issue