Creating a vector from the diagonal values of a square matrix
33 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Kourosh
am 30 Jul. 2014
Beantwortet: Ahmet Cecen
am 30 Jul. 2014
Hello,
Does anybody know how I can read the diagonal values of a square matrix and create a vector (1:n) from those values?
Cheers,
Cyrus
0 Kommentare
Akzeptierte Antwort
Ahmet Cecen
am 30 Jul. 2014
vector=diag(matrix);
check help diag for more detailed information.
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Operating on Diagonal Matrices finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!