Intel® oneAPI Math Kernel Library Developer Reference - C
Performs a symmetric rank-2k update.
void cblas_ssyr2k (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 *b, const MKL_INT ldb, const float beta, float *c, const MKL_INT ldc);
void cblas_dsyr2k (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 *b, const MKL_INT ldb, const double beta, double *c, const MKL_INT ldc);
void cblas_csyr2k (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 *b, const MKL_INT ldb, const void *beta, void *c, const MKL_INT ldc);
void cblas_zsyr2k (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 *b, const MKL_INT ldb, const void *beta, void *c, const MKL_INT ldc);
The ?syr2k routines perform a rank-2k matrix-matrix operation for a symmetric matrix C using general matrices A and BThe operation is defined as:
C := alpha*A*B' + alpha*B*A' + beta*C,
or
C := alpha*A'*B + alpha*B'*A + beta*C,
where:
alpha and beta are scalars,
C is an n-by-n symmetric matrix,
A and B are n-by-k matrices in the first case, and k-by-n matrices in the second case.
Specifies whether two-dimensional array storage is row-major (CblasRowMajor) or column-major (CblasColMajor).
Specifies whether the upper or lower triangular part of the array c is used.
If uplo = CblasUpper, then the upper triangular part of the array c is used.
If uplo = CblasLower, then the low triangular part of the array c is used.
Specifies the operation:
if trans=CblasNoTrans, then C := alpha*A*B'+alpha*B*A'+beta*C;
if trans=CblasTrans, then C := alpha*A'*B +alpha*B'*A +beta*C;
if trans=CblasConjTrans, then C := alpha*A'*B +alpha*B'*A +beta*C.
Specifies the order of the matrix C.The value of n must be at least zero.
On entry with trans=CblasNoTrans, k specifies the number of columns of the matrices A and B, and on entry with trans=CblasTrans or trans=CblasConjTrans, k specifies the number of rows of the matrices A and B. The value of k must be at least zero.
Specifies the scalar alpha.
trans=CblasNoTrans |
trans=CblasConjTrans |
|
Layout = CblasColMajor |
Array, size lda*k. Before entry, the leading n-by-k part of the array a must contain the matrix A. |
Array, size lda*n. Before entry, the leading k-by-n part of the array a must contain the matrix A. |
Layout = CblasRowMajor |
Array, size lda*n. Before entry, the leading k-by-n part of the array a must contain the matrix A. |
Array, size lda*k. Before entry, the leading n-by-k part of the array a must contain the matrix A. |
Specifies the leading dimension of a as declared in the calling (sub)program.
trans=CblasNoTrans |
trans=CblasConjTrans |
|
Layout = CblasColMajor |
lda must be at least max(1, n). |
lda must be at least max(1, k) |
Layout = CblasRowMajor |
lda must be at least max(1, k) |
lda must be at least max(1, n). |
trans=CblasNoTrans |
trans=CblasConjTrans |
|
Layout = CblasColMajor |
Array, size ldb*k. Before entry, the leading n-by-k part of the array b must contain the matrix B. |
Array, size ldb*n. Before entry, the leading k-by-n part of the array b must contain the matrix B. |
Layout = CblasRowMajor |
Array, size lda*n. Before entry, the leading k-by-n part of the array b must contain the matrix B. |
Array, size lda*k. Before entry, the leading n-by-k part of the array b must contain the matrix B. |
Specifies the leading dimension of a as declared in the calling (sub)program.
trans=CblasNoTrans |
trans=CblasConjTrans |
|
Layout = CblasColMajor |
ldb must be at least max(1, n). |
ldb must be at least max(1, k) |
Layout = CblasRowMajor |
ldb must be at least max(1, k) |
ldb must be at least max(1, n). |
Specifies the scalar beta.
Array, size ldc* n. Before entry with uplo = CblasUpper, the leading n-by-n upper triangular part of the array c must contain the upper triangular part of the symmetric matrix and the strictly lower triangular part of c is not referenced.
Before entry with uplo = CblasLower, the leading n-by-n lower triangular part of the array c must contain the lower triangular part of the symmetric matrix and the strictly upper triangular part of c is not referenced.
Specifies the leading dimension of c as declared in the calling (sub)program. The value of ldc must be at least max(1, n).
With uplo = CblasUpper, the upper triangular part of the array c is overwritten by the upper triangular part of the updated matrix.
With uplo = CblasLower, the lower triangular part of the array c is overwritten by the lower triangular part of the updated matrix.