Diff for /rpl/lapack/lapack/zhetf2.f between versions 1.13 and 1.14

version 1.13, 2012/12/14 14:22:47 version 1.14, 2014/01/27 09:24:36
Line 1 Line 1
 *> \brief \b ZHETF2 computes the factorization of a complex Hermitian matrix, using the diagonal pivoting method (unblocked algorithm).  *> \brief \b ZHETF2 computes the factorization of a complex Hermitian matrix, using the diagonal pivoting method (unblocked algorithm, calling Level 2 BLAS).
 *  *
 *  =========== DOCUMENTATION ===========  *  =========== DOCUMENTATION ===========
 *  *
 * Online html documentation available at   * Online html documentation available at
 *            http://www.netlib.org/lapack/explore-html/   *            http://www.netlib.org/lapack/explore-html/
 *  *
 *> \htmlonly  *> \htmlonly
 *> Download ZHETF2 + dependencies   *> Download ZHETF2 + dependencies
 *> <a href="http://www.netlib.org/cgi-bin/netlibfiles.tgz?format=tgz&filename=/lapack/lapack_routine/zhetf2.f">   *> <a href="http://www.netlib.org/cgi-bin/netlibfiles.tgz?format=tgz&filename=/lapack/lapack_routine/zhetf2.f">
 *> [TGZ]</a>   *> [TGZ]</a>
 *> <a href="http://www.netlib.org/cgi-bin/netlibfiles.zip?format=zip&filename=/lapack/lapack_routine/zhetf2.f">   *> <a href="http://www.netlib.org/cgi-bin/netlibfiles.zip?format=zip&filename=/lapack/lapack_routine/zhetf2.f">
 *> [ZIP]</a>   *> [ZIP]</a>
 *> <a href="http://www.netlib.org/cgi-bin/netlibfiles.txt?format=txt&filename=/lapack/lapack_routine/zhetf2.f">   *> <a href="http://www.netlib.org/cgi-bin/netlibfiles.txt?format=txt&filename=/lapack/lapack_routine/zhetf2.f">
 *> [TXT]</a>  *> [TXT]</a>
 *> \endhtmlonly   *> \endhtmlonly
 *  *
 *  Definition:  *  Definition:
 *  ===========  *  ===========
 *  *
 *       SUBROUTINE ZHETF2( UPLO, N, A, LDA, IPIV, INFO )  *       SUBROUTINE ZHETF2( UPLO, N, A, LDA, IPIV, INFO )
 *   *
 *       .. Scalar Arguments ..  *       .. Scalar Arguments ..
 *       CHARACTER          UPLO  *       CHARACTER          UPLO
 *       INTEGER            INFO, LDA, N  *       INTEGER            INFO, LDA, N
Line 28 Line 28
 *       INTEGER            IPIV( * )  *       INTEGER            IPIV( * )
 *       COMPLEX*16         A( LDA, * )  *       COMPLEX*16         A( LDA, * )
 *       ..  *       ..
 *    *
 *  *
 *> \par Purpose:  *> \par Purpose:
 *  =============  *  =============
Line 90 Line 90
 *> \verbatim  *> \verbatim
 *>          IPIV is INTEGER array, dimension (N)  *>          IPIV is INTEGER array, dimension (N)
 *>          Details of the interchanges and the block structure of D.  *>          Details of the interchanges and the block structure of D.
 *>          If IPIV(k) > 0, then rows and columns k and IPIV(k) were  *>
 *>          interchanged and D(k,k) is a 1-by-1 diagonal block.  *>          If UPLO = 'U':
 *>          If UPLO = 'U' and IPIV(k) = IPIV(k-1) < 0, then rows and  *>             If IPIV(k) > 0, then rows and columns k and IPIV(k) were
 *>          columns k-1 and -IPIV(k) were interchanged and D(k-1:k,k-1:k)  *>             interchanged and D(k,k) is a 1-by-1 diagonal block.
 *>          is a 2-by-2 diagonal block.  If UPLO = 'L' and IPIV(k) =  *>
 *>          IPIV(k+1) < 0, then rows and columns k+1 and -IPIV(k) were  *>             If IPIV(k) = IPIV(k-1) < 0, then rows and columns
 *>          interchanged and D(k:k+1,k:k+1) is a 2-by-2 diagonal block.  *>             k-1 and -IPIV(k) were interchanged and D(k-1:k,k-1:k)
   *>             is a 2-by-2 diagonal block.
   *>
   *>          If UPLO = 'L':
   *>             If IPIV(k) > 0, then rows and columns k and IPIV(k) were
   *>             interchanged and D(k,k) is a 1-by-1 diagonal block.
   *>
   *>             If IPIV(k) = IPIV(k+1) < 0, then rows and columns
   *>             k+1 and -IPIV(k) were interchanged and D(k:k+1,k:k+1)
   *>             is a 2-by-2 diagonal block.
 *> \endverbatim  *> \endverbatim
 *>  *>
 *> \param[out] INFO  *> \param[out] INFO
Line 113 Line 122
 *  Authors:  *  Authors:
 *  ========  *  ========
 *  *
 *> \author Univ. of Tennessee   *> \author Univ. of Tennessee
 *> \author Univ. of California Berkeley   *> \author Univ. of California Berkeley
 *> \author Univ. of Colorado Denver   *> \author Univ. of Colorado Denver
 *> \author NAG Ltd.   *> \author NAG Ltd.
 *  *
 *> \date September 2012  *> \date November 2013
 *  *
 *> \ingroup complex16HEcomputational  *> \ingroup complex16HEcomputational
 *  *
Line 182 Line 191
 *  =====================================================================  *  =====================================================================
       SUBROUTINE ZHETF2( UPLO, N, A, LDA, IPIV, INFO )        SUBROUTINE ZHETF2( UPLO, N, A, LDA, IPIV, INFO )
 *  *
 *  -- LAPACK computational routine (version 3.4.2) --  *  -- LAPACK computational routine (version 3.5.0) --
 *  -- LAPACK is a software package provided by Univ. of Tennessee,    --  *  -- LAPACK is a software package provided by Univ. of Tennessee,    --
 *  -- Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..--  *  -- Univ. of California Berkeley, Univ. of Colorado Denver and NAG Ltd..--
 *     September 2012  *     November 2013
 *  *
 *     .. Scalar Arguments ..  *     .. Scalar Arguments ..
       CHARACTER          UPLO        CHARACTER          UPLO
Line 273 Line 282
          ABSAKK = ABS( DBLE( A( K, K ) ) )           ABSAKK = ABS( DBLE( A( K, K ) ) )
 *  *
 *        IMAX is the row-index of the largest off-diagonal element in  *        IMAX is the row-index of the largest off-diagonal element in
 *        column K, and COLMAX is its absolute value  *        column K, and COLMAX is its absolute value.
   *        Determine both COLMAX and IMAX.
 *  *
          IF( K.GT.1 ) THEN           IF( K.GT.1 ) THEN
             IMAX = IZAMAX( K-1, A( 1, K ), 1 )              IMAX = IZAMAX( K-1, A( 1, K ), 1 )
Line 284 Line 294
 *  *
          IF( (MAX( ABSAKK, COLMAX ).EQ.ZERO) .OR. DISNAN(ABSAKK) ) THEN           IF( (MAX( ABSAKK, COLMAX ).EQ.ZERO) .OR. DISNAN(ABSAKK) ) THEN
 *  *
 *           Column K is zero or contains a NaN: set INFO and continue  *           Column K is zero or underflow, or contains a NaN:
   *           set INFO and continue
 *  *
             IF( INFO.EQ.0 )              IF( INFO.EQ.0 )
      $         INFO = K       $         INFO = K
             KP = K              KP = K
             A( K, K ) = DBLE( A( K, K ) )              A( K, K ) = DBLE( A( K, K ) )
          ELSE           ELSE
   *
   *           ============================================================
   *
   *           Test for interchange
   *
             IF( ABSAKK.GE.ALPHA*COLMAX ) THEN              IF( ABSAKK.GE.ALPHA*COLMAX ) THEN
 *  *
 *              no interchange, use 1-by-1 pivot block  *              no interchange, use 1-by-1 pivot block
Line 299 Line 315
             ELSE              ELSE
 *  *
 *              JMAX is the column-index of the largest off-diagonal  *              JMAX is the column-index of the largest off-diagonal
 *              element in row IMAX, and ROWMAX is its absolute value  *              element in row IMAX, and ROWMAX is its absolute value.
   *              Determine only ROWMAX.
 *  *
                JMAX = IMAX + IZAMAX( K-IMAX, A( IMAX, IMAX+1 ), LDA )                 JMAX = IMAX + IZAMAX( K-IMAX, A( IMAX, IMAX+1 ), LDA )
                ROWMAX = CABS1( A( IMAX, JMAX ) )                 ROWMAX = CABS1( A( IMAX, JMAX ) )
Line 313 Line 330
 *                 no interchange, use 1-by-1 pivot block  *                 no interchange, use 1-by-1 pivot block
 *  *
                   KP = K                    KP = K
   *
                ELSE IF( ABS( DBLE( A( IMAX, IMAX ) ) ).GE.ALPHA*ROWMAX )                 ELSE IF( ABS( DBLE( A( IMAX, IMAX ) ) ).GE.ALPHA*ROWMAX )
      $                   THEN       $                   THEN
 *  *
Line 328 Line 346
                   KP = IMAX                    KP = IMAX
                   KSTEP = 2                    KSTEP = 2
                END IF                 END IF
   *
             END IF              END IF
 *  *
   *           ============================================================
   *
             KK = K - KSTEP + 1              KK = K - KSTEP + 1
             IF( KP.NE.KK ) THEN              IF( KP.NE.KK ) THEN
 *  *
Line 456 Line 477
          ABSAKK = ABS( DBLE( A( K, K ) ) )           ABSAKK = ABS( DBLE( A( K, K ) ) )
 *  *
 *        IMAX is the row-index of the largest off-diagonal element in  *        IMAX is the row-index of the largest off-diagonal element in
 *        column K, and COLMAX is its absolute value  *        column K, and COLMAX is its absolute value.
   *        Determine both COLMAX and IMAX.
 *  *
          IF( K.LT.N ) THEN           IF( K.LT.N ) THEN
             IMAX = K + IZAMAX( N-K, A( K+1, K ), 1 )              IMAX = K + IZAMAX( N-K, A( K+1, K ), 1 )
Line 467 Line 489
 *  *
          IF( (MAX( ABSAKK, COLMAX ).EQ.ZERO) .OR. DISNAN(ABSAKK) ) THEN           IF( (MAX( ABSAKK, COLMAX ).EQ.ZERO) .OR. DISNAN(ABSAKK) ) THEN
 *  *
 *           Column K is zero or contains a NaN: set INFO and continue  *           Column K is zero or underflow, or contains a NaN:
   *           set INFO and continue
 *  *
             IF( INFO.EQ.0 )              IF( INFO.EQ.0 )
      $         INFO = K       $         INFO = K
             KP = K              KP = K
             A( K, K ) = DBLE( A( K, K ) )              A( K, K ) = DBLE( A( K, K ) )
          ELSE           ELSE
   *
   *           ============================================================
   *
   *           Test for interchange
   *
             IF( ABSAKK.GE.ALPHA*COLMAX ) THEN              IF( ABSAKK.GE.ALPHA*COLMAX ) THEN
 *  *
 *              no interchange, use 1-by-1 pivot block  *              no interchange, use 1-by-1 pivot block
Line 482 Line 510
             ELSE              ELSE
 *  *
 *              JMAX is the column-index of the largest off-diagonal  *              JMAX is the column-index of the largest off-diagonal
 *              element in row IMAX, and ROWMAX is its absolute value  *              element in row IMAX, and ROWMAX is its absolute value.
   *              Determine only ROWMAX.
 *  *
                JMAX = K - 1 + IZAMAX( IMAX-K, A( IMAX, K ), LDA )                 JMAX = K - 1 + IZAMAX( IMAX-K, A( IMAX, K ), LDA )
                ROWMAX = CABS1( A( IMAX, JMAX ) )                 ROWMAX = CABS1( A( IMAX, JMAX ) )
Line 496 Line 525
 *                 no interchange, use 1-by-1 pivot block  *                 no interchange, use 1-by-1 pivot block
 *  *
                   KP = K                    KP = K
   *
                ELSE IF( ABS( DBLE( A( IMAX, IMAX ) ) ).GE.ALPHA*ROWMAX )                 ELSE IF( ABS( DBLE( A( IMAX, IMAX ) ) ).GE.ALPHA*ROWMAX )
      $                   THEN       $                   THEN
 *  *
Line 511 Line 541
                   KP = IMAX                    KP = IMAX
                   KSTEP = 2                    KSTEP = 2
                END IF                 END IF
   *
             END IF              END IF
 *  *
   *           ============================================================
   *
             KK = K + KSTEP - 1              KK = K + KSTEP - 1
             IF( KP.NE.KK ) THEN              IF( KP.NE.KK ) THEN
 *  *

Removed from v.1.13  
changed lines
  Added in v.1.14


CVSweb interface <joel.bertrand@systella.fr>