Logical Matrix .... Solution
Posted
by Sanju
on Stack Overflow
See other posts from Stack Overflow
or by Sanju
Published on 2010-04-16T04:45:13Z
Indexed on
2010/04/16
7:43 UTC
Read the original article
Hit count: 274
matrix
|language-agnostic
Suppose you have an NxN matrix and you have to check whether it's a upper diagonal matrix or not. Is there any generic method to solve this problem?
I am elaborating my question: Some thing is like this: Suppose you have NXN matrix having the value of N=4 then matrix will look like this:
|5 6 9 2|
|1 8 4 9|
|5 8 1 6|
|7 6 3 2|
Its a 4X4 square matrix and again if it's upper triangle matrix it will look something like this:
|5 6 9 2|
|1 8 4 0|
|5 8 0 0|
|7 0 0 0|
I need to generate a generic program in any language to check wether a square matrix is upper trailgle or not.
© Stack Overflow or respective owner