
Idivide - Integer division with rounding option.
kron - Kronecker tensor product
Relational operators.
eq - Equal ==
ne - Not equal ~=
lt - Less than <
gt - Greater than >
le - Less than or equal <=
ge - Greater than or equal >=
Logical operators.
relop - Short-circuit logical AND &&
relop - Short-circuit logical OR ||
and - Element-wise logical AND &
or - Element-wise logical OR |
not - Logical NOT ~
punct - Ignore function argument or output ~
xor - Logical EXCLUSIVE OR
any - True if any element of vector is nonzero
all - True if all elements of vector are nonzero
Special characters.
colon - Colon :
paren - Parentheses and subscripting ( )
paren - Brackets [ ]
paren - Braces and subscripting { }
punct - Function handle creation @
punct - Decimal point .
punct - Structure field access .
punct - Parent directory ..
punct - Continuation ...
punct - Separator ,
punct - Semicolon ;
punct - Comment %
punct - Invoke operating system command !
punct - Assignment =
punct - Quote '
transpose - Transpose .'
ctranspose - Complex conjugate transpose '
horzcat - Horizontal concatenation [,]
vertcat - Vertical concatenation [;]
subsasgn - Subscripted assignment ( ),{ },.
subsref - Subscripted reference ( ),{ },.
subsindex - Subscript index
metaclass - Metaclass for MATLAB class ?
Bitwise operators.
bitand - Bit-wise AND.
bitcmp - Complement bits.
bitor - Bit-wise OR.
bitmax - Maximum floating point integer.
bitxor - Bit-wise XOR.
bitset - Set bit.
bitget - Get bit.
bitshift - Bit-wise shift.
Set operators.
union - Set union.
unique - Set unique.
intersect - Set intersection.
setdiff - Set difference.
setxor - Set exclusive-or.
ismember - True for set member.
See also arith, relop, slash, function_handle.
<find> - Find indices of nonzero elements.
FIND Find indices of nonzero elements.
I = FIND(X) returns the linear indices corresponding to
the nonzero entries of the array X. X may be a logical expression.
Use IND2SUB(SIZE(X),I) to calculate multiple subscripts from
the linear indices I.
I = FIND(X,K) returns at most the first K indices corresponding to
the nonzero entries of the array X. K must be a positive integer,
but can be of any numeric type.
I = FIND(X,K,'first') is the same as I = FIND(X,K).
I = FIND(X,K,'last') returns at most the last K indices corresponding
to the nonzero entries of the array X.
[I,J] = FIND(X,...) returns the row and column indices instead of
linear indices into X. This syntax is especially useful when working
with sparse matrices. If X is an N-dimensional array where N > 2, then
J is a linear index over the N-1 trailing dimensions of X.
[I,J,V] = FIND(X,...) also returns a vector V containing the values
that correspond to the row and column indices I and J.
Example:
A = magic(3)
find(A > 5)
finds the linear indices of the 4 entries of the matrix A that are
greater than 5.
[rows,cols,vals] = find(speye(5))
finds the row and column indices and nonzero values of the 5-by-5
sparse identity matrix.
See also sparse, ind2sub, relop, nonzeros.
Overloaded methods:
codistributed/find
cgprojconnections/find
coninputfactor/find
sweepsetfilter/find
sweepset/find
cgddnode/find
Reference page in Help browser
doc find
<end> - Last index.
END Terminate scope of FOR, WHILE, SWITCH, TRY, and IF statements.
Without END's, FOR, WHILE, SWITCH, TRY, and IF wait for further input.
Each END is paired with the closest previous unpaired FOR, WHILE,
SWITCH, TRY or IF and serves to terminate its scope.
END also marks the termination of an M-file function, although in
most cases it is optional. END statements are required only in
M-files that employ one or more nested functions. Within such an
M-file, every function (including primary, nested, private, and
subfunctions) must be terminated with an END statement. You can
terminate any function type with END, but doing so is not required
unless the M-file contains a nested function.
END can also serve as the last index in an indexing expression. In
that context, END = SIZE(X,k) when used as part of the k-th index.
Examples of this use are, X(3:end) and X(1,1:2:end-1). When using END
to grow an array, as in X(end+1) = 5, make sure X exists first.
END(A,K,N) is called for indexing expressions involving the object A
when END is part of the K-th index out of N indices. For example,
the expression A(end-1,:) calls A's END method with END(A,1,2).
See also for, while, switch, try, if.
Overloaded methods:
categorical/end
timer/end
serial/end
tscollection/end
instrument/end
gf/end
DynamicSystem/end
daqdevice/end
daqchild/end
distributed/end
codistributed/end
fints/end
idmodel/end
idfrd/end
iddata/end
idnlfunVector/end
imaqdevice/end
imaqchild/end
icgroup/end
xregpointer/end
guidarray/end
designdev/end
coninputfactor/end
xregtable/end
sweepsetfilter/end
sweepset/end
opcroot/end
uss/end
umat/end
ufrd/end
ndlft/end
dataset/end
qrandset/end
Reference page in Help browser
doc end
<sub2ind> - Linear index from multiple subscripts.
SUB2IND Linear index from multiple subscripts.
SUB2IND is used to determine the equivalent single index
corresponding to a given set of subscript values.
IND = SUB2IND(SIZ,I,J) returns the linear index equivalent to the
row and column subscripts in the arrays I and J for a matrix of
size SIZ.
IND = SUB2IND(SIZ,I1,I2,...,IN) returns the linear index
equivalent to the N subscripts in the arrays I1,I2,...,IN for an
array of size SIZ.
I1,I2,...,IN must have the same size, and IND will have the same size
as I1,I2,...,IN. For an array A, if IND = SUB2IND(SIZE(A),I1,...,IN)),
then A(IND(k))=A(I1(k),...,IN(k)) for all k.
Class support for inputs I,J:
float: double, single
See also ind2sub.
Reference page in Help browser
doc sub2ind
<ind2sub> - Multiple subscripts from linear index.
IND2SUB Multiple subscripts from linear index.
IND2SUB is used to determine the equivalent subscript values
corresponding to a given single index into an array.
[I,J] = IND2SUB(SIZ,IND) returns the arrays I and J containing the
equivalent row and column subscripts corresponding to the index
matrix IND for a matrix of size SIZ.
For matrices, [I,J] = IND2SUB(SIZE(A),FIND(A>5)) returns the same
values as [I,J] = FIND(A>5).
[I1,I2,I3,...,In] = IND2SUB(SIZ,IND) returns N subscript arrays
I1,I2,..,In containing the equivalent N-D array subscripts
equivalent to IND for an array of size SIZ.
Class support for input IND:
float: double, single
See also sub2ind, find.
Reference page in Help browser
doc ind2sub
<bsxfun> - Binary singleton expansion function.
BSXFUN Binary Singleton Expansion Function
C = BSXFUN(FUNC,A,B) applies the element-by-element binary operation
specified by the function handle FUNC to arrays A and B, with singleton
expansion enabled. FUNC must be able to accept as input either two column
vectors of the same size, or one column vector and one scalar, and return
as output a column vector of the same size as the input(s). FUNC can
either be a function handle for an arbitrary function satisfying the above
conditions or one of the following built-in functions:
@plus Plus
@minus Minus
@times Array multiply
@rdivide Right array divide
@ldivide Left array divide
@power Array power
@max Binary maximum
@min Binary minimum
@rem Remainder after division
@mod Modulus after division
@atan2 Four-quadrant inverse tangent
@hypot Square root of sum of squares
@eq Equal
@ne Not equal
@lt Less than
@le Less than or equal
@gt Greater than
@ge Greater than or equal
@and Element-wise logical AND
@or Element-wise logical OR
@xor Logical EXCLUSIVE OR
Each dimension of A and B must be equal to each other, or equal to one.
Whenever a dimension of one of A or B is singleton (equal to 1), the array
is virtually replicated along that dimension to match the other array
(or diminished if the corresponding dimension of the other array is 0).
The size of the output array C is equal to
max(size(A),size(B)).*(size(A)>0 & size(B)>0). For example, if
size(A) == [2 5 4] and size(B) == [2 1 4 3], then size(C) == [2 5 4 3].
Examples:
Subtract the column means from the matrix A:
A = magic(5);
A = bsxfun(@minus, A, mean(A));
Scale each row of A by its maximum absolute value:
A = rand(5);
A = bsxfun(@rdivide, A, max(abs(A),[],2));
Compute z(x, y) = x.*sin(y) on a grid:
x = 1:10;
y = x.';
z = bsxfun(@(x, y) x.*sin(y), x, y);
See also repmat, arrayfun
Reference page in Help browser
doc bsxfun
Multi-dimensional array functions.
<ndgrid> - Generate arrays for N-D functions and interpolation.
NDGRID Generation of arrays for N-D functions and interpolation.
[X1,X2,X3,...] = NDGRID(x1,x2,x3,...) transforms the domain
specified by vectors x1,x2,x3, etc. into arrays X1,X2,X3, etc. that
can be used for the evaluation of functions of N variables and N-D
interpolation. The i-th dimension of the output array Xi are copies
of elements of the vector xi.
[X1,X2,...] = NDGRID(x) is the same as [X1,X2,...] = NDGRID(x,x,...).
For example, to evaluate the function x2*exp(-x1^2-x2^2-x^3) over the
range -2 < x1 < 2, -2 < x2 < 2, -2 < x3 < 2,
[x1,x2,x3] = ndgrid(-2:.2:2, -2:.25:2, -2:.16:2);
z = x2 .* exp(-x1.^2 - x2.^2 - x3.^2);
slice(x2,x1,x3,z,[-1.2 .8 2],2,[-2 -.2])
NDGRID is like MESHGRID except that the order of the first two input
arguments are switched (i.e., [X1,X2,X3] = NDGRID(x1,x2,x3) produces
the same result as [X2,X1,X3] = MESHGRID(x2,x1,x3)). Because of
this, NDGRID is better suited to N-D problems that aren't spatially
based, while MESHGRID is better suited to problems in cartesian
space (2-D or 3-D).
See also meshgrid, interpn.
Reference page in Help browser
doc ndgrid
<permute> - Permute array dimensions.
PERMUTE Permute array dimensions.
B = PERMUTE(A,ORDER) rearranges the dimensions of A so that they
are in the order specified by the vector ORDER. The array produced
has the same values as A but the order of the subscripts needed to
access any particular element are rearranged as specified by ORDER.
For an N-D array A, numel(ORDER)>=ndims(A). All the elements of
ORDER must be unique.
PERMUTE and IPERMUTE are a generalization of transpose (.')
for N-D arrays.
Example:
a = rand(1,2,3,4);
size(permute(a,[3 2 1 4])) % now it's 3-by-2-by-1-by-4.
See also ipermute, circshift, size.
Overloaded methods:
categorical/permute
codistributed/permute
uss/permute
umat/permute
ufrd/permute
ndlft/permute
Reference page in Help browser
doc permute
<ipermute> - Inverse permute array dimensions.