trtrs_scratchpad_size

Computes size of scratchpad memory required for trtrs function.

trtrs_scratchpad_size supports the following precisions.

T

float

double

std::complex<float>

std::complex<double>

Description

Computes the number of elements of type T the scratchpad memory to be passed to trtrs function should be able to hold. Calls to this routine must specify the template parameter explicitly.

trtrs_scratchpad_size

Syntax

template<typename T>
std::int64_t onemkl::lapack::trtrs_scratchpad_size(cl::sycl::queue &queue, onemkl::uplo upper_lower, onemkl::transpose trans, onemkl::diag diag, std::int64_t n, std::int64_t nrhs, std::int64_t lda, std::int64_t ldb)

Input Parameters

queue

Device queue where calculations by trtrs function will be performed.

upper_lower

Indicates whether A is upper or lower triangular:

If upper_lower = uplo::upper, then A is upper triangular.

If upper_lower = uplo::lower, then A is lower triangular.

trans

Indicates the form of the equations:

If trans=onemkl::transpose::nontrans, then A*X = B is solved for X.

If trans=onemkl::transpose::trans, then AT*X = B is solved for X.

If trans=onemkl::transpose::conjtrans, then AH*X = B is solved for X.

diag

If diag = onemkl::diag::nonunit, then A is not a unit triangular matrix.

If unit_diag = diag::unit, then A is unit triangular: diagonal elements of A are assumed to be 1 and not referenced in the array a.

n

The order of A; the number of rows in B; n 0.

nrhs

The number of right-hand sides (0≤nrhs).

lda

The leading dimension of a; lda max(1, n).

ldb

The leading dimension of b; ldb max(1, n).

Throws

onemkl::lapack::exception

Exception is thrown in case of incorrect argument value is supplied. Position of wrong argument can be determined by get_info() method of exception object.

Return Value

The number of elements of type T the scratchpad memory to be passed to trtrs function should be able to hold.