Boost logo

Boost Users :

From: Russell Hind (rhind_at_[hidden])
Date: 2004-04-08 07:15:17

I have an expression

a = (X^T * X)^-1 * X^T * y

where x is an n * k matrix
and y is an n row vector

How do I implement this expression in ublas? I can create and populate
the matrices and can do the product of matrices and the transpose use
prod and trans, but I'm unsure on the ^-1. Can I do this with ublas?

(I don't know much about matrices, but have been given the above
expression as a way of finding a polynomial fit for a set of data).

Thanks in advance


Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at