wrong localisation of the error in stpctl
Infinite or NaN values are correctly detected in stpctl with these line
& ISNAN( SUM(zmax(1:jptst)) ) .OR. & ! NaN encounter in the tests
& ABS( SUM(zmax(1:jptst)) ) > HUGE(1._wp) ) THEN ! Infinity encounter in the tests
However their positions is determined with maxloc
/minloc
or mpp_maxloc
/mpp_minloc
with does not apply to Infinite or NaN values...
The following lines are also not working for Infinite or NaN values...
! find which subdomain has the max.
iareamin(:) = jpnij+1 ; iareamax(:) = 0 ; iareasum(:) = 0
DO ji = 1, jptst
IF( zmaxlocal(ji) == zmax(ji) ) THEN
iareamin(ji) = narea ; iareamax(ji) = narea ; iareasum(ji) = 1
ENDIF
END DO