Sign in
◑
Theme
eigen
/
mirror
/
ae4d9434e23e62d9403e570c20aeb3b8b44a2dd3
/
.
/
doc
/
snippets
/
MatrixBase_diagonal.cpp
blob: cd63413f37f71b837bccda5508882cc2beefae83 [
file
]
Matrix3i
m
=
Matrix3i
::
Random
();
cout
<<
"Here is the matrix m:"
<<
endl
<<
m
<<
endl
;
cout
<<
"Here are the coefficients on the main diagonal of m:"
<<
endl
<<
m
.
diagonal
()
<<
endl
;