J
john
Hi, in TC++PL 3 on pages 674-675 it is mentioned:
"Maybe your first idea for a two-dimensional vector was something like this:
class Matrix {
valarray< valarray<double> >v;
public:
// ...
};
This would also work (22.9[10]). However, it is not easy to match
efficiency and compatibility required by high performance computations
without dropping to the lower and more conventional level represented by
valarray plus slices".
However since 1998 much time has passed, and I wonder if the current
compiler implementations allow valarray<valarray<T> > to be equally
efficient (or more) than using a valarray with slices/slice_arrays.
"Maybe your first idea for a two-dimensional vector was something like this:
class Matrix {
valarray< valarray<double> >v;
public:
// ...
};
This would also work (22.9[10]). However, it is not easy to match
efficiency and compatibility required by high performance computations
without dropping to the lower and more conventional level represented by
valarray plus slices".
However since 1998 much time has passed, and I wonder if the current
compiler implementations allow valarray<valarray<T> > to be equally
efficient (or more) than using a valarray with slices/slice_arrays.