Boost logo

Boost :

From: boost (boost_at_[hidden])
Date: 2001-08-08 14:17:44


Salut,

On Wednesday 08 August 2001 18:42, Jens Maurer wrote:

> You need to use
>
> -DBOOST_NO_LIMITS -D_CPP_NUMERIC_LIMITS
>
> as a hacky workaround when compiling to avoid using the broken
> std::numeric_limits<> from GCC's libstdc++.
> (see Makefile).
>
> (There's a reason why the test aborts when Infinity == NaN == 0).
>
> Jens Maurer
>

Thanks, this improves the situation a lot.
Now, only trigonometric tests fail,
and the find_root_demo doesn't compile, which seems to
be a g++-3.0 problem.

Best wishes,
Peter

------------------------------------------------------------

peter_at_wawa:~/Boost/interval$ g++-3.0 -I /home/peter/Boost/boost -DBOOST_NO_LIMITS -D_CPP_NUMERIC_LIMITS \
        -g -fstrict-aliasing -mieee-fp interval_test.cpp -o interval_test

peter_at_wawa:~/Boost/interval$ ./interval_test
Infinity: inf
NaN: nan
Testing + on [-2,2] x [-2,2] step 0.3
Testing - on [-2,2] x [-2,2] step 0.3
Testing * on [-2,2] x [-2,2] step 0.3
Testing / on [-2,2] x [-2,2] step 0.3
Testing + on [-5,5] step 0.17 x scalar(-5 .. 5) step 0.17
Testing - on [-5,5] step 0.17 x scalar(-5 .. 5) step 0.17
Testing * on [-5,5] step 0.17 x scalar(-5 .. 5) step 0.17
Testing / on [-5,5] step 0.17 x scalar(-5 .. 5) step 0.17
Testing + (arg rev) on [-5,5] step 0.17 x scalar(-5 .. 5) step 0.17
Testing - (arg rev) on [-5,5] step 0.17 x scalar(-5 .. 5) step 0.17
Testing * (arg rev) on [-5,5] step 0.17 x scalar(-5 .. 5) step 0.17
Testing / (arg rev) on [-5,5] step 0.17 x scalar(-5 .. 5) step 0.17
Testing pow on [-2,2] x [-2,2] step 0.3
Testing pow_int on [-9.99999,10] step 0.1 x scalar(-10 .. 10) step 1
Testing atan2 on [-2,2] x [-2,2] step 0.3
1.9 atan2 -0.2 = 1.675673265525131 not in [1.9,1.930000000000001] atan2 [-0.1999999999999998,-0.1699999999999998] = [-1.482940170565263,1.675673265525131]
Testing - on [-10,10] step 0.1
Testing abs on [-10,10] step 0.1
Testing square on [-10,10] step 0.1
Testing sqrt on [-1,10] step 0.1
Testing exp on [-10,10] step 0.1
Testing log on [-1,10] step 0.1
Testing log10 on [-1,10] step 0.1
Testing sin on [-10,10] step 0.1
sin(0.8099999999999808) = 0.7242871743701293 not in sin([-3.900000000000021,0.809999999999981]) = [-1,0.7242871743701293]
sin(0.3099999999999808) = 0.3050586364434252 not in sin([-2.80000000000002,0.309999999999981]) = [-1,0.3050586364434252]
sin(0.3099999999999808) = 0.3050586364434252 not in sin([-2.60000000000002,0.309999999999981]) = [-1,0.3050586364434252]
Testing cos on [-10,10] step 0.1
cos(-1.390000000000019) = 0.1798129776729806 not in cos([-2.50000000000002,-1.390000000000019]) = [-0.8011436155469458,0.1798129776729806]
cos(-1.490000000000019) = 0.08070844845478137 not in cos([-2.40000000000002,-1.49000000000002]) = [-0.7373937155412591,0.08070844845478134]
cos(-1.590000000000019) = -0.01920249290171196 not in cos([-2.30000000000002,-1.590000000000019]) = [-0.6662760212798391,-0.01920249290171202]
Testing tan on [-10,10] step 0.1
Testing asin on [-10,10] step 0.1
Testing acos on [-10,10] step 0.1
acos(0.9999999999999811) = 1.942873717904893e-07 not in acos([0.999999999999981,1.009999999999981]) = [nan,1.942872322803204e-07]
acos(0.9999999999999811) = 1.942873717904893e-07 not in acos([0.999999999999981,1.109999999999981]) = [nan,1.942872322803204e-07]
acos(0.9999999999999811) = 1.942873717904893e-07 not in acos([0.999999999999981,1.209999999999982]) = [nan,1.942872322803204e-07]
acos(0.9999999999999811) = 1.942873717904893e-07 not in acos([0.999999999999981,1.309999999999982]) = [nan,1.942872322803204e-07]
[...]


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk