|
Ublas : |
From: Karl Meerbergen (Karl.Meerbergen_at_[hidden])
Date: 2006-04-14 08:18:25
I suppose atlas is a compiled lapack. there are bindings in
boost-sandbox/numeric/bindings/lapack/gesv.hpp
#include <boost/numeric/bindings/traits/ublas_matrix.hpp>
#include <boost/numeric/bindings/traits/ublas_vector2.hpp>
#include <boost/numeric/bindings/lapack/gesv.hpp>
boost::numeric::bindings::lapack::gesv( matrix, rhs ) ;
solves matrix * x = b where rhs stores b on input and receives x on output.
for the factorization only (with singularity check), use:
#include <boost/numeric/bindings/traits/std_vector.hpp>
std::vector<int> pivots( matrix.size1() ) ;
int info = boost::numeric::bindings::lapack::getrfv( matrix, pivots )
Karl
Nico Galoppo wrote:
>Have a look at the ATLAS bindings for ublas. ATLAS provides such factorization
>methods.
>
>http://www.crystalclearsoftware.com/cgi-bin/boost_wiki/wiki.pl?action=browse&id=Linear_Algebra_With_UBLAS&revision=15
>
>HTH,
>
>--nico
>
>John Maddock wrote:
>
>
>>I gather from a quick web search that ublas does have LUP decomposition
>>routines, however a grep of the docs failed to find any mention of the
>>routine in question, and how they should be used.
>>
>>So.... does anyone have the boiler plate code needed to solve for x given
>>matrix A and vector b ?
>>
>>Many thanks,
>>
>>John Maddock.
>>
>>_______________________________________________
>>ublas mailing list
>>ublas_at_[hidden]
>>http://lists.boost.org/mailman/listinfo.cgi/ublas
>>
>>
>
>
>
-- ============================================== Look at our unique training program and Register on-line at http://www.fft.be/?id=35 ---------------------------------------------- Karl Meerbergen Free Field Technologies NEW ADDRESS FROM FEBRUARY 1st ONWARD: Axis Park Louvain-la-Neuve rue Emile Francqui, 1 B-1435 Mont-Saint Guibert - BELGIUM Company Phone: +32 10 45 12 26 Company Fax: +32 10 45 46 26 Mobile Phone: +32 474 26 66 59 Home Phone: +32 2 306 38 10 mailto:Karl.Meerbergen_at_[hidden] http://www.fft.be ============================================