# Matrix Operators In MatLab(Illustrated Expression)

In this article of Mechanical Base you will find various matrix operators that you can manage the matrix elements in Matlab according to your requirements. If you know the below operatör rules in Matlab coding, it will be vital in your advanced mathematical coding Matlab in future.

YOU CAN LEARN MatLab IN MECHANICAL BASE; Click And Start To Learn MatLab!

### Matrix Operators And Their Descriptions In Matlab

a(:); This code creates a vector that includes succesively aligned row of “a” matrix elements.

a(:,i); The “j” row of matrix “a” will be indexed in Matlab.

a(j,:); The “j” column of matrix “a” will be indexed in Matlab.

a(:,[i j]); The “j” and “i” rows of matrix “a” will be indexed in Matlab.

a([i j],:); The “j” and “i” columns of matrix “a” will be indexed in Matlab.

e=a:b:n; An “e” matrix that will be created that has (a, a+b, a+2b,…,n) elements.

length(a); The row number of matrix “a” will be indexed.

[m,n]=size(a); The row and column number of matrix “a” will be indexed to “m” and “n” variables.

max(a); The biggest element of matrix “a” will be indexed in Matlab.

min(a); The smallest element of matrix “a” will be indexed in Matlab.

[m,i]=max(a); It indexes the biggest element a column vector “a” to “m”, and indexes its row number to “i” in Matlab.

[m,i]=min(a); It indexes the smallest element a column vector “a” to “m”, and indexes its row number to “i” in Matlab.

sort(a); The elements of matrix “a” will be sorted from biggest to smallest.

a(:,i)=[]; It will delete the “i” column of matrix “a”.

a(i,:)=[]; It will delete the “i” row of matrix “a”.