User`s guide

4 Using MWArra y Classes
Test x for infin ity:
double x = 1.0 / 0.0;
if (MWNumericArray.isInf(x))
System.out.println("The input value is infinite");
When run, the example displays this output:
The input value is infinite
isNaN. This method tests for NaN (Not a Number) in a machine-independent
manner. This is a static method of the class and does not need to be invoked
in reference to an instance of the class.
The prototype for the
isNaN method is
public static boolean isNaN(double value)
Input Parameters
value
double
value to test for NaN
Example Testing for NaN Array Values
Test x for NaN:
double x = 0.0 / 0.0;
if (MWNumericArray.isNaN(x))
System.out.println("The input value is not a number.");
When run, the example displays this output:
The input value is not a number.
4-74