Matlab review

Matlab is just two years ago (junior) contact time courses (remote sensing image processing, quantitative geography ......) involves a simple problem of mathematical modeling. Matlab those experienced developer may seem a bit marginalized, and while it can do to develop, to OOP, and even do GUI, but it is now called "Matrix Laboratory (Matrix Laboratory)", it is obvious it is born of mathematical calculations, if R is the vector features that Matlab is surely a matrix. Recently also preparing his first modeling contest, so brush up on the basics of it. (This article take only the most basic summary, do not do in-depth)

(1) Common Operation

doc XXX% XXX view documents (help) 
the Clear; CLC; the Save; the Load; whos% do not go into details 
Ctrl + R (T)% comment / uncomment
...% continuation lines
;% & punctuation does not show results

(2) Numerical Methods

+ -% Modified 
* / \% ^ matrix by, in addition to the right, left division, exponentiation
... * ./ \% ^ by the array, in addition to the right, left division, exponentiation
. '% Transpose of a matrix

& | ~ xor% aND, oR, NOT, XOR, or
any% non-zero elements of
all% are all non-zero elements

sum; mean; std; var% summing; average; standard deviation; variance
median; sort; sortrows% in digits; sorting by columns; row ordered

(3) Input Output

Input input% 
disp% output 
fprintf% formatted output     
num2str; str2num% conversion between strings and numerical

(4) matrix

eye; ones; zeros; rand; randn% matrix; a matrix; 0 matrix; uniformly distributed random; Normal Random 
linspace; logspace% aliquot linear vector; logarithmic aliquot vector 
det; inv; rank; trace; eig % determinant; inversion; rank; trace; eigenvalues and eigenvectors
length; size; ndims% length; size; dimension

(5) Drawing

plot% basic mapping 
plot3; mesh; surf% dimensional mapping; 3D grid; 3-D surface 
axis% coordinate axis setting 
grid% grid 
hold% retention 
title% title 
xlabel; ylabel% coordinate axis name 
legend% legend 
text% text 
plotyy % bis ordinate 
a hist histogram%

  

Guess you like

Origin www.cnblogs.com/maoerbao/p/11521341.html