diff options
author | Gael Guennebaud <g.gael@free.fr> | 2016-04-05 14:49:41 +0200 |
---|---|---|
committer | Gael Guennebaud <g.gael@free.fr> | 2016-04-05 14:49:41 +0200 |
commit | 4d7e230d2f8a55c45c1191fe08aa19d41e869a65 (patch) | |
tree | 5a7b2ba3f9a2355721612df6dbb04f708ab0d8ec /unsupported/test/autodiff.cpp | |
parent | 158fea0f5e15e4611c36ce73f582c484deeace1a (diff) |
bug #1189: fix pow/atan2 compilation for AutoDiffScalar
Diffstat (limited to 'unsupported/test/autodiff.cpp')
-rw-r--r-- | unsupported/test/autodiff.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/unsupported/test/autodiff.cpp b/unsupported/test/autodiff.cpp index 1aa1b3d2d..374f86df9 100644 --- a/unsupported/test/autodiff.cpp +++ b/unsupported/test/autodiff.cpp @@ -16,7 +16,7 @@ EIGEN_DONT_INLINE Scalar foo(const Scalar& x, const Scalar& y) using namespace std; // return x+std::sin(y); EIGEN_ASM_COMMENT("mybegin"); - return static_cast<Scalar>(x*2 - pow(x,2) + 2*sqrt(y*y) - 4 * sin(x) + 2 * cos(y) - exp(-0.5*x*x)); + return static_cast<Scalar>(x*2 - 1 + pow(1+x,2) + 2*sqrt(y*y+0) - 4 * sin(0+x) + 2 * cos(y+0) - exp(-0.5*x*x+0)); //return x+2*y*x;//x*2 -std::pow(x,2);//(2*y/x);// - y*2; EIGEN_ASM_COMMENT("myend"); } |