From c7910eb7ef1a200d0bacc5fc4c5eb048aeace358 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Walter?= Date: Tue, 18 Feb 2003 07:34:44 +0000 Subject: [PATCH] More fixes. [SVN r17504] --- Jamfile | 16 + bench1/Jamfile | 16 + bench2/Jamfile | 16 + bench3/Jamfile | 16 + bench3/bench31.cpp | 20 - bench3/bench32.cpp | 32 - bench3/bench33.cpp | 12 - bench4/Jamfile | 16 + bench4/bench41.cpp | 51 +- bench4/bench42.cpp | 76 +- bench4/bench43.cpp | 34 +- doc/banded.htm | 2 +- doc/container.htm | 2 +- doc/expression.htm | 2 +- doc/hermitian.htm | 2 +- doc/index.htm | 646 ++--- doc/iterator.htm | 2486 +++++++++-------- doc/matrix.htm | 2 +- doc/matrix_expression.htm | 2 +- doc/matrix_proxy.htm | 2 +- doc/matrix_sparse.htm | 2 +- doc/overview.htm | 2 +- doc/samples/Jamfile | 16 + doc/storage.htm | 7 +- doc/storage_sparse.htm | 2 +- doc/symmetric.htm | 2 +- doc/triangular.htm | 2 +- doc/vector.htm | 4 +- doc/vector_expression.htm | 4 +- doc/vector_proxy.htm | 2 +- doc/vector_sparse.htm | 6 +- include/boost/numeric/ublas/banded.hpp | 4 +- include/boost/numeric/ublas/concepts.hpp | 10 +- include/boost/numeric/ublas/config.hpp | 15 +- include/boost/numeric/ublas/functional.hpp | 8 +- include/boost/numeric/ublas/hermitian.hpp | 4 +- include/boost/numeric/ublas/matrix.hpp | 12 +- .../boost/numeric/ublas/matrix_expression.hpp | 88 +- include/boost/numeric/ublas/matrix_proxy.hpp | 262 +- include/boost/numeric/ublas/matrix_sparse.hpp | 8 +- include/boost/numeric/ublas/operation.hpp | 144 + .../boost/numeric/ublas/operation_blocked.hpp | 88 - include/boost/numeric/ublas/storage.hpp | 82 +- include/boost/numeric/ublas/symmetric.hpp | 4 +- include/boost/numeric/ublas/triangular.hpp | 4 +- include/boost/numeric/ublas/vector.hpp | 10 +- .../boost/numeric/ublas/vector_expression.hpp | 72 +- include/boost/numeric/ublas/vector_proxy.hpp | 183 +- include/boost/numeric/ublas/vector_sparse.hpp | 6 +- test1/Jamfile | 16 + test1/test11.cpp | 16 - test1/test12.cpp | 12 - test1/test13.cpp | 16 - test2/Jamfile | 16 + test3/Jamfile | 16 + test3/test31.cpp | 16 - test3/test32.cpp | 12 - test3/test33.cpp | 16 - test4/Jamfile | 16 + test4/test41.cpp | 16 - test4/test42.cpp | 24 - test4/test43.cpp | 32 - test5/Jamfile | 16 + test5/test51.cpp | 16 - test5/test52.cpp | 24 - test5/test53.cpp | 32 - test6/Jamfile | 16 + test6/test61.cpp | 16 - test6/test62.cpp | 24 - test6/test63.cpp | 32 - test7/Jamfile | 16 + test7/test71.cpp | 16 - test7/test72.cpp | 12 - test7/test73.cpp | 16 - 74 files changed, 2088 insertions(+), 2876 deletions(-) diff --git a/Jamfile b/Jamfile index 2d6f5389..09c5a9b6 100644 --- a/Jamfile +++ b/Jamfile @@ -1,3 +1,19 @@ +# +# Copyright (c) 2000-2002 +# Joerg Walter, Mathias Koch +# +# Permission to use, copy, modify, distribute and sell this software +# and its documentation for any purpose is hereby granted without fee, +# provided that the above copyright notice appear in all copies and +# that both that copyright notice and this permission notice appear +# in supporting documentation. The authors make no representations +# about the suitability of this software for any purpose. +# It is provided "as is" without express or implied warranty. +# +# The authors gratefully acknowledge the support of +# GeNeSys mbH & Co. KG in producing this work. +# + subproject libs/numeric/ublas ; subinclude libs/numeric/ublas/test1 ; subinclude libs/numeric/ublas/test2 ; diff --git a/bench1/Jamfile b/bench1/Jamfile index e62332b9..7c6bb931 100644 --- a/bench1/Jamfile +++ b/bench1/Jamfile @@ -1,3 +1,19 @@ +# +# Copyright (c) 2000-2002 +# Joerg Walter, Mathias Koch +# +# Permission to use, copy, modify, distribute and sell this software +# and its documentation for any purpose is hereby granted without fee, +# provided that the above copyright notice appear in all copies and +# that both that copyright notice and this permission notice appear +# in supporting documentation. The authors make no representations +# about the suitability of this software for any purpose. +# It is provided "as is" without express or implied warranty. +# +# The authors gratefully acknowledge the support of +# GeNeSys mbH & Co. KG in producing this work. +# + subproject libs/numeric/ublas/bench1 ; SOURCES = bench1 bench11 bench12 bench13 ; diff --git a/bench2/Jamfile b/bench2/Jamfile index f3c17608..d0c2b0ea 100644 --- a/bench2/Jamfile +++ b/bench2/Jamfile @@ -1,3 +1,19 @@ +# +# Copyright (c) 2000-2002 +# Joerg Walter, Mathias Koch +# +# Permission to use, copy, modify, distribute and sell this software +# and its documentation for any purpose is hereby granted without fee, +# provided that the above copyright notice appear in all copies and +# that both that copyright notice and this permission notice appear +# in supporting documentation. The authors make no representations +# about the suitability of this software for any purpose. +# It is provided "as is" without express or implied warranty. +# +# The authors gratefully acknowledge the support of +# GeNeSys mbH & Co. KG in producing this work. +# + subproject libs/numeric/ublas/bench2 ; SOURCES = bench2 bench21 bench22 bench23 ; diff --git a/bench3/Jamfile b/bench3/Jamfile index b03a88dc..57a2c1b1 100644 --- a/bench3/Jamfile +++ b/bench3/Jamfile @@ -1,3 +1,19 @@ +# +# Copyright (c) 2000-2002 +# Joerg Walter, Mathias Koch +# +# Permission to use, copy, modify, distribute and sell this software +# and its documentation for any purpose is hereby granted without fee, +# provided that the above copyright notice appear in all copies and +# that both that copyright notice and this permission notice appear +# in supporting documentation. The authors make no representations +# about the suitability of this software for any purpose. +# It is provided "as is" without express or implied warranty. +# +# The authors gratefully acknowledge the support of +# GeNeSys mbH & Co. KG in producing this work. +# + subproject libs/numeric/ublas/bench3 ; SOURCES = bench3 bench31 bench32 bench33 ; diff --git a/bench3/bench31.cpp b/bench3/bench31.cpp index 47aba28d..6c2ada24 100644 --- a/bench3/bench31.cpp +++ b/bench3/bench31.cpp @@ -66,15 +66,9 @@ struct bench_my_inner_prod { void operator () (int runs) const { try { -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL - static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range<> (0, N)), - vr2 (v2, ublas::range<> (0, N)); -#else static V v1 (N), v2 (N); ublas::vector_range vr1 (v1, ublas::range (0, N)), vr2 (v2, ublas::range (0, N)); -#endif initialize_vector (vr1); initialize_vector (vr2); boost::timer t; @@ -151,17 +145,10 @@ struct bench_my_vector_add { void operator () (int runs, safe_tag) const { try { -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL - static V v1 (N), v2 (N), v3 (N); - ublas::vector_range vr1 (v1, ublas::range<> (0, N)), - vr2 (v2, ublas::range<> (0, N)), - vr3 (v2, ublas::range<> (0, N)); -#else static V v1 (N), v2 (N), v3 (N); ublas::vector_range vr1 (v1, ublas::range (0, N)), vr2 (v2, ublas::range (0, N)), vr3 (v2, ublas::range (0, N)); -#endif initialize_vector (vr1); initialize_vector (vr2); initialize_vector (vr3); @@ -181,17 +168,10 @@ struct bench_my_vector_add { } void operator () (int runs, fast_tag) const { try { -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL - static V v1 (N), v2 (N), v3 (N); - ublas::vector_range vr1 (v1, ublas::range<> (0, N)), - vr2 (v2, ublas::range<> (0, N)), - vr3 (v2, ublas::range<> (0, N)); -#else static V v1 (N), v2 (N), v3 (N); ublas::vector_range vr1 (v1, ublas::range (0, N)), vr2 (v2, ublas::range (0, N)), vr3 (v2, ublas::range (0, N)); -#endif initialize_vector (vr1); initialize_vector (vr2); boost::timer t; diff --git a/bench3/bench32.cpp b/bench3/bench32.cpp index efbf1072..27b9741f 100644 --- a/bench3/bench32.cpp +++ b/bench3/bench32.cpp @@ -68,19 +68,11 @@ struct bench_my_outer_prod { void operator () (int runs, safe_tag) const { try { -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL - static M m (N, N); - ublas::matrix_range mr (m, ublas::range<> (0, N), ublas::range<> (0, N)); - static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range<> (0, N)), - vr2 (v2, ublas::range<> (0, N)); -#else static M m (N, N); ublas::matrix_range mr (m, ublas::range (0, N), ublas::range (0, N)); static V v1 (N), v2 (N); ublas::vector_range vr1 (v1, ublas::range (0, N)), vr2 (v2, ublas::range (0, N)); -#endif initialize_vector (vr1); initialize_vector (vr2); boost::timer t; @@ -99,19 +91,11 @@ struct bench_my_outer_prod { } void operator () (int runs, fast_tag) const { try { -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL - static M m (N, N); - ublas::matrix_range mr (m, ublas::range<> (0, N), ublas::range<> (0, N)); - static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range<> (0, N)), - vr2 (v2, ublas::range<> (0, N)); -#else static M m (N, N); ublas::matrix_range mr (m, ublas::range (0, N), ublas::range (0, N)); static V v1 (N), v2 (N); ublas::vector_range vr1 (v1, ublas::range (0, N)), vr2 (v2, ublas::range (0, N)); -#endif initialize_vector (vr1); initialize_vector (vr2); boost::timer t; @@ -195,19 +179,11 @@ struct bench_my_matrix_vector_prod { void operator () (int runs, safe_tag) const { try { -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL - static M m (N, N); - ublas::matrix_range mr (m, ublas::range<> (0, N), ublas::range<> (0, N)); - static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range<> (0, N)), - vr2 (v2, ublas::range<> (0, N)); -#else static M m (N, N); ublas::matrix_range mr (m, ublas::range (0, N), ublas::range (0, N)); static V v1 (N), v2 (N); ublas::vector_range vr1 (v1, ublas::range (0, N)), vr2 (v2, ublas::range (0, N)); -#endif initialize_matrix (mr); initialize_vector (vr1); boost::timer t; @@ -226,19 +202,11 @@ struct bench_my_matrix_vector_prod { } void operator () (int runs, fast_tag) const { try { -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL - static M m (N, N); - ublas::matrix_range mr (m, ublas::range<> (0, N), ublas::range<> (0, N)); - static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range<> (0, N)), - vr2 (v2, ublas::range<> (0, N)); -#else static M m (N, N); ublas::matrix_range mr (m, ublas::range (0, N), ublas::range (0, N)); static V v1 (N), v2 (N); ublas::vector_range vr1 (v1, ublas::range (0, N)), vr2 (v2, ublas::range (0, N)); -#endif initialize_matrix (mr); initialize_vector (vr1); boost::timer t; diff --git a/bench3/bench33.cpp b/bench3/bench33.cpp index 6395be43..89154ae9 100644 --- a/bench3/bench33.cpp +++ b/bench3/bench33.cpp @@ -71,15 +71,9 @@ struct bench_my_matrix_prod { void operator () (int runs, safe_tag) const { try { static M m1 (N, N), m2 (N, N), m3 (N, N); -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL - ublas::matrix_range mr1 (m1, ublas::range<> (0, N), ublas::range<> (0, N)), - mr2 (m2, ublas::range<> (0, N), ublas::range<> (0, N)), - mr3 (m3, ublas::range<> (0, N), ublas::range<> (0, N)); -#else ublas::matrix_range mr1 (m1, ublas::range (0, N), ublas::range (0, N)), mr2 (m2, ublas::range (0, N), ublas::range (0, N)), mr3 (m3, ublas::range (0, N), ublas::range (0, N)); -#endif initialize_matrix (mr1); initialize_matrix (mr2); boost::timer t; @@ -99,15 +93,9 @@ struct bench_my_matrix_prod { void operator () (int runs, fast_tag) const { try { static M m1 (N, N), m2 (N, N), m3 (N, N); -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL - ublas::matrix_range mr1 (m1, ublas::range<> (0, N), ublas::range<> (0, N)), - mr2 (m2, ublas::range<> (0, N), ublas::range<> (0, N)), - mr3 (m3, ublas::range<> (0, N), ublas::range<> (0, N)); -#else ublas::matrix_range mr1 (m1, ublas::range (0, N), ublas::range (0, N)), mr2 (m2, ublas::range (0, N), ublas::range (0, N)), mr3 (m3, ublas::range (0, N), ublas::range (0, N)); -#endif initialize_matrix (mr1); initialize_matrix (mr2); boost::timer t; diff --git a/bench4/Jamfile b/bench4/Jamfile index e720dcb7..c075f068 100644 --- a/bench4/Jamfile +++ b/bench4/Jamfile @@ -1,3 +1,19 @@ +# +# Copyright (c) 2000-2002 +# Joerg Walter, Mathias Koch +# +# Permission to use, copy, modify, distribute and sell this software +# and its documentation for any purpose is hereby granted without fee, +# provided that the above copyright notice appear in all copies and +# that both that copyright notice and this permission notice appear +# in supporting documentation. The authors make no representations +# about the suitability of this software for any purpose. +# It is provided "as is" without express or implied warranty. +# +# The authors gratefully acknowledge the support of +# GeNeSys mbH & Co. KG in producing this work. +# + subproject libs/numeric/ublas/bench4 ; SOURCES = bench4 bench41 bench42 bench43 ; diff --git a/bench4/bench41.cpp b/bench4/bench41.cpp index 4084272d..953973c3 100644 --- a/bench4/bench41.cpp +++ b/bench4/bench41.cpp @@ -69,21 +69,13 @@ struct bench_my_inner_prod { void operator () (int runs) const { try { -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range<> (0, N)), - vr2 (v2, ublas::range<> (0, N)); -#else - static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range (0, N)), - vr2 (v2, ublas::range (0, N)); -#endif - initialize_vector (vr1); - initialize_vector (vr2); + initialize_vector (v1); + initialize_vector (v2); boost::timer t; for (int i = 0; i < runs; ++ i) { static value_type s (0); - s = ublas::inner_prod (vr1, vr2); + s = ublas::inner_prod (v1, v2); // sink_scalar (s); } footer () (N, N - 1, runs, t.elapsed ()); @@ -154,24 +146,13 @@ struct bench_my_vector_add { void operator () (int runs, safe_tag) const { try { -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL static V v1 (N), v2 (N), v3 (N); - ublas::vector_range vr1 (v1, ublas::range<> (0, N)), - vr2 (v2, ublas::range<> (0, N)), - vr3 (v2, ublas::range<> (0, N)); -#else - static V v1 (N), v2 (N), v3 (N); - ublas::vector_range vr1 (v1, ublas::range (0, N)), - vr2 (v2, ublas::range (0, N)), - vr3 (v2, ublas::range (0, N)); -#endif - initialize_vector (vr1); - initialize_vector (vr2); - initialize_vector (vr3); + initialize_vector (v1); + initialize_vector (v2); boost::timer t; for (int i = 0; i < runs; ++ i) { - vr3 = - (vr1 + vr2); -// sink_vector (vr3); + v3 = - (v1 + v2); +// sink_vector (v3); } footer () (0, 2 * N, runs, t.elapsed ()); } @@ -184,23 +165,13 @@ struct bench_my_vector_add { } void operator () (int runs, fast_tag) const { try { -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL static V v1 (N), v2 (N), v3 (N); - ublas::vector_range vr1 (v1, ublas::range<> (0, N)), - vr2 (v2, ublas::range<> (0, N)), - vr3 (v2, ublas::range<> (0, N)); -#else - static V v1 (N), v2 (N), v3 (N); - ublas::vector_range vr1 (v1, ublas::range (0, N)), - vr2 (v2, ublas::range (0, N)), - vr3 (v2, ublas::range (0, N)); -#endif - initialize_vector (vr1); - initialize_vector (vr2); + initialize_vector (v1); + initialize_vector (v2); boost::timer t; for (int i = 0; i < runs; ++ i) { - vr3.assign (- (vr1 + vr2)); -// sink_vector (vr3); + v3.assign (- (v1 + v2)); +// sink_vector (v3); } footer () (0, 2 * N, runs, t.elapsed ()); } diff --git a/bench4/bench42.cpp b/bench4/bench42.cpp index caf398af..2c530621 100644 --- a/bench4/bench42.cpp +++ b/bench4/bench42.cpp @@ -71,25 +71,14 @@ struct bench_my_outer_prod { void operator () (int runs, safe_tag) const { try { -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL static M m (N, N); - ublas::matrix_range mr (m, ublas::range<> (0, N), ublas::range<> (0, N)); static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range<> (0, N)), - vr2 (v2, ublas::range<> (0, N)); -#else - static M m (N, N); - ublas::matrix_range mr (m, ublas::range (0, N), ublas::range (0, N)); - static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range (0, N)), - vr2 (v2, ublas::range (0, N)); -#endif - initialize_vector (vr1); - initialize_vector (vr2); + initialize_vector (v1); + initialize_vector (v2); boost::timer t; for (int i = 0; i < runs; ++ i) { - mr = - ublas::outer_prod (vr1, vr2); -// sink_matrix (mr); + m = - ublas::outer_prod (v1, v2); +// sink_matrix (m); } footer () (N * N, N * N, runs, t.elapsed ()); } @@ -102,25 +91,14 @@ struct bench_my_outer_prod { } void operator () (int runs, fast_tag) const { try { -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL static M m (N, N); - ublas::matrix_range mr (m, ublas::range<> (0, N), ublas::range<> (0, N)); static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range<> (0, N)), - vr2 (v2, ublas::range<> (0, N)); -#else - static M m (N, N); - ublas::matrix_range mr (m, ublas::range (0, N), ublas::range (0, N)); - static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range (0, N)), - vr2 (v2, ublas::range (0, N)); -#endif - initialize_vector (vr1); - initialize_vector (vr2); + initialize_vector (v1); + initialize_vector (v2); boost::timer t; for (int i = 0; i < runs; ++ i) { - mr.assign (- ublas::outer_prod (vr1, vr2)); -// sink_matrix (mr); + m.assign (- ublas::outer_prod (v1, v2)); +// sink_matrix (m); } footer () (N * N, N * N, runs, t.elapsed ()); } @@ -198,25 +176,14 @@ struct bench_my_matrix_vector_prod { void operator () (int runs, safe_tag) const { try { -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL static M m (N, N); - ublas::matrix_range mr (m, ublas::range<> (0, N), ublas::range<> (0, N)); static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range<> (0, N)), - vr2 (v2, ublas::range<> (0, N)); -#else - static M m (N, N); - ublas::matrix_range mr (m, ublas::range (0, N), ublas::range (0, N)); - static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range (0, N)), - vr2 (v2, ublas::range (0, N)); -#endif - initialize_matrix (mr); - initialize_vector (vr1); + initialize_matrix (m); + initialize_vector (v1); boost::timer t; for (int i = 0; i < runs; ++ i) { - vr2 = ublas::prod (mr, vr1); -// sink_vector (vr2); + v2 = ublas::prod (m, v1); +// sink_vector (v2); } footer () (N * N, N * (N - 1), runs, t.elapsed ()); } @@ -229,25 +196,14 @@ struct bench_my_matrix_vector_prod { } void operator () (int runs, fast_tag) const { try { -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL static M m (N, N); - ublas::matrix_range mr (m, ublas::range<> (0, N), ublas::range<> (0, N)); static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range<> (0, N)), - vr2 (v2, ublas::range<> (0, N)); -#else - static M m (N, N); - ublas::matrix_range mr (m, ublas::range (0, N), ublas::range (0, N)); - static V v1 (N), v2 (N); - ublas::vector_range vr1 (v1, ublas::range (0, N)), - vr2 (v2, ublas::range (0, N)); -#endif - initialize_matrix (mr); - initialize_vector (vr1); + initialize_matrix (m); + initialize_vector (v1); boost::timer t; for (int i = 0; i < runs; ++ i) { - vr2.assign (ublas::prod (mr, vr1)); -// sink_vector (vr2); + v2.assign (ublas::prod (m, v1)); +// sink_vector (v2); } footer () (N * N, N * (N - 1), runs, t.elapsed ()); } diff --git a/bench4/bench43.cpp b/bench4/bench43.cpp index 20bec0a4..2f0b0fcc 100644 --- a/bench4/bench43.cpp +++ b/bench4/bench43.cpp @@ -74,21 +74,12 @@ struct bench_my_matrix_prod { void operator () (int runs, safe_tag) const { try { static M m1 (N, N), m2 (N, N), m3 (N, N); -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL - ublas::matrix_range mr1 (m1, ublas::range<> (0, N), ublas::range<> (0, N)), - mr2 (m2, ublas::range<> (0, N), ublas::range<> (0, N)), - mr3 (m3, ublas::range<> (0, N), ublas::range<> (0, N)); -#else - ublas::matrix_range mr1 (m1, ublas::range (0, N), ublas::range (0, N)), - mr2 (m2, ublas::range (0, N), ublas::range (0, N)), - mr3 (m3, ublas::range (0, N), ublas::range (0, N)); -#endif - initialize_matrix (mr1); - initialize_matrix (mr2); + initialize_matrix (m1); + initialize_matrix (m2); boost::timer t; for (int i = 0; i < runs; ++ i) { - mr3 = ublas::prod (mr1, mr2); -// sink_matrix (mr3); + m3 = ublas::prod (m1, m2); +// sink_matrix (m3); } footer () (N * N * N, N * N * (N - 1), runs, t.elapsed ()); } @@ -102,21 +93,12 @@ struct bench_my_matrix_prod { void operator () (int runs, fast_tag) const { try { static M m1 (N, N), m2 (N, N), m3 (N, N); -#ifdef BOOST_UBLAS_ENABLE_INDEX_SET_ALL - ublas::matrix_range mr1 (m1, ublas::range<> (0, N), ublas::range<> (0, N)), - mr2 (m2, ublas::range<> (0, N), ublas::range<> (0, N)), - mr3 (m3, ublas::range<> (0, N), ublas::range<> (0, N)); -#else - ublas::matrix_range mr1 (m1, ublas::range (0, N), ublas::range (0, N)), - mr2 (m2, ublas::range (0, N), ublas::range (0, N)), - mr3 (m3, ublas::range (0, N), ublas::range (0, N)); -#endif - initialize_matrix (mr1); - initialize_matrix (mr2); + initialize_matrix (m1); + initialize_matrix (m2); boost::timer t; for (int i = 0; i < runs; ++ i) { - mr3.assign (ublas::prod (mr1, mr2)); -// sink_matrix (mr3); + m3.assign (ublas::prod (m1, m2)); +// sink_matrix (m3); } footer () (N * N * N, N * N * (N - 1), runs, t.elapsed ()); } diff --git a/doc/banded.htm b/doc/banded.htm index 32cc9ead..812f1dda 100644 --- a/doc/banded.htm +++ b/doc/banded.htm @@ -598,7 +598,7 @@ provided this copyright notice appears in all copies. This document is provided ``as is'' without express or implied warranty, and with no claim as to its suitability for any purpose.

-

Last revised: 8/3/2002

+

Last revised: 1/15/2003

diff --git a/doc/container.htm b/doc/container.htm index 1e4aed8d..04b49941 100644 --- a/doc/container.htm +++ b/doc/container.htm @@ -416,7 +416,7 @@ provided this copyright notice appears in all copies. This document is provided ``as is'' without express or implied warranty, and with no claim as to its suitability for any purpose.

-

Last revised: 8/3/2002

+

Last revised: 1/15/2003

diff --git a/doc/expression.htm b/doc/expression.htm index 675835bb..31cccd9b 100644 --- a/doc/expression.htm +++ b/doc/expression.htm @@ -1071,7 +1071,7 @@ provided this copyright notice appears in all copies. This document is provided ``as is'' without express or implied warranty, and with no claim as to its suitability for any purpose.

-

Last revised: 8/3/2002

+

Last revised: 1/15/2003

diff --git a/doc/hermitian.htm b/doc/hermitian.htm index 7c115999..71b2b609 100644 --- a/doc/hermitian.htm +++ b/doc/hermitian.htm @@ -599,7 +599,7 @@ provided this copyright notice appears in all copies. This document is provided ``as is'' without express or implied warranty, and with no claim as to its suitability for any purpose.

-

Last revised: 8/3/2002

+

Last revised: 1/15/2003

diff --git a/doc/index.htm b/doc/index.htm index 0ac63a58..4106ad46 100644 --- a/doc/index.htm +++ b/doc/index.htm @@ -1,400 +1,402 @@ - + - + Boost Basic Linear Algebra - +

c++boost.gif - Basic Linear Algebra

- + Basic Linear Algebra +

uBLAS is a C++ template class library that provides - BLAS - level 1, 2, 3 functionality for dense, packed and sparse matrices. The -design and implementation unify mathematical notation via operator overloading + BLAS + level 1, 2, 3 functionality for dense, packed and sparse matrices. The +design and implementation unify mathematical notation via operator overloading and efficient code generation via expression templates.

- +

Functionality

- -

uBLAS provides templated C++ classes for dense, unit and sparse vectors, -dense, identity, triangular, banded, symmetric, hermitian and sparse matrices. -Views into vectors and matrices can be constructed via ranges or slices and -adaptor classes. The library covers the usual basic linear algebra operations -on vectors and matrices: reductions like different norms, addition and subtraction -of vectors and matrices and multiplication with a scalar, inner and outer -products of vectors, matrix vector and matrix matrix products and triangular -solver. The glue between containers, views and expression templated operations -is a mostly STL - conforming iterator interface.

- + +

uBLAS provides templated C++ classes for dense, unit and sparse vectors, + dense, identity, triangular, banded, symmetric, hermitian and sparse matrices. + Views into vectors and matrices can be constructed via ranges or slices +and adaptor classes. The library covers the usual basic linear algebra operations + on vectors and matrices: reductions like different norms, addition and subtraction + of vectors and matrices and multiplication with a scalar, inner and outer + products of vectors, matrix vector and matrix matrix products and triangular + solver. The glue between containers, views and expression templated operations + is a mostly STL + conforming iterator interface.

+

Dense, packed and sparse matrix classes are being tested with the - CLAPACK - test suite.

- + CLAPACK + test suite.

+

Known limitations:

- +
    -
  • The implementation assumes a linear memory address model.
  • -
  • Tuning was focussed on dense matrices.
  • - +
  • The implementation assumes a linear memory address model.
  • +
  • Tuning was focussed on dense matrices.
  • +
- +

Documentation

- +