xref: /aosp_15_r20/external/eigen/doc/snippets/Matrix_resize_int.cpp (revision bf2c37156dfe67e5dfebd6d394bad8b2ab5804d4)
1 VectorXd v(10);
2 v.resize(3);
3 RowVector3d w;
4 w.resize(3); // this is legal, but has no effect
5 cout << "v: " << v.rows() << " rows, " << v.cols() << " cols" << endl;
6 cout << "w: " << w.rows() << " rows, " << w.cols() << " cols" << endl;
7