Turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Intel Community
- Software Development SDKs and Libraries
- Intel® Integrated Performance Primitives
- Any sample code that includes QRDecomp?

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

Highlighted
##

lamoid

Beginner

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

10-28-2009
10:22 AM

9 Views

Any sample code that includes QRDecomp?

Dear Folks,

I need to obtain a QR factorization of a matrix. The results of the IPP QRDecomp function appear to be many steps removed from an actual QR decomposition. (See p. 239 of the small matrices manual). Is there any sample code available that demonstrates how to compute the Q matrix from the Householder vectors that are actually returned by QRDecomp? The code in Example 7-1 ippmQRFactorization_32f does not actually extract a separate Q and R but instead immediately uses the Householder vector results in a back-substitution to solve a linear system.

Thank you,

Alan Peters

2 Replies

Highlighted
##

*
*

lamoid

Beginner

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

10-31-2009
02:21 PM

9 Views

Quoting - lamoid

Of course if there are no zeros on the main diagonal of R, then R is invertible and you can get Q by post-multiplying the input matrix by the inverse of R. That is, if A = QR and R is invertible then Q = A*inv. If R has a zero on the main diagonal then the question still stands.

Dear Folks,

I need to obtain a QR factorization of a matrix. The results of the IPP QRDecomp function appear to be many steps removed from an actual QR decomposition. (See p. 239 of the small matrices manual). Is there any sample code available that demonstrates how to compute the Q matrix from the Householder vectors that are actually returned by QRDecomp? The code in Example 7-1 ippmQRFactorization_32f does not actually extract a separate Q and R but instead immediately uses the Householder vector results in a back-substitution to solve a linear system.

Thank you,

Alan Peters

Highlighted
##

Hi Lamoid,

What's the purpose for you to get the exact Q matrix? The QR decom in small matrix domain ismainly forsolve the least squares (LS) small-sizeproblem, so no explicit Q generated. But sure, you can caculate it by Q=A*inv.

If you are developing somemath compuation application, there are another library named MKL (math kernal library, http://software.intel.com/en-us/intel-mkl/, which provide more routines to support math compuation. You may try it.

For example, it includes some routines like *geqrf() and *orggr()

To compute the elements of Q explicitly, call

SGEQRF()

then

sorgqr (for real matrices)

(one fortransample code is under MKL install folder)

Regards,

Ying

Ying_H_Intel

Employee

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content

11-02-2009
01:04 AM

9 Views

Hi Lamoid,

What's the purpose for you to get the exact Q matrix? The QR decom in small matrix domain ismainly forsolve the least squares (LS) small-sizeproblem, so no explicit Q generated. But sure, you can caculate it by Q=A*inv.

If you are developing somemath compuation application, there are another library named MKL (math kernal library, http://software.intel.com/en-us/intel-mkl/, which provide more routines to support math compuation. You may try it.

For example, it includes some routines like *geqrf() and *orggr()

To compute the elements of Q explicitly, call

SGEQRF()

then

sorgqr (for real matrices)

(one fortransample code is under MKL install folder)

Regards,

Ying

For more complete information about compiler optimizations, see our Optimization Notice.