F11JBF (PDF version)
F11 Chapter Contents
F11 Chapter Introduction
NAG Library Manual

NAG Library Routine Document

F11JBF

Note:  before using this routine, please read the Users' Note for your implementation to check the interpretation of bold italicised terms and other implementation-dependent details.

 Contents

    1  Purpose
    7  Accuracy

1  Purpose

F11JBF solves a system of linear equations involving the incomplete Cholesky preconditioning matrix generated by F11JAF.

2  Specification

SUBROUTINE F11JBF ( N, A, LA, IROW, ICOL, IPIV, ISTR, CHECK, Y, X, IFAIL)
INTEGER  N, LA, IROW(LA), ICOL(LA), IPIV(N), ISTR(N+1), IFAIL
REAL (KIND=nag_wp)  A(LA), Y(N), X(N)
CHARACTER(1)  CHECK

3  Description

F11JBF solves a system of linear equations
Mx=y  
involving the preconditioning matrix M=PLDLTPT, corresponding to an incomplete Cholesky decomposition of a sparse symmetric matrix stored in symmetric coordinate storage (SCS) format (see Section 2.1.2 in the F11 Chapter Introduction), as generated by F11JAF.
In the above decomposition L is a lower triangular sparse matrix with unit diagonal, D is a diagonal matrix and P is a permutation matrix. L and D are supplied to F11JBF through the matrix
C=L+D-1-I  
which is a lower triangular N by N sparse matrix, stored in SCS format, as returned by F11JAF. The permutation matrix P is returned from F11JAF via the array IPIV.
It is envisaged that a common use of F11JBF will be to carry out the preconditioning step required in the application of F11GEF to sparse symmetric linear systems. F11JBF is used for this purpose by the Black Box routine F11JCF.
F11JBF may also be used in combination with F11JAF to solve a sparse symmetric positive definite system of linear equations directly (see Section 9.4 in F11JAF). This use of F11JBF is demonstrated in Section 10.

4  References

None.

5  Parameters

1:     N – INTEGERInput
On entry: n, the order of the matrix M. This must be the same value as was supplied in the preceding call to F11JAF.
Constraint: N1.
2:     ALA – REAL (KIND=nag_wp) arrayInput
On entry: the values returned in the array A by a previous call to F11JAF.
3:     LA – INTEGERInput
On entry: the dimension of the arrays A, IROW and ICOL as declared in the (sub)program from which F11JBF is called. This must be the same value returned by the preceding call to F11JAF.
4:     IROWLA – INTEGER arrayInput
5:     ICOLLA – INTEGER arrayInput
6:     IPIVN – INTEGER arrayInput
7:     ISTRN+1 – INTEGER arrayInput
On entry: the values returned in arrays IROW, ICOL, IPIV and ISTR by a previous call to F11JAF.
8:     CHECK – CHARACTER(1)Input
On entry: specifies whether or not the input data should be checked.
CHECK='C'
Checks are carried out on the values of N, IROW, ICOL, IPIV and ISTR.
CHECK='N'
No checks are carried out.
See also Section 9.2.
Constraint: CHECK='C' or 'N'.
9:     YN – REAL (KIND=nag_wp) arrayInput
On entry: the right-hand side vector y.
10:   XN – REAL (KIND=nag_wp) arrayOutput
On exit: the solution vector x.
11:   IFAIL – INTEGERInput/Output
On entry: IFAIL must be set to 0, -1​ or ​1. If you are unfamiliar with this parameter you should refer to Section 3.3 in the Essential Introduction for details.
For environments where it might be inappropriate to halt program execution when an error is detected, the value -1​ or ​1 is recommended. If the output of error messages is undesirable, then the value 1 is recommended. Otherwise, if you are not familiar with this parameter, the recommended value is 0. When the value -1​ or ​1 is used it is essential to test the value of IFAIL on exit.
On exit: IFAIL=0 unless the routine detects an error or a warning has been flagged (see Section 6).

6  Error Indicators and Warnings

If on entry IFAIL=0 or -1, explanatory error messages are output on the current error message unit (as defined by X04AAF).
Errors or warnings detected by the routine:
IFAIL=1
On entry,CHECK'C' or 'N'.
IFAIL=2
On entry,N<1.
IFAIL=3
On entry, the SCS representation of the preconditioning matrix M is invalid. Further details are given in the error message. Check that the call to F11JBF has been preceded by a valid call to F11JAF and that the arrays A, IROW, ICOL, IPIV and ISTR have not been corrupted between the two calls.
IFAIL=-99
An unexpected error has been triggered by this routine. Please contact NAG.
See Section 3.8 in the Essential Introduction for further information.
IFAIL=-399
Your licence key may have expired or may not have been installed correctly.
See Section 3.7 in the Essential Introduction for further information.
IFAIL=-999
Dynamic memory allocation failed.
See Section 3.6 in the Essential Introduction for further information.

7  Accuracy

The computed solution x is the exact solution of a perturbed system of equations M+δMx=y, where
δMcnεPLDLTPT,  
cn is a modest linear function of n, and ε is the machine precision.

8  Parallelism and Performance

Not applicable.

9  Further Comments

9.1  Timing

The time taken for a call to F11JBF is proportional to the value of NNZC returned from F11JAF.

9.2  Use of CHECK

It is expected that a common use of F11JBF will be to carry out the preconditioning step required in the application of F11GEF to sparse symmetric linear systems. In this situation F11JBF is likely to be called many times with the same matrix M. In the interests of both reliability and efficiency, you are recommended to set CHECK='C' for the first of such calls, and to set CHECK='N' for all subsequent calls.

10  Example

This example reads in a symmetric positive definite sparse matrix A and a vector y. It then calls F11JAF, with LFILL=-1 and DTOL=0.0, to compute the complete Cholesky decomposition of A:
A=PLDLTPT.  
Then it calls F11JBF to solve the system
PLDLTPTx=y.  
It then repeats the exercise for the same matrix permuted with the bandwidth-reducing Reverse Cuthill–McKee permutation, calculated with F11YEF.

10.1  Program Text

Program Text (f11jbfe.f90)

10.2  Program Data

Program Data (f11jbfe.d)

10.3  Program Results

Program Results (f11jbfe.r)


F11JBF (PDF version)
F11 Chapter Contents
F11 Chapter Introduction
NAG Library Manual

© The Numerical Algorithms Group Ltd, Oxford, UK. 2015