eigen/doc/snippets/MatrixBase_template_int_end.cpp
Gael Guennebaud c10f069b6b * Merge Extract and Part to the Part expression.
Renamed "MatrixBase::extract() const" to "MatrixBase::part() const"
* Renamed static functions identity, zero, ones, random with an upper case
  first letter: Identity, Zero, Ones and Random.
2008-07-21 00:34:46 +00:00

6 lines
227 B
C++

RowVector4i v = RowVector4i::Random();
cout << "Here is the vector v:" << endl << v << endl;
cout << "Here is v.end(2):" << endl << v.end<2>() << endl;
v.end<2>().setZero();
cout << "Now the vector v is:" << endl << v << endl;