no.uib.cipr.matrix
Class QR

java.lang.Object
  extended by no.uib.cipr.matrix.QR

public class QR
extends java.lang.Object

Computers QR decompositions


Constructor Summary
QR(int m, int n)
          Constructs an empty QR decomposition
 
Method Summary
 QR factor(DenseMatrix A)
          Computes an orthogonal decomposition
static QR factorize(Matrix A)
          Convenience method to compute a QR decomposition
 DenseMatrix getQ()
          Returns the orthogonal part of the factorization
 UpperTriangDenseMatrix getR()
          Returns the upper triangular factor
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

QR

public QR(int m,
          int n)
Constructs an empty QR decomposition

Parameters:
m - Number of rows. Must be larger than or equal the number of columns
n - Number of columns
Method Detail

factorize

public static QR factorize(Matrix A)
Convenience method to compute a QR decomposition

Parameters:
A - Matrix to decompose. Not modified
Returns:
Newly allocated decomposition

factor

public QR factor(DenseMatrix A)
Computes an orthogonal decomposition

Parameters:
A - Matrix to decompose. Overwritten on exit. Pass a copy to avoid this
Returns:
The current decomposition

getR

public UpperTriangDenseMatrix getR()
Returns the upper triangular factor


getQ

public DenseMatrix getQ()
Returns the orthogonal part of the factorization