SGEMV/DGEMV/CGEMV/ZGEMV

 

Matrix-vector multiply

Input

trans

Transposition option for A:

 

 

’N’ or ’n’

Compute y ← αAx + βy

 

 

’T’ or ’t’

Compute y ← αATx + βy

 

 

’C’ or ’c’

Compute y ← αA*x + βy

 

 

where AT is the transpose of A and A* is the conjugate

 

 

transpose. In the real subprograms, ’C’ and ’c’ have the

 

 

same meaning as ’T’ and ’t’.

 

m

Number of rows in matrix A, m ≥ 0. If m = 0, the

 

 

subprograms do not reference a, x, or y.

 

n

Number of columns in matrix A, n ≥ 0. If n = 0, the

 

 

subprograms do not reference a, x, or y.

 

alpha

The scalar α. If alpha = 0, the subprograms compute

 

 

y ← βy without referencing A or x.

 

a

Array containing the m-by-nmatrix A.

 

lda

The leading dimension of array a as declared in the

 

 

calling program unit, with lda ≥ max(m,1).

 

x

Array containing the vector x. The number of elements

 

 

of x and the value of lenx, the dimension of the array x,

 

 

depend on trans:

 

 

’N’ or ’n’

x has n elements lenx = (n−1)⋅incx+1

 

 

otherwise

x has m elements lenx = (m−1)⋅incx+1

 

incx

Increment for the array x, incx ≠ 0:

 

 

incx > 0

x is stored forward in array x; that is,

 

 

 

xi is stored in x((i−1)⋅incx+1).

 

 

incx < 0

x is stored backward in array x; that

 

 

 

is, if trans = ’N’ or ’n’, then xi is stored

 

 

 

in x((in)⋅incx+1); otherwise, xi is

 

 

 

stored in x((im)⋅incx+1).

 

 

Use incx = 1 if the vector x is stored contiguously in

 

 

array x, that is, if xi is stored in x(i). Refer to “BLAS

 

 

Indexing Conventions” in the introduction to

 

 

Chapter 2.

 

 

beta

The scalar β.

 

234HP MLIB User’s Guide