Registered Member
|
Hi all,
I want to cast an Eigen::MatrixXi (containing ints) to a matrix containing doubles. When I do
Although the error is quite verbose (kudos to the devs, it's generally helpful), I can't solve it. I tried
So how can I use an integer matrix as if it contained doubles? |
Registered Member
|
This error means that you are using this matrix in a larger expressions that expects a different type. Just the snippet you showed here is not enough to help you --- the problem is not there. Can you please make a compilable test case?
Join us on Eigen's IRC channel: #eigen on irc.freenode.net
Have a serious interest in Eigen? Then join the mailing list! |
Registered Member
|
Thank you! You are right, the problem is not where I thought it would be.
Now I have to check, where the problem lies. Should I be unable to solve it, I'll post back. EDIT I found the error: A matrix that should've been MatrixXd was of type MatrixXi. Whoops. Sorry for the noise... |
Registered users: Bing [Bot], blue_bullet, Google [Bot], rockscient, Yahoo [Bot]