128 SUBROUTINE ssygs2( ITYPE, UPLO, N, A, LDA, B, LDB, INFO )
137 INTEGER INFO, ITYPE, LDA, LDB, N
140 REAL A( lda, * ), B( ldb, * )
147 parameter ( one = 1.0, half = 0.5 )
169 upper = lsame( uplo,
'U' )
170 IF( itype.LT.1 .OR. itype.GT.3 )
THEN
172 ELSE IF( .NOT.upper .AND. .NOT.lsame( uplo,
'L' ) )
THEN
174 ELSE IF( n.LT.0 )
THEN
176 ELSE IF( lda.LT.max( 1, n ) )
THEN
178 ELSE IF( ldb.LT.max( 1, n ) )
THEN
182 CALL xerbla(
'SSYGS2', -info )
186 IF( itype.EQ.1 )
THEN
200 CALL sscal( n-k, one / bkk, a( k, k+1 ), lda )
202 CALL saxpy( n-k, ct, b( k, k+1 ), ldb, a( k, k+1 ),
204 CALL ssyr2( uplo, n-k, -one, a( k, k+1 ), lda,
205 $ b( k, k+1 ), ldb, a( k+1, k+1 ), lda )
206 CALL saxpy( n-k, ct, b( k, k+1 ), ldb, a( k, k+1 ),
208 CALL strsv( uplo,
'Transpose',
'Non-unit', n-k,
209 $ b( k+1, k+1 ), ldb, a( k, k+1 ), lda )
225 CALL sscal( n-k, one / bkk, a( k+1, k ), 1 )
227 CALL saxpy( n-k, ct, b( k+1, k ), 1, a( k+1, k ), 1 )
228 CALL ssyr2( uplo, n-k, -one, a( k+1, k ), 1,
229 $ b( k+1, k ), 1, a( k+1, k+1 ), lda )
230 CALL saxpy( n-k, ct, b( k+1, k ), 1, a( k+1, k ), 1 )
231 CALL strsv( uplo,
'No transpose',
'Non-unit', n-k,
232 $ b( k+1, k+1 ), ldb, a( k+1, k ), 1 )
247 CALL strmv( uplo,
'No transpose',
'Non-unit', k-1, b,
248 $ ldb, a( 1, k ), 1 )
250 CALL saxpy( k-1, ct, b( 1, k ), 1, a( 1, k ), 1 )
251 CALL ssyr2( uplo, k-1, one, a( 1, k ), 1, b( 1, k ), 1,
253 CALL saxpy( k-1, ct, b( 1, k ), 1, a( 1, k ), 1 )
254 CALL sscal( k-1, bkk, a( 1, k ), 1 )
255 a( k, k ) = akk*bkk**2
267 CALL strmv( uplo,
'Transpose',
'Non-unit', k-1, b, ldb,
270 CALL saxpy( k-1, ct, b( k, 1 ), ldb, a( k, 1 ), lda )
271 CALL ssyr2( uplo, k-1, one, a( k, 1 ), lda, b( k, 1 ),
273 CALL saxpy( k-1, ct, b( k, 1 ), ldb, a( k, 1 ), lda )
274 CALL sscal( k-1, bkk, a( k, 1 ), lda )
275 a( k, k ) = akk*bkk**2
subroutine ssyr2(UPLO, N, ALPHA, X, INCX, Y, INCY, A, LDA)
SSYR2
subroutine ssygs2(ITYPE, UPLO, N, A, LDA, B, LDB, INFO)
SSYGS2 reduces a symmetric definite generalized eigenproblem to standard form, using the factorizatio...
subroutine xerbla(SRNAME, INFO)
XERBLA
subroutine strmv(UPLO, TRANS, DIAG, N, A, LDA, X, INCX)
STRMV
subroutine strsv(UPLO, TRANS, DIAG, N, A, LDA, X, INCX)
STRSV
subroutine saxpy(N, SA, SX, INCX, SY, INCY)
SAXPY
subroutine sscal(N, SA, SX, INCX)
SSCAL