1.\" Copyright (c) 1991 The Regents of the University of California. 2.\" All rights reserved. 3.\" 4.\" This code is derived from software contributed to Berkeley by 5.\" the American National Standards Committee X3, on Information 6.\" Processing Systems. 7.\" 8.\" %sccs.include.redist.man% 9.\" 10.\" @(#)ldexp.3 5.2 (Berkeley) 06/29/91 11.\" 12.Dd 13.Dt LDEXP 3 14.Os 15.Sh NAME 16.Nm ldexp 17.Nd mutliply floating-point number by integral power of 2 18.Sh SYNOPSIS 19.Fd #include <math.h> 20.Ft double 21.Fn ldexp "double x" "int exp" 22.Sh DESCRIPTION 23The 24.Fn ldexp 25function multiplies a floating-point number by an integral 26power of 2. 27.Sh RETURN VALUES 28The 29.Fn ldexp 30function returns the value of 31.Fa x 32times 2 raised to the power 33.Fa exp . 34.Pp 35If the resultant value would cause an overflow, 36the global variable 37.Va errno 38is set to 39.Er ERANGE 40and the value 41.Dv HUGE 42is returned. 43.Sh SEE ALSO 44.Xr frexp 3 , 45.Xr modf 3 , 46.Xr math 3 47.Sh STANDARDS 48The 49.Fn ldexp 50function conforms 51.St -ansiC . 52