You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
282 B
15 lines
282 B
#include <Eigen/Core>
|
|
#include <iostream>
|
|
|
|
using namespace Eigen;
|
|
using namespace std;
|
|
|
|
int main(void)
|
|
{
|
|
int const N = 5;
|
|
MatrixXi A(N,N);
|
|
A.setRandom();
|
|
cout << "A =\n" << A << '\n' << endl;
|
|
cout << "A(2..3,:) =\n" << A.middleRows(2,2) << endl;
|
|
return 0;
|
|
}
|