f02xef

f02xef © Numerical Algorithms Group, 2002.

Purpose

F02XEF SVD of complex matrix

Synopsis

[a,q,sv,ph,b,ifail] = f02xef(a<,wantp,wantq,b,ifail>)

Description

 
 The m by n matrix A is factorized as
 
                                   H
                              A=QDP ,
 
 where
 
       (S)           
     D=(0)           m>n,
 
     D=S,            m=n,
 
     D=(S 0),        m<n,
 
 Q is an m by m unitary matrix, P is an n by n unitary matrix and 
 S is a min(m,n) by min(m,n) diagonal matrix with real non-
 negative diagonal elements, sv ,sv ,...,sv        , ordered such 
                               1   2       min(m,n)              
 that
 
                   sv >=sv >=...>=sv        >=0.
                     1    2         min(m,n)
 
 The first min(m,n) columns of Q are the left-hand singular 
 vectors of A, the diagonal elements of S are the singular values 
 of A and the first min(m,n) columns of P are the right-hand 
 singular vectors of A.
 
 Either or both of the left-hand and right-hand singular vectors 
 of A may be requested and the matrix C given by
 
                                 H
                              C=Q B,
 
 where B is an m by ncolb given matrix, may also be requested.
 
 Note that if K is any unitary diagonal matrix so that
 
                                H
                              KK =I,
 
 then
 
                                      H
                           A=(QK)D(PK) 
 
 is also a singular value decomposition of A.
 

Parameters

f02xef

Required Input Arguments:

a (:,:)                               complex

Optional Input Arguments:                       <Default>

wantp                                 logical  1
wantq                                 logical  1
b (:,:)                               complex  zeros(size(a,1),1)
ifail                                 integer  -1

Output Arguments:

a (:,:)                               complex
q (:,:)                               complex
sv (:)                                real
ph (:,:)                              complex
b (:,:)                               complex
ifail                                 integer