Moved documentation pages where they belong
[scilab.git] / scilab / modules / polynomials / help / en_US / poly.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" version="5.0-subset Scilab" xml:lang="en" xml:id="poly">
3   <info>
4     <pubdate>$LastChangedDate$</pubdate>
5   </info>
6   <refnamediv>
7     <refname>poly</refname>
8     <refpurpose>polynomial definition</refpurpose>
9   </refnamediv>
10   <refsynopsisdiv>
11     <title>Calling Sequence</title>
12     <synopsis>p=poly(a,vname, ["flag"])</synopsis>
13   </refsynopsisdiv>
14   <refsection>
15     <title>Arguments</title>
16     <variablelist>
17       <varlistentry>
18         <term>a</term>
19         <listitem>
20           <para>matrix or real number</para>
21         </listitem>
22       </varlistentry>
23       <varlistentry>
24         <term>vname</term>
25         <listitem>
26           <para>String, the symbolic variable name. If the string have more
27             than 4 characters only the first 4 are taken into account.
28           </para>
29         </listitem>
30       </varlistentry>
31       <varlistentry>
32         <term>"flag"  </term>
33         <listitem>
34           <para>
35             string ("roots", "coeff"), default value is <literal>"roots"</literal>.
36           </para>
37         </listitem>
38       </varlistentry>
39     </variablelist>
40   </refsection>
41   <refsection>
42     <title>Description</title>
43     <variablelist>
44       <varlistentry>
45         <term>
46           If <literal>a</literal> is a matrix,
47         </term>
48         <listitem>
49           <para>
50             <literal>p</literal> is the characteristic
51             polynomial i.e. <literal>determinant(x*eye()-a)</literal>, <literal>x</literal> being
52             the symbolic variable.
53           </para>
54         </listitem>
55       </varlistentry>
56       <varlistentry>
57         <term>If v is a vector,</term>
58         <listitem>
59           <itemizedlist>
60             <listitem>
61               <para>
62                 <literal>poly(v,"x",["roots"])</literal>  is the polynomial
63                 with <literal>roots</literal> the entries of <literal>v</literal> and
64                 <literal>"x"</literal> as formal variable. (In this case,
65                 <literal>roots</literal> and   <literal>poly</literal> are inverse functions). 
66                 Note that Infinite roots gives zero  highest degree coefficients. 
67               </para>
68             </listitem>
69             <listitem>
70               <para>
71                 <literal>poly(v,"x","coeff")</literal> creates the
72                 polynomial with symbol <literal>"x"</literal> and with coefficients
73                 the entries of <literal>v</literal> (<literal>v(1)</literal> is the constant term 
74                 of the polynomial). (Here <literal>poly</literal> and <literal>coeff</literal> are 
75                 inverse functions).
76               </para>
77             </listitem>
78           </itemizedlist>
79         </listitem>
80       </varlistentry>
81     </variablelist>
82     <para>
83       <literal>s=poly(0,"s")</literal> is the seed for defining
84       polynomials with symbol <literal>"s"</literal>.
85     </para>
86   </refsection>
87   <refsection>
88     <title>Examples</title>
89     <programlisting role="example"><![CDATA[ 
90 s=poly(0,"s");
91 p=1+s+2*s^2;
92 A=rand(2,2);
93 poly(A,"x")
94 //rational fractions
95 h=(1+2*%s)/poly(1:4,'s','c')
96  ]]></programlisting>
97   </refsection>
98   <refsection role="see also">
99     <title>See Also</title>
100     <simplelist type="inline">
101       <member>
102         <link linkend="coeff">coeff</link>
103       </member>
104       <member>
105         <link linkend="roots">roots</link>
106       </member>
107       <member>
108         <link linkend="varn">varn</link>
109       </member>
110       <member>
111         <link linkend="horner">horner</link>
112       </member>
113       <member>
114         <link linkend="derivat">derivat</link>
115       </member>
116       <member>
117         <link linkend="matrices">matrices</link>
118       </member>
119       <member>
120         <link linkend="rational">rational</link>
121       </member>
122     </simplelist>
123   </refsection>
124 </refentry>