This bugzilla service is closed. All entries have been migrated to

Bug 1760

Summary: Support for products of double and {Eigen type}<adtl::adouble>
Product: Eigen Reporter: Ose Pedro <osemwaro.pedro>
Component: Core - expression templatesAssignee: Nobody <eigen.nobody>
Status: NEW ---    
Severity: Unknown CC: chtz, gael.guennebaud, jacob.benoit.1
Priority: Normal    
Version: 3.3 (current stable)   
Hardware: All   
OS: All   
Description Flags
Minimal failing example none

Description Ose Pedro 2019-10-15 12:48:57 UTC
Created attachment 956 [details]
Minimal failing example

In the test.cpp file in the attachment, I have followed your explanation here about how to add support for Adolc's adtl::adouble type: . The code compiles under the version of Eigen that comes with Ubuntu 16.04 (dpkg calls this version 3.3~beta1-2), but when I compile it under Eigen 3.3.7, the fact that I have multiplied a double with an Eigen::Matrix<adtl::adouble,2,1> causes compiler errors. I first noticed this issue in Eigen 3.3.4 (the version that comes with Ubuntu 18.04). But if you replace adtl::adouble with std::complex<double>, it compiles in all three versions of Eigen. The attachment contains the GCC errors that occur under Eigen 3.3.4 and 3.3.7.

Adolc provides the following overload of the * operator:

adouble operator * (const double v, const adouble& a) 

Do I need to specialise some additional class templates to allow Eigen to determine the return type? 

P.S.: I know I can work around the issue by constructing an adtl::adouble from the double.
P.P.S.: I'm using AdolC 2.4.1, but I don't think this is relevant to the issue.
Comment 1 Nobody 2019-12-04 18:50:42 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: