• RGG

    From db@21:1/5 to All on Sat Nov 25 11:15:03 2023
    The subroutine RGG, that computes eigenvalues and -vectors,
    has me a bit confused, with respect to where the eigenvectors
    are. It says

    SUBROUTINE RGG(NM,N,A,B,ALFR,ALFI,BETA,MATZ,Z,IERR)
    C
    INTEGER N,NM,IERR,MATZ
    DOUBLE PRECISION A(NM,N),B(NM,N),ALFR(N),ALFI(N),BETA(N),Z(NM,N)
    LOGICAL TF
    [...]

    C ON OUTPUT

    [...]

    C Z CONTAINS THE REAL AND IMAGINARY PARTS OF THE EIGENVECTORS
    C IF MATZ IS NOT ZERO. IF THE J-TH EIGENVALUE IS REAL, THE
    C J-TH COLUMN OF Z CONTAINS ITS EIGENVECTOR. IF THE J-TH
    C EIGENVALUE IS COMPLEX WITH POSITIVE IMAGINARY PART, THE
    C J-TH AND (J+1)-TH COLUMNS OF Z CONTAIN THE REAL AND
    C IMAGINARY PARTS OF ITS EIGENVECTOR. THE CONJUGATE OF THIS
    C VECTOR IS THE EIGENVECTOR FOR THE CONJUGATE EIGENVALUE.

    It seems to mean that Z has N columns and 2N rows, to accommodate both
    real and imaginary vectors. But if the given Jth vector is at J and J+1, wouldn't that overwrite the next vector, which would be at J+1 and J+2?

    Where do I find the Jth complex eigenvector in Z?

    --
    Dieter Britz

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)