fmax(), fmaxf(), fmin(), fminf()

floating-point maximum and minimum functions 

Function


SYNOPSIS

#include <math.h>

float fmaxf(float x, float y)

double fmax(double x, double y)

float fminf(float x, float y)

double fmin(double x, double y)


DESCRIPTION

The fmax(), fmaxf() functions return the larger of x and y, and likewise, the fmin() and fminf() functions return the smaller of x and y. They treat +0.0 as being larger than -0.0. If one argument is an NaN, then the other argument is returned. If both arguments are NaNs, then the result is an NaN. These routines do not raise any floating-point exceptions.


CONFORMANCE

fmin() and fmax() class of functions conform to ANSI/ISO 9899:1999 'ISO C99'.


MULTITHREAD SAFETY LEVEL

MT-Safe.


PORTING ISSUES

None.


AVAILABILITY

PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Professional Developers 64-Bit Edition
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition


SEE ALSO

Functions:
fabs(), fdim(), isnan(), math()


PTC MKS Toolkit 10.4 Documentation Build 39.