Subject: Re: [ublas] [bindings][traits] is_vector, is_matrix
From: Rutger ter Borg (rutger_at_[hidden])
Date: 2009-03-11 05:16:50
Karl Meerbergen wrote:
> I am not always in favour of common names for different operations on
> the bindings level.
> Similarly, one could argue whether it is a good idea to have a function
> eig(), e.g. for unsymmetric and symmetric matrices, since their
> interface looks the same, but it is not the same (think of complex or
> real eigenvalues). using the same names for everything suggests the user
> not to think any longer about what he is doing (like in matlab). (I
> actually have a function eig() for all types of eigenvalue problems in
> my lapack toolbox, but I might change that at some point for this reason.)
I agree, and I think that the proposed forward_solve and back_solve is a
good (counter-) example of making explicit what should be happening. It
fact, I believe it should almost read like natural language and do what it
states. A blas' based "solve" would be less explicit, and be more
acceptable for lapack's solve. On the other hand, where it is not making
any difference, I would advocate the principle of least suprise, not to
bother the user with matrix format stuff.
But this is exactly what I am looking for, a discussion on a good set of
function mapping / naming, both for blas and lapack. Of course, we might
end up with more than one type of "..._eig".