rocsolver_sgels_batched Interface Reference#
GELS_BATCHED solves a batch of overdetermined (or underdetermined) linear systems defined by a set of m-by-n matrices \(A_i\), and corresponding matrices \(B_i\), using the QR factorizations computed by GEQRF_BATCHED (or the LQ factorizations computed by GELQF_BATCHED). More...
Public Member Functions | |
integer(kind(rocblas_status_success)) function | rocsolver_sgels_batched_ (handle, trans, m, n, nrhs, A, lda, B, ldb, myInfo, batch_count) |
integer(kind(rocblas_status_success)) function | rocsolver_sgels_batched_full_rank (handle, trans, m, n, nrhs, A, lda, B, ldb, myInfo, batch_count) |
integer(kind(rocblas_status_success)) function | rocsolver_sgels_batched_rank_0 (handle, trans, m, n, nrhs, A, lda, B, ldb, myInfo, batch_count) |
integer(kind(rocblas_status_success)) function | rocsolver_sgels_batched_rank_1 (handle, trans, m, n, nrhs, A, lda, B, ldb, myInfo, batch_count) |
Detailed Description
GELS_BATCHED solves a batch of overdetermined (or underdetermined) linear systems defined by a set of m-by-n matrices \(A_i\), and corresponding matrices \(B_i\), using the QR factorizations computed by GEQRF_BATCHED (or the LQ factorizations computed by GELQF_BATCHED).
For each instance in the batch, depending on the value of trans, the problem solved by this function is either of the form
\[ \begin{array}{cl} A_i X_i = B_i & \: \text{not transposed, or}\newline A_i' X_i = B_i & \: \text{transposed if real, or conjugate transposed if complex} \end{array} \]
If m >= n (or m < n in the case of transpose/conjugate transpose), the system is overdetermined and a least-squares solution approximating X_i is found by minimizing
\[ || B_i - A_i X_i || \quad \text{(or} \: || B_i - A_i' X_i ||\text{)} \]
If m < n (or m >= n in the case of transpose/conjugate transpose), the system is underdetermined and a unique solution for X_i is chosen such that \(|| X_i ||\) is minimal.
- Parameters
-
[in] handle rocblas_handle. [in] trans rocblas_operation.
Specifies the form of the system of equations.[in] m rocblas_int. m >= 0.
The number of rows of all matrices A_i in the batch.[in] n rocblas_int. n >= 0.
The number of columns of all matrices A_i in the batch.[in] nrhs rocblas_int. nrhs >= 0.
The number of columns of all matrices B_i and X_i in the batch; i.e., the columns on the right hand side.[in,out] A array of pointer to type. Each pointer points to an array on the GPU of dimension lda*n.
On entry, the matrices A_i. On exit, the QR (or LQ) factorizations of A_i as returned by GEQRF_BATCHED (or GELQF_BATCHED).[in] lda rocblas_int. lda >= m.
Specifies the leading dimension of matrices A_i.[in,out] B array of pointer to type. Each pointer points to an array on the GPU of dimension ldb*nrhs.
On entry, the matrices B_i. On exit, when info[i] = 0, B_i is overwritten by the solution vectors (and the residuals in the overdetermined cases) stored as columns.[in] ldb rocblas_int. ldb >= max(m,n).
Specifies the leading dimension of matrices B_i.[out] info pointer to rocblas_int. Array of batch_count integers on the GPU.
If info[i] = 0, successful exit for solution of A_i. If info[i] = j > 0, the solution of A_i could not be computed because input matrix A_i is rank deficient; the j-th diagonal element of its triangular factor is zero.[in] batch_count rocblas_int. batch_count >= 0.
Number of matrices in the batch.
Member Function/Subroutine Documentation
◆ rocsolver_sgels_batched_()
integer(kind(rocblas_status_success)) function hipfort_rocsolver::rocsolver_sgels_batched::rocsolver_sgels_batched_ | ( | type(c_ptr), value | handle, |
integer(kind(rocblas_operation_none)), value | trans, | ||
integer(c_int), value | m, | ||
integer(c_int), value | n, | ||
integer(c_int), value | nrhs, | ||
type(c_ptr) | A, | ||
integer(c_int), value | lda, | ||
type(c_ptr) | B, | ||
integer(c_int), value | ldb, | ||
integer(c_int) | myInfo, | ||
integer(c_int), value | batch_count | ||
) |
◆ rocsolver_sgels_batched_full_rank()
integer(kind(rocblas_status_success)) function hipfort_rocsolver::rocsolver_sgels_batched::rocsolver_sgels_batched_full_rank | ( | type(c_ptr) | handle, |
integer(kind(rocblas_operation_none)) | trans, | ||
integer(c_int) | m, | ||
integer(c_int) | n, | ||
integer(c_int) | nrhs, | ||
real(c_float), dimension(:,:,:), target | A, | ||
integer(c_int) | lda, | ||
real(c_float), dimension(:,:,:), target | B, | ||
integer(c_int) | ldb, | ||
integer(c_int) | myInfo, | ||
integer(c_int) | batch_count | ||
) |
◆ rocsolver_sgels_batched_rank_0()
integer(kind(rocblas_status_success)) function hipfort_rocsolver::rocsolver_sgels_batched::rocsolver_sgels_batched_rank_0 | ( | type(c_ptr) | handle, |
integer(kind(rocblas_operation_none)) | trans, | ||
integer(c_int) | m, | ||
integer(c_int) | n, | ||
integer(c_int) | nrhs, | ||
real(c_float), target | A, | ||
integer(c_int) | lda, | ||
real(c_float), target | B, | ||
integer(c_int) | ldb, | ||
integer(c_int) | myInfo, | ||
integer(c_int) | batch_count | ||
) |
◆ rocsolver_sgels_batched_rank_1()
integer(kind(rocblas_status_success)) function hipfort_rocsolver::rocsolver_sgels_batched::rocsolver_sgels_batched_rank_1 | ( | type(c_ptr) | handle, |
integer(kind(rocblas_operation_none)) | trans, | ||
integer(c_int) | m, | ||
integer(c_int) | n, | ||
integer(c_int) | nrhs, | ||
real(c_float), dimension(:), target | A, | ||
integer(c_int) | lda, | ||
real(c_float), dimension(:), target | B, | ||
integer(c_int) | ldb, | ||
integer(c_int) | myInfo, | ||
integer(c_int) | batch_count | ||
) |
The documentation for this interface was generated from the following file: