|
NAG[f08qfc] NAG[nag_dtrexc] - Reorder Schur factorization of real matrix using orthogonal similarity transformation
|
|
Calling Sequence
f08qfc(compq, t, q, ifst, ilst, 'n'=n, 'fail'=fail)
nag_dtrexc(. . .)
Parameters
|
compq - String;
|
|
|
On entry: indicates whether the matrix of Schur vectors is to be updated.
|
|
The matrix of Schur vectors is updated.
|
|
No Schur vectors are updated.
|
|
Constraint: "Nag_UpdateSchur" or "Nag_NotQ". .
|
|
|
t - Matrix(1..dim1, 1..dim2, datatype=float[8], order=order);
|
|
|
Note: this array may be supplied in Fortran_order or C_order , as specified by order. All array parameters must use a consistent order.
|
|
On exit: is overwritten by the updated matrix . See also Section [Further Comments].
|
|
|
q - Matrix(1..dim1, 1..dim2, datatype=float[8], order=order);
|
|
|
Note: this array may be supplied in Fortran_order or C_order , as specified by order. All array parameters must use a consistent order.
|
|
On exit: if , q contains the updated matrix of Schur vectors.
|
|
If , q is not referenced.
|
|
|
ifst - assignable;
ilst - assignable;
|
|
|
Note: On exit the variable ifst will have a value of type integer, ilst will have a value of type integer.
|
|
On entry: ifst and ilst must specify the reordering of the diagonal elements or blocks of . The element or block with row index ifst is moved to row ilst by a sequence of exchanges between adjacent elements or blocks.
|
|
On exit: if ifst pointed to the second row of a 2 by 2 block on entry, it is changed to point to the first row. ilst always points to the first row of the block in its final position (which may differ from its input value by ).
|
|
Constraint: and . .
|
|
|
'n'=n - integer; (optional)
|
|
|
Default value: the dimension of the array t.
|
|
On entry: , the order of the matrix .
|
|
Constraint: . .
|
|
|
'fail'=fail - table; (optional)
|
|
|
The NAG error argument, see the documentation for NagError.
|
|
|
|
Description
|
|
|
Purpose
|
|
nag_dtrexc (f08qfc) reorders the Schur factorization of a real general matrix.
|
|
Error Indicators and Warnings
|
|
"NE_ALLOC_FAIL"
Dynamic memory allocation failed.
"NE_BAD_PARAM"
On entry, argument had an illegal value.
"NE_EXCHANGE"
Two adjacent diagonal elements or blocks could not be successfully exchanged. This error can only occur if the exchange involves at least one 2 by 2 block; it implies that the problem is very ill-conditioned, and that the eigenvalues of the two blocks are very close. On exit, may have been partially reordered, and ilst points to the first row of the current position of the block being moved; (if requested) is updated consistently with .
"NE_INT"
On entry, . Constraint: .
"NE_INT_3"
On entry, , , . Constraint: and .
"NE_INTERNAL_ERROR"
An internal error has occurred in this function. Check the function call and any array sizes. If the call is correct then please consult NAG for assistance.
|
|
Accuracy
|
|
The computed matrix is exactly similar to a matrix , where
and is the machine precision.
Note that if a 2 by 2 diagonal block is involved in the reordering, its off-diagonal elements are in general changed; the diagonal elements and the eigenvalues of the block are unchanged unless the block is sufficiently ill-conditioned, in which case they may be noticeably altered. It is possible for a 2 by 2 block to break into two 1 by 1 blocks, that is, for a pair of complex eigenvalues to become purely real. The values of real eigenvalues however are never changed by the reordering.
|
|
|
Examples
|
|
>
|
compq := "Nag_NotQ":
n := 4:
ifst := 2:
ilst := 1:
t := Matrix([[0.8, -0.11, 0.01, 0.03], [0, -0.1, 0.25, 0.35], [0, -0.65, -0.1, 0.2], [0, 0, 0, -0.1]], datatype=float[8]):
q := Matrix([[0]], datatype=float[8]):
NAG:-f08qfc(compq, t, q, ifst, ilst, 'n' = n):
|
|
|