MathGroup Archive 1997

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Sorting Eigenvalues/EigenVectors

  • To: mathgroup at smc.vnet.net
  • Subject: [mg8237] Re: Sorting Eigenvalues/EigenVectors
  • From: crose at c2.telstra-mm.net.au (Colin Rose)
  • Date: Thu, 21 Aug 1997 21:16:54 -0400
  • Organization: Theoretical Research Institute
  • Sender: owner-wri-mathgroup at wolfram.com

murray at math.umass.edu (Murray Eisenberg) wrote:

 
  > Here's one way -- undoubtedly the most elegant.

  > a = {{16,19,1},{18,10,20},{10,5,3}};
  > esys = N[Eigensystem[a]]
  > evals = esys[[1]]; evect = esys[[2]]
  > (* Sort[evals] gives the sorted list.  That's not all you want. *)
  > where = Flatten[Map[Position[Sort[evals], #]&, evals]]
  > evals[[where]]
  > evects[[where]]

Yuck.

-- 
Colin Rose 
tr(I) - Theoretical Research Institute
______________________________________
crose at c2.telstra-mm.net.au
http://www.usyd.edu.au/su/tri/


  • Prev by Date: mathematica comes of age as a scientific simulation tool.
  • Next by Date: Re: floor problems
  • Previous by thread: Re: Sorting Eigenvalues/EigenVectors
  • Next by thread: Re: Sorting Eigenvalues/EigenVectors