blob: 7086e01e2ca9852f7db951978c3671e1afc3eee6 [file] [log] [blame]
Benoit Jacobf04c1cb2008-08-11 21:26:37 +00001MatrixXf m = MatrixXf::Random(3,5);
2cout << "Here is the matrix m:" << endl << m << endl;
Benoit Jacobe4e58e82009-11-08 16:51:41 -05003MatrixXf ker = m.fullPivLu().kernel();
Benoit Jacobf04c1cb2008-08-11 21:26:37 +00004cout << "Here is a matrix whose columns form a basis of the kernel of m:"
5 << endl << ker << endl;
6cout << "By definition of the kernel, m*ker is zero:"
7 << endl << m*ker << endl;