f11dtf computes a block diagonal incomplete factorization of a complex sparse non-Hermitian matrix, represented in coordinate storage format. The diagonal blocks may be composed of arbitrary rows and the corresponding columns, and may overlap. This factorization can be used to provide a block Jacobi or additive Schwarz preconditioner, for use in combination with f11bsforf11duf.
The nb diagonal blocks need not consist of consecutive rows and columns of , but may be composed of arbitrarily indexed rows, and the corresponding columns, as defined in the arguments indb and istb. Any given row or column index may appear in more than one diagonal block, resulting in overlap. Each diagonal block , , is factorized as:
and is lower triangular with unit diagonal elements, is diagonal, is upper triangular with unit diagonals, and are permutation matrices, and is a remainder matrix.
The amount of fill-in occurring in the factorization of block can vary from zero to complete fill, and can be controlled by specifying either the maximum level of fill , or the drop tolerance .
The parameter defines the pivoting strategy to be used in block . The options currently available are no pivoting, user-defined pivoting, partial pivoting by columns for stability, and complete pivoting by rows for sparsity and by columns for stability. The factorization may optionally be modified to preserve the row-sums of the original block matrix.
The sparse matrix is represented in coordinate storage (CS) format (see Section 2.1.1 in the F11 Chapter Introduction). The array a stores all the nonzero elements of the matrix , while arrays irow and icol store the corresponding row and column indices respectively. Multiple nonzero elements may not be specified for the same row and column index.
The preconditioning matrices , , are returned in terms of the CS representations of the matrices
Meijerink J and Van der Vorst H (1977) An iterative solution method for linear systems of which the coefficient matrix is a symmetric M-matrix Math. Comput.31 148–162
Meijerink J and Van der Vorst H (1981) Guidelines for the usage of incomplete decompositions in solving sets of linear equations as they occur in practical problems J. Comput. Phys.44 134–155
Saad Y (1996) Iterative Methods for Sparse Linear Systems PWS Publishing Company, Boston, MA
1: – IntegerInput
On entry: , the order of the matrix .
2: – IntegerInput
On entry: the number of nonzero elements in the matrix .
3: – Complex (Kind=nag_wp) arrayInput/Output
On entry: the nonzero elements in the matrix , ordered by increasing row index, and by increasing column index within each row. Multiple entries for the same row and column indices are not permitted. The routine f11znf may be used to order the elements in this way.
On exit: the first nnz entries of a contain the nonzero elements of and the next nnzc entries contain the elements of the matrices
, for stored consecutively. Within each block the matrix elements are ordered by increasing row index, and by increasing column index within each row.
4: – IntegerInput
On entry: the dimension of the arrays a, irow and icol as declared in the (sub)program from which f11dtf is called. These arrays must be of sufficient size to store both (nnz elements) and (nnzc elements).
Note: the minimum value for la is only appropriate if lfill and dtol are set such that minimal fill-in occurs. If this is not the case then we recommend that la is set much larger than the minimum value indicated in the constraint.
5: – Integer arrayInput/Output
6: – Integer arrayInput/Output
On entry: the row and column indices of the nonzero elements supplied in a.
irow and icol must satisfy these constraints (which may be imposed by a call to f11znf):
and , for ;
either or both and , for .
On exit: the row and column indices of the nonzero elements returned in a.
7: – IntegerInput
On entry: the number of diagonal blocks to factorize.
8: – Integer arrayInput
On entry: , for , holds the indices in arrays indb, ipivp, ipivq and idiag that, on successful exit from this function, define block . holds the sum of the number of rows in all blocks plus .
, for .
9: – Integer arrayInput
On entry: indb must hold the row indices appearing in each diagonal block, stored consecutively. Thus the elements to are the row indices in the
th block, for .
, for .
10: – IntegerInput
On entry: the dimension of the arrays indb, ipivp, ipivq and idiag as declared in the (sub)program from which f11dtf is called.
11: – Integer arrayInput
On entry: if its value is the maximum level of fill allowed in the decomposition of the block (see Section 9.2 in f11dnf). A negative value of indicates that will be used to control the fill in block instead.
12: – Real (Kind=nag_wp) arrayInput
On entry: if then is used as a drop tolerance in block to control the fill-in (see Section 9.2 in f11dnf); otherwise is not referenced.
, for .
13: – Character(1) arrayInput
On entry: , for , specifies the pivoting strategy to be adopted in the block as follows:
No pivoting is carried out.
Pivoting is carried out according to the user-defined input values of ipivp and ipivq.
Partial pivoting by columns for stability is carried out.
Complete pivoting by rows for sparsity, and by columns for stability, is carried out.
, for .
, , or , for .
14: – Character(1) arrayInput
On entry: , for , indicates whether or not the factorization in block should be modified to preserve row-sums (see Section 9.4 in f11dnf).
The factorization is modified.
The factorization is not modified.
or , for .
15: – Integer arrayInput/Output
16: – Integer arrayInput/Output
On entry: if , and must specify the row and column indices of the element used as a pivot at elimination stage of the factorization of the block. Otherwise ipivp and ipivq need not be initialized.
if , the elements to of ipivp and ipivq must both hold valid permutations of the integers on .
On exit: the row and column indices of the pivot elements, arranged consecutively for each block, as for indb. If and , the element in row and column of was used as the pivot at elimination stage .
17: – Integer arrayOutput
On exit: , gives the index in the arrays a, irow and icol of row of the matrix , for and .
18: – Integer arrayOutput
On exit: , gives the index in the arrays a, irow and icol of the diagonal element in row of the matrix , for and .
19: – IntegerOutput
On exit: the sum total number of nonzero elements in the matrices
, for .
20: – Integer arrayOutput
On exit: if it gives the number of pivots which were modified during the factorization to ensure that exists.
no pivot modifications were required, but a local restart occurred (see Section 9.3 in f11dnf). The quality of the preconditioner will generally depend on the returned values of , for .
If is large, for some , the preconditioner may not be satisfactory. In this case it may be advantageous to call f11dtf again with an increased value of , a reduced value of , or .
21: – Integer arrayWorkspace
22: – IntegerInput
On entry: the dimension of the array iwork as declared in the (sub)program from which f11dtf is called.
23: – IntegerInput/Output
On entry: ifail must be set to , or to set behaviour on detection of an error; these values have no effect when no error is detected.
A value of causes the printing of an error message and program execution will be halted; otherwise program execution continues. A value of means that an error message is printed while a value of means that it is not.
If halting is not appropriate, the value or is recommended. If message printing is undesirable, then the value is recommended. Otherwise, the value is recommended. When the value or is used it is essential to test the value of ifail on exit.
On exit: unless the routine detects an error or a warning has been flagged (see Section 6).
6Error Indicators and Warnings
If on entry or , explanatory error messages are output on the current error message unit (as defined by x04aaf).
On entry, the user-supplied value of ipivp for block lies outside its range.
On entry, the user-supplied value of ipivp for block was repeated.
On entry, the user-supplied value of ipivq for block lies outside its range.
On entry, the user-supplied value of ipivq for block was repeated.
The number of nonzero entries in the decomposition is too large.
The decomposition has been terminated before completion.
Either increase la, or reduce the fill by reducing lfill, or increasing dtol.
An unexpected error has been triggered by this routine. Please
See Section 7 in the Introduction to the NAG Library FL Interface for further information.
Your licence key may have expired or may not have been installed correctly.
See Section 8 in the Introduction to the NAG Library FL Interface for further information.
Dynamic memory allocation failed.
See Section 9 in the Introduction to the NAG Library FL Interface for further information.
The accuracy of the factorization of each block will be determined by the size of the elements that are dropped and the size of any modifications made to the pivot elements. If these sizes are small then the computed factors will correspond to a matrix close to . The factorization can generally be made more accurate by increasing the level of fill , or by reducing the drop tolerance with .
If f11dtf is used in combination with f11bsforf11duf, the more accurate the factorization the fewer iterations will be required. However, the cost of the decomposition will also generally increase.
8Parallelism and Performance
Background information to multithreading can be found in the Multithreading documentation.
f11dtf is threaded by NAG for parallel execution in multithreaded implementations of the NAG Library.
Please consult the X06 Chapter Introduction for information on how to control and interrogate the OpenMP environment used within this routine. Please also consult the Users' Note for your implementation for any additional implementation-specific information.
f11dtf calls f11dnf
internally for each block
. The comments and advice provided in
Section 9 in f11dnf on timing, control of
fill, algorithmic details, and choice of parameters, are all
therefore, relevant to f11dtf, if interpreted blockwise.
This example program reads in a sparse matrix and then defines a block partitioning of the row indices with a user-supplied overlap and computes an overlapping incomplete factorization suitable for use as an additive Schwarz preconditioner. Such a factorization is used for this purpose in the example program of f11duf.