Fwd: [eigen] matrix exponential with c++0x

[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]


I am forwarding since I forgot to hit reply all...

I did some more tests. It might be Cygwin specific since e.g. on VC10 all tests build fine.

- Hauke

---------- Forwarded message ----------
From: Hauke Heibel <hauke.heibel@xxxxxxxxxxxxxx>
Date: Mon, Nov 30, 2009 at 1:00 PM
Subject: Re: [eigen] matrix exponential with c++0x
To: Thomas Capricelli <orzel@xxxxxxxxxxxxxxx>


Hi Thomas,

we have a switch in the CMake build system (EIGEN_TEST_C++0X, sets CXX_FLAGS=-std=c++0x) to activate the new c++ standard as it is supportet by e.g. gcc 4.4. I am using that e.g. to work with rvalue references. You can see all kinds of variables when you use 'ccmake ../eigen' (this is no typo) instead of 'cmake ../eigen'.

As I said before, fixing M_LOG2_E is not really an issue. The second error on the other hand side is rather strange.

- Hauke


On Mon, Nov 30, 2009 at 12:38 PM, Thomas Capricelli <orzel@xxxxxxxxxxxxxxxx> wrote:

Hi,

In data lunedì 30 novembre 2009 12:03:21, Hauke Heibel ha scritto:
> I tried to compile the unit tests with c++0x and the matrix exponential stuff failed. I got actually two errors where the first one was trivial to fix though I am not sure anymore whether the fix is correct considering the second error.

what do you mean by 'c++0x' ? did you try gcc improved c++ support from the 4.5 branch ?

> First, M_LOG2_E suddenly was not defined anymore so I added
>
> #if defined(log2) && !defined(M_LOG2_E)
>   #define M_LOG2_E 0.693147180559945309417
> #endif

According to what i've read about gcc-4.5, it is able to compute complex math formulae at compile-time, so that for example "log(e)/log(2)" will be compiled as the floating point that it represents. It was not able to do so before if i understand well. So mabye that's the reason M_LOG2_E is not defined anymore ?

++
Thomas
--
Thomas Capricelli <orzel@xxxxxxxxxxxxxxx>
http://www.freehackers.org/thomas




Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/