Convert decimal number to character array representing hexadecimal number
hexStr = dec2hex(
returns the hexadecimal,
or base-16, representation of the number D
)D
. The output argument
hexStr
is a character vector that represents hexadecimal digits using
the characters 0
-9
and
A
-F
.
If D
is a numeric vector, matrix, or multidimensional array, then
hexStr
is a two-dimensional character array. Each row of
hexStr
represents an element of D
.
If the input argument D
has a value greater than the value returned
by flintmax
, then dec2hex
might not return an
exact representation.