HP MLIB User's Guide Vol. 1 7th Ed.

232 HP MLIB User’s Guide
SGEMV/DGEMV/CGEMV/ZGEMV Matrix-vector multiply
Name SGEMV/DGEMV/CGEMV/ZGEMV
Matrix-vector multiply
Purpose These subprograms compute the matrix-vector products Ax, A
T
x, and A*x,
where A is an m-by-n matrix, A
T
is the transpose of A, and A* is the conjugate
transpose of A. The product can be stored in the result array or added to or
subtracted from it. This is handled in a convenient, but general, way by two
scalar arguments, α and β, which are used as multipliers of the matrix-vector
product and the result vector. Specifically, these subprograms compute
matrix-vector products of the forms:
Refer to “F_SGEMV/F_DGEMV/F_CGEMV/F_ZGEMV” on page 365 for a
description of the BLAS Standard subprograms for a triangular matrix-vector
multiply.
Usage VECLIB:
CHARACTER*1 trans
INTEGER*4 m, n, lda, incx, incy
REAL*4 alpha, beta, a(lda, n), x(lenx), y(leny)
CALL SGEMV(trans, m, n, alpha, a, lda, x, incx, beta, y, incy)
CHARACTER*1 trans
INTEGER*4 m, n, lda, incx, incy
REAL*8 alpha, beta, a(lda, n), x(lenx), y(leny)
CALL DGEMV(trans, m, n, alpha, a, lda, x, incx, beta, y, incy)
CHARACTER*1 trans
INTEGER*4 m, n, lda, incx, incy
COMPLEX*8 alpha, beta, a(lda, n), x(lenx), y(leny)
CALL CGEMV(trans, m, n, alpha, a, lda, x, incx, beta, y, incy)
CHARACTER*1 trans
INTEGER*4 m, n, lda, incx, incy
COMPLEX*16 alpha, beta, a(lda, n), x(lenx), y(leny)
CALL ZGEMV(trans, m, n, alpha, a, lda, x, incx, beta, y, incy)
VECLIB8:
CHARACTER*1 trans
INTEGER*8 m, n, lda, incx, incy
REAL*4 alpha, beta, a(lda, n), x(lenx), y(leny)
CALL SGEMV(trans, m, n, alpha, a, lda, x, incx, beta, y, incy)
yaAx←βy+ yaA
T
x←βy+ and yaA*x βy.+,,