home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / lang / fortran / 3055 < prev    next >
Encoding:
Internet Message Format  |  1992-08-16  |  771 b 

  1. Path: sparky!uunet!wupost!waikato.ac.nz!aukuni.ac.nz!ecmtwhk
  2. Newsgroups: comp.lang.fortran
  3. Subject: Re: how to quit on an NaN result?
  4. Message-ID: <1992Aug16.221125.19419@ccu1.aukuni.ac.nz>
  5. From: ecmtwhk@ccu1.aukuni.ac.nz (Thomas Koenig)
  6. Date: Sun, 16 Aug 1992 22:11:25 GMT
  7. References: <1992Aug16.200837.14024@samba.oit.unc.edu>
  8. Organization: University of Auckland, New Zealand.
  9. Lines: 13
  10.  
  11. Bruce.Scott@bbs.oit.unc.edu (Bruce Scott) writes:
  12.  
  13. >How can I check forNaN's and quit when one arises.
  14.  
  15. NaN's are supposed to fail every test, so
  16.  
  17.       IF ((.NOT.AVAR.GE.0.) .AND. (.NOT.AVAR.LT.0.)) STOP
  18.  
  19. should do the trick.
  20. -- 
  21. Thomas Koenig, ecmtwhk@ccu1.aukuni.ac.nz, ib09@rz.uni-karlsruhe.de
  22. The joy of engineering is to find a straight line on a double logarithmic
  23. diagram.
  24.