Line | |
---|
1 | #include <Eigen/Dense>
|
---|
2 | #include <iostream>
|
---|
3 |
|
---|
4 | using namespace Eigen;
|
---|
5 | using namespace std;
|
---|
6 |
|
---|
7 | int main(int, char**)
|
---|
8 | {
|
---|
9 | cout.precision(3);
|
---|
10 | RowVectorXd vec1(3);
|
---|
11 | vec1 << 1, 2, 3;
|
---|
12 | std::cout << "vec1 = " << vec1 << std::endl;
|
---|
13 |
|
---|
14 | RowVectorXd vec2(4);
|
---|
15 | vec2 << 1, 4, 9, 16;;
|
---|
16 | std::cout << "vec2 = " << vec2 << std::endl;
|
---|
17 |
|
---|
18 | RowVectorXd joined(7);
|
---|
19 | joined << vec1, vec2;
|
---|
20 | std::cout << "joined = " << joined << std::endl;
|
---|
21 |
|
---|
22 | return 0;
|
---|
23 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.