[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference rusure::math

Title:Mathematics at DEC
Moderator:RUSURE::EDP
Created:Mon Feb 03 1986
Last Modified:Fri Jun 06 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:2083
Total number of notes:14613

1760.0. "matrix factor into row and column vecotrs?" by STAR::ABBASI () Thu May 27 1993 20:04

    hi,

    any one knows a routine that takes a square matrix A and
    returns 2 vectors that their products is A ?

    i.e  A = uv, only A is given, and I need to find u and v.

    offcourse the solution is not unique.

    I think there is probably a routine already written for this.  
    I thought I'll ask while Iam looking around.
    
    thank you,
    \nasser
T.RTitleUserPersonal
Name
DateLines
1760.1Overdetermined.CADSYS::COOPERTopher CooperThu May 27 1993 20:4511
1760.2you're both rightAUSSIE::GARSONnouveau pauvreThu May 27 1993 22:3914
    re .0
    
    Just off the top of my head, a solution exists iff each row of the
    matrix is a (real) multiple of the first row that is not all zeros,
    in which case the solution is non-unique and takes the form
    
    u = t * (a column giving the multiples)
    
    v = 1/t * (the first row that is not all zeros)
    
    where t is an arbitrary non-zero real number.
    
    [The special case where the matrix is entirely zeros, not covered by the
     above, has obvious solutions and many of them.]
1760.3SVD will test for thisGAUSS::ROTHGeometry is the real life!Thu May 27 1993 22:3916
    I assume you mean the matrix is the outer product of the vectors.

	A[i,j] = u[i]*v[j]

    The criteria for this is for A to be rank 1, since all rows or
    columns are scalar multiples of each other.

    The most numerically reliable way to get this would be based
    on a singular value decomposition since this would also indicate
    just how close A is to really satisfying this criteria.

    SVD routines are available in most linear algebra packages, and
    I have a copies of these.  (See Numerical Recipes for another one;
    the latest edition fixes some bugs in the first edition.)

    - Jim
1760.4GAUSS::ROTHGeometry is the real life!Thu May 27 1993 22:457
    By the way, if the matrix *really* is rank 1, then you could simply
    normalize each row or column to be a unit vector.

    Then the norms will form one of your vectors (up to sign) and
    one of the unit vectors will form the other.

    - Jim