~ubuntu-branches/ubuntu/hoary/scilab/hoary

« back to all changes in this revision

Viewing changes to man/eng/mtlb/mtlb_max.xml

  • Committer: Bazaar Package Importer
  • Author(s): Torsten Werner
  • Date: 2005-01-09 22:58:21 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20050109225821-473xr8vhgugxxx5j
Tags: 3.0-12
changed configure.in to build scilab's own malloc.o, closes: #255869

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<?xml version="1.0" encoding="ISO-8859-1" standalone="no"?>
 
2
<!-- When this file is modified please also modify mtlb_min.xml -->
 
3
<!DOCTYPE MAN SYSTEM "../../manrev.dtd">
 
4
<MAN>
 
5
  <LANGUAGE>eng</LANGUAGE>
 
6
  <TITLE>mtlb_max</TITLE>
 
7
  <TYPE>M2SCI function</TYPE>
 
8
  <DATE>April 2004</DATE>
 
9
 
 
10
  <SHORT_DESCRIPTION name="mtlb_max">Matlab max emulation function</SHORT_DESCRIPTION>
 
11
 
 
12
  <DESCRIPTION>
 
13
 
 
14
    <P>Matlab and Scilab <VERB>max</VERB> behave differently in some particular cases:</P>
 
15
 
 
16
    <DESCRIPTION_INDENT>
 
17
    <DESCRIPTION_ITEM>
 
18
    <ITEMIZE>
 
19
      <ITEM>
 
20
        <SP>
 
21
        With complex values: Matlab <VERB>max</VERB> can be used with complex values but not Scilab function.
 
22
        </SP>
 
23
      </ITEM>
 
24
 
 
25
      <ITEM>
 
26
        <SP>
 
27
        When called with one input: Matlab <VERB>max</VERB> threats values along the first
 
28
        non-singleton dimension but Scilab threats all input values.
 
29
        </SP>
 
30
      </ITEM>
 
31
 
 
32
      <ITEM>
 
33
        <SP>
 
34
        When called with two inputs: if one is an empty matrix, Scilab returns an error message but Matlab returns [].
 
35
        </SP>
 
36
      </ITEM>
 
37
 
 
38
      <ITEM>
 
39
        <SP>
 
40
        When called with three inputs: if <VERB>dim</VERB> parameter is greater than number of
 
41
        dimensions of first input, Scilab returns an error message and Matlab returns the first input.
 
42
        </SP>
 
43
      </ITEM>
 
44
    </ITEMIZE>
 
45
    </DESCRIPTION_ITEM>
 
46
    </DESCRIPTION_INDENT>
 
47
 
 
48
    <P>
 
49
    The function <VERB>[r[,k]] = mtlb_max(A[,B[,dim]])</VERB> is used by
 
50
    <VERB>mfile2sci</VERB> to replace <VERB>[r[,k]] = max(A[,B[,dim]])</VERB> when it was not
 
51
    possible to know what were the inputs while porting Matlab code to Scilab. This function will
 
52
    determine the correct semantic at run time. If you want to have a
 
53
    more efficient code it is possible to replace <VERB>mtlb_max</VERB> calls:
 
54
    </P>
 
55
 
 
56
    <DESCRIPTION_INDENT>
 
57
    <DESCRIPTION_ITEM>
 
58
    <ITEMIZE>
 
59
      <ITEM>
 
60
        <SP>
 
61
        When called with one input, if <VERB>A</VERB> is a vector or a scalar
 
62
        <VERB>[r[,k]] = mtlb_max(A)</VERB> may be replaced by <VERB>max(A)</VERB>
 
63
        </SP>
 
64
      </ITEM>
 
65
 
 
66
      <ITEM>
 
67
        <SP>
 
68
        When called with one input, if <VERB>A</VERB> is a matrix
 
69
        <VERB>[r[,k]] = mtlb_max(A)</VERB> may be replaced by <VERB>max(A,&quot;r&quot;)</VERB>
 
70
        </SP>
 
71
      </ITEM>
 
72
 
 
73
      <ITEM>
 
74
        <SP>
 
75
        When called with two inputs, if <VERB>A</VERB> and <VERB>B</VERB> are real matrices and not empty matrices
 
76
        <VERB>[r[,k]] = mtlb_max(A,B)</VERB> may be replaced by <VERB>max(A,B)</VERB>
 
77
        </SP>
 
78
      </ITEM>
 
79
 
 
80
      <ITEM>
 
81
        <SP>
 
82
        When called with three inputs, if <VERB>dim</VERB> is lesser than the number of dimensions of <VERB>A</VERB>
 
83
        <VERB>[r[,k]] = mtlb_max(A,[],dim)</VERB> may be replaced by <VERB>max(A,dim)</VERB>
 
84
        </SP>
 
85
      </ITEM>
 
86
    </ITEMIZE>
 
87
    </DESCRIPTION_ITEM>
 
88
    </DESCRIPTION_INDENT>
 
89
 
 
90
    <P>Caution: <VERB>mtlb_max</VERB> has not to be used for hand coded functions.</P>
 
91
 
 
92
  </DESCRIPTION>
 
93
 
 
94
  <SEE_ALSO>
 
95
    <SEE_ALSO_ITEM> <LINK>firstnonsingleton</LINK> </SEE_ALSO_ITEM>
 
96
  </SEE_ALSO>
 
97
 
 
98
  <AUTHORS>
 
99
    <AUTHORS_ITEM>V.C.</AUTHORS_ITEM>
 
100
  </AUTHORS>
 
101
</MAN>