How many hessenbegs for a given matrix?


allynm
04-09-2013, 01:12 PM
Hello everyone,

I recently made the grievous mistake of thinking that the elmhes.c routine in NR did not function as intended. I reached this conclusion because when I compared the output of gnu-octave (3.4.2) using the [u,h]=hess(a) routine the results differed from what I got using elmhes on the same matrix.

However, I went ahead and performed the hqr analysis on the hessenberg factorization from elmhes and it identified exactly the same eigenvalues as were reported by octave using the [u,v]=eig(a) call.

This is my question (Sorry for the rather verbose intro): Is it possible to compute two different hessenbergs for the same matrix (whilst preserving the eigenvalues)? Apparently so, but it is not intuitive... Someone who is more knowledgeable than I might offer some enlightenment. For example: when is this not possible?

Thanks,
Mark Allyn

Saul Teukolsky
04-10-2013, 05:24 PM
Hi Mark,

The Hessenberg decomposition is not unique. Details are e.g. in Golub and Van Loan's book, section 7.4.5. You can always check two different purported decompositions by seeing that Q H Q^T gives the original matrix A for both cases.

Best,
Saul Teukolsky

allynm
04-10-2013, 08:16 PM
Good evening, Saul,

Thank you for confirming my hunch.

Regards,
Mark