diff options
author | Gael Guennebaud <g.gael@free.fr> | 2010-07-11 11:01:17 +0200 |
---|---|---|
committer | Gael Guennebaud <g.gael@free.fr> | 2010-07-11 11:01:17 +0200 |
commit | 19a70ae939911505839358d8e3ba72c51e47b254 (patch) | |
tree | b43a7080654f35e9a1d380e41af66a9cf625993a /doc/examples/Tutorial_ReductionsVisitorsBroadcasting_maxnorm.cpp | |
parent | 850c6d8a2b908869492ed0627c5906f7eee9c81f (diff) |
fix doc compilation on non 32bits systems
Diffstat (limited to 'doc/examples/Tutorial_ReductionsVisitorsBroadcasting_maxnorm.cpp')
-rw-r--r-- | doc/examples/Tutorial_ReductionsVisitorsBroadcasting_maxnorm.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/doc/examples/Tutorial_ReductionsVisitorsBroadcasting_maxnorm.cpp b/doc/examples/Tutorial_ReductionsVisitorsBroadcasting_maxnorm.cpp index cb46887b6..049c747b0 100644 --- a/doc/examples/Tutorial_ReductionsVisitorsBroadcasting_maxnorm.cpp +++ b/doc/examples/Tutorial_ReductionsVisitorsBroadcasting_maxnorm.cpp @@ -2,13 +2,14 @@ #include <Eigen/Dense> using namespace std; +using namespace Eigen; int main() { - Eigen::MatrixXf mat(2,4); + MatrixXf mat(2,4); mat << 1, 2, 6, 9, 3, 1, 7, 2; - int maxIndex; + MatrixXf::Index maxIndex; float maxNorm = mat.colwise().sum().maxCoeff(&maxIndex); std::cout << "Maximum sum at position " << maxIndex << std::endl; |