14
14
<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns5="http://www.w3.org/1999/xhtml" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" version="5.0-subset Scilab" xml:id="bin2dec" xml:lang="en">
16
<refname>bin2dec</refname>
17
<refpurpose>convert from binary to decimal</refpurpose>
20
<title>Calling Sequence</title>
21
<synopsis>y=bin2dec(str)</synopsis>
24
<title>Arguments</title>
29
<para>a matrix of strings containing only
30
characters '1' and '0'
37
<para>a matrix of doubles, positive integer values</para>
43
<title>Description</title>
45
Given <literal>str</literal> a binary string, this function returns
46
<literal>y</literal> the decimal number whose the binary representation is
47
given by <literal>str</literal> ( <literal>y</literal> and
48
<literal>str</literal> have the same size).
52
<title>Examples</title>
53
<programlisting role="example"><![CDATA[
16
<refname>bin2dec</refname>
17
<refpurpose>convert from binary to decimal</refpurpose>
20
<title>Calling Sequence</title>
21
<synopsis>y=bin2dec(str)</synopsis>
24
<title>Arguments</title>
29
<para>a matrix of strings containing only
30
characters '1' and '0'
37
<para>a matrix of doubles, positive integer values</para>
43
<title>Description</title>
45
Given <literal>str</literal> a binary string, this function returns
46
<literal>y</literal> the decimal number whose the binary representation is
47
given by <literal>str</literal> ( <literal>y</literal> and
48
<literal>str</literal> have the same size).
52
<title>Examples</title>
53
<programlisting role="example"><![CDATA[
55
55
// '1010110' : is the binary representation of 86
62
62
str=['1011011'; '1010010']
64
64
]]></programlisting>
66
<refsection role="see also">
67
<title>See Also</title>
68
<simplelist type="inline">
70
<link linkend="base2dec">base2dec</link>
73
<link linkend="oct2dec">oct2dec</link>
76
<link linkend="hex2dec">hex2dec</link>
79
<link linkend="dec2bin">dec2bin</link>
82
<link linkend="dec2oct">dec2oct</link>
85
<link linkend="dec2hex">dec2hex</link>
66
<refsection role="see also">
67
<title>See Also</title>
68
<simplelist type="inline">
70
<link linkend="base2dec">base2dec</link>
73
<link linkend="oct2dec">oct2dec</link>
76
<link linkend="hex2dec">hex2dec</link>
79
<link linkend="dec2bin">dec2bin</link>
82
<link linkend="dec2oct">dec2oct</link>
85
<link linkend="dec2hex">dec2hex</link>