ordeig

Eigenvalues of a quasitriangular matrix in the order of the diagonal blocks.

Category: Mathematics > Linear Algebra

Syntax

e = ordeig(T)

Returns the eigenvalues of the (quasi)triangular T as they appear down the diagonal.

e = ordeig(A, B)

Same for the generalized problem with triangular pair (A, B).

Description

eig returns eigenvalues in an order that does not tell where they sit in a Schur form. ordeig reads them straight from the diagonal of T, including the 2-by-2 blocks of real Schur form, so you can build the selection vector that ordschur needs.

Input arguments

T
Upper triangular or quasitriangular (real Schur) matrix.

Output arguments

e
Column vector of eigenvalues in diagonal order.

Example

Diagonal order of a Schur form

T = [1 2 3; 0 4 5; 0 0 6];
ordeig(T)
[U, S] = schur([1 2; 3 4]);
ordeig(S)
Output
ans = 3×1

     1
     4
     6
ans = 2×1

   -0.3723
    5.3723

See also

ordschur schur eig ordqz