blob: ff6746e21861f2e25d590e5865ca4260e73dfcb0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
#include <iostream>
#include <Eigen/Dense>
using namespace Eigen;
using namespace std;
int main()
{
MatrixXd m = MatrixXd::Random(3,3);
m = (m + MatrixXd::Constant(3,3,1.2)) * 50;
cout << "m =" << endl << m << endl;
VectorXd v(3);
v << 1, 2, 3;
cout << "m * v =" << endl << m * v << endl;
}
|