linalg(deprecated)/QRdecomp - Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : linalg(deprecated)/QRdecomp

linalg(deprecated)

  

QRdecomp

  

QR decomposition of a matrix

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

QRdecomp(A)

QRdecomp(A, arg2, arg3, ...)

QRdecomp(A, Q='q', rank='r', fullspan=value)

Parameters

A

-

rectangular matrix

arg.i

-

(optional) is of the form name=val

rank='r'

-

(optional) for returning the rank of A

Q='q'

-

(optional) for returning the Q factor of A

fullspan=value

-

(optional) include null span in Q

Description

• 

Important: The linalg package has been deprecated. Use the superseding command LinearAlgebra[QRDecomposition], instead.

  

- For information on migrating linalg code to the new packages, see examples/LinearAlgebraMigration.

• 

The routine QRdecomp computes the QR decomposition of the matrix A.

• 

For matrices of floating-point entries, the numerically stable Householder-transformations are used.  For symbolic computation, the Gram-Schmidt process is applied.

• 

The result is an upper triangular matrix R.  The orthonormal (unitary) factor Q is passed back to the Q parameter.

• 

The default factorization is the full QR where R will have the same dimension as A.  Q will be a full rank square matrix whose first n columns span the column space of A and whose last m-n columns span the null space of A.

• 

If the (optional) fullspan arg is set to false, a Q1R1 factorization will be given where the Q1 factor will have the same dimension as A and, assuming A has full column rank, the columns of Q will span the column space of A. The R factor will be square and agree in dimension with Q.  The default for fullspan is true.

• 

If A is an n by n matrix then i],i=1..nR[i.

• 

If A contains complex entries, the Q factor will be unitary.

• 

The QR factorization can be used to generate a least squares solution to an overdetermined system of linear equations.  If Ax=b, and QR=A then Rx=transposeQb can be solved through backsubstitution.

• 

The command with(linalg,QRdecomp) allows the use of the abbreviated form of this command.

Examples

Important: The linalg package has been deprecated. Use the superseding command LinearAlgebra[QRDecomposition], instead.

withlinalg:

Amatrix3,3,1,2,3,0,0,1,2,3,4

A123001234

(1)

RQRdecompA,Q='q',rank='r'

R58551155055255001

(2)

rankR

Warning, unable to find a provably non-zero pivot

3

(3)

evalmq

552550001255550

(4)

Amatrix4,2,1,2,3,0,0,1,2,3

A12300123

(5)

RQRdecompA,Q='q',fullspan=false

R14414704627

(6)

rankR

Warning, unable to find a provably non-zero pivot

2

(7)

evalmq

141454622313141424627704626614713462462

(8)

See Also

linalg(deprecated)[backsub]

linalg(deprecated)[GramSchmidt]

linalg(deprecated)[leastsqrs]

linalg(deprecated)[rank]

LinearAlgebra