RE: OON: matrix 'object' operations

From: Richard Weidner (richard@spartacus.jpl.nasa.gov)
Date: Tue Mar 18 1997 - 16:18:51 EST


>>It makes you long for the non-oo simplicity of this:

>>product(B,C,A); // A is the result and was created by the caller

>>Basically, I've found even the simplest oo-ifying of linear algebra
>>operations turns up tons of details like that that can have profound impact
>>on performance.

I think it would be nice to talk about what oo-ifying does and what
it does not do. It will avoid comments like the above.

The careful definition and use of operators, functions, and their arguments
is required of Basic much less object-oriented languages or designs.
Nobody need say that extra versatility allows one to make more mistakes.
That is obvious.

It would be better to say that caution should be exercised against
assuming any one approach is a panacea for all design goals.
You simply can not create a single library or set of functions
that solves the general linear algebra problem. That goes for Fortran
much less for C++. One merely try finding the inverse of a stiff
10,000,000 x 10,000,000 matrix to start getting the idea. Hopefully,
you will not use that code on a 3x3 matrix. It makes a profound
impact on performance. (I apologize for the extreme exaggeration
to make a point.)

But then if you know you are only going to have 3x3 matrices. Well, ...

-- 
Richard Weidner



This archive was generated by hypermail 2b29 : Wed Feb 20 2002 - 03:20:05 EST