cblas_?hemm
cblas_?hemm
Computes a matrix-matrix product where one input matrix is Hermitian.
Syntax
void
cblas_chemm
(
const
CBLAS_LAYOUT
Layout
,
const
CBLAS_SIDE
side
,
const
CBLAS_UPLO
uplo
,
const
MKL_INT
m
,
const
MKL_INT
n
,
const
void
*alpha
,
const
void
*a
,
const
MKL_INT
lda
,
const
void
*b
,
const
MKL_INT
ldb
,
const
void
*beta
,
void
*c
,
const
MKL_INT
ldc
);
void
cblas_zhemm
(
const
CBLAS_LAYOUT
Layout
,
const
CBLAS_SIDE
side
,
const
CBLAS_UPLO
uplo
,
const
MKL_INT
m
,
const
MKL_INT
n
,
const
void
*alpha
,
const
void
*a
,
const
MKL_INT
lda
,
const
void
*b
,
const
MKL_INT
ldb
,
const
void
*beta
,
void
*c
,
const
MKL_INT
ldc
);
Include Files
- mkl.h
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 asC := 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
- Layout
- Specifies whether two-dimensional array storage is row-major (CblasRowMajor) or column-major (CblasColMajor).
- side
- Specifies whether the Hermitian matrixAappears on the left or right in the operation as follows:if, thenside=CblasLeft;C:=alpha*A*B+beta*Cif, thenside=CblasRight.C:=alpha*B*A+beta*C
- uplo
- Specifies whether the upper or lower triangular part of the Hermitian matrixAis used:Ifuplo=CblasUpper, then the upper triangular part of the Hermitian matrixAis used.Ifuplo=CblasLower, then the low triangular part of the Hermitian matrixAis used.
- m
- Specifies the number of rows of the matrixC.The value ofmmust be at least zero.
- n
- Specifies the number of columns of the matrixC.The value ofnmust be at least zero.
- alpha
- Specifies the scalaralpha.
- a
- Array, sizelda*ka, wherekaismwhenside=CblasLeftand isnotherwise. Before entry withside=CblasLeft, them-by-mpart of the arrayamust contain the Hermitian matrix, such that whenuplo=CblasUpper, the leadingm-by-mupper triangular part of the arrayamust contain the upper triangular part of the Hermitian matrix and the strictly lower triangular part ofais not referenced, and whenuplo=CblasLower, the leadingm-by-mlower triangular part of the arrayamust contain the lower triangular part of the Hermitian matrix, and the strictly upper triangular part ofais not referenced.Before entry withside=CblasRight, then-by-npart of the arrayamust contain the Hermitian matrix, such that whenuplo=CblasUpper, the leadingn-by-nupper triangular part of the arrayamust contain the upper triangular part of the Hermitian matrix and the strictly lower triangular part ofais not referenced, and whenuplo=CblasLower, the leadingn-by-nlower triangular part of the arrayamust contain the lower triangular part of the Hermitian matrix, and the strictly upper triangular part ofais not referenced. The imaginary parts of the diagonal elements need not be set, they are assumed to be zero.
- lda
- Specifies the leading dimension ofaas declared in the calling (sub) program. Whenside=CblasLeftthenldamust be at leastmax(1,, otherwisem)ldamust be at leastmax(1,.n)
- b
- ForLayout=CblasColMajor: array, sizeldb*n.The leadingm-by-npart of the arraybmust contain the matrixB.ForLayout=CblasRowMajor: array, sizeldb*m. The leadingn-by-mpart of the arraybmust contain the matrixB
- ldb
- Specifies the leading dimension ofbas declared in the calling (sub)program.WhenLayout=CblasColMajor,ldbmust be at leastmax(1,m); otherwise,ldbmust be at leastmax(1,.n)
- beta
- Specifies the scalarbeta.Whenbetais supplied as zero, thencneed not be set on input.
- c
- ForLayout=CblasColMajor: array, size. Before entry, the leadingldc*nm-by-npart of the arraycmust contain the matrixC, except whenbetais zero, in which casecneed not be set on entry.ForLayout=CblasRowMajor: array, size. Before entry, the leadingldc*mn-by-mpart of the arraycmust contain the matrixC, except whenbetais zero, in which casecneed not be set on entry.
- ldc
- Specifies the leading dimension ofcas declared in the calling (sub)program.WhenLayout=CblasColMajor,ldcmust be at leastmax(1,m); otherwise,ldcmust be at leastmax(1,.n)
Output Parameters
- c
- Overwritten by them-by-nupdated matrix.