First, essentially all eigenvalue packages are adaptations of routines
published in the Handbook on Linear Algebra, Wilkinson and Reinsch, 1971.
This includes EISPACK, IMSL, and the routines shown in Numerical Recipes.
The Handbook presented ALGOL code, and as this was a few years before the
"don't use goto" paper, the code is really spaghetti'd, and the EISPACK
routines inherited this structure. The Numerical Recipes authors have
done the great service of untangling this mess and presenting well-strucured
code (at least in the C and Pascal versions, I haven't looked at the
FORTRAN book in a long time).
So, in response to your question: The QL algorithm does not inherently
produce ordered eigenvalues. There are about three lines of code that
implement a bubble sort within the outermost loop. If you don't want
ordered eigenvalues or want some other ordering, modify those lines.
Consult NR to identify those lines, even if you are working with EISPACK
code.
If you need only a small fraction of the eigenvalues, use one of the bisection
routines, rather than QL.
--
Bill Frensley
Electrical Engineering
University of Texas at Dallas
P.O. Box 830688, MS. EC-33
Richardson, Texas 75083-0688