source: pacpussensors/trunk/Vislab/lib3dv/eigen/doc/snippets/Tridiagonalization_compute.cpp@ 136

Last change on this file since 136 was 136, checked in by ldecherf, 7 years ago

Doc

File size: 392 bytes
Line 
1Tridiagonalization<MatrixXf> tri;
2MatrixXf X = MatrixXf::Random(4,4);
3MatrixXf A = X + X.transpose();
4tri.compute(A);
5cout << "The matrix T in the tridiagonal decomposition of A is: " << endl;
6cout << tri.matrixT() << endl;
7tri.compute(2*A); // re-use tri to compute eigenvalues of 2A
8cout << "The matrix T in the tridiagonal decomposition of 2A is: " << endl;
9cout << tri.matrixT() << endl;
Note: See TracBrowser for help on using the repository browser.