Linear Algebra Commands In MatLab(Illustrated Expression)

In this content of Mechanical Base, we will show som kinds of Linear Algebra commands in Matlab that will make your linear algebra calculations in Matlab very easy. It is very important to know these commands in Matlab coding to do advanced calculations in Matlab again.

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

Basic Linear Algebraic Commands In Matlab

The use of basic commands in Matlab suc as inv(a).

inv(a): Taking inverse of the matrix a in Matlab.

a’ : Taking tranpose of the a matrix in Matlab.

det(a): Calculation of determinant of matrix a in Matlab.

a+b: Addition of same dimension a and b matrices in Matlab.

a-b: Subtraction of same dimension a and b matrices in Matlab.

a*b: Multiplication of same dimension a and b matrices in Matlab.

a/b : If b is a regular square matrix(determinant of this matrix is different from zero), makes a*inv(b) calculation with same dimensioned b.

a.*b: The elements of matrix a and matrix b will be multiplied respectively around them.

a./b: The elements of matrix a and matrix b will be divided respectively around them.

trace(a): Diagonal elements of a matrix will be added in Matlab.

diag(a): A row vector will be created with diagonal elements of a matrix. Or if “a” is a vector, a matrix that includes diagonal elements of “a” vector will be created in Matlab.

sum(a): Whole rows of metrix a will be added. If “a” is a vector, the result will be the addition of vector a elements.

triu(a): The upper triangle matrix of a matrix will be created in Matlab.

tril(a): The lower triangle matrix of a matrix will be created in Matlab.

Share This Post! Share Tweet Share

Write your comment on this topic.