help-gsl
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-gsl] eigen test fails on 32-bit (x86) Linux


From: address@hidden
Subject: Re: [Help-gsl] eigen test fails on 32-bit (x86) Linux
Date: Mon, 18 Aug 2014 14:48:03 -0700

Thanks for quick responses guys.

Patrick, please find attached the patch that implements your suggestion
which does fix the test failures. I've
reused GSL_EIGEN_SORT_VAL_{ASC,DESC}, that were previously unused for
complex numbers, for the new type of comparison.

Victor


On Mon, Aug 18, 2014 at 12:21 PM, Patrick Alken <address@hidden>
wrote:

> GSL is already sorting the eigenvalues based on magnitude, so the problem
> seems to be that with the extra -O3 optimization, the gsl_eigen_gen and
> gsl_eigen_genv routines are producing slightly different results, leading
> to a different sorting order. One way to fix this would be to sort by real
> part first and then by imaginary part, but it may be a little while until I
> can look into this further.
>
> Patrick
>
>
> On 08/18/2014 12:59 PM, Martin Jansche wrote:
>
>> I'm not sure if GSL makes any guarantees about the direction of
>> eigenvectors. It looks like the test might pass if one only looks at the
>> magnitude of the values. Perhaps the test could be made robust against
>> sign
>> changes by looking at absolute values.
>>
>>
>>
>> On Mon, Aug 18, 2014 at 1:53 PM, address@hidden <
>> address@hidden> wrote:
>>
>>  Hello,
>>>
>>> I noticed that eigen test fails on 32-bit Linux (x86) when compiled with
>>> -O3 flag:
>>>
>>> $ ./configure CFLAGS="-O3"
>>> $ make
>>> $ eigen/test
>>> FAIL: gen, direct eigenvalue(4) imag, random (-0.481216772353650846
>>> observed vs 0.481216772353650846 expected) [877968]
>>> FAIL: gen, direct eigenvalue(5) imag, random (0.481216772353650901
>>> observed
>>> vs -0.481216772353650846 expected) [877970]
>>> FAIL: gen, direct eigenvalue(15) imag, random (6.85872455924790447
>>> observed
>>> vs -6.85872455924790536 expected) [877990]
>>> FAIL: gen, direct eigenvalue(16) imag, random (-6.85872455924790536
>>> observed vs 6.85872455924790625 expected) [877992]
>>>
>>> I'm using GSL version 1.16, 32-bit Ubuntu 10.04 and GCC 4.4.3.
>>>
>>> Best regards,
>>> Victor
>>>
>>>
>
>

Attachment: 0001-Sort-eigenvalues-by-real-then-imaginary-part.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]