SuanShu, a Java numerical and statistical library

com.numericalmethod.suanshu.matrix.doubles.factorization.eigen
Class Hessenberg

java.lang.Object
  extended by com.numericalmethod.suanshu.matrix.doubles.factorization.eigen.Hessenberg

public class Hessenberg
extends java.lang.Object

This class implements the operations for an upper Hessenberg matrix. An upper Hessenberg matrix is a square matrix which has zero entries below the first subdiagonal.

For example,

 | 1 2 3 4   |
 | 5 6 7 8   |
 | 0 9 10 11 |
 | 0 0 12 13 |
 

See Also:
Nested Class Summary
static class Hessenberg.DefaultDeflationCriterion
          Users can override the default implementation to define their 0 threshold.
static class Hessenberg.Deflation
          This class encapsulates the indices for the upper left hand corner, and lower right hand corner of H22.
static interface Hessenberg.DeflationCriterion
          User implements this class to decide whether to split an upper Hessenberg into multiple smaller upper Hessenberg when the sub-diagonal entries are sufficiently small.
 
Field Summary
 Hessenberg.DeflationCriterion deflationCriterion
          the deflation criterion used for this instance of Hessenberg
 
Constructor Summary
Hessenberg()
          Create a Hessenberg utility class with the default deflation criterion.
Hessenberg(Hessenberg.DeflationCriterion dc)
          Create a Hessenberg utility class with a customized deflation criterion.
 
Method Summary
 Hessenberg.Deflation backSearch(Matrix H, int n, double epsilon)
          Find H22 such that H22 is the largest unreduced Hessenberg sub-matrix.
static boolean isHessenberg(Matrix H, double epsilon)
          Check if H is upper Hessenberg.
 boolean isReducible(Matrix H, double epsilon)
          Check if H is upper Hessenberg and is reducible.
 java.util.ArrayList<Matrix> reduce(Matrix H)
          Deprecated. Not supported yet.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

deflationCriterion

public final Hessenberg.DeflationCriterion deflationCriterion
the deflation criterion used for this instance of Hessenberg

Constructor Detail

Hessenberg

public Hessenberg()
Create a Hessenberg utility class with the default deflation criterion.


Hessenberg

public Hessenberg(Hessenberg.DeflationCriterion dc)
Create a Hessenberg utility class with a customized deflation criterion.

Parameters:
dc - a deflation criterion
Method Detail

isHessenberg

public static boolean isHessenberg(Matrix H,
                                   double epsilon)
Check if H is upper Hessenberg.

An upper Hessenberg matrix has zero entries below the first subdiagonal.

Parameters:
H - a matrix
epsilon - a precision parameter: when a number |x| ≤ ε, it is considered 0
Returns:
true iff H is upper Hessenberg

isReducible

public boolean isReducible(Matrix H,
                           double epsilon)
Check if H is upper Hessenberg and is reducible.

Note: zero matrix

| 0 |
is unreducible.

Parameters:
H - a matrix
epsilon - a precision parameter: when a number |x| ≤ ε, it is considered 0
Returns:
true iff H is upper Hessenberg and is reducible

reduce

@Deprecated
public java.util.ArrayList<Matrix> reduce(Matrix H)
Deprecated. Not supported yet.

This looks for 0s in the sub-diagonal of a Hessenberg matrix, H. This reduces (splits) H into a number of non-reducible Hessenberg matrices.

For example, we reduce

 |  1  2  3  4  5  6 |
 |  7  8  9 10 11 12 |
 |  0 14 15 16 17 18 |
 |  0  0  0 22 23 24 |
 |  0  0  0 28 29 30 |
 |  0  0  0  0 35 36 |
 
into
 |  1  2  3 |
 |  7  8  9 |
 |  0 14 15 |
 
and
 | 22 23 24 |
 | 28 29 30 |
 |  0 35 36 |
 
Not yet implemented.

Parameters:
H - a matrix
Returns:
a list of non-reducible Hessenberg matrices

backSearch

public Hessenberg.Deflation backSearch(Matrix H,
                                       int n,
                                       double epsilon)
Find H22 such that H22 is the largest unreduced Hessenberg sub-matrix. A modified version of
 Algorithm 3.3 in
 Matrix Algorithms, Volume II by
 Steward G. W.
 

For performance reason:

Side effect: this modifies H by rounding the negligible sub-diagonal elements to 0

Parameters:
H - the Hessenberg matrix
n - the start index for the back search
epsilon - a precision parameter: when a number |x| ≤ ε, it is considered 0
Returns:
Deflation information which specifies the upper left hand corner and lower right hand corner indices of H22

SuanShu, a Java numerical and statistical library

Copyright © 2011 Numerical Method Inc. Ltd. All Rights Reserved.