threed-beam-fea/ext/eigen-3.2.7/doc/snippets/Map_outer_stride.cpp

4 lines
138 B
C++
Raw Normal View History

2015-11-05 19:36:26 +01:00
int array[12];
for(int i = 0; i < 12; ++i) array[i] = i;
cout << Map<MatrixXi, 0, OuterStride<> >(array, 3, 3, OuterStride<>(4)) << endl;