RE: [eigen] no matching function for call to 'abs(const float&)' |
[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]
Hi Adrien,
Thanks for the answer. >It looks like your cmath is not providing an abs function for float. >You can try to define this function (in the std namespace) prior to including Eigen. That doesn't make sense, as std::abs also is defined for floats on <cmath>: http://en.cppreference.com/w/cpp/numeric/math/fabs. > A side note: I don't know what are the exact computations you want to achieve, but there are very few cases in numerical computations where it is necessary to >explicitly compute the inverse of a matrix. >Especially for solving a system Ax=b (and you are most likely solving such a system one way or an other), one never compute the inverse of A because it is expensive >to produce. >Instead in Eigen, you can do A.partialPivLu().solve(b); (or A.colPivHouseholderQR.solve(b); if you are willing to trade speed for robustness).I'll keep that in mind but for now I want to keep it as is. Don't know, but should we use std::fabs() instead? Best, --- +351 912 090 991 Azambuja | Portugal As the creation appears, the path is driven in the conscious feeling of madness and happiness, which returns, in multiple ways, to what we achieve in greatness... Follow me in: This message and any files herewith attached may contain confidential or privileged information and is intended solely for the use of the entity to which it is addressed. If you receive this message in error, please notify the sender immediately and delete this message and any files attached without copying them in any way. Date: Thu, 27 Aug 2015 13:45:12 +0900 Subject: Re: [eigen] no matching function for call to 'abs(const float&)' From: adrien.escande@xxxxxxxxx To: eigen@xxxxxxxxxxxxxxxxxxx It looks like your cmath is not providing an abs function for float. You can try to define this function (in the std namespace) prior to including Eigen.Best, Adrien EscandeOn Thu, Aug 27, 2015 at 12:51 AM, Nuno Marques <n.marques21@xxxxxxxxxxx> wrote:
|
Mail converted by MHonArc 2.6.19+ | http://listengine.tuxfamily.org/ |