Re: [eigen] QR factorization question

[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]


2009/8/26 Eric Chu <eytchu@xxxxxxxxx>:
> hi all,
> thanks for the great work. i recently updated my version of eigen, and the
> api's changed a bit from before.
> more specifically, the qr factorization module has changed. i was wondering
> how i'd go about retrieving the upper triangular matrix "R" from a qr
> factorization.
> that is, if i have an m x n matrix A, and i call
> R = A.householderQr().matrixR();
> the API seems to have deprecated this function call. i think i can call
> matrixQR() instead, but it's no longer upper triangular. any pointers?

Yes, matrixR() is removed at the moment, we may reintroduce it in the
future though once we support trapezoid matrices.

Meawhile you can retrive R as the upper triangular part of matrixQR().

R = A.householderQr().matrixQR().triangularView<UpperTriangular>();

Benoit



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/