diff options
Diffstat (limited to 'doc/snippets/MatrixBase_template_int.cpp')
-rw-r--r-- | doc/snippets/MatrixBase_template_int.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/doc/snippets/MatrixBase_template_int.cpp b/doc/snippets/MatrixBase_template_int.cpp new file mode 100644 index 000000000..4041a2214 --- /dev/null +++ b/doc/snippets/MatrixBase_template_int.cpp @@ -0,0 +1,5 @@ +RowVector5i v = RowVector5i::Random(); +cout << "Here is the vector v:" << endl << v << endl; +cout << "Here is v.block<2>(1):" << endl << v.start<2>() << endl; +v.block<2>(2).setZero(); +cout << "Now the vector v is:" << endl << v << endl; |