|
NAG[f04mcc] NAG[nag_real_cholesky_skyline_solve] - Approximate solution of real symmetric positive-definite variable-bandwidth simultaneous linear equations (coefficient matrix already factorized by f01mcc (nag_real_cholesky_skyline))
|
|
Calling Sequence
f04mcc(selct, al, d, row, b, x, 'n'=n, 'nrhs'=nrhs, 'lal'=lal, 'tdb'=tdb, 'tdx'=tdx, 'fail'=fail)
nag_real_cholesky_skyline_solve(. . .)
Parameters
|
al - Vector(1..lal, datatype=float[8]);
|
|
|
On entry: the elements within the envelope of the lower triangular matrix , taken in row by row order, as returned by f01mcc (nag_real_cholesky_skyline). The unit diagonal elements of must be stored explicitly.
|
|
|
d - Vector(1..n, datatype=float[8]);
|
|
|
|
row - Vector(1..n, datatype=integer[kernelopts('wordsize')/8]);
|
|
|
Constraint: for . .
|
|
|
b - Matrix(1..n, 1..tdb, datatype=float[8], order=C_order);
|
|
|
|
x - Matrix(1..n, 1..tdx, datatype=float[8], order=C_order);
|
|
|
|
'n'=n - integer; (optional)
|
|
|
Default value: the first dimension of the arrays d, row, b, x.
|
|
On entry: , the order of the matrix .
|
|
Constraint: . .
|
|
|
'nrhs'=nrhs - integer; (optional)
|
|
|
Default value: the second dimension of the arrays b, x.
|
|
On entry: , the number of right-hand sides.
|
|
Constraint: . .
|
|
|
'lal'=lal - integer; (optional)
|
|
|
Default value: the dimension of the array al.
|
|
On entry: the dimension of the array al as declared in the function from which nag_real_cholesky_skyline_solve (f04mcc) is called.
|
|
Constraint: . .
|
|
|
'tdb'=tdb - integer; (optional)
|
|
|
On entry: the second dimension of the array b as declared in the function from which nag_real_cholesky_skyline_solve (f04mcc) is called.
|
|
Constraint: . .
|
|
|
'tdx'=tdx - integer; (optional)
|
|
|
On entry: the second dimension of the array x as declared in the function from which nag_real_cholesky_skyline_solve (f04mcc) is called.
|
|
Constraint: . .
|
|
|
'fail'=fail - table; (optional)
|
|
|
The NAG error argument, see the documentation for NagError.
|
|
|
|
Description
|
|
|
Purpose
|
|
nag_real_cholesky_skyline_solve (f04mcc) computes the approximate solution of a system of real linear equations with multiple right-hand sides, , where is a symmetric positive-definite variable-bandwidth matrix, which has previously been factorized by f01mcc (nag_real_cholesky_skyline). Related systems may also be solved.
|
|
Description
|
|
The normal use of nag_real_cholesky_skyline_solve (f04mcc) is the solution of the systems , following a call of f01mcc (nag_real_cholesky_skyline) to determine the Cholesky factorization of the symmetric positive-definite variable-bandwidth matrix .
However, the function may be used to solve any one of the following systems of linear algebraic equations:
(1)
(2)
(3)
(4)
(5)
(6)
denotes a unit lower triangular variable-bandwidth matrix of order , a diagonal matrix of order , and a set of right-hand sides.
The matrix is represented by the elements lying within its envelope, i.e., between the first non-zero of each row and the diagonal (see Section [Example] for an example). The width of the th row is the number of elements between the first non-zero element and the element on the diagonal inclusive.
|
|
Error Indicators and Warnings
|
|
"NE_2_INT_ARG_GT"
On entry, while . These arguments must satisfy .
"NE_2_INT_ARG_LT"
On entry, while . These arguments must satisfy .
"NE_BAD_PARAM"
On entry, argument selct had an illegal value.
"NE_INT_ARG_LT"
On entry, n must not be less than 1: .
"NE_NOT_UNIT_DIAG"
The lower triangular matrix has at least one diagonal element which is not equal to unity. The first non-unit element has been located in the array
"NE_ZERO_DIAG"
The diagonal matrix is singular as it has at least one zero element. The first zero element has been located in the array
|
|
Accuracy
|
|
The usual backward error analysis of the solution of triangular system applies: each computed solution vector is exact for slightly perturbed matrices and , as appropriate (see pages 25-27 and 54-55 of Wilkinson and Reinsch (1971)).
|
|
Further Comments
|
|
The time taken by nag_real_cholesky_skyline_solve (f04mcc) is approximately proportional to , where .
The function may be called with the same actual array supplied for the arguments b and x, in which case the solution matrix will overwrite the right-hand side matrix.
|
|
|
Examples
|
|
>
|
selct := "Nag_LDLTX":
n := 6:
nrhs := 2:
lal := 14:
tdb := 2:
tdx := 2:
al := Vector([1, 2, 1, 3, 1, 1, 5, 4, 1.5, 0.5, 1, 1.5, 5, 1], datatype=float[8]):
d := Vector([1, 1, 4, 16, 1, 16], datatype=float[8]):
arow := Vector([1, 2, 2, 1, 5, 3], datatype=integer[kernelopts('wordsize')/8]):
b := Matrix([[6, -10], [15, -21], [11, -3], [0, 24], [51, -39], [46, 67]], datatype=float[8], order='C_order'):
x := Matrix(6, 2, datatype=float[8], order='C_order'):
NAG:-f04mcc(selct, al, d, arow, b, x, 'n' = n, 'nrhs' = nrhs, 'lal' = lal, 'tdb' = tdb, 'tdx' = tdx):
|
|
|