Developer Reference for Intel® oneAPI Math Kernel Library for C

ID 766684
Date 7/13/2023
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

mkl_?trsm_compact

Solves a triangular matrix equation for a set of general, m x n matrices that have been stored in Compact format.

Syntax

mkl_strsm_compact (MKL_LAYOUT layout, MKL_SIDE side, MKL_UPLO uplo, MKL_TRANSPOSE transa, MKL_DIAG diag, MKL_INT m, MKL_INT n, float alpha, const float *ap, MKL_INT a_stride, float *bp, MKL_INT b_stide, MKL_COMPACT_PACK format, MKL_INT nm);

mkl_dtrsm_compact (MKL_LAYOUT layout, MKL_SIDE side, MKL_UPLO uplo, MKL_TRANSPOSE transa, MKL_DIAG diag, MKL_INT m, MKL_INT n, double alpha, const double*ap, MKL_INT a_stride, double *bp, MKL_INT b_stride, MKL_COMPACT_PACK format, MKL_INT nm);

mkl_ctrsm_compact (MKL_LAYOUT layout, MKL_SIDE side, MKL_UPLO uplo, MKL_TRANSPOSE transa, MKL_DIAG diag, MKL_INT m, MKL_INT n, mkl_compact_complex_float *alpha, const float *ap, MKL_INT a_stride, float *bp, MKL_INT b_stride, MKL_COMPACT_PACK format, MKL_INT nm);

mkl_ztrsm_compact (MKL_LAYOUT layout, MKL_SIDE side, MKL_UPLO uplo, MKL_TRANSPOSE transa, MKL_DIAG diag, MKL_INT m, MKL_INT n, mkl_compact_complex_double *alpha, const double *ap, MKL_INT a_stride, double *bp, MKL_INT b_stride, MKL_COMPACT_PACK format, MKL_INT nm);

Description

The routine solves one of the following matrix equations for a group of nm matrices:

op(Ac)*Xc = alpha*Bc,

or

Xc*op(Ac) = alpha*Bc

where:

alpha is a scalar, Xc and Bc are m-by-n matrices that have been stored in compact format, and Ac is a m-by-m unit, or non-unit, upper or lower triangular matrix that has been stored in compact format.

op(Ac) is one of op(Ac) = Ac, or op(Ac) = AcT, or op(Ac) = AcH,

Bc is overwritten by the solution matrix Xc.

Input Parameters

layout

Specifies whether two-dimensional array storage is row-major (MKL_ROW_MAJOR) or column-major (MKL_COL_MAJOR).

side

Specifies whether op(Ac) appears on the left or right of Xc in the equation:

if side = MKL_LEFT, then op(Ac)*Xc = alpha*Bc, if side = MKL_RIGHT, then Xc*op(Ac) = alpha*Bc

uplo

Specifies whether matrix Ac is upper or lower triangular.

If uplo = MKL_UPPER, Ac is upper triangular.

If uplo = MKL_LOWER, Ac is lower triangular.

transa

Specifies the operation:

If transa=MKL_NOTRANS, then op(Ac) = Ac;

If transa=MKL_TRANS, then op(Ac) = AcT;

If transa=MKL_CONJTRANS, then op(Ac) = AcH ;

diag

Specifies whether the matrix Ac is unit triangular:

If diag=MKL_UNIT, then the matrix is unit triangular;

if diag=MKL_NONUNIT, then the matrix is not unit triangular.

m
The number of rows of Bc and the number of rows and columns of Ac when side=MKL_LEFT; m >= 0.
n
The number of columns of Bc and the number of rows and columns of Ac when side=MKL_RIGHT; n >= 0.
alpha
Specifies the scalar alpha. When alpha is zero, then ap is not referenced and bp need not be set before entry.
ap
Array, size ldap*k*nm, where k is m when side= MKL_LEFTand n when side = MKL_RIGHT. ap points to the beginning of nm Ac matrices stored in compact format. When uplo = MKL_UPPER, Ac is assumed to be an upper triangular matrix and the lower triangular part of Ac is not referenced. With uplo = MKL_LOWER, Ac is assumed to be a lower triangular matrix and the upper triangular part of Ac is not referenced. With diag = MKL_UNIT, the diagonal elements of Ac are not referenced either, but are assumed to be unity.
ldap
Column stride (column-major layout) or row stride (row-major layout) of Ac.

When side=MKL_LEFT, ldap must be at least max (1,m).

When side=MKL_RIGHT, ldap must be at least max (1,n).

bp
Array, size ldbp*n*nm when layout = MKL_COL_MAJOR; size ldbp*m*nm when layout = MKL_ROW_MAJOR. Before entry, bp points to the beginning of nm Bc matrices stored in compact format.
ldbp
Column stride (column-major layout) or row stride (row-major layout) of Bc.

layout = MKL_COL_MAJOR

ldbp must be at least max (1,m).

layout = MKL_ROW_MAJOR

*ldbp must be at least max (1,n).

format
Specifies the format of the compact matrices. See <Compact Format> or mkl_get_format_compact for details.
nm
Total number of matrices stored in Compact format; nm >= 0.
NOTE:

The values of ldap and ldbp used in mkl_?trsm_compact must be consistent with the values used in mkl_?get_size_compact, mkl_?gepack_compact, and mkl_?geunpack_compact.

Output Parameters

bp
On exit, Bc is overwritten by the solution matrix Xc. bp points to the beginning of nm such Xc matrices.