Square matrices, MATLAB in Engineering

Square Matrices:

If a matrix has similar number of rows and columns, for illustration, if m == n, the matrix is square matrix. The definitions which follow in this part apply only to the square matrices.

The main diagonal of a square matrix is the set of terms aii for which the row and column indices are similar, for illustration, from the upper left element to the lower right. For illustration, for the matrix below it is the set of numbers 1, 6, 11, & 16.

1636_Square Matrices.png

This is sometimes just called the diagonal. The MATLAB has a function diag which will return the diagonal of a matrix as a column vector.

>> mymat = reshape(1:16,4,4)'

mymat =

 1    2    3    4

 5    6    7    8

 9   10    11   12

13   14   15   16

>> diag(mymat)'

ans =

1   6   11   16

Posted Date: 10/22/2012 2:27:34 AM | Location : United States







Related Discussions:- Square matrices, Assignment Help, Ask Question on Square matrices, Get Answer, Expert's Help, Square matrices Discussions

Write discussion on Square matrices
Your posts are moderated
Related Questions
Sound Files: The sound signal is an illustration of a continuous signal which is sampled to result in a discrete signal. In this situation, sound waves traveling through the a

Displaying expressions: The good-looking function will show such expressions by using exponents; for illustration, >> b = sym('x^2') b = x^2 >> pretty(b)

Replacing a string - function strrep: The function strrep finds all the occurrences of a substring within the string, and substitutes them with a new substring. The order of a

Function used in sound files: The MATLAB has numerous other functions which let you read and play sound or audio files. In the audio files, sampled data for each audio channel

Function cellplot - Cell array: The function cellplot place a graphical display of the cell array in a figure Window; though, it is a high-level view and fundamentally just di

Illustration of Image processing: This displays that there are 64 rows, or in another word, 64 colors, in this specific colormap. It also displays that the first five colors a

IS Functions for Strings: There are many functions for strings, that return logical true or false. The function isletter returns the logical true when the character is a lette

readlenwid function: function call: [length, width] = readlenwid; function header: function [l,w] = readlenwid In the function call, not any argument is passed; henc

Illustration of Preallocating a Vector: Illustration of calling the function: >> myveccumsum([5 9 4]) ans =     5  14  18 At the first time in the loop, outvec wil

Function fieldnames - structure functions: The function fieldnames will return the names of the fields which are contained in the structure variable. >> pack_fields = fiel