Registered Member
|
I'm porting MATLAB code into C++, but I have a problem.
In the MATLAB source, there is a statement like this. C=atan2(-A,B) where A and B are matrices. How can I write this in C++ using Eigen? |
Moderator
|
indeed, we don't offer an atan2 method yet. You can still do:
using std::atan2; -A.binaryExpr(B, std::ptr_fun(atan2)) |
Registered Member
|
Oh... Thanks.
I didn't notice binaryExpr function. It worked. |
Registered users: Bing [Bot], claydoh, Google [Bot], rblackwell, Yahoo [Bot]