Diff for /rpl/lapack/lapack/zhetrf_aa_2stage.f between versions 1.1 and 1.2

version 1.1, 2018/05/29 14:55:12 version 1.2, 2020/05/21 21:46:06
Line 38 Line 38
 *> ZHETRF_AA_2STAGE computes the factorization of a double hermitian matrix A  *> ZHETRF_AA_2STAGE computes the factorization of a double hermitian matrix A
 *> using the Aasen's algorithm.  The form of the factorization is  *> using the Aasen's algorithm.  The form of the factorization is
 *>  *>
 *>    A = U*T*U**T  or  A = L*T*L**T  *>    A = U**H*T*U  or  A = L*T*L**H
 *>  *>
 *> where U (or L) is a product of permutation and unit upper (lower)  *> where U (or L) is a product of permutation and unit upper (lower)
 *> triangular matrices, and T is a hermitian band matrix with the  *> triangular matrices, and T is a hermitian band matrix with the
Line 66 Line 66
 *>  *>
 *> \param[in,out] A  *> \param[in,out] A
 *> \verbatim  *> \verbatim
 *>          A is COMPLEX array, dimension (LDA,N)  *>          A is COMPLEX*16 array, dimension (LDA,N)
 *>          On entry, the hermitian matrix A.  If UPLO = 'U', the leading  *>          On entry, the hermitian matrix A.  If UPLO = 'U', the leading
 *>          N-by-N upper triangular part of A contains the upper  *>          N-by-N upper triangular part of A contains the upper
 *>          triangular part of the matrix A, and the strictly lower  *>          triangular part of the matrix A, and the strictly lower
Line 87 Line 87
 *>  *>
 *> \param[out] TB  *> \param[out] TB
 *> \verbatim  *> \verbatim
 *>          TB is COMPLEX array, dimension (LTB)  *>          TB is COMPLEX*16 array, dimension (LTB)
 *>          On exit, details of the LU factorization of the band matrix.  *>          On exit, details of the LU factorization of the band matrix.
 *> \endverbatim  *> \endverbatim
 *>  *>
 *> \param[in] LTB  *> \param[in] LTB
 *> \verbatim  *> \verbatim
   *>          LTB is INTEGER
 *>          The size of the array TB. LTB >= 4*N, internally  *>          The size of the array TB. LTB >= 4*N, internally
 *>          used to select NB such that LTB >= (3*NB+1)*N.  *>          used to select NB such that LTB >= (3*NB+1)*N.
 *>  *>
Line 112 Line 113
 *>  *>
 *> \param[out] IPIV2  *> \param[out] IPIV2
 *> \verbatim  *> \verbatim
 *>          IPIV is INTEGER array, dimension (N)  *>          IPIV2 is INTEGER array, dimension (N)
 *>          On exit, it contains the details of the interchanges, i.e.,  *>          On exit, it contains the details of the interchanges, i.e.,
 *>          the row and column k of T were interchanged with the  *>          the row and column k of T were interchanged with the
 *>          row and column IPIV(k).  *>          row and column IPIV(k).
Line 120 Line 121
 *>  *>
 *> \param[out] WORK  *> \param[out] WORK
 *> \verbatim  *> \verbatim
 *>          WORK is COMPLEX workspace of size LWORK  *>          WORK is COMPLEX*16 workspace of size LWORK
 *> \endverbatim  *> \endverbatim
 *>  *>
 *> \param[in] LWORK  *> \param[in] LWORK
 *> \verbatim  *> \verbatim
   *>          LWORK is INTEGER
 *>          The size of WORK. LWORK >= N, internally used to select NB  *>          The size of WORK. LWORK >= N, internally used to select NB
 *>          such that LWORK >= N*NB.  *>          such that LWORK >= N*NB.
 *>  *>
Line 274 Line 276
       IF( UPPER ) THEN        IF( UPPER ) THEN
 *  *
 *        .....................................................  *        .....................................................
 *        Factorize A as L*D*L**T using the upper triangle of A  *        Factorize A as U**H*D*U using the upper triangle of A
 *        .....................................................  *        .....................................................
 *  *
          DO J = 0, NT-1           DO J = 0, NT-1
Line 450  c               END IF Line 452  c               END IF
 *                    > Apply pivots to previous columns of L  *                    > Apply pivots to previous columns of L
                      CALL ZSWAP( K-1, A( (J+1)*NB+1, I1 ), 1,                        CALL ZSWAP( K-1, A( (J+1)*NB+1, I1 ), 1, 
      $                                A( (J+1)*NB+1, I2 ), 1 )       $                                A( (J+1)*NB+1, I2 ), 1 )
 *                    > Swap A(I1+1:M, I1) with A(I2, I1+1:M)                 *                    > Swap A(I1+1:M, I1) with A(I2, I1+1:M)
                      CALL ZSWAP( I2-I1-1, A( I1, I1+1 ), LDA,                       IF( I2.GT.(I1+1) ) THEN
      $                                    A( I1+1, I2 ), 1 )                          CALL ZSWAP( I2-I1-1, A( I1, I1+1 ), LDA,
        $                                       A( I1+1, I2 ), 1 )
                           CALL ZLACGV( I2-I1-1, A( I1+1, I2 ), 1 )
                        END IF
                      CALL ZLACGV( I2-I1, A( I1, I1+1 ), LDA )                       CALL ZLACGV( I2-I1, A( I1, I1+1 ), LDA )
                      CALL ZLACGV( I2-I1-1, A( I1+1, I2 ), 1 )  
 *                    > Swap A(I2+1:M, I1) with A(I2+1:M, I2)  *                    > Swap A(I2+1:M, I1) with A(I2+1:M, I2)
                      CALL ZSWAP( N-I2, A( I1, I2+1 ), LDA,                       IF( I2.LT.N )
      $                                 A( I2, I2+1 ), LDA )        $                  CALL ZSWAP( N-I2, A( I1, I2+1 ), LDA,
        $                                    A( I2, I2+1 ), LDA ) 
 *                    > Swap A(I1, I1) with A(I2, I2)  *                    > Swap A(I1, I1) with A(I2, I2)
                      PIV = A( I1, I1 )                       PIV = A( I1, I1 )
                      A( I1, I1 ) = A( I2, I2 )                       A( I1, I1 ) = A( I2, I2 )
Line 474  c               END IF Line 479  c               END IF
       ELSE        ELSE
 *  *
 *        .....................................................  *        .....................................................
 *        Factorize A as L*D*L**T using the lower triangle of A  *        Factorize A as L*D*L**H using the lower triangle of A
 *        .....................................................  *        .....................................................
 *  *
          DO J = 0, NT-1           DO J = 0, NT-1
Line 627  c               END IF Line 632  c               END IF
 *                    > Apply pivots to previous columns of L  *                    > Apply pivots to previous columns of L
                      CALL ZSWAP( K-1, A( I1, (J+1)*NB+1 ), LDA,                        CALL ZSWAP( K-1, A( I1, (J+1)*NB+1 ), LDA, 
      $                                A( I2, (J+1)*NB+1 ), LDA )       $                                A( I2, (J+1)*NB+1 ), LDA )
 *                    > Swap A(I1+1:M, I1) with A(I2, I1+1:M)                 *                    > Swap A(I1+1:M, I1) with A(I2, I1+1:M)
                      CALL ZSWAP( I2-I1-1, A( I1+1, I1 ), 1,                       IF( I2.GT.(I1+1) ) THEN
      $                                    A( I2, I1+1 ), LDA )                          CALL ZSWAP( I2-I1-1, A( I1+1, I1 ), 1,
        $                                       A( I2, I1+1 ), LDA )
                           CALL ZLACGV( I2-I1-1, A( I2, I1+1 ), LDA )
                        END IF
                      CALL ZLACGV( I2-I1, A( I1+1, I1 ), 1 )                       CALL ZLACGV( I2-I1, A( I1+1, I1 ), 1 )
                      CALL ZLACGV( I2-I1-1, A( I2, I1+1 ), LDA )  
 *                    > Swap A(I2+1:M, I1) with A(I2+1:M, I2)  *                    > Swap A(I2+1:M, I1) with A(I2+1:M, I2)
                      CALL ZSWAP( N-I2, A( I2+1, I1 ), 1,                       IF( I2.LT.N )
      $                                 A( I2+1, I2 ), 1 )        $                  CALL ZSWAP( N-I2, A( I2+1, I1 ), 1,
        $                                    A( I2+1, I2 ), 1 ) 
 *                    > Swap A(I1, I1) with A(I2, I2)  *                    > Swap A(I1, I1) with A(I2, I2)
                      PIV = A( I1, I1 )                       PIV = A( I1, I1 )
                      A( I1, I1 ) = A( I2, I2 )                       A( I1, I1 ) = A( I2, I2 )
Line 658  c     $                     (J+1)*NB+1, Line 666  c     $                     (J+1)*NB+1,
 *     Factor the band matrix  *     Factor the band matrix
       CALL ZGBTRF( N, N, NB, NB, TB, LDTB, IPIV2, INFO )        CALL ZGBTRF( N, N, NB, NB, TB, LDTB, IPIV2, INFO )
 *  *
         RETURN
   *
 *     End of ZHETRF_AA_2STAGE  *     End of ZHETRF_AA_2STAGE
 *  *
       END        END

Removed from v.1.1  
changed lines
  Added in v.1.2


CVSweb interface <joel.bertrand@systella.fr>