f08yfc reorders the generalized real
matrix pair
in real generalized Schur form, so that the diagonal element or block of
with row index
is moved to row
, using an orthogonal equivalence transformation. That is,
and
are factorized as
where
are also in real generalized Schur form.
The pair
are in real generalized Schur form if
is block upper triangular with
and
diagonal blocks and
is upper triangular as returned, for example, by
f08xcc, or
f08xec with
.
If
and
are the result of a generalized Schur factorization of a matrix pair
then, optionally, the matrices
and
can be updated as
and
.
Anderson E, Bai Z, Bischof C, Blackford S, Demmel J, Dongarra J J, Du Croz J J, Greenbaum A, Hammarling S, McKenney A and Sorensen D (1999)
LAPACK Users' Guide (3rd Edition) SIAM, Philadelphia
https://www.netlib.org/lapack/lug
-
1:
– Nag_OrderType
Input
-
On entry: the
order argument specifies the two-dimensional storage scheme being used, i.e., row-major ordering or column-major ordering. C language defined storage is specified by
. See
Section 3.1.3 in the Introduction to the NAG Library CL Interface for a more detailed explanation of the use of this argument.
Constraint:
or .
-
2:
– Nag_Boolean
Input
-
On entry: if
, update the left transformation matrix
.
If , do not update .
-
3:
– Nag_Boolean
Input
-
On entry: if
, update the right transformation matrix
.
If , do not update .
-
4:
– Integer
Input
-
On entry: , the order of the matrices and .
Constraint:
.
-
5:
– double
Input/Output
-
Note: the dimension,
dim, of the array
a
must be at least
.
The
th element of the matrix
is stored in
- when ;
- when .
On entry: the matrix in the pair .
On exit: the updated matrix .
-
6:
– Integer
Input
-
On entry: the stride separating row or column elements (depending on the value of
order) in the array
a.
Constraint:
.
-
7:
– double
Input/Output
-
Note: the dimension,
dim, of the array
b
must be at least
.
The
th element of the matrix
is stored in
- when ;
- when .
On entry: the matrix , in the pair .
On exit: the updated matrix
-
8:
– Integer
Input
-
On entry: the stride separating row or column elements (depending on the value of
order) in the array
b.
Constraint:
.
-
9:
– double
Input/Output
-
Note: the dimension,
dim, of the array
q
must be at least
- when
;
- otherwise.
The
th element of the matrix
is stored in
- when ;
- when .
On entry: if , the orthogonal matrix .
On exit: if
, the updated matrix
.
If
,
q is not referenced.
-
10:
– Integer
Input
-
On entry: the stride separating row or column elements (depending on the value of
order) in the array
q.
Constraints:
- if , ;
- otherwise .
-
11:
– double
Input/Output
-
Note: the dimension,
dim, of the array
z
must be at least
- when
;
- otherwise.
The
th element of the matrix
is stored in
- when ;
- when .
On entry: if , the orthogonal matrix .
On exit: if
, the updated matrix
.
If
,
z is not referenced.
-
12:
– Integer
Input
-
On entry: the stride separating row or column elements (depending on the value of
order) in the array
z.
Constraints:
- if , ;
- otherwise .
-
13:
– Integer *
Input/Output
-
14:
– Integer *
Input/Output
-
On entry: the indices
and
that specify the reordering of the diagonal blocks of
. The block with row index
ifst is moved to row
ilst, by a sequence of swapping between adjacent blocks.
On exit: if
ifst pointed on entry to the second row of a
block, 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
or
).
Constraint:
and .
-
15:
– NagError *
Input/Output
-
The NAG error argument (see
Section 7 in the Introduction to the NAG Library CL Interface).
- NE_ALLOC_FAIL
-
Dynamic memory allocation failed.
See
Section 3.1.2 in the Introduction to the NAG Library CL Interface for further information.
- NE_BAD_PARAM
-
On entry, argument had an illegal value.
- NE_CONSTRAINT
-
Constraint: if , ;
otherwise .
Constraint: if , ;
otherwise .
- NE_INT
-
On entry, .
Constraint: .
On entry, .
Constraint: .
On entry, .
Constraint: .
On entry, .
Constraint: .
On entry, .
Constraint: .
- NE_INT_2
-
On entry, and .
Constraint: .
On entry, and .
Constraint: .
- NE_INT_3
-
On entry, , and .
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 contact
NAG for assistance.
See
Section 7.5 in the Introduction to the NAG Library CL Interface for further information.
- NE_NO_LICENCE
-
Your licence key may have expired or may not have been installed correctly.
See
Section 8 in the Introduction to the NAG Library CL Interface for further information.
- NE_SCHUR
-
The transformed matrix pair would be too far from generalized Schur form; the problem is ill-conditioned.
may have been partially reordered, and
ilst points to the first row of the current position of the block being moved.
The computed generalized Schur form is nearly the exact generalized Schur form for nearby matrices
and
, where
and
is the
machine precision. See Section 4.11 of
Anderson et al. (1999) for further details of error bounds for the generalized nonsymmetric eigenproblem.
Background information to multithreading can be found in the
Multithreading documentation.
Please consult the
X06 Chapter Introduction for information on how to control and interrogate the OpenMP environment used within this function. Please also consult the
Users' Note for your implementation for any additional implementation-specific information.
The complex analogue of this function is
f08ytc.
This example exchanges blocks
and
of the matrix pair
, where