diff options
Diffstat (limited to 'SRC/dsytri2.f')
-rw-r--r-- | SRC/dsytri2.f | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/SRC/dsytri2.f b/SRC/dsytri2.f index ed32d543..6e1fa5bd 100644 --- a/SRC/dsytri2.f +++ b/SRC/dsytri2.f @@ -7,6 +7,7 @@ * * -- Written by Julie Langou of the Univ. of TN -- * +* @generated d * .. Scalar Arguments .. CHARACTER UPLO INTEGER INFO, LDA, LWORK, N @@ -19,7 +20,7 @@ * Purpose * ======= * -* DSYTRI2 computes the inverse of a real symmetric indefinite matrix +* DSYTRI2 computes the inverse of a DOUBLE PRECISION hermitian indefinite matrix * A using the factorization A = U*D*U**T or A = L*D*L**T computed by * DSYTRF. DSYTRI2 sets the LEADING DIMENSION of the workspace * before calling DSYTRI2X that actually computes the inverse. @@ -94,7 +95,11 @@ LQUERY = ( LWORK.EQ.-1 ) * Get blocksize NBMAX = ILAENV( 1, 'DSYTRF', UPLO, N, -1, -1, -1 ) - MINSIZE = (N+NBMAX+1)*(NBMAX+3) + IF ( NBMAX .GE. N ) THEN + MINSIZE = N + ELSE + MINSIZE = (N+NBMAX+1)*(NBMAX+3) + END IF * IF( .NOT.UPPER .AND. .NOT.LSAME( UPLO, 'L' ) ) THEN INFO = -1 @@ -113,13 +118,17 @@ CALL XERBLA( 'DSYTRI2', -INFO ) RETURN ELSE IF( LQUERY ) THEN - WORK(1)=(N+NBMAX+1)*(NBMAX+3) + WORK(1)=MINSIZE RETURN END IF IF( N.EQ.0 ) $ RETURN - CALL DSYTRI2X( UPLO, N, A, LDA, IPIV, WORK, NBMAX, INFO ) + IF( NBMAX .GE. N ) THEN + CALL DSYTRI( UPLO, N, A, LDA, IPIV, WORK, INFO ) + ELSE + CALL DSYTRI2X( UPLO, N, A, LDA, IPIV, WORK, NBMAX, INFO ) + END IF RETURN * * End of DSYTRI2 |