Registered Member
|
Hi all
Maybe it is somewhere in the documentations but I havent been able to find it. Is there a simple way to access/assigning to substructure similar to the expression
Similar to matlabs
Thanks, Leon |
Registered Member
|
further digging into the forum, it seems that there is not simple way to perform the action above.
Just for reference, IT++ seems to provide something along this line and it is also a template matrix library. http://itpp.sourceforge.net/current/users_guide.html |
Registered Member
|
Seems like what you're after is select().
http://eigen.tuxfamily.org/dox/classEig ... 24a4884807 search this forum for usage examples.
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
|
Your answer has always been very helpful. Thank you very much for your time. Select() does some of what I need but I ultimately wants to have the reference to the SUB-matrix based on the bool vec. This might be difficult in c++ because the size of the resulting matrix is only known at run-time and the pattern of boolean vector is not determined at compile-time. Something like
|
Registered Member
|
Sorry, you have to construct that by hand with a for loop. The good news is that this isn't going to be slower than anything we could do within Eigen (e.g. this is not vectorizable anyway).
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
|
Fair enough. Thanks! |
Registered users: abc72656, Bing [Bot], daret, Google [Bot], Sogou [Bot], Yahoo [Bot]