Floating-Point Intrinsic Functions (Windows CE 5.0)

Send Feedback

Floating-point intrinsic functions can be separated into a group of general-purpose functions and three groups of related transcendental functions.

Except for _isunordered, these functions have always been part of the Microsoft C Run-time Library for Windows CE for Windows CE, and the intrinsic versions perform the same operation as the run-time versions except as noted. For more information, see Run-Time Library Reference.

All floating-point operations should adhere to the IEEE Standard for Binary Floating-Point Arithmetic, or IEEE-754.

The IEEE standard reserves some exponent fields for special values. These special values include zero and the value NaN, Not a Number. NaN represents a value that is not a real number, such as the indeterminate result of dividing a real number by zero.

The floating-point intrinsic functions are available in both double-precision and single-precision versions, and you can implement them as single instructions on some hardware platforms.

The following table shows the general-purpose floating-point intrinsic functions.

Function Description
fabs
fabsf
Calculates the absolute value of a floating-point number.

This function is part of the Microsoft C Run-Time Library for Windows CE, and the intrinsic version performs the same operation as the run-time version.

floor
floorf
Calculates the floor value (greatest integer less than or equal to) of a number.

This function is part of the Microsoft C Run-Time Library for Windows CE, and the intrinsic version performs the same operation as the run-time version.

ceil
ceilf
Calculates the ceiling value (smallest integer greater than or equal to) of a number. Ceil is the result of rounding up.

This function is part of the Microsoft C Run-Time Library for Windows CE, and the intrinsic version performs the same operation as the run-time version.

fmod
fmodf
Calculates the modulus, or floating-point remainder.

This function is part of the Microsoft C Run-Time Library for Windows CE, and the intrinsic version performs the same operation as the run-time version.

sqrt
sqrtf
Calculates the square root of a floating-point number.

This function is part of the Microsoft C Run-Time Library for Windows CE, and the intrinsic version performs the same operation as the run-time version.

_isnan

_isnanf

Returns true when argument is not a number (NaN). Returns false when argument is zero, subnormal, or infinite.

This function is part of the Microsoft C Run-Time Library for Windows CE, and the intrinsic version performs the same operation as the run-time version.

_isunordered

_isunorderedf

_isunordered compares two double precision numbers. _isunorderedf compares two floating point numbers. Returns true when arguments are unordered.

In addition to general-purpose floating-point intrinsic functions, Windows CE provides support for transcendental floating-point functions. These intrinsic functions implement logarithmic, trigonometric, and hyperbolic functions.

Transcendental intrinsic functions take double-precision arguments and return a double-precision result. These functions have always been available as intrinsic on all hardware platforms and are provided for backwards compatibility. In most cases they are implemented by calling the Microsoft C Run-Time Library.

The following table shows the logarithmic functions.

Function Description
exp Calculates the exponential function value of a floating-point number.

This function is part of the Microsoft C Run-Time Library for Windows CE, and the intrinsic version performs the same operation as the run-time version.

loglog10 Calculates the logarithm of a floating-point number.

This function is part of the Microsoft C Run-Time Library for Windows CE, and the intrinsic version performs the same operation as the run-time version.

pow Calculates the value of x raised to the power of y, x^y.

This function is part of the Microsoft C Run-Time Library for Windows CE, and the intrinsic version performs the same operation as the run-time version.

The following table shows the trigonometric functions.

Function Description
cos, cosh Calculates the cosine or hyperbolic cosine of a floating-point number from a radian argument.

This function is part of the Microsoft C Run-Time Library for Windows CE, and the intrinsic version performs the same operation as the run-time version.

sin, sinh Calculates the sine or hyperbolic sine of a floating-point number from a radian argument.

This function is part of the Microsoft C Run-Time Library for Windows CE, and the intrinsic version performs the same operation as the run-time version.

tan, tanh Calculates the tangent or hyperbolic tangent of a floating-point number from a radian argument.

This function is part of the Microsoft C Run-Time Library for Windows CE, and the intrinsic version performs the same operation as the run-time version.

acos Calculates the arccosine of a floating-point number, in radians.

This function is part of the Microsoft C Run-Time Library for Windows CE, and the intrinsic version performs the same operation as the run-time version.

asin Calculates the arcsine of a floating-point number, in radians.
atan, atan2 Calculates the arctangent of a floating-point number, in radians or a rational number.

This function is part of the Microsoft C Run-Time Library for Windows CE, and the intrinsic version performs the same operation as the run-time version.

See Also

Common Intrinsic Functions | Microsoft C Run-time Library for Windows CE

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.