cblas_?syrk
cblas_?syrk
Performs a symmetric rank-k update.
Syntax
void
cblas_ssyrk
(
const
CBLAS_LAYOUT
Layout
,
const
CBLAS_UPLO
uplo
,
const
CBLAS_TRANSPOSE
trans
,
const
MKL_INT
n
,
const
MKL_INT
k
,
const
float
alpha
,
const
float
*a
,
const
MKL_INT
lda
,
const
float
beta
,
float
*c
,
const
MKL_INT
ldc
);
void
cblas_dsyrk
(
const
CBLAS_LAYOUT
Layout
,
const
CBLAS_UPLO
uplo
,
const
CBLAS_TRANSPOSE
trans
,
const
MKL_INT
n
,
const
MKL_INT
k
,
const
double
alpha
,
const
double
*a
,
const
MKL_INT
lda
,
const
double
beta
,
double
*c
,
const
MKL_INT
ldc
);
void
cblas_csyrk
(
const
CBLAS_LAYOUT
Layout
,
const
CBLAS_UPLO
uplo
,
const
CBLAS_TRANSPOSE
trans
,
const
MKL_INT
n
,
const
MKL_INT
k
,
const
void
*alpha
,
const
void
*a
,
const
MKL_INT
lda
,
const
void
*beta
,
void
*c
,
const
MKL_INT
ldc
);
void
cblas_zsyrk
(
const
CBLAS_LAYOUT
Layout
,
const
CBLAS_UPLO
uplo
,
const
CBLAS_TRANSPOSE
trans
,
const
MKL_INT
n
,
const
MKL_INT
k
,
const
void
*alpha
,
const
void
*a
,
const
MKL_INT
lda
,
const
void
*beta
,
void
*c
,
const
MKL_INT
ldc
);
Include Files
- mkl.h
Description
The
?syrk
routines perform a rank-k matrix-matrix operation for a symmetric matrix
. The operation is defined as:
C
using a general matrix A
C := alpha*A*A' + beta*C,
or
C := alpha*A'*A + beta*C,
where:
alpha
and beta
are scalars,C
is an n
-by-n
symmetric matrix,A
is an n
-by-k
matrix in the first case and a k
-by-n
matrix in the second case.Input Parameters
- Layout
- Specifies whether two-dimensional array storage is row-major (CblasRowMajor) or column-major (CblasColMajor).
- uplo
- Specifies whether the upper or lower triangular part of the arraycis used.If, then the upper triangular part of the arrayuplo=CblasUppercis used.If, then the low triangular part of the arrayuplo=CblasLowercis used.
- trans
- Specifies the operation:iftrans=CblasNoTrans, then;C:=alpha*A*A' +beta*Ciftrans=CblasTrans, then;C:=alpha*A'*A+beta*Ciftrans=CblasConjTrans, then.C:=alpha*A'*A+beta*C
- n
- Specifies the order of the matrixThe value ofC.nmust be at least zero.
- k
- On entry withtrans=CblasNoTrans,kspecifies the number of columns of the matrixa, and on entry withtrans=CblasTransortrans=CblasConjTrans,kspecifies the number of rows of the matrixa.The value ofkmust be at least zero.
- alpha
- Specifies the scalaralpha.
- a
- Array, sizelda*ka, wherekaiskwhentrans=CblasNoTrans, and isnotherwise. Before entry withtrans=CblasNoTrans, the leadingn-by-kpart of the arrayamust contain the matrixA, otherwise the leadingk-by-npart of the arrayamust contain the matrixA.trans=CblasNoTranstrans=CblasConjTransLayout=CblasColMajorArray, sizelda*k.Before entry, the leadingn-by-kpart of the arrayamust contain the matrixA.Array, sizelda*n.Before entry, the leadingk-by-npart of the arrayamust contain the matrixA.Layout=CblasRowMajorArray, sizelda*n.Before entry, the leadingk-by-npart of the arrayamust contain the matrixA.Array, sizelda*k.Before entry, the leadingn-by-kpart of the arrayamust contain the matrixA.
- lda
- trans=CblasNoTranstrans=CblasConjTransLayout=CblasColMajorldamust be at leastmax(1,.n)ldamust be at leastmax(1,k)Layout=CblasRowMajorldamust be at leastmax(1,k)ldamust be at leastmax(1,.n)
- beta
- Specifies the scalarbeta.
- c
- Array, sizeldc*n. Before entry withuplo=CblasUpper, the leadingn-by-nupper triangular part of the arraycmust contain the upper triangular part of the symmetric matrix and the strictly lower triangular part ofcis not referenced.Before entry withuplo=CblasLower, the leadingn-by-nlower triangular part of the arraycmust contain the lower triangular part of the symmetric matrix and the strictly upper triangular part ofcis not referenced.
- ldc
- Specifies the leading dimension ofcas declared in the calling (sub)program. The value ofldcmust be at leastmax(1,.n)
Output Parameters
- c
- Withuplo=CblasUpper, the upper triangular part of the arraycis overwritten by the upper triangular part of the updated matrix.Withuplo=CblasLower, the lower triangular part of the arraycis overwritten by the lower triangular part of the updated matrix.