Compile error using Eigen 3 in Diamondback (Inverse Matrix)
Hi,
I'm working on writing a FastSLAM 2.0 implementation to use with our system. I have the line of code:
Eigen::Matrix3d sigma_x = (G_v[current_feature].transpose() * (Z[current_feature].inverse() * G_v[current_feature])) + motion_noise_.inverse();
G_v[current_feature] is a 2x3 matrix, Eigen::Matrix<double,2,3>
Z[current_feature] is a 2x2 matrix, Eigen::Matrix2d
motion_noise_ is a 3x3 matrix, Eigen::Matrix3d
So it becomes sigma_x = (3x2) * ((2x2) * (2x3)) + (3x3)
When I try to compile this I get the following error:
/home/msands/ros/smart_wheelchair/chair_SLAM/src/chair_SLAM.cpp:209: error: invalid use of incomplete type ‘const struct Eigen::internal::inverse_impl<eigen::matrix<double, 2,="" 2,="" 0,="" 2,="" 2=""> >’ /home/msands/ros/geometry/eigen/include/Eigen/src/Core/util/ForwardDeclarations.h:233: error: declaration of ‘const struct Eigen::internal::inverse_impl<eigen::matrix<double, 2,="" 2,="" 0,="" 2,="" 2=""> >’
It has something to do with the calling of inverse() but I can't figure out what it is. Anyone have any thoughts?
-Mike