cos

copysign

#include <math.h>float copysignf(float val, float signval);double copysign(double val, double signval); long double copysignl(long double val, long double                       signval);

copysign( ), copysignf( ), and copysignl( ) were added by C99.

The copysign( ) family of functions gives val the same sign as the value passed in signval and returns the result. Thus, the value returned has a magnitude equal to val, but with the same sign as that of signval.

A related function is fabs( ).




C(s)C++ Programmer's Reference
C Programming on the IBM PC (C Programmers Reference Guide Series)
ISBN: 0673462897
EAN: 2147483647
Year: 2002
Pages: 539

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net