145 SUBROUTINE slagtm( TRANS, N, NRHS, ALPHA, DL, D, DU, X, LDX, BETA,
155 INTEGER LDB, LDX, N, NRHS
159 REAL B( ldb, * ), D( * ), DL( * ), DU( * ),
167 parameter ( one = 1.0e+0, zero = 0.0e+0 )
183 IF( beta.EQ.zero )
THEN
189 ELSE IF( beta.EQ.-one )
THEN
192 b( i, j ) = -b( i, j )
197 IF( alpha.EQ.one )
THEN
198 IF( lsame( trans,
'N' ) )
THEN
204 b( 1, j ) = b( 1, j ) + d( 1 )*x( 1, j )
206 b( 1, j ) = b( 1, j ) + d( 1 )*x( 1, j ) +
208 b( n, j ) = b( n, j ) + dl( n-1 )*x( n-1, j ) +
211 b( i, j ) = b( i, j ) + dl( i-1 )*x( i-1, j ) +
212 $ d( i )*x( i, j ) + du( i )*x( i+1, j )
222 b( 1, j ) = b( 1, j ) + d( 1 )*x( 1, j )
224 b( 1, j ) = b( 1, j ) + d( 1 )*x( 1, j ) +
226 b( n, j ) = b( n, j ) + du( n-1 )*x( n-1, j ) +
229 b( i, j ) = b( i, j ) + du( i-1 )*x( i-1, j ) +
230 $ d( i )*x( i, j ) + dl( i )*x( i+1, j )
235 ELSE IF( alpha.EQ.-one )
THEN
236 IF( lsame( trans,
'N' ) )
THEN
242 b( 1, j ) = b( 1, j ) - d( 1 )*x( 1, j )
244 b( 1, j ) = b( 1, j ) - d( 1 )*x( 1, j ) -
246 b( n, j ) = b( n, j ) - dl( n-1 )*x( n-1, j ) -
249 b( i, j ) = b( i, j ) - dl( i-1 )*x( i-1, j ) -
250 $ d( i )*x( i, j ) - du( i )*x( i+1, j )
260 b( 1, j ) = b( 1, j ) - d( 1 )*x( 1, j )
262 b( 1, j ) = b( 1, j ) - d( 1 )*x( 1, j ) -
264 b( n, j ) = b( n, j ) - du( n-1 )*x( n-1, j ) -
267 b( i, j ) = b( i, j ) - du( i-1 )*x( i-1, j ) -
268 $ d( i )*x( i, j ) - dl( i )*x( i+1, j )
subroutine slagtm(TRANS, N, NRHS, ALPHA, DL, D, DU, X, LDX, BETA, B, LDB)
SLAGTM performs a matrix-matrix product of the form C = αAB+βC, where A is a tridiagonal matrix...