Computes a matrix-matrix product where one input matrix is Hermitian.

Syntax

call chemm(side, uplo, m, n, alpha, a, lda, b, ldb, beta, c, ldc)

call zhemm(side, uplo, m, n, alpha, a, lda, b, ldb, beta, c, ldc)

call hemm(a, b, c [,side][,uplo] [,alpha][,beta])

Include Files

  • mkl.fi, blas.f90

Description

The ?hemm routines compute a scalar-matrix-matrix product using a Hermitian matrix A and a general matrix B and add the result to a scalar-matrix product using a general matrix C. The operation is defined as

C := alpha*A*B + beta*C

or

C := alpha*B*A + beta*C

where:

alpha and beta are scalars,

A is a Hermitian matrix,

B and C are m-by-n matrices.

Input Parameters

side

CHARACTER*1. Specifies whether the Hermitian matrix A appears on the left or right in the operation as follows:

if side = 'L' or 'l' , then C := alpha*A*B + beta*C;

if side = 'R' or 'r' , then C := alpha*B*A + beta*C.

uplo

CHARACTER*1. Specifies whether the upper or lower triangular part of the Hermitian matrix A is used:

If uplo = 'U' or 'u', then the upper triangular part of the Hermitian matrix A is used.

If uplo = 'L' or 'l', then the low triangular part of the Hermitian matrix A is used.

m

INTEGER. Specifies the number of rows of the matrix C.

The value of m must be at least zero.

n

INTEGER. Specifies the number of columns of the matrix C.

The value of n must be at least zero.

alpha

COMPLEX for chemm

DOUBLE COMPLEX for zhemm

Specifies the scalar alpha.

a

COMPLEX for chemm

DOUBLE COMPLEX for zhemm

Array, size (lda, ka), where ka is m when side = 'L' or 'l' and is n otherwise. Before entry with side = 'L' or 'l', the m-by-m part of the array a must contain the Hermitian matrix, such that when uplo = 'U' or 'u', the leading m-by-m upper triangular part of the array a must contain the upper triangular part of the Hermitian matrix and the strictly lower triangular part of a is not referenced, and when uplo = 'L' or 'l', the leading m-by-m lower triangular part of the array a must contain the lower triangular part of the Hermitian matrix, and the strictly upper triangular part of a is not referenced.

Before entry with side = 'R' or 'r', the n-by-n part of the array a must contain the Hermitian matrix, such that when uplo = 'U' or 'u', the leading n-by-n upper triangular part of the array a must contain the upper triangular part of the Hermitian matrix and the strictly lower triangular part of a is not referenced, and when uplo = 'L' or 'l', the leading n-by-n lower triangular part of the array a must contain the lower triangular part of the Hermitian matrix, and the strictly upper triangular part of a is not referenced. The imaginary parts of the diagonal elements need not be set, they are assumed to be zero.

lda

INTEGER. Specifies the leading dimension of a as declared in the calling (sub) program. When side = 'L' or 'l' then lda must be at least max(1, m), otherwise lda must be at least max(1,n).

b

COMPLEX for chemm

DOUBLE COMPLEX for zhemm

Array, size ldb by n.

The leading m-by-n part of the array b must contain the matrix B.

ldb

INTEGER. Specifies the leading dimension of b as declared in the calling (sub)program.ldb must be at least max(1, m)

beta

COMPLEX for chemm

DOUBLE COMPLEX for zhemm

Specifies the scalar beta.

When beta is supplied as zero, then c need not be set on input.

c

COMPLEX for chemm

DOUBLE COMPLEX for zhemm

Array, size (c, n). Before entry, the leading m-by-n part of the array c must contain the matrix C, except when beta is zero, in which case c need not be set on entry.

ldc

INTEGER. Specifies the leading dimension of c as declared in the calling (sub)program. ldc must be at least max(1, m)

Output Parameters

:

 

c

Overwritten by the m-by-n updated matrix.

BLAS 95 Interface Notes

Routines in Fortran 95 interface have fewer arguments in the calling sequence than their FORTRAN 77 counterparts. For general conventions applied to skip redundant or reconstructible arguments, see BLAS 95 Interface Conventions.

Specific details for the routine hemm interface are the following:

a

Holds the matrix A of size (k,k) where

k = m if side = 'L',

k = n otherwise.

b

Holds the matrix B of size (m,n).

c

Holds the matrix C of size (m,n).

side

Must be 'L' or 'R'. The default value is 'L'.

uplo

Must be 'U' or 'L'. The default value is 'U'.

alpha

The default value is 1.

beta

The default value is 0.

有关编译器优化的更完整信息,请参阅优化通知
选择粘滞按钮颜色: 
Orange (only for download buttons)