KmlScaissGmresInitWithoutMat?I
Initialize the data structure required for matrix-free solving. It must be used in conjunction with a user-defined matrix-vector multiplication function.
Interface Definition
C interface:
int KmlScaissGmresInitWithoutMatSI(KmlScasolverTask **handle, int nstripes, const int *stripeWidth, MPI_Comm comm);
int KmlScaissGmresInitWithoutMatDI(KmlScasolverTask **handle, int nstripes, const int *stripeWidth, MPI_Comm comm);
Parameters
Parameter |
Type |
Description |
Input/Output |
|---|---|---|---|
handle |
KmlScasolverTask ** |
Solver handle. handle cannot be a null pointer. |
Input/Output |
nstripes |
int |
Number of matrices stored in the current MPI process. Currently, the value can only be 1. |
Input |
stripeWidth |
int * |
Number of rows in the matrix in the current MPI process. The lifecycle of this variable is the same as that of handle. |
Input |
comm |
MPI_Comm |
Communicator of the MPI process. |
Input |
Return Value
Return Value |
Type |
Description |
|---|---|---|
KMLSS_NO_ERROR |
int |
Normal execution. |
KMLSS_NULL_ARGUMENT |
int |
A null argument exists in {handle, stripeWidth}. |
KMLSS_NOT_IMPLEMENTED |
int |
The value of nstripes is not 1. |
KMLSS_NO_MEMORY |
int |
The memory is insufficient. |