~ubuntu-branches/ubuntu/karmic/scilab/karmic

« back to all changes in this revision

Viewing changes to man/elementary/maxi.man

  • Committer: Bazaar Package Importer
  • Author(s): Torsten Werner
  • Date: 2002-03-21 16:57:43 UTC
  • Revision ID: james.westby@ubuntu.com-20020321165743-e9mv12c1tb1plztg
Tags: upstream-2.6
ImportĀ upstreamĀ versionĀ 2.6

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
.TH maxi G "April 1993" "Scilab Group" "Scilab Function"
 
2
.so ../sci.an
 
3
.SH NAME
 
4
maxi - maximum
 
5
.SH CALLING SEQUENCE
 
6
.nf
 
7
[m [,k]]=maxi(A)
 
8
[m [,k]]=maxi(A,'c') or [m [,k]]=maxi(A,'r')
 
9
[m [,k]]=maxi(A1,A2,...,An)
 
10
[m [,k]]=maxi(list(A1,A2,...,An))
 
11
.fi
 
12
.SH PARAMETERS
 
13
.TP 10
 
14
A
 
15
: real vector or matrix.
 
16
.TP 10
 
17
A1,...,An
 
18
: a set of real vectors or matrices, all of the same size or scalar.
 
19
.SH DESCRIPTION
 
20
For \fVA\fR, a real  vector or matrix, \fVmaxi(A)\fR 
 
21
is the largest element 
 
22
\fVA\fR. \fV[m,k]=maxi(A)\fR gives in addition the index of the maximum.
 
23
A second argument of type string \fV'r'\fR or \fV'c'\fR can be used : \fV'r'\fR
 
24
is used to get a row vector \fVm\fR such that \fVm(j)\fR contains the 
 
25
maximum of the \fVj\fR th column of A (\fVA(:,j)\fR), \fVk(j)\fR gives the row 
 
26
indice which contain the maximum for column \fVj\fR. \fV'c'\fR is used for the dual operation on the rows of \fVA\fR.
 
27
 
 
28
\fVm=maxi(A1,A2,...,An)\fR, where all the \fVAj\fR are matrices of the same 
 
29
sizes,returns a vector or a matrix \fVm\fR of size \fVsize(m)=size(A1)\fR
 
30
such that \fVm(i)= max( Aj(i)), j=1,...,n\fR. \fV[m,k]=maxi(A1,A2,...,An)\fR 
 
31
gives in addition the vector or matrix \fVk\fR. for a fixed \fVi\fR,
 
32
\fVk(i)\fR is the number of the first \fVAj(i)\fR achieving the maximum.
 
33
 
 
34
\fV[m,k]=maxi(list(A1,...,An))\fR is an equivalent syntax of 
 
35
\fV[m,k]=maxi(A1,A2,...,An)\fR
 
36
.SH EXAMPLE
 
37
.nf
 
38
[m,n]=maxi([1,3,1])
 
39
[m,n]=maxi([3,1,1],[1,3,1],[1,1,3])
 
40
[m,n]=maxi([3,-2,1],1)
 
41
[m,n]=maxi(list([3,1,1],[1,3,1],[1,1,3]))
 
42
[m,n]=maxi(list(1,3,1))
 
43
.fi
 
44
.SH SEE ALSO
 
45
sort, find, mini
 
46