Developer Reference for Intel® oneAPI Math Kernel Library for C

ID 766684
Date 10/31/2024
Public
Document Table of Contents

p?posv

Solves a symmetric positive definite system of linear equations.

Syntax

void psposv (char *uplo , MKL_INT *n , MKL_INT *nrhs , float *a , MKL_INT *ia , MKL_INT *ja , MKL_INT *desca , float *b , MKL_INT *ib , MKL_INT *jb , MKL_INT *descb , MKL_INT *info );

void pdposv (char *uplo , MKL_INT *n , MKL_INT *nrhs , double *a , MKL_INT *ia , MKL_INT *ja , MKL_INT *desca , double *b , MKL_INT *ib , MKL_INT *jb , MKL_INT *descb , MKL_INT *info );

void pcposv (char *uplo , MKL_INT *n , MKL_INT *nrhs , MKL_Complex8 *a , MKL_INT *ia , MKL_INT *ja , MKL_INT *desca , MKL_Complex8 *b , MKL_INT *ib , MKL_INT *jb , MKL_INT *descb , MKL_INT *info );

void pzposv (char *uplo , MKL_INT *n , MKL_INT *nrhs , MKL_Complex16 *a , MKL_INT *ia , MKL_INT *ja , MKL_INT *desca , MKL_Complex16 *b , MKL_INT *ib , MKL_INT *jb , MKL_INT *descb , MKL_INT *info );

Include Files

  • mkl_scalapack.h

Description

The p?posvfunction computes the solution to a real/complex system of linear equations

sub(A)*X = sub(B),

where sub(A) denotes A(ia:ia+n-1,ja:ja+n-1) and is an n-by-n symmetric/Hermitian distributed positive definite matrix and X and sub(B) denoting B(ib:ib+n-1,jb:jb+nrhs-1) are n-by-nrhs distributed matrices. The Cholesky decomposition is used to factor sub(A) as

sub(A) = UT*U, if uplo = 'U', or

sub(A) = L*LT, if uplo = 'L',

where U is an upper triangular matrix and L is a lower triangular matrix. The factored form of sub(A) is then used to solve the system of equations.

Input Parameters

uplo

(global) Must be 'U' or 'L'.

Indicates whether the upper or lower triangular part of sub(A) is stored.

n

(global) The order of the distributed matrix sub(A) (n 0).

nrhs

The number of right-hand sides; the number of columns of the distributed matrix sub(B) (nrhs 0).

a

(local)

Pointer into the local memory to an array of size lld_a*LOCc(ja+n-1). On entry, this array contains the local pieces of the n-by-n symmetric distributed matrix sub(A) to be factored.

If uplo = 'U', the leading n-by-n upper triangular part of sub(A) contains the upper triangular part of the matrix, and its strictly lower triangular part is not referenced.

If uplo = 'L', the leading n-by-n lower triangular part of sub(A) contains the lower triangular part of the distributed matrix, and its strictly upper triangular part is not referenced.

ia, ja

(global) The row and column indices in the global matrix A indicating the first row and the first column of the submatrix A, respectively.

desca

(global and local) array of size dlen_. The array descriptor for the distributed matrix A.

b

(local)

Pointer into the local memory to an array of size lld_b*LOCc(jb+nrhs-1). On entry, the local pieces of the right hand sides distributed matrix sub(B).

ib, jb

(global) The row and column indices in the global matrix B indicating the first row and the first column of the submatrix B, respectively.

descb

(global and local) array of size dlen_. The array descriptor for the distributed matrix B.

Output Parameters

a

On exit, if info = 0, this array contains the local pieces of the factor U or L from the Cholesky factorization sub(A) = UH*U, or L*LH.

b

On exit, if info = 0, sub(B) is overwritten by the solution distributed matrix X.

info

(global)

If info =0, the execution is successful.

If info < 0: If the i-th argument is an array and the j-th entry, indexed j-1, had an illegal value, then info = -(i*100+j), if the i-th argument is a scalar and had an illegal value, then info = -i.

If info > 0: If info = k, the leading minor of order k, A(ia:ia+k-1, ja:ja+k-1) is not positive definite, and the factorization could not be completed, and the solution has not been computed.

See Also