ILNumerics Ultimate VS

ILMathqr Method (InArraycomplex, OutArraycomplex, OutArrayInt32, Boolean)

ILNumerics Ultimate VS Documentation
ILNumerics - Technical Application Development
QR decomposition with pivoting, potentially size saving shapes.

[ILNumerics Computing Engine]

Namespace:  ILNumerics
Assembly:  ILNumerics.Computing (in ILNumerics.Computing.dll) Version: 5.5.0.0 (5.5.7503.3146)
Syntax

public static RetArray<complex> qr(
	InArray<complex> A,
	OutArray<complex> R = null,
	OutArray<int> E = null,
	bool economySize = false
)

Parameters

A
Type: ILNumericsInArraycomplex
Input matrix. Size [m x n].
R (Optional)
Type: ILNumericsOutArraycomplex
[Output, optional] Upper triangular matrix. Size [m x n] or [min(m,n) x n] depending on economySize (see remarks). Default: (null) do not compute R.
E (Optional)
Type: ILNumericsOutArrayInt32
[Output, optional] Permutation matrix from pivoting. Size [m x m]. Default: (null) do not return.E.
economySize (Optional)
Type: SystemBoolean
[Optional] True: return more efficient structures if possible. See remarks for details. Default: false.

Return Value

Type: RetArraycomplex
Orthonormal / unitary matrix Q as result of decomposing A. Size [m x m] or [m x min(m,n)], depending on economySize (see remarks).
Remarks

This function performs the QR decomposition on matrix A. It computes matrices Q, R and E, with Q ** R = A ** E, where '**' denotes matrix multiplication.

If R is null on entry, the function returns the compact QR decomposition result from qr(InArraycomplex).

If economySize is false, the function returns Q, R and E such that the equation

A * E = Q * R
holds within roundoff errors.

If economySize is true ...

  • and m >= n the size of Q and R will be [m x min(m,n)] and [min(m,n) x n] respectively. For m < n the sizes are not changed and as specified above.
  • the output parameter E is returned as vector [n] with permutation indices rather than as a permutation matrix [n,n]. In this case the equation
    A[":",E] == Q * R
    holds, except roundoff errors.

E reflects the pivoting of A done inside the LAPACK function performing the decomposition so that R shows increasing diagonal element values. If E is not requested (null) the equation Q ** R = A holds instead.

[ILNumerics Computing Engine]

See Also

Reference

MathInternal.qr(InArraycomplex, OutArraycomplex, Boolean)
MathInternal.svd(InArraycomplex, OutArraycomplex)
MathInternal.eig(InArraySingle, OutArrayfcomplex, MatrixProperties, Boolean)