1*61111Sbostic.\" Copyright (c) 1991, 1993 2*61111Sbostic.\" The Regents of the University of California. All rights reserved. 320316Smckusick.\" 450301Sbostic.\" This code is derived from software contributed to Berkeley by 550301Sbostic.\" the American National Standards Committee X3, on Information 650301Sbostic.\" Processing Systems. 750301Sbostic.\" 848352Scael.\" %sccs.include.redist.man% 948352Scael.\" 10*61111Sbostic.\" @(#)frexp.3 8.1 (Berkeley) 06/04/93 1148352Scael.\" 1248352Scael.Dd 1348352Scael.Dt FREXP 3 1448352Scael.Os 1548352Scael.Sh NAME 1648352Scael.Nm frexp 1748352Scael.Nd convert floating-point number to fractional and integral components 1848352Scael.Sh SYNOPSIS 1948352Scael.Fd #include <math.h> 2048352Scael.Ft double 2148352Scael.Fn frexp "double value" "int *exp" 2248352Scael.Sh DESCRIPTION 2348352ScaelThe 2448352Scael.Fn frexp 2548352Scaelfunction breaks a floating-point number into a normalized 2648352Scaelfraction and an integral power of 2. 2748352ScaelIt stores the integer in the 2848352Scael.Em int 2948352Scaelobject pointed to by 3048352Scael.Fa exp . 3148352Scael.Sh RETURN VALUES 3248352ScaelThe 3348352Scael.Fn frexp 3448352Scaelfunction returns the value 3548352Scael.Em x , 3648352Scaelsuch that 3748352Scael.Em x 3848352Scaelis a 3948352Scael.Em double 4048352Scaelwith magnitude in the interval 4148352Scael.Bq 1/2 , 1 4248352Scaelor zero, and 4348352Scael.Fa value 4448352Scaelequals 4548352Scael.Em x 4648352Scaeltimes 2 raised to the power 4748352Scael.Fa *exp . 4848352ScaelIf 4948352Scael.Fa value 5048352Scaelis zero, both parts of the result are zero. 5148352Scael.Sh SEE ALSO 5248352Scael.Xr ldexp 3 , 5348352Scael.Xr modf 3 , 5448352Scael.Xr math 3 5548352Scael.Sh STANDARDS 5648352ScaelThe 5748352Scael.Fn frexp 5848352Scaelfunction conforms to 5948352Scael.St -ansiC . 60