QRDecomp

Computes the QR decomposition for the given matrix.

Syntax

Case 1: Matrix operation

IppStatus ippmQRDecomp_m_32f(const Ipp32f* pSrc, int srcStride1, int srcStride2, Ipp32f* pBuffer, Ipp32f* pDst, int dstStride1, int dstStride2, int width, int height);

IppStatus ippmQRDecomp_m_64f(const Ipp64f* pSrc, int srcStride1, int srcStride2, Ipp64f* pBuffer, Ipp64f* pDst, int dstStride1, int dstStride2, int width, int height);

IppStatus ippmQRDecomp_m_32f_P(const Ipp32f** ppSrc, int srcRoiShift, Ipp32f* pBuffer, Ipp32f** ppDst, int dstRoiShift, int width, int height);

IppStatus ippmQRDecomp_m_64f_P(const Ipp64f** ppSrc, int srcRoiShift, Ipp64f* pBuffer, Ipp64f** ppDst, int dstRoiShift, int width, int height);

Case 2: Matrix array operation

IppStatus ippmQRDecomp_ma_32f(const Ipp32f* pSrc, int srcStride0, int srcStride1, int srcStride2, Ipp32f* pBuffer, Ipp32f* pDst, int dstStride0, int dstStride1, int dstStride2, int width, int height, int count);

IppStatus ippmQRDecomp_ma_64f(const Ipp64f* pSrc, int srcStride0, int srcStride1, int srcStride2, Ipp64f* pBuffer, Ipp64f* pDst, int dstStride0, int dstStride1, int dstStride2, int width, int height, int count);

IppStatus ippmQRDecomp_ma_32f_P(const Ipp32f** ppSrc, int srcRoiShift, int srcStride0, Ipp32f* pBuffer, Ipp32f** ppDst, int dstRoiShift, int dstStride0, int width, int height, int count);

IppStatus ippmQRDecomp_ma_64f_P(const Ipp64f** ppSrc, int srcRoiShift, int srcStride0, Ipp64f* pBuffer, Ipp64f** ppDst, int dstRoiShift, int dstStride0, int width, int height, int count);

IppStatus ippmQRDecomp_ma_32f_L(const Ipp32f** ppSrc, int srcRoiShift, int srcStride1, int srcStride2, Ipp32f* pBuffer, Ipp32f** ppDst, int dstRoiShift, int dstStride1, int dstStride2, int width, int height, int count);

IppStatus ippmQRDecomp_ma_64f_L(const Ipp64f** ppSrc, int srcRoiShift, int srcStride1, int srcStride2, Ipp64f* pBuffer, Ipp64f** ppDst, int dstRoiShift, int dstStride1, int dstStride2, int width, int height, int count);

Parameters

pSrc, ppSrc

Pointer to the source matrix or array of matrices.

srcStride0

Stride between the matrices in source array.

srcStride1

Stride between the rows in the source matrix(ces).

srcStride2

Stride between the elements in the source matrix(ces).

srcRoiShift

ROI shift in the source matrix(ces).

pBuffer

Pointer to a pre-allocated auxiliary array to be used for internal computations. The number of elements in the array must be at least height.

pDst, ppDst

Pointer to the destination matrix or array of matrices.

dstStride0

Stride between the matrices in the destination array.

dstStride1

Stride between the rows in the destination matrix.

dstStride2

Stride between the elements in the destination matrix.

dstRoiShift

ROI shift in the destination matrix.

width

Matrix width.

height

Matrix height.

count

Number of matrices in the array.

Description

The function ippmQRDecomp is declared in the ippm.h header file. The function computes the QR decomposition of a general matrix A without the use of pivoting. The number of rows height is greater or equal to the number of columns width, that is rank (A) = width.

The function forms the matrix Q implicitly. Instead of Q, Householder vectors Vn are stored, width in number. The first (n -1) components of each Householder vector Vn are not stored because they are equal to 0. The n-th component of each Householder vector Vn is not stored either because it is equal to 1. The last (height - n) elements of vector Vn are located below the diagonal of the pDst, or ppDst, matrix. The remaining elements of the pDst, or ppDst, matrix form the upper triangular matrix R (see Figure QR Decomposition Matrix Storage).

QR Decomposition Matrix Storage

Mathematically, the matrix Q is represented as a product of width elementary reflections

Q = H 1 * H2 *...* Hk , where k = width.

Each elementary reflection is

Hn = I - (2/r) Vn * VnT ,

where Vn is the Householder vector, I is the identity matrix,



Return Values

ippStsOk

Returns no error.

ippStsNullPtrErr

Returns an error when one of the input pointers is NULL.

ippStsSizeErr

Returns an error when the size of the source matrix is equal to 0.

ippStsDivByZeroErr

Returns an error when the source matrix has an incomplete column rank.

ippStsStrideMatrixErr

Returns an error when the stride value is not positive or not divisible by size of data type.

ippStsRoiShiftMatrixErr

Returns an error when the roiShift value is negative or not divisible by size of data type.

ippStsCountMatrixErr

Returns an error when the count value is less or equal to zero.

ippStsSizeMatchMatrixErr

Returns an error when the sizes of the source matrices are unsuitable.

Submit feedback on this help topic

Copyright © 2000 - 2010, Intel Corporation. All rights reserved.