Scilab Function
Last update : 30/10/2005
dec2bin - conversion of decimal numbers into binary
representation
Calling Sequence
-
y = dec2bin(x)
Parameters
-
x
: a row vector decimal numbers.
-
y
: a matrix, representing the decimal numbers of x as binary
numbers. Each column represents one decimal number. The 1st row of y
contains the most signigicant bits, the last row the least
significant bit.
Description
-
The elements of the input row vector are made positive and rounded.
Only natural positive numbers are used for that function.
Examples
x=ceil(256 .*rand(1,10));
y=dec2bin(x);
disp(x);
disp(y);
Authors
-
Dr. Andreas Geissler geisslea@web.de