|
Ublas : |
Subject: Re: [ublas] [bindings][lapack] Initial high-level solve
From: Rutger ter Borg (rutger_at_[hidden])
Date: 2009-03-24 16:13:22
Jesse Perla wrote:
> Quite often you want to solve AX=b with b a ublas
> vector and don't want to convert between the two types. I am not sure if
> there is the ability for the traits to treat a vector as an Nx1 matrix.
I have thought about this, I guess this would become feasible if stuff
mentioned in http://lists.boost.org/MailArchives/ublas/2009/03/3367.php is
implemented. I.e., if is_bindable_vector<T> is a true_type, we could use an
alternative traits implementation or dispatch (or something along that
line). This would enable us to use a vector as if it is a matrix in a
transparent way.
Of course, as for the syntax, suppose b is a vector, defaulting to a column
vector, I guess
solve( A, b )
solve( A, _trans(b) )
could be an interface I could live with.
Cheers,
Rutger