MATLAB Function Reference |
Convert singles and doubles to IEEE hexadecimal strings.
Syntax
Description
If X
is a single or double precision array with n elements, num2hex(X)
is an n-by-8 or n-by-16 char array of the hexadecimal floating-point representation. The same representation is printed with format hex
.
Examples
ans = 3ff0000000000000 0000000000000000 3fb999999999999a c00921fb54442d18 7ff0000000000000 fff8000000000000 num2hex(single([1 0 0.1 -pi Inf NaN]))
See Also
num2cell | num2str |
© 1994-2005 The MathWorks, Inc.