how to change what is under the diagonals in a matrix into Zeros

3 visualizaciones (últimos 30 días)
Brian Nuttall
Brian Nuttall el 31 de Mzo. de 2015
Respondida: Matt J el 31 de Mzo. de 2015
how do i turn what is under the diagonal on a matrix into zeros. for example i cant figure out how to do the following.
[1 2 3,4 5 6,7 8 9]
into
[1 2 3,0 5 6,0 0 9]

Respuestas (1)

Matt J
Matt J el 31 de Mzo. de 2015
See the TRIU command.

Categorías

Más información sobre Operating on Diagonal Matrices en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by