203 SUBROUTINE dlarhs( PATH, XTYPE, UPLO, TRANS, M, N, KL, KU, NRHS,
204 $ A, LDA, X, LDX, B, LDB, ISEED, INFO )
211 CHARACTER TRANS, UPLO, XTYPE
213 INTEGER INFO, KL, KU, LDA, LDB, LDX, M, N, NRHS
217 DOUBLE PRECISION A( LDA, * ), B( LDB, * ), X( LDX, * )
223 DOUBLE PRECISION ONE, ZERO
224 parameter( one = 1.0d+0, zero = 0.0d+0 )
227 LOGICAL BAND, GEN, NOTRAN, QRS, SYM, TRAN, TRI
233 LOGICAL LSAME, LSAMEN
234 EXTERNAL lsame, lsamen
250 tran = lsame( trans,
'T' ) .OR. lsame( trans,
'C' )
252 gen = lsame( path( 2: 2 ),
'G' )
253 qrs = lsame( path( 2: 2 ),
'Q' ) .OR. lsame( path( 3: 3 ),
'Q' )
254 sym = lsame( path( 2: 2 ),
'P' ) .OR. lsame( path( 2: 2 ),
'S' )
255 tri = lsame( path( 2: 2 ),
'T' )
256 band = lsame( path( 3: 3 ),
'B' )
257 IF( .NOT.lsame( c1,
'Double precision' ) )
THEN
259 ELSE IF( .NOT.( lsame( xtype,
'N' ) .OR. lsame( xtype,
'C' ) ) )
262 ELSE IF( ( sym .OR. tri ) .AND. .NOT.
263 $ ( lsame( uplo,
'U' ) .OR. lsame( uplo,
'L' ) ) )
THEN
265 ELSE IF( ( gen .OR. qrs ) .AND. .NOT.
266 $ ( tran .OR. lsame( trans,
'N' ) ) )
THEN
268 ELSE IF( m.LT.0 )
THEN
270 ELSE IF( n.LT.0 )
THEN
272 ELSE IF( band .AND. kl.LT.0 )
THEN
274 ELSE IF( band .AND. ku.LT.0 )
THEN
276 ELSE IF( nrhs.LT.0 )
THEN
278 ELSE IF( ( .NOT.band .AND. lda.LT.max( 1, m ) ) .OR.
279 $ ( band .AND. ( sym .OR. tri ) .AND. lda.LT.kl+1 ) .OR.
280 $ ( band .AND. gen .AND. lda.LT.kl+ku+1 ) )
THEN
282 ELSE IF( ( notran .AND. ldx.LT.max( 1, n ) ) .OR.
283 $ ( tran .AND. ldx.LT.max( 1, m ) ) )
THEN
285 ELSE IF( ( notran .AND. ldb.LT.max( 1, m ) ) .OR.
286 $ ( tran .AND. ldb.LT.max( 1, n ) ) )
THEN
290 CALL xerbla(
'DLARHS', -info )
303 IF( .NOT.lsame( xtype,
'C' ) )
THEN
305 CALL dlarnv( 2, iseed, n, x( 1, j ) )
312 IF( lsamen( 2, c2,
'GE' ) .OR. lsamen( 2, c2,
'QR' ) .OR.
313 $ lsamen( 2, c2,
'LQ' ) .OR. lsamen( 2, c2,
'QL' ) .OR.
314 $ lsamen( 2, c2,
'RQ' ) )
THEN
318 CALL dgemm( trans,
'N', mb, nrhs, nx, one, a, lda, x, ldx,
321 ELSE IF( lsamen( 2, c2,
'PO' ) .OR. lsamen( 2, c2,
'SY' ) )
THEN
325 CALL dsymm(
'Left', uplo, n, nrhs, one, a, lda, x, ldx, zero,
328 ELSE IF( lsamen( 2, c2,
'GB' ) )
THEN
333 CALL dgbmv( trans, mb, nx, kl, ku, one, a, lda, x( 1, j ),
334 $ 1, zero, b( 1, j ), 1 )
337 ELSE IF( lsamen( 2, c2,
'PB' ) )
THEN
342 CALL dsbmv( uplo, n, kl, one, a, lda, x( 1, j ), 1, zero,
346 ELSE IF( lsamen( 2, c2,
'PP' ) .OR. lsamen( 2, c2,
'SP' ) )
THEN
351 CALL dspmv( uplo, n, one, a, x( 1, j ), 1, zero, b( 1, j ),
355 ELSE IF( lsamen( 2, c2,
'TR' ) )
THEN
361 CALL dlacpy(
'Full', n, nrhs, x, ldx, b, ldb )
367 CALL dtrmm(
'Left', uplo, trans, diag, n, nrhs, one, a, lda, b,
370 ELSE IF( lsamen( 2, c2,
'TP' ) )
THEN
374 CALL dlacpy(
'Full', n, nrhs, x, ldx, b, ldb )
381 CALL dtpmv( uplo, trans, diag, n, a, b( 1, j ), 1 )
384 ELSE IF( lsamen( 2, c2,
'TB' ) )
THEN
388 CALL dlacpy(
'Full', n, nrhs, x, ldx, b, ldb )
395 CALL dtbmv( uplo, trans, diag, n, kl, a, lda, b( 1, j ), 1 )
403 CALL xerbla(
'DLARHS', -info )
subroutine dlarhs(path, xtype, uplo, trans, m, n, kl, ku, nrhs, a, lda, x, ldx, b, ldb, iseed, info)
DLARHS
subroutine xerbla(srname, info)
subroutine dgbmv(trans, m, n, kl, ku, alpha, a, lda, x, incx, beta, y, incy)
DGBMV
subroutine dgemm(transa, transb, m, n, k, alpha, a, lda, b, ldb, beta, c, ldc)
DGEMM
subroutine dsbmv(uplo, n, k, alpha, a, lda, x, incx, beta, y, incy)
DSBMV
subroutine dsymm(side, uplo, m, n, alpha, a, lda, b, ldb, beta, c, ldc)
DSYMM
subroutine dspmv(uplo, n, alpha, ap, x, incx, beta, y, incy)
DSPMV
subroutine dlacpy(uplo, m, n, a, lda, b, ldb)
DLACPY copies all or part of one two-dimensional array to another.
subroutine dlarnv(idist, iseed, n, x)
DLARNV returns a vector of random numbers from a uniform or normal distribution.
subroutine dtbmv(uplo, trans, diag, n, k, a, lda, x, incx)
DTBMV
subroutine dtpmv(uplo, trans, diag, n, ap, x, incx)
DTPMV
subroutine dtrmm(side, uplo, transa, diag, m, n, alpha, a, lda, b, ldb)
DTRMM