a couple of improvements in the Autodiff module

This commit is contained in:
Gael Guennebaud
2010-01-05 16:04:05 +01:00
parent c3823dce72
commit 801e601ff1
2 changed files with 208 additions and 46 deletions

View File

@@ -31,7 +31,7 @@ EIGEN_DONT_INLINE Scalar foo(const Scalar& x, const Scalar& y)
// return x+std::sin(y);
EIGEN_ASM_COMMENT("mybegin");
return static_cast<Scalar>(x*2 - std::pow(x,2) + 2*std::sqrt(y*y) - 4 * std::sin(x) + 2 * std::cos(y) - std::exp(-0.5*x*x));
// return x - y;//x*2 -std::pow(x,2);//(2*y/x);// - y*2;
//return x+2*y*x;//x*2 -std::pow(x,2);//(2*y/x);// - y*2;
EIGEN_ASM_COMMENT("myend");
}