Professional Documents
Culture Documents
MATLAB stands for Matrix Laboratory MATLAB had many functions and toolboxes to help in various applications MATLAB is very extendable. There are many add-ons (toolboxes) for specific requirements. It allows to solve many technical computing problems, especially those with matrix and vector formulas.
DESKTOP TOOLS
Command Window -type commands Workspace -view program variables -clear to clear -double click on a variable to see it in the array editor Command History -view past commands -save a whole session using dairy Launch Pad -access tools, demos and documentation
MATLAB HELP
Can browse or search product help for a specific function or topic MATLAB help has introductory help material, basic overviews of how to use functions, plot program in MATLAB, example code, etc. lookfor keyword command also find functions that have the keyword with them doc fuction_name brings up the full documentation for the function
MATLAB OPERATORS
Arithmetic operators Relational operators Logical operators Special characters Bitwise operators Set operators
ARITHMETIC OPERATORS
Plus Minus Matrix multiply Matrix power Backslash or left matrix divide Slash or right matrix divide Element-by-element multiplication Element-by-element division Left array divide Right array divide Element-by-element power + * ^ \ / .* .\ ./ .^
RELATIONAL OPERATORS
Equal Not equal Less than Greater than Less than or equal Greater than or equal == ~= < > <= >=
LOGICAL OPERATORS
Short-circuit logical AND Short-circuit logical OR Element-wise logical AND Element-wise logical OR Logical NOT Logical EXCLUSIVE OR True if any element of vector is nonzero True if all elements of vector are nonzero && || & | ~ xor any all
SPECIAL CHARACTERS
Colon Parentheses and subscripting Brackets Braces and subscripting Decimal point Structure field access Continuation Separator Semicolon Comment Invoke operating system command Assignment Quote Transpose Complex conjugate transpose Horizontal concatenation Vertical concatenation : () [] {} . . ... , ; % ! = ' . ' [,] [;]
MATLAB FUNCTIONS
diag sum mean max min median cov std var sort det inv dot cross linspace logspace Diagonal matrices and diagonals of a matrix Sum of elements Average or mean value Largest component Smallest component Median value Covariance matrix Standard deviation Variance Sort in ascending or descending order Determinant Matrix inverse Vector dot product Vector cross product Linearly spaced vector Logarithmically spaced vector
CONTROL FUNCTIONS
Condition Control If, else, elseif Switch, case Loop Control For, while, continue, break Error Control Try, catch Program Termination return
ELEMENTARY FUNCTION
sin Sine asin, sind Cosine acos, cosd Square root sqrtm Absolute value sign, angle, unwrap Exponential expm1, log, log10, expm, exprint Common (base 10) logarithm log, log2, exp, logm Round towards nearest integer floor, ceil, fix
cos
sqrt
abs
exp
log10
round
pascal(m)