Bug Fix #14415 - Corrected some spellings error in help pages
[scilab.git] / scilab / modules / compatibility_functions / help / en_US / mtlb_logical.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) 2004-2007 - INRIA - Vincent COUVERT
5     *
6  * Copyright (C) 2012 - 2016 - Scilab Enterprises
7  *
8  * This file is hereby licensed under the terms of the GNU GPL v2.0,
9  * pursuant to article 5.3.4 of the CeCILL v.2.1.
10  * This file was originally licensed under the terms of the CeCILL v2.1,
11  * and continues to be available under such terms.
12  * For more information, see the COPYING file which you should have received
13  * along with this program.
14     *
15     -->
16 <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" xmlns:scilab="http://www.scilab.org" xml:lang="en" xml:id="mtlb_logical">
17     <refnamediv>
18         <refname>mtlb_logical</refname>
19         <refpurpose>Matlab logical emulation function</refpurpose>
20     </refnamediv>
21     <refsection>
22         <title>Description</title>
23         <para>
24             There is no Scilab equivalent function for Matlab <literal>logical</literal> but its behavior can be easily reproduced.
25         </para>
26         <para>
27             The function <literal>mtlb_logical(A)</literal> is used by
28             <literal>mfile2sci</literal> to replace <literal>logical(A)</literal> when it was not
29             possible to know what was the input while porting Matlab code to Scilab. This function will
30             determine the correct semantic at run time. If you want to have a
31             more efficient code it is possible to replace <literal>mtlb_logical</literal> calls:
32         </para>
33         <itemizedlist>
34             <listitem>
35                 <para>
36                     If <literal>A</literal> is a boolean matrix
37                     <literal>mtlb_logical(A)</literal> may be replaced by <literal>A</literal>
38                 </para>
39             </listitem>
40             <listitem>
41                 <para>
42                     If <literal>A</literal> is not an empty matrix
43                     <literal>mtlb_logical(A)</literal> may be replaced by <literal>A&lt;&gt;[]</literal>
44                 </para>
45             </listitem>
46             <listitem>
47                 <para>
48                     If <literal>A</literal> is an empty matrix
49                     <literal>mtlb_logical(A)</literal> may be replaced by <literal>[]</literal>
50                 </para>
51             </listitem>
52         </itemizedlist>
53         <para>
54             <warning>
55                 Caution: <literal>mtlb_logical</literal> has not to be used for hand coded functions.
56             </warning>
57         </para>
58     </refsection>
59 </refentry>