nan(3) Library Functions Manual nan(3) nan, nanf, nanl - ' ' (libm -lm) #include double nan(const char *tagp); float nanf(const char *tagp); long double nanl(const char *tagp); glibc ( feature_test_macros(7)): nan(), nanf(), nanl(): _ISOC99_SOURCE || _POSIX_C_SOURCE >= 200112L ( tagp) NaN . NaNs . nan("char-sequence") : strtod("NAN(char-sequence)", NULL); nanf() nanl() strtof(3) strtold(3). tagp . IEEE 754 NaN tagp . . attributes(7). +----------------------+------------------------------------+---------------------------------------------------------------------------------------------+ | | | | +----------------------+------------------------------------+---------------------------------------------------------------------------------------------+ |nan(), nanf(), nanl() | | (locale) (MT-Safe) | +----------------------+------------------------------------+---------------------------------------------------------------------------------------------+ C11, POSIX.1-2008. IEC 559 IEEE 754/IEEE 854. glibc 2.1. C99 POSIX.1-2001. isnan(3), strtod(3), math_error(7) 3 . . : . 6.18 8 2026 nan(3)