2010-06-17 12:12:40 +01:00
|
|
|
#include <iostream>
|
|
|
|
|
#include <Eigen/Dense>
|
|
|
|
|
|
2010-06-27 19:37:16 +02:00
|
|
|
using namespace Eigen;
|
|
|
|
|
using namespace std;
|
2010-06-17 12:12:40 +01:00
|
|
|
|
2010-06-25 10:04:10 -04:00
|
|
|
int main()
|
2010-06-17 12:12:40 +01:00
|
|
|
{
|
2012-08-17 14:49:18 +01:00
|
|
|
MatrixXd m = MatrixXd::Random(3,3);
|
|
|
|
|
m = (m + MatrixXd::Constant(3,3,1.2)) * 50;
|
2010-06-27 19:37:16 +02:00
|
|
|
cout << "m =" << endl << m << endl;
|
2012-08-17 14:49:18 +01:00
|
|
|
VectorXd v(3);
|
2010-06-27 19:37:16 +02:00
|
|
|
v << 1, 2, 3;
|
|
|
|
|
cout << "m * v =" << endl << m * v << endl;
|
2010-06-17 12:12:40 +01:00
|
|
|
}
|