📄 help.op
字号:
op = op :=X = YX := Y Assigns Y to X and returns X. X must be a variable name, a subsection of a matrix (submatrix), or the result of a function call returning a global variable. If X is a submatrix then the dimensions of Y must match the dimensions of X.op || op orm || nm or n If m evaluates to true (non-zero) then one is returned. Otherwise, n is evaluated and if n is false then zero is returned. If n is true (non-zero) then one is returned. Both m and n must be scalars.op && op andm && nm and n If m evaluates to false (zero) then zero is returned. Otherwise, n is evaluated and if n is false then zero is returned. If n is true (non-zero) then one is returned. Both m and n must be scalars.op ==X == Y Compares each element of X against each element of Y and sets the corresponding element of the result to one if X is equal to Y, and zero otherwise. If both X and Y are matrices then their dimensions must match.op != op <>X != YX <> Y Compares each element of X against each element of Y and sets the corresponding element of the result to one if X is not equal to Y, and zero otherwise. If both X and Y are matrices then their dimensions must match.op <X < Y Compares each element of X against each element of Y and sets the corresponding element of the result to one if X is less than to Y, and zero otherwise. If both X and Y are matrices then their dimensions must match.op >X > Y Compares each element of X against each element of Y and sets the corresponding element of the result to one if X is greater than Y, and zero otherwise. If both X and Y are matrices then their dimensions must match.op <=X <= Y Compares each element of X against each element of Y and sets the corresponding element of the result to one if X is less than or equal to Y, and zero otherwise. If both X and Y are matrices then their dimensions must match.op >=X >= Y Compares each element of X against each element of Y and sets the corresponding element of the result to one if X is greater than or equal to Y, and zero otherwise. If both X and Y are matrices then their dimensions must match.op :m : nm : k : n Returns a row vector starting with values m through n. If k is given then it is used as the increment between successive values. Otherwise, the increment is one.op ++ XX + Y In the unary form, returns X. In the binary form, returns the sum of X and Y. If X and Y are both scalars then scalar addition is performed. If one is a scalar and the other is a matrix then the scalar value is added to each element of the matrix. If both are matrices then matrix addition is performed, and the dimensions of each must agree.op -- XX - Y In the unary form, returns the negative of X. In the binary form, returns the difference of X and Y. If X and Y are both scalars then subtraction is performed. If X is a matrix and Y is a scalar then Y is subtracted from each element of X. If X is a scalar and Y is a matrix then each element of X is subtracted from Y. If both are matrices then matrix subtraction is performed, and the dimensions of each must agree.op *X * Y Returns the product of X and Y. If X and Y are both scalars then scalar multiplication is performed. If one is a scalar and the other is a matrix then the matrix is scaled by the scalar value. If both are matrices then the matrix multiplication is performed, and the inner dimensions must agree.op \X \ Y Returns the "left division" of X and Y, or (1/X) * Y. If X and Y are matrices then an LU decomposition is used to compute the "inverse" of X. If X is a matrix but Y is a scalar then the true inverse of X is scaled by Y.op /X / Y Returns the "right division" of X and Y, or X * (1/Y). If X and Y are matrices then an LU decomposition (along with transposition) is used to compute the "inverse" of Y. If X is a scalar but Y is a matrix then the true inverse of Y is scaled by X.op % func fmodX % Yfmod (X, Y) Returns the modulo of X and Y. If X and Y are both scalars then the scalar remainder is computed. If X is a matrix and Y is a scalar then each element of X is computed modulo Y. If X is a scalar and Y is a matrix then X is computed modulo each element of Y. If both are matrices then each element of X is computed modulo each element of Y, and the dimensions of each must agree.op ^ op ** func powm ^ nm ** npow (m, n) Returns m raised to the power n, where m is non-negative or n is an integer value. Both m and n must be scalars.op 'X ' Returns the transpose of X. The transpose of a scalar is itself.op ! op not! Xnot X Returns the logical negation of X. If X is a matrix then each element of X is negated. The logical negation of zero is one and the logical negation of a non-zero value is zero.op ( op ) op ()( X )X ( ... ) In the first form, which may be used for enforcing precedence, the result is X. In the second form, if X is a matrix then the result is a subsection of the matrix (submatrix). The number of indices must be appropriate. If an index is a vector then it designates a series of rows or columns and must be contiguous. The special index : may be used to designate an entire row or column. If X is an array then the return value is the result of indexing the array. Otherwise, X is evaluated as a function and the remaining expressions are passed as arguments. The result is the return value of the function call.op [ op ] op [][ ... ; ... ; ... ] Returns a matrix. A semicolon (or return) separates one row for the next. Matrix elements on the same row are separated with commas. The matrix elements may be matrices or scalars, but all elements on the same row must have the same number of rows. Each row must also have the same number of columns.op .X . id Returns the field id of structure X. This operator is used to access members of the FElt data structures.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -