150 SUBROUTINE zsbmv( UPLO, N, K, ALPHA, A, LDA, X, INCX, BETA, Y,
159 INTEGER INCX, INCY, K, LDA, N
160 COMPLEX*16 ALPHA, BETA
163 COMPLEX*16 A( LDA, * ), X( * ), Y( * )
170 parameter( one = ( 1.0d+0, 0.0d+0 ) )
172 parameter( zero = ( 0.0d+0, 0.0d+0 ) )
175 INTEGER I, INFO, IX, IY, J, JX, JY, KPLUS1, KX, KY, L
176 COMPLEX*16 TEMP1, TEMP2
193 IF( .NOT.lsame( uplo,
'U' ) .AND. .NOT.lsame( uplo,
'L' ) )
THEN
195 ELSE IF( n.LT.0 )
THEN
197 ELSE IF( k.LT.0 )
THEN
199 ELSE IF( lda.LT.( k+1 ) )
THEN
201 ELSE IF( incx.EQ.0 )
THEN
203 ELSE IF( incy.EQ.0 )
THEN
207 CALL xerbla(
'ZSBMV ', info )
213 IF( ( n.EQ.0 ) .OR. ( ( alpha.EQ.zero ) .AND. ( beta.EQ.one ) ) )
221 kx = 1 - ( n-1 )*incx
226 ky = 1 - ( n-1 )*incy
234 IF( beta.NE.one )
THEN
236 IF( beta.EQ.zero )
THEN
247 IF( beta.EQ.zero )
THEN
254 y( iy ) = beta*y( iy )
262 IF( lsame( uplo,
'U' ) )
THEN
267 IF( ( incx.EQ.1 ) .AND. ( incy.EQ.1 ) )
THEN
272 DO 50 i = max( 1, j-k ), j - 1
273 y( i ) = y( i ) + temp1*a( l+i, j )
274 temp2 = temp2 + a( l+i, j )*x( i )
276 y( j ) = y( j ) + temp1*a( kplus1, j ) + alpha*temp2
282 temp1 = alpha*x( jx )
287 DO 70 i = max( 1, j-k ), j - 1
288 y( iy ) = y( iy ) + temp1*a( l+i, j )
289 temp2 = temp2 + a( l+i, j )*x( ix )
293 y( jy ) = y( jy ) + temp1*a( kplus1, j ) + alpha*temp2
306 IF( ( incx.EQ.1 ) .AND. ( incy.EQ.1 ) )
THEN
310 y( j ) = y( j ) + temp1*a( 1, j )
312 DO 90 i = j + 1, min( n, j+k )
313 y( i ) = y( i ) + temp1*a( l+i, j )
314 temp2 = temp2 + a( l+i, j )*x( i )
316 y( j ) = y( j ) + alpha*temp2
322 temp1 = alpha*x( jx )
324 y( jy ) = y( jy ) + temp1*a( 1, j )
328 DO 110 i = j + 1, min( n, j+k )
331 y( iy ) = y( iy ) + temp1*a( l+i, j )
332 temp2 = temp2 + a( l+i, j )*x( ix )
334 y( jy ) = y( jy ) + alpha*temp2
subroutine zsbmv(uplo, n, k, alpha, a, lda, x, incx, beta, y, incy)
ZSBMV
subroutine xerbla(srname, info)