Registered Member
|
Hi,
I want to change the values of matrix based on some logical masking. Is there any efficient way of in-place modification method instead of using unaryexpr and std::for_each individual member access. Say change Identity matrix I to -I by logical condition, if coefficient =1 change to -1. Thanks, |
Moderator
|
The closest is select (mimics C++ ternary operator):
http://eigen.tuxfamily.org/dox/classEig ... 2e40d1ef6e |
Registered users: bartoloni, Bing [Bot], Evergrowing, Google [Bot], ourcraft