127 SUBROUTINE claptm( UPLO, N, NRHS, ALPHA, D, E, X, LDX, BETA, B,
136 INTEGER LDB, LDX, N, NRHS
141 COMPLEX B( LDB, * ), E( * ), X( LDX, * )
148 parameter( one = 1.0e+0, zero = 0.0e+0 )
165 IF( beta.EQ.zero )
THEN
171 ELSE IF( beta.EQ.-one )
THEN
174 b( i, j ) = -b( i, j )
179 IF( alpha.EQ.one )
THEN
180 IF( lsame( uplo,
'U' ) )
THEN
186 b( 1, j ) = b( 1, j ) + d( 1 )*x( 1, j )
188 b( 1, j ) = b( 1, j ) + d( 1 )*x( 1, j ) +
190 b( n, j ) = b( n, j ) + conjg( e( n-1 ) )*
191 $ x( n-1, j ) + d( n )*x( n, j )
193 b( i, j ) = b( i, j ) + conjg( e( i-1 ) )*
194 $ x( i-1, j ) + d( i )*x( i, j ) +
205 b( 1, j ) = b( 1, j ) + d( 1 )*x( 1, j )
207 b( 1, j ) = b( 1, j ) + d( 1 )*x( 1, j ) +
208 $ conjg( e( 1 ) )*x( 2, j )
209 b( n, j ) = b( n, j ) + e( n-1 )*x( n-1, j ) +
212 b( i, j ) = b( i, j ) + e( i-1 )*x( i-1, j ) +
214 $ conjg( e( i ) )*x( i+1, j )
219 ELSE IF( alpha.EQ.-one )
THEN
220 IF( lsame( uplo,
'U' ) )
THEN
226 b( 1, j ) = b( 1, j ) - d( 1 )*x( 1, j )
228 b( 1, j ) = b( 1, j ) - d( 1 )*x( 1, j ) -
230 b( n, j ) = b( n, j ) - conjg( e( n-1 ) )*
231 $ x( n-1, j ) - d( n )*x( n, j )
233 b( i, j ) = b( i, j ) - conjg( e( i-1 ) )*
234 $ x( i-1, j ) - d( i )*x( i, j ) -
245 b( 1, j ) = b( 1, j ) - d( 1 )*x( 1, j )
247 b( 1, j ) = b( 1, j ) - d( 1 )*x( 1, j ) -
248 $ conjg( e( 1 ) )*x( 2, j )
249 b( n, j ) = b( n, j ) - e( n-1 )*x( n-1, j ) -
252 b( i, j ) = b( i, j ) - e( i-1 )*x( i-1, j ) -
254 $ conjg( e( i ) )*x( i+1, j )
subroutine claptm(uplo, n, nrhs, alpha, d, e, x, ldx, beta, b, ldb)
CLAPTM