Re: Turning off math error checking for a code block [message #28871] |
Fri, 18 January 2002 07:47  |
Paul van Delst
Messages: 364 Registered: March 1997
|
Senior Member |
|
|
Kenneth Bowman wrote:
>
> In article <888zawn5bq.fsf@catspaw.jpl.nasa.gov>, Vapuser <vapuser@catspaw.jpl.nasa.gov> wrote:
>
>> The help says that for !except=1 (the default) it only reports the
>> exception upon arriving at back at an interactive prompt. On my SGI, it
>> still does the `where' and returns the correct answer, it just
>> complains.
>
> The problem is that changing !EXCEPT does not reset the accumulated error status, so the errors that occur with !EXCEPT = 0 are still present. Hence the need to call CHECK_MATH (twice).
>
> I want to be able to run my whole code with !EXCEPT = 2 (or 1) but not generate errors for the blocks that I *know* will have floating point exceptions in them.
>
> I think my solution is probably the simplest way to do what I want to do.
Given the (valid) reason the NaN's are in your array (flagging missing values) and that you
want to _not_ accumulate certain well-identified errors, I think you're right.
paulv
--
Paul van Delst Religious and cultural
CIMSS @ NOAA/NCEP purity is a fundamentalist
Ph: (301)763-8000 x7274 fantasy
Fax:(301)763-8545 V.S.Naipaul
|
|
|