sla.qr {RScaLAPACK}R Documentation

The QR Decomposition of a Matrix (Using ScaLAPACK)

Description

The function sla.qr computes the QR decomposition of a matrix using the ScaLAPACK library routine PDGEQRF.

Usage

sla.qr(A, NPROWS=0, NPCOLS=0, MB=16, RFLAG = 1, SPAWN = 1 )

Arguments

A

A numeric matrix whose QR decomposition is to be computed.

NPROWS

Number of Process Rows in the Process Grid.

NPCOLS

Number of Process Cols in the Process Grid.

MB

Block Size.

RFLAG

Flag saying whether the Process Grid should be released after computation.

SPAWN

Flag saying whether a new Process Grid should be spawned.

Details

If the number of processor rows and columns are both zero, one processor is used. If the number of processor rows is nonzero and the number of processor columns is zero, then the processor rows is taken to be a number of processors, and a grid is made accordingly.

Value

The QR decomposition of the matrix as computed by PDGEQRF is returned.

qr

a matrix with the same dimensions as A. The upper triangle contains the \bold{R} of the decomposition and the lower triangle contains a representation of the \bold{Q} of the decomposition (stored in the LAPACK compact form).

qraux

a vector of length min(ncol(A),nrow(A) which contains information needed to extract \bold{Q}.

rank

the length of vector \bold{qraux}.

Author(s)

Nagiza Samatova (samatovan@ornl.gov), Guruprasad Kora (koragh@ornl.gov), Srikanth Yoginath (yoginathsb@ornl.gov), David Bauer (bauerda@ornl.gov)

References

http://mathworld.wolfram.com/QRDecomposition.html

http://www.netlib.org/scalapack/

See Also

qr for the normal solving function.

Examples

library(RScaLAPACK)
rnorm(10000)->x
dim(x)=c(100,100)
sla.qr(x, NPROWS=2,NPCOLS=2)

[Package RScaLAPACK version 0.6.1 Index]