subroutine sgemv ( trans, m, n, alpha, a, lda, x, incx, $ beta, y, incy ) * .. scalar arguments .. real alpha, beta integer incx, incy, lda, m, n character*1 trans * .. array arguments .. real a( lda, * ), x( * ), y( * ) * .. * * purpose * ======= * * sgemv performs one of the matrix-vector operations * * y := alpha*a*x + beta*y, or y := alpha*a'*x + beta*y, * * where alpha and beta are scalars, x and y are vectors and a is an * m by n matrix. * * parameters * ========== * * trans - character*1. * on entry, trans specifies the operation to be performed as * follows: * * trans = 'n' or 'n' y := alpha*a*x + beta*y. * * trans = 't' or 't' y := alpha*a'*x + beta*y. * * trans = 'c' or 'c' y := alpha*a'*x + beta*y. * * unchanged on exit. * * m - integer. * on entry, m specifies the number of rows of the matrix a. * m must be at least zero. * unchanged on exit. * * n - integer. * on entry, n specifies the number of columns of the matrix a. * n must be at least zero. * unchanged on exit. * * alpha - real . * on entry, alpha specifies the scalar alpha. * unchanged on exit. * * a - real array of dimension ( lda, n ). * before entry, the leading m by n part of the array a must * contain the matrix of coefficients. * unchanged on exit. * * lda - integer. * on entry, lda specifies the first dimension of a as declared * in the calling (sub) program. lda must be at least * max( 1, m ). * unchanged on exit. * * x - real array of dimension at least * ( 1 + ( n - 1 )*abs( incx ) ) when trans = 'n' or 'n' * and at least * ( 1 + ( m - 1 )*abs( incx ) ) otherwise. * before entry, the incremented array x must contain the * vector x. * unchanged on exit. * * incx - integer. * on entry, incx specifies the increment for the elements of * x. incx must not be zero. * unchanged on exit. * * beta - real . * on entry, beta specifies the scalar beta. when beta is * supplied as zero then y need not be set on input. * unchanged on exit. * * y - real array of dimension at least * ( 1 + ( m - 1 )*abs( incy ) ) when trans = 'n' or 'n' * and at least * ( 1 + ( n - 1 )*abs( incy ) ) otherwise. * before entry with beta non-zero, the incremented array y * must contain the vector y. on exit, y is overwritten by the * updated vector y. * * incy - integer. * on entry, incy specifies the increment for the elements of * y. incy must not be zero. * unchanged on exit. * * * level 2 blas routine. * * -- written on 22-october-1986. * jack dongarra, argonne national lab. * jeremy du croz, nag central office. * sven hammarling, nag central office. * richard hanson, sandia national labs. *