Registered Member
|
Hi, I'm totally newbie in eigen but I'm trying to convert the following Matlab code to C++ using Eigen.
Note that T is a sparse Matrix. I manage to make this:
T still a SparseMatrix. The code above is not the "complete" code, and the compiler pukes tons of lines of errors, I guess its the Sparse*MatrixXf is the main problem... any ideas? Thanks in Advance! |
Moderator
|
could you show how the variables are declared, and the first errors.
|
Registered Member
|
T and R are already filled when the plan method is called. The full code is available in: https://github.com/flaviotruzzi/MDP-in-C-- There are 342 lines of debug errors... The first error is:
|
Registered Member
|
I read in the forums that I should not mix floats and doubles (viewtopic.php?f=74&t=107124), I changed all the MaxtrixXf to MatrixXd, and tryed to use SparseMatrix<double>(S,1) instead of SparseVector<double>(S).
I could make it work! Thanks anyway, and thanks the other people on the forum! |
Registered users: Baidu [Spider], Bing [Bot], Google [Bot], Yahoo [Bot]