Update cell help page.
[scilab.git] / scilab / modules / data_structures / help / pt_BR / cell.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3  * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
4  * Copyright (C) 2007-2008 - INRIA
5  *
6  * This file must be used under the terms of the CeCILL.
7  * This source file is licensed as described in the file COPYING, which
8  * you should have received as part of this distribution.  The terms
9  * are also available at
10  * http://www.cecill.info/licences/Licence_CeCILL_V2.1-en.txt
11  *
12  -->
13 <refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns4="http://www.w3.org/1999/xhtml" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org" xml:id="cell" xml:lang="en">
14     <refnamediv>
15         <refname>cell</refname>
16         <refpurpose>cria um cell (célula) de matrizes vazias</refpurpose>
17     </refnamediv>
18     <refsynopsisdiv>
19         <title>Seqüência de Chamamento</title>
20         <synopsis>
21             c=cell()
22             c=cell(m1)
23             c=cell(m1, m2)
24             c=cell(m1, m2, ..., mn)
25             c=cell(x)
26         </synopsis>
27     </refsynopsisdiv>
28     <refsection>
29         <title>Parâmetros</title>
30         <variablelist>
31             <varlistentry>
32                 <term>x</term>
33                 <listitem>
34                     <para>vetor contendo as dimensões do cell a ser criado</para>
35                 </listitem>
36             </varlistentry>
37             <varlistentry>
38                 <term>m1, m2,..</term>
39                 <listitem>
40                     <para>dimensões do cell a ser criado</para>
41                 </listitem>
42             </varlistentry>
43         </variablelist>
44     </refsection>
45     <refsection>
46         <title>Descrição</title>
47         <para>retorna um cell de matrizes vazias</para>
48         <variablelist>
49             <varlistentry>
50                 <term>cell()</term>
51                 <listitem>
52                     <para>
53                         retorna um cell <literal>(0,0)</literal> de matrizes
54                         vazias.
55                     </para>
56                 </listitem>
57             </varlistentry>
58             <varlistentry>
59                 <term>cell(m1)</term>
60                 <listitem>
61                     <para>
62                         retorna um cell <literal>(m1,m1)</literal> de matrizes
63                         vazias.
64                     </para>
65                 </listitem>
66             </varlistentry>
67             <varlistentry>
68                 <term>cell(m1,m2)</term>
69                 <listitem>
70                     <para>
71                         retorna um cell <literal>(m1,m2) </literal>de matrizes
72                         vazias.
73                     </para>
74                 </listitem>
75             </varlistentry>
76             <varlistentry>
77                 <term>cell(m1,m2,..,mn)</term>
78                 <listitem>
79                     <para>
80                         retorna um cell <literal>(m1,m2,..,mn)</literal> de matrizes
81                         vazias.
82                     </para>
83                 </listitem>
84             </varlistentry>
85             <varlistentry>
86                 <term>cell(x)</term>
87                 <listitem>
88                     <para>retorna um cell de matrizes vazias com: a primeira dimensão
89                         sendo <literal>x(1)</literal>, a segunda sendo <literal>x(2),
90                             ...
91                         </literal>
92                     </para>
93                 </listitem>
94             </varlistentry>
95         </variablelist>
96     </refsection>
97     <refsection>
98         <title>Observações</title>
99         <para>
100             <literal>cell(x) </literal>não possui o mesmo tamanho que
101             <literal>x</literal>.
102         </para>
103         <para>
104             <literal>cell()</literal> é equivalente a
105             <literal>cell(0)</literal>.
106         </para>
107         <para>Se A for um cell, você pode acessar os conteúdos de um elemento de A
108             utilizando <literal>A{m1, m2, ..., mn}</literal>. A expressão
109             <literal>A(1,1) = zeros(2,2)</literal> não é válida, a sintaxe correta é
110             <literal>A{1,1} = zeros(2,2)</literal>.
111         </para>
112     </refsection>
113     <refsection>
114         <title>Exemplos</title>
115         <programlisting role="example"><![CDATA[ 
116 a = cell(3)
117 b = cell(3,1)
118 c = cell([2,3,4])
119  
120 // Assigning cell entries
121 b = cell(3,1);
122  
123 // Assigning the first element of b using {}
124 b{1} = 1:3
125  
126 // Assigning the second element of b using {}
127 b{2} = 'Scilab'
128  
129 // Assigning the third element of b using the 'entries' field
130 b{3} = poly(1:3,'s')
131  
132 // Assigning sub-cells
133 X = cell(3,2);
134 X{:,1} = b
135  
136 // Extracting a sub-cell: result is a cell
137 b{1}
138 b{1:2}
139  
140 // Extracting a sub-cell value: result is an array
141 b{1}
142  
143 // Dimensions of b as a double value
144 size(b)
145  ]]></programlisting>
146     </refsection>
147     <refsection>
148         <title>Ver Também</title>
149         <simplelist type="inline">
150             <member>
151                 <link linkend="eye">eye</link>
152             </member>
153             <member>
154                 <link linkend="ones">ones</link>
155             </member>
156             <member>
157                 <link linkend="zeros">zeros</link>
158             </member>
159             <member>
160                 <link linkend="iscell">iscell</link>
161             </member>
162         </simplelist>
163     </refsection>
164     <refsection>
165         <title>History</title>
166         <revhistory>
167             <revision>
168                 <revnumber>6.0.0</revnumber>
169                 <revremark>
170                     <para>
171                         Fields "entries" and "dims" do not exist anymore. To assign or extract an element, use {}.
172                     </para>
173                 </revremark>
174             </revision>
175         </revhistory>
176     </refsection>
177 </refentry>