eigen/doc/snippets/MatrixBase_inverse.cpp
Benoit Jacob 486fdb26a1 many small fixes and documentation improvements,
this should be alpha5.
2008-05-29 03:12:30 +00:00

8 lines
271 B
C++

Matrix2d m = Matrix2d::random();
cout << "Here is the matrix m:" << endl << m << endl;
Matrix2d::InverseType m_inv = m.inverse();
if(m_inv.exists())
cout << "m is invertible, and its inverse is:" << endl << m_inv << endl;
else
cout << "m is not invertible." << endl;