nag_zptcon (f07juc) (PDF version)
f07 Chapter Contents
f07 Chapter Introduction
NAG Library Manual

NAG Library Function Document

nag_zptcon (f07juc)

+ Contents

    1  Purpose
    7  Accuracy

1  Purpose

nag_zptcon (f07juc) computes the reciprocal condition number of a complex n  by n  Hermitian positive definite tridiagonal matrix A , using the LDLH  factorization returned by nag_zpttrf (f07jrc).

2  Specification

#include <nag.h>
#include <nagf07.h>
void  nag_zptcon (Integer n, const double d[], const Complex e[], double anorm, double *rcond, NagError *fail)

3  Description

nag_zptcon (f07juc) should be preceded by a call to nag_zpttrf (f07jrc), which computes a modified Cholesky factorization of the matrix A  as
where L  is a unit lower bidiagonal matrix and D  is a diagonal matrix, with positive diagonal elements. nag_zptcon (f07juc) then utilizes the factorization to compute A-11  by a direct method, from which the reciprocal of the condition number of A , 1/κA  is computed as
1/κ1A=1 / A1 A-11 .
1/κA  is returned, rather than κA , since when A  is singular κA  is infinite.

4  References

Higham N J (2002) Accuracy and Stability of Numerical Algorithms (2nd Edition) SIAM, Philadelphia

5  Arguments

1:     nIntegerInput
On entry: n, the order of the matrix A.
Constraint: n0.
2:     d[dim]const doubleInput
Note: the dimension, dim, of the array d must be at least max1,n.
On entry: must contain the n diagonal elements of the diagonal matrix D from the LDLH factorization of A.
3:     e[dim]const ComplexInput
Note: the dimension, dim, of the array e must be at least max1,n-1.
On entry: must contain the n-1 subdiagonal elements of the unit lower bidiagonal matrix L. (e can also be regarded as the superdiagonal of the unit upper bidiagonal matrix U from the UHDU factorization of A.)
4:     anormdoubleInput
On entry: the 1-norm of the original matrix A, which may be computed as shown in Section 10. anorm must be computed either before calling nag_zpttrf (f07jrc) or else from a copy of the original matrix A.
Constraint: anorm0.0.
5:     rconddouble *Output
On exit: the reciprocal condition number, 1/κ1A=1/A1A-11.
6:     failNagError *Input/Output
The NAG error argument (see Section 3.6 in the Essential Introduction).

6  Error Indicators and Warnings

Dynamic memory allocation failed.
On entry, argument value had an illegal value.
On entry, n=value.
Constraint: n0.
An internal error has occurred in this function. Check the function call and any array sizes. If the call is correct then please contact NAG for assistance.
On entry, anorm=value.
Constraint: anorm0.0.

7  Accuracy

The computed condition number will be the exact condition number for a closely neighbouring matrix.

8  Parallelism and Performance

Not applicable.

9  Further Comments

The condition number estimation requires On  floating-point operations.
See Section 15.6 of Higham (2002) for further details on computing the condition number of tridiagonal matrices.
The real analogue of this function is nag_dptcon (f07jgc).

10  Example

This example computes the condition number of the Hermitian positive definite tridiagonal matrix A  given by
A = 16.0i+00.0 16.0-16.0i 0.0i+0.0 0.0i+0.0 16.0+16.0i 41.0i+00.0 18.0+9.0i 0.0i+0.0 0.0i+00.0 18.0-09.0i 46.0i+0.0 1.0+4.0i 0.0i+00.0 0.0i+00.0 1.0-4.0i 21.0i+0.0 .

10.1  Program Text

Program Text (f07juce.c)

10.2  Program Data

Program Data (f07juce.d)

10.3  Program Results

Program Results (f07juce.r)

nag_zptcon (f07juc) (PDF version)
f07 Chapter Contents
f07 Chapter Introduction
NAG Library Manual

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