Ticket #3539 (closed Bugs: fixed)

Opened 8 years ago

Last modified 7 years ago

uBLAS: norm_inf returns incorrect output for complex vectors.

Reported by: karvind.umich@… Owned by: guwi17
Milestone: Boost 1.43.0 Component: uBLAS
Version: Boost 1.39.0 Severity: Problem
Keywords: Cc:


The attached code shows that norm_inf returns an incorrect output for vector<complex> inputs.

I've tried it with VS using boost-1.39 and boost-1.40 as well as gcc4.4 on linux and mingw/windows with boost-1.39. They all return the incorrect output for norm_inf.


test_ublas.cpp (1.3 KB) - added by karvind.umich@… 8 years ago.
test code that produces error

Change History

Changed 8 years ago by karvind.umich@…

test code that produces error

comment:1 Changed 8 years ago by guwi17

  • Milestone changed from Boost 1.41.0 to Boost 1.42.0

too late for 1.41 now

comment:2 Changed 7 years ago by guwi17

(In [61135]) see #3539: a testcase was provided to recreate the problem

test/Jamfile.v2: added new target

test/test_complex_norms.cpp: added new testcase for complex vector norms

comment:3 Changed 7 years ago by guwi17

  • Status changed from new to assigned
  • Milestone changed from Boost 1.42.0 to Boost 1.43.0

fix will go into current release.

comment:4 Changed 7 years ago by guwi17

(In [61136]) see #3539:

changed implementation of norm_inf and norm_1 for complex types to use abs(z) instead of max(abs(real(z)),abs(imag(z))).

comment:5 Changed 7 years ago by guwi17

(In [61137]) see #3539:

added release note and warning

comment:6 Changed 7 years ago by guwi17

  • Status changed from assigned to closed
  • Resolution set to fixed

(In [61206]) fix #3539: merged [61135], [61136], [61137] into release

boost/numeric/ublas/traits.hpp: fixed complex_traits

libs/numeric/ublas/test/Jamfile.v2: added testcase

libs/numeric/ublas/test/test_complex_norms.cpp: new testcase

libs/numeric/ublas/doc/release_notes.htm: updated release notes


Add a comment

Modify Ticket

Change Properties
<Author field>
as closed
The resolution will be deleted. Next status will be 'reopened'

E-mail address and user name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.