dev/cpp/boost/yAx/bbb

23 lines
528 B
Plaintext
Raw Normal View History

2011-04-07 17:03:45 +04:00
#include <boost/numeric/ublas/vector.hpp>
#include <boost/numeric/ublas/matrix.hpp>
#include <boost/numeric/ublas/io.hpp>
#include <boost/numeric/ublas/triangular.hpp>
#include <boost/numeric/ublas/blas.hpp>
#include <boost/numeric/ublas/lu.hpp>
using namespace boost::numeric::ublas;
int main()
{
matrix<double> A(2,2);
A(0,0) = 4; A(0,1) = 3;
A(1,0) = 6; A(1,1) = 3;
std::cout<<"A="<<A<<std::endl;
lu_factorize(A);
std::cout<<"A="<<A<<std::endl;
triangular_matrix<double> L(A);
return 0;
}