~ubuntu-branches/ubuntu/raring/scilab/raring-proposed

« back to all changes in this revision

Viewing changes to modules/compatibility_functions/help/en_US/firstnonsingleton.xml

  • Committer: Package Import Robot
  • Author(s): Sylvestre Ledru
  • Date: 2012-08-30 14:42:38 UTC
  • mfrom: (1.4.7)
  • Revision ID: package-import@ubuntu.com-20120830144238-c1y2og7dbm7m9nig
Tags: 5.4.0-beta-3-1~exp1
* New upstream release
* Update the scirenderer dep
* Get ride of libjhdf5-java dependency

Show diffs side-by-side

added added

removed removed

Lines of Context:
11
11
    *
12
12
    -->
13
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: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="firstnonsingleton">
14
 
  <refnamediv>
15
 
    <refname>firstnonsingleton</refname>
16
 
    <refpurpose>Finds first dimension which is not 1</refpurpose>
17
 
  </refnamediv>
18
 
  <refsynopsisdiv>
19
 
    <title>Calling Sequence</title>
20
 
    <synopsis>[dim]=firstnonsingleton(A[,opt])</synopsis>
21
 
  </refsynopsisdiv>
22
 
  <refsection>
23
 
    <title>Arguments</title>
24
 
    <variablelist>
25
 
      <varlistentry>
26
 
        <term>dim</term>
27
 
        <listitem>
28
 
          <para>first dimension of A which is not 1</para>
29
 
        </listitem>
30
 
      </varlistentry>
31
 
      <varlistentry>
32
 
        <term>A</term>
33
 
        <listitem>
34
 
          <para>a variable of any Scilab data type</para>
35
 
        </listitem>
36
 
      </varlistentry>
37
 
      <varlistentry>
38
 
        <term>opt</term>
39
 
        <listitem>
40
 
          <para>a character string giving the type of output we want</para>
41
 
          <variablelist>
42
 
            <varlistentry>
43
 
              <term>"num"</term>
44
 
              <listitem>
45
 
                <para>returned value is a numerical value</para>
46
 
              </listitem>
47
 
            </varlistentry>
48
 
            <varlistentry>
49
 
              <term>"str"</term>
50
 
              <listitem>
51
 
                <para>returned value is a character string if possible ("r" instead of 1 and "c" instead of 2)</para>
52
 
              </listitem>
53
 
            </varlistentry>
54
 
          </variablelist>
55
 
        </listitem>
56
 
      </varlistentry>
57
 
    </variablelist>
58
 
  </refsection>
59
 
  <refsection>
60
 
    <title>Description</title>
61
 
    <para>
62
 
      This function is used by <literal>mfile2sci</literal> to emulate Matlab behavior under Scilab, particularly
63
 
      for functions which treat the values along the first non-singleton dimension of A in Matlab
64
 
      while in Scilab they treat all values of A.
65
 
    </para>
66
 
  </refsection>
67
 
  <refsection>
68
 
    <title>Examples</title>
69
 
    <programlisting role="example"><![CDATA[ 
 
14
    <refnamediv>
 
15
        <refname>firstnonsingleton</refname>
 
16
        <refpurpose>Finds first dimension which is not 1</refpurpose>
 
17
    </refnamediv>
 
18
    <refsynopsisdiv>
 
19
        <title>Calling Sequence</title>
 
20
        <synopsis>[dim]=firstnonsingleton(A[,opt])</synopsis>
 
21
    </refsynopsisdiv>
 
22
    <refsection>
 
23
        <title>Arguments</title>
 
24
        <variablelist>
 
25
            <varlistentry>
 
26
                <term>dim</term>
 
27
                <listitem>
 
28
                    <para>first dimension of A which is not 1</para>
 
29
                </listitem>
 
30
            </varlistentry>
 
31
            <varlistentry>
 
32
                <term>A</term>
 
33
                <listitem>
 
34
                    <para>a variable of any Scilab data type</para>
 
35
                </listitem>
 
36
            </varlistentry>
 
37
            <varlistentry>
 
38
                <term>opt</term>
 
39
                <listitem>
 
40
                    <para>a character string giving the type of output we want</para>
 
41
                    <variablelist>
 
42
                        <varlistentry>
 
43
                            <term>"num"</term>
 
44
                            <listitem>
 
45
                                <para>returned value is a numerical value</para>
 
46
                            </listitem>
 
47
                        </varlistentry>
 
48
                        <varlistentry>
 
49
                            <term>"str"</term>
 
50
                            <listitem>
 
51
                                <para>returned value is a character string if possible ("r" instead of 1 and "c" instead of 2)</para>
 
52
                            </listitem>
 
53
                        </varlistentry>
 
54
                    </variablelist>
 
55
                </listitem>
 
56
            </varlistentry>
 
57
        </variablelist>
 
58
    </refsection>
 
59
    <refsection>
 
60
        <title>Description</title>
 
61
        <para>
 
62
            This function is used by <literal>mfile2sci</literal> to emulate Matlab behavior under Scilab, particularly
 
63
            for functions which treat the values along the first non-singleton dimension of A in Matlab
 
64
            while in Scilab they treat all values of A.
 
65
        </para>
 
66
    </refsection>
 
67
    <refsection>
 
68
        <title>Examples</title>
 
69
        <programlisting role="example"><![CDATA[ 
70
70
A = [1 2 3;4 5 6];
71
71
// Scilab max
72
72
M = max(A)
73
73
// Matlab max emulation
74
74
M = max(A,firstnonsingleton(A))
75
75
 ]]></programlisting>
76
 
  </refsection>
 
76
    </refsection>
77
77
</refentry>