[CppAD] Some math functions don't seem to be defined for
AD<AD<double>> types
Mitch Watrous
watrous at u.washington.edu
Wed Nov 28 14:23:10 EST 2007
Hi.
When I tried to use the latest version of CppAD, I get the following
error messages:
/usr/local/include/cppad/local/std_math_ad.hpp: In member function
‘CppAD::AD<Base> CppAD::AD<Base>::sqrt() const [with Base =
CppAD::AD<double>]’:
/usr/local/include/cppad/local/std_math_ad.hpp:285: instantiated from
‘CppAD::AD<Base> CppAD::sqrt(const CppAD::AD<Base>&) [with Base =
CppAD::AD<double>]’
/usr/local/include/cppad/local/acos_op.hpp:182: instantiated from
‘void CppAD::ForAcosOp(size_t, Base*, Base*, const Base*) [with Base =
CppAD::AD<CppAD::AD<double> >]’
/usr/local/include/cppad/local/forward_sweep.hpp:301: instantiated
from ‘size_t CppAD::ForwardSweep(bool, size_t, size_t,
CppAD::TapeRec<Base>*, size_t, Base*) [with Base =
CppAD::AD<CppAD::AD<double> >]’
/usr/local/include/cppad/local/fun_construct.hpp:217: instantiated
from ‘CppAD::ADFun<Base>::ADFun(const VectorAD&, const VectorAD&) [with
ADvector = std::vector<CppAD::AD<CppAD::AD<CppAD::AD<double> > >,
std::allocator<CppAD::AD<CppAD::AD<CppAD::AD<double> > > > >, Base =
CppAD::AD<CppAD::AD<double> >]’
IndPredModelBase.cpp:1542: instantiated from ‘void
IndPredModelBase<Scalar>::evalFAndH_theta() const [with Scalar =
CppAD::AD<double>]’
IndPredModelBase.cpp:2878: instantiated from here
/usr/local/include/cppad/local/std_math_ad.hpp:285: error: no matching
function for call to ‘sqrt(const CppAD::AD<double>&)’
/usr/local/include/cppad/local/base_complex.hpp:202: note: candidates
are: std::complex<double> CppAD::sqrt(const std::complex<double>&)
/usr/local/include/cppad/local/base_complex.hpp:327: note:
std::complex<float> CppAD::sqrt(const std::complex<float>&)
/usr/local/include/cppad/std_math_unary.hpp:127: note:
float CppAD::sqrt(const float&)
/usr/local/include/cppad/std_math_unary.hpp:127: note:
double CppAD::sqrt(const double&)
/
Thanks,
Mitch
More information about the CppAD
mailing list