diff options
Diffstat (limited to 'eigen/doc/snippets/MatrixBase_end_int.cpp')
-rw-r--r-- | eigen/doc/snippets/MatrixBase_end_int.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/eigen/doc/snippets/MatrixBase_end_int.cpp b/eigen/doc/snippets/MatrixBase_end_int.cpp new file mode 100644 index 0000000..03c54a9 --- /dev/null +++ b/eigen/doc/snippets/MatrixBase_end_int.cpp @@ -0,0 +1,5 @@ +RowVector4i v = RowVector4i::Random(); +cout << "Here is the vector v:" << endl << v << endl; +cout << "Here is v.tail(2):" << endl << v.tail(2) << endl; +v.tail(2).setZero(); +cout << "Now the vector v is:" << endl << v << endl; |