Opened 5 years ago

Closed 5 years ago

Last modified 4 years ago

#1624 closed Enhancement (fixed)

Detecting NaN values in NEMO

Reported by: joakim Owned by: nemo
Priority: low Milestone:
Component: OCE Version: release-3.6
Severity: Keywords:
Cc: Review:
MP ready?:


NEMO checks for unrealistically high velocities and negative surface salinities each time step.
However, it does not check for Na Ns?, which may occur under some circumstances.
Line 114 in stpctl.F90 could be replaced by

IF( tmask(ji,jj,1) == 1) THEN     
   zsmin = MIN(zsmin,tsn(ji,jj,1,jp_sal))
   IF ( isnan(tsn(ji,jj,1,jp_sal)) ) THEN  
      WRITE(numout,*) ' SSS is NaN '
      tsn(ji,jj,1,jp_sal) = -999. 
      zsmin = -999. 
   END IF 

This would make NEMO point to the problematic point and dump the output.abort files.
However, the "isnan" function seems to be specific to Intel compilers. "ieee_is_nan" is a similar function that is supported by most compilers.
Do we wish to put this functionality into NEMO?


Commit History (0)

(No commits)

Change History (3)

comment:1 Changed 5 years ago by cbricaud

  • Resolution set to fixed
  • Status changed from new to closed

there are some options in compilers which can do the same.It is not necessary to put it in the code.

comment:2 Changed 4 years ago by nicolasmartin

  • Keywords NaN removed

comment:3 Changed 4 years ago by nicolasmartin

  • Keywords stpctl removed
Note: See TracTickets for help on using tickets.