NaN is een afkorting voor Not a Number . Het is de uitkomst van onmogelijke floating point-berekening op een computer. Denk aan een Division by Zero, of, in de niet-complexe wiskunde, aan de wortel uit een negatief getal.
In Matlab: http://www.mathworks.com/access/helpdesk/help/techdoc/ref/nan.html
In JavaScript & Actionscript :
In ECMAScript, NaN is classified as a primitive value.
It is used to signify that a value is not a legal number.
Note that the primitive value, Infinity, is used to signify that a number, 1.5x10^321 for example, has exceeded the defined range of legal values for a floating point number in JavaScript. You can use the isNan() function to test a value to see if it is NaN.
In C++:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vclang/html/vclrfnotnumbernanitems.asp
Type man isnan:
#include <math.h>
int isnan (double dsrc);
int isnanl (long double dsrc);
#include <ieeefp.h> // Wanneer je IEEE floats gebruikt...
int isnand (double dsrc);
int isnanf (float fsrc);
int finite (double dsrc);
fpclass_t fpclass (double dsrc);
int unordered (double dsrc1, double dsrc2);
fpclass_t fpclassl (long double dsrc);
int finitel (long double dsrc);
int unorderedl (long double dsrc1, long double dsrc2);