Re: full QR decomposition

*To*: mathgroup at smc.vnet.net*Subject*: [mg51704] Re: full QR decomposition*From*: koopman at sfu.ca (Ray Koopman)*Date*: Fri, 29 Oct 2004 03:40:28 -0400 (EDT)*References*: <clprf3$a4b$1@smc.vnet.net>*Sender*: owner-wri-mathgroup at wolfram.com

Jan Schmedes <schmedes at rz.uni-potsdam.de> wrote in message news:<clprf3$a4b$1 at smc.vnet.net>... > i have the following problem. For a given a NxM (e.g. 3000x600) matrix A i > get a matrix Q (MxN) and R (MxM) after the QRDecomposition. But i would > like to get the full decomposition with a matrix QF (NxN) and RF (NxM) where > RF contains only zero lines below the line with index M. I'm especially > interrested in the last N-M lines in QF which create the zero lines in RF. > At the moment i use QRDecomposition and append then N-M random lines to the > matrix Q. With this new matrix i go into the routine GramSchmidt and extract > the last N-M lines from the result. But this is very slow and i'm not sure if > it will always work? Are there any suggestions or hints? In[1]:= a = Table[Random[],{30},{6}]; q = First@QRDecomposition@a; qf = Join[q,First@QRDecomposition@Transpose@NullSpace@q]; Max at Abs[qf.Transpose@qf-IdentityMatrix@30] // InputForm Out[4]//InputForm= 8.881784197001252*^-16