Package ubic.basecode.math.linalg
Class Dqrsl
- java.lang.Object
- 
- ubic.basecode.math.linalg.Dqrsl
 
- 
 public class Dqrsl extends Object This class contains the LINPACK DQRDC (QR decomposition) and DQRSL (QR solve) routines. IMPORTANT: The "_j" suffixes indicate that these routines use Java/C style indexing. For example, you will see for (i = 0; i < n; i++) rather than for (i = 1; i <= n; i++) To use the "_j" routines you will have to fill elements 0 through n - 1 rather than elements 1 through n. Versions of these programs that use FORTYRAN style indexing are also available. They end with the suffix "_f77". This class was translated by a statistician from FORTRAN versions of the LINPACK routines. It is NOT an official translation. When public domain Java numerical analysis routines become available from the people who produce LAPACK, then THE CODE PRODUCED BY THE NUMERICAL ANALYSTS SHOULD BE USED. Meanwhile, if you have suggestions for improving this code, please contact Steve Verrill at sverrill@fs.fed.us.- Version:
- .5 --- June 5, 1997
- Author:
- Steve Verrill
 
- 
- 
Constructor SummaryConstructors Constructor Description Dqrsl()
 - 
Method SummaryAll Methods Static Methods Concrete Methods Modifier and Type Method Description static voiddqrdc_j(double[][] x, int n, int p, double[] qraux, int[] jpvt, int job)This method decomposes an n by p matrix X into a product, QR, of an orthogonal n by n matrix Q and an upper triangular n by p matrix R.static intdqrsl_j(double[][] x, int n, int k, double[] qraux, double[] y, double[] qy, double[] qty, double[] b, double[] rsd, double[] xb, int job)This method "applies the output of DQRDC to compute coordinate transformations, projections, and least squares solutions." For details, see the comments in the code.
 
- 
- 
- 
Method Detail- 
dqrdc_jpublic static void dqrdc_j(double[][] x, int n, int p, double[] qraux, int[] jpvt, int job)This method decomposes an n by p matrix X into a product, QR, of an orthogonal n by n matrix Q and an upper triangular n by p matrix R. For details, see the comments in the code. This method is a translation from FORTRAN to Java of the LINPACK subroutine DQRDC. In the LINPACK listing DQRDC is attributed to G.W. Stewart with a date of 8/14/78. Translated by Steve Verrill, February 25, 1997.- Parameters:
- X- The matrix to be decomposed
- n- The number of rows of the matrix X
- p- The number of columns of the matrix X
- qraux- This vector "contains further information required to recover the orthogonal part of the decomposition."
- jpvt- This output vector contains pivoting information.
- work- This vector is used as temporary space
- job- This value indicates whether column pivoting should be performed
 
 - 
dqrsl_jpublic static int dqrsl_j(double[][] x, int n, int k, double[] qraux, double[] y, double[] qy, double[] qty, double[] b, double[] rsd, double[] xb, int job)This method "applies the output of DQRDC to compute coordinate transformations, projections, and least squares solutions." For details, see the comments in the code. This method is a translation from FORTRAN to Java of the LINPACK subroutine DQRSL. In the LINPACK listing DQRSL is attributed to G.W. Stewart with a date of 8/14/78. Translated by Steve Verrill, February 27, 1997.- Parameters:
- X- This n by p matrix contains most of the output from DQRDC
- n- The number of rows of X
- k- k <= min(n,p) where p is the number of columns of X
- qraux- This vector "contains further information required to recover the orthogonal part of the decomposition"
- y- This n by 1 vector will be manipulated by DQRSL
- qy- On output, this vector contains Qy if it has been requested
- qty- On output, this vector contains transpose(Q)y if it has been requested
- b- Parameter estimates
- rsd- Residuals
- xb- Predicted values
- job- Specifies what is to be computed (see the code for details)
 
 
- 
 
-