Bug #10041 fixed - WFILE_f block was not declared as deprecated
[scilab.git] / scilab / modules / xcos / help / en_US / palettes / Sinks_pal / WFILE_f.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3  * Xcos
4  *
5  * Copyright (C) INRIA - METALAU Project <scicos@inria.fr> (HTML version)
6  * Copyright (C) DIGITEO - Scilab Consortium (XML Docbook version)
7  * Copyright (C) 2011 - Bernard DUJARDIN <bernard.dujardin@contrib.scilab.org>
8  *
9  * This program is free software; you can redistribute it and/or modify
10  * it under the terms of the GNU General Public License as published by
11  * the Free Software Foundation; either version 2 of the License, or
12  *  (at your option) any later version.
13  *
14  * This program is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17  * GNU General Public License for more details.
18  *
19  * You should have received a copy of the GNU General Public License
20  * along with this program; if not, write to the Free Software
21  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
22  *
23  * See the file ./license.txt
24  -->
25 <refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns3="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="WFILE_f" xml:lang="en_US">
26     <refnamediv>
27         <refname>WFILE_f</refname>
28         <refpurpose>Write to output file. <emphasis role="bold">This function is obsolete.</emphasis></refpurpose>
29     </refnamediv>
30     <refsection>
31         <title>Block Screenshot</title>
32         <para>
33             <inlinemediaobject>
34                 <imageobject>
35                     <imagedata align="center" fileref="../../../../images/palettes/WFILE_f.png" valign="middle"/>
36                 </imageobject>
37             </inlinemediaobject>
38         </para>
39     </refsection>
40     <refsection id="Contents_WFILE_f">
41         <title>Contents</title>
42         <itemizedlist>
43             <listitem>
44                 <para>
45                     <link linkend="WFILE_f">Write to output file</link>
46                 </para>
47             </listitem>
48             <listitem>
49                 <itemizedlist>
50                     <listitem>
51                         <para>
52                             <xref linkend="Palette_WFILE_f">Palette</xref>
53                         </para>
54                     </listitem>
55                     <listitem>
56                         <para>
57                             <xref linkend="Description_WFILE_f">Description</xref>
58                         </para>
59                     </listitem>
60                     <listitem>
61                         <para>
62                             <xref linkend="Datatype_WFILE_f">Data types</xref>
63                         </para>
64                     </listitem>
65                     
66                     <listitem>
67                         <para>
68                             <xref linkend="Dialogbox_WFILE_f">Dialog box</xref>
69                         </para>
70                     </listitem>
71                     
72                     <listitem>
73                         <para>
74                             <xref linkend="Defaultproperties_WFILE_f">Default properties</xref>
75                         </para>
76                     </listitem>
77                     
78                     <listitem>
79                         <para>
80                             <xref linkend="Example_WFILE_f">Example</xref>
81                         </para>
82                     </listitem>
83                     
84                     <listitem>
85                         <para>
86                             <xref linkend="Interfacingfunction_WFILE_f">Interfacing function</xref>
87                         </para>
88                     </listitem>
89                     
90                     <listitem>
91                         <para>
92                             <xref linkend="Computationalfunction_WFILE_f">Computational  function</xref>
93                         </para>
94                     </listitem>
95                     
96                     <listitem>
97                         <para>
98                             <xref linkend="Seealso_WFILE_f">See also</xref>
99                         </para>
100                     </listitem>
101                     
102                 </itemizedlist>
103             </listitem>
104         </itemizedlist>
105     </refsection>
106     <refsection id="Palette_WFILE_f">
107         <title>Palette</title>
108         <itemizedlist>
109             <listitem>
110                 <para>
111                     <link linkend="Sinks_pal">Sinks palette</link>
112                 </para>
113             </listitem>
114         </itemizedlist>
115     </refsection>
116     <refsection id="Description_WFILE_f">
117         <title>Description</title>
118         <para>
119             This block is <emphasis role="bold">obsolete</emphasis>. This block allows user to save data in a file with the name defined with the <emphasis role="bold">Output File Name</emphasis> parameter, in text formatted mode or in binary mode.
120         </para>
121         <para>
122             The file is a sequence of records. Each record has a length <emphasis role="bold">Output Size</emphasis> <literal> + 1 </literal> and the structure shown below:
123         </para>
124         <para />
125         <mediaobject><imageobject>
126                 <imagedata fileref="../../../images/sinks_pal/en_US/wfile_f_record_en_US.png" align="center" />
127             </imageobject>
128         </mediaobject>
129         <para>
130             where the first field is the date of the event received on the activation input of the block during the simulation and other fields the regular input data. Each call to the
131             bloc writes a record in the file.
132         </para>
133         <para>
134             The <emphasis role="bold">Output Format</emphasis> parameter gives the record format.
135         </para>
136         <itemizedlist>
137             <listitem>
138                 <para>
139                     For a binary file, this parameter is an empty string.
140                 </para>
141             </listitem>
142             <listitem>
143                 <para>
144                     For a text file, this parameter is a string of format (Fortran syntax) enclosed by parentheses.
145                 </para>
146             </listitem>
147         </itemizedlist>
148     </refsection>
149     
150     <refsection id="Datatype_WFILE_f">
151         <title>Data types</title>
152         
153         <itemizedlist>
154             <listitem>
155                 <para>
156                     Input: a scalar or a column vector of length <emphasis role="bold">Input Size</emphasis>.
157                 </para>
158             </listitem>
159         </itemizedlist>
160     </refsection>
161     <refsection id="Dialogbox_WFILE_f">
162         <title>Dialog box</title>
163         <para>
164             <inlinemediaobject>
165                 <imageobject>
166                     <imagedata align="center" fileref="../../../gui/sinks_pal/en_US/WFILE_f_gui.png" valign="middle"/>
167                 </imageobject>
168             </inlinemediaobject>
169         </para>
170         <para/>
171         <itemizedlist>
172             <listitem>
173                 <para>
174                     <emphasis role="bold">Input Size</emphasis>
175                 </para>
176                 <para>A scalar, the size of the input column vector.</para>
177                 <para>Properties : Type 'vec' of size 1.</para>
178             </listitem>
179             <listitem>
180                 <para>
181                     <emphasis role="bold">Output File Name</emphasis>
182                 </para>
183                 <para>
184                     A character string defining the path and the file name of the file to be written. The block support file name expansion and you can use environment variables
185                     like <emphasis>HOME</emphasis> in the path, by example <emphasis>"HOME/my_datas/foo.datas"</emphasis>. Without
186                     file path, the file is writen in the directory defined by the <emphasis>PWD</emphasis> variable.
187                 </para>
188                 <para>The directory path must exist, otherwise you will be prompted by an error message.</para>
189                 <para>Properties : Type 'str' of size 1.</para>
190             </listitem>
191             <listitem>
192                 <para>
193                     <emphasis role="bold">Output Format</emphasis>
194                 </para>
195                 <para>
196                     A character string defining the Fortran format to use or nothing for an unformatted (binary) write. If given, the format must began by a left parenthesis and
197                     end by a right parenthesis. Example: <emphasis>(10e3)</emphasis>
198                 </para>
199                 <para>Properties : Type 'str' of size 1.</para>
200             </listitem>
201             <listitem>
202                 <para>
203                     <emphasis role="bold">Buffer Size</emphasis>
204                 </para>
205                 <para>
206                     To improve efficiency it is possible to buffer the input data. Data writing on the file is only done
207                     after the filling of the buffer and at the end of simulation.
208                 </para>
209                 <para>Properties : Type 'vec' of size 1.</para>
210             </listitem>
211         </itemizedlist>
212     </refsection>
213     <refsection id="Defaultproperties_WFILE_f">
214         <title>Default properties</title>
215         <itemizedlist>
216             <listitem>
217                 <para>
218                     <emphasis role="bold">always active:</emphasis> no
219                 </para>
220             </listitem>
221             <listitem>
222                 <para>
223                     <emphasis role="bold">direct-feedthrough:</emphasis> yes
224                 </para>
225             </listitem>
226             <listitem>
227                 <para>
228                     <emphasis role="bold">zero-crossing:</emphasis> no
229                 </para>
230             </listitem>
231             <listitem>
232                 <para>
233                     <emphasis role="bold">mode:</emphasis> no
234                 </para>
235             </listitem>
236             <listitem>
237                 <para>
238                     <emphasis role="bold">regular inputs:</emphasis>
239                 </para>
240                 <para>
241                     <emphasis role="bold">- port 1 : size [1,1] / type 1</emphasis>
242                 </para>
243             </listitem>
244             <listitem>
245                 <para>
246                     <emphasis role="bold">number/sizes of activation
247                         inputs:
248                     </emphasis>
249                     1
250                 </para>
251             </listitem>
252             <listitem>
253                 <para>
254                     <emphasis role="bold">number/sizes of activation
255                         outputs:
256                     </emphasis>
257                     0
258                 </para>
259             </listitem>
260             <listitem>
261                 <para>
262                     <emphasis role="bold">continuous-time state:</emphasis>
263                     no
264                 </para>
265             </listitem>
266             <listitem>
267                 <para>
268                     <emphasis role="bold">discrete-time state:</emphasis> yes
269                 </para>
270             </listitem>
271             <listitem>
272                 <para>
273                     <emphasis role="bold">object discrete-time state:</emphasis>
274                     no
275                 </para>
276             </listitem>
277             <listitem>
278                 <para>
279                     <emphasis role="bold">name of computational function:</emphasis>
280                     <emphasis role="italic">writef</emphasis>
281                 </para>
282             </listitem>
283         </itemizedlist>
284     </refsection>
285     
286     <refsection id="Example_WFILE_f">
287         <title>Example</title>
288         <para>
289             In this example the block is used to record the output and its inverse of the sine wave generator. A multiplexer form the input vector of the WFILE_f block which record the data in
290             the file <emphasis>"TMPDIR/wfile_f.text"</emphasis>. Then you can read these data with the block
291             <link linkend="RFILE_f">RFILE_f</link>.
292             <link type="scilab" linkend="scilab.xcos/xcos/examples/sinks_pal/en_US/wfile_f_en_US.xcos">
293                 Open this example in Xcos
294             </link>
295             .
296         </para>
297         <para />
298         <inlinemediaobject><imageobject>
299                 <imagedata align="center" fileref="../../../examples/sinks_pal/en_US/wfile_f_diagram_en_US.png" />
300             </imageobject>
301         </inlinemediaobject>
302         <para>
303             <emphasis>After the simulation</emphasis> of this example, you can see the contents of the file with <emphasis>Scinotes</emphasis> with the following command:
304         </para>
305         <para />
306         <programlisting role="exec"><![CDATA[scinotes(TMPDIR + "/wfile_f.txt")]]></programlisting>
307     </refsection>
308     
309     <refsection id="Interfacingfunction_WFILE_f">
310         <title>Interfacing function</title>
311         <itemizedlist>
312             <listitem>
313                 <para>
314                     <link type="scilab" linkend="scilab.scinotes/scicos_blocks/macros/Sinks/WFILE_f.sci">SCI/modules/scicos_blocks/macros/Sinks/WFILE_f.sci</link>
315                 </para>
316             </listitem>
317         </itemizedlist>
318     </refsection>
319     <refsection id="Computationalfunction_WFILE_f">
320         <title>Computational function</title>
321         <itemizedlist>
322             <listitem>
323                 <para>SCI/modules/scicos_blocks/src/fortran/writef.f (Type 0)</para>
324             </listitem>
325         </itemizedlist>
326     </refsection>
327     
328     <refsection role="see also" id="Seealso_WFILE_f">
329         <title>See also</title>
330         <itemizedlist>
331             <listitem>
332                 <link linkend="RFILE_f">RFILE_f</link>
333             </listitem>
334             <listitem>
335                 <link linkend="READC_f">READC_f</link>
336             </listitem>
337             <listitem>
338                 <link linkend="WRITEC_f">WRITEC_f</link>
339             </listitem>
340         </itemizedlist>
341     </refsection>
342     <refsection>
343         <title>History</title>
344         <revhistory>
345             <revision>
346                 <revnumber>5.4.0</revnumber>
347                 <revremark>WFILE_f block declared as obsolete.</revremark>
348             </revision>
349         </revhistory>
350     </refsection>
351 </refentry>