Jump to content
  • Advertisement
Sign in to follow this  
EonStrife

Eigenvector

This topic is 3956 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, I'm trying to make a routine calculating eigenvalues and eigenvectors. The eigenvectors result of my program is a bit different from the result of this site : http://www.arndt-bruenner.de/mathe/scripts/engl_eigenwert.htm, in which some vectors are in opposing direction. Here's the example.
The matrix :
2 1 0 0
1 2 1 0
0 1 2 1
0 0 1 2

Eigenvalues : 3.16803 2.61803 1.38197 0.38197
Eigenvectors: 
(my result)
0.37175  0.60150  0.60150 -0.37175
0.60150  0.37175 -0.37175  0.60150
0.60150 -0.37175  0.37175 -0.60150
0.37175 -0.60150  0.60150  0.37175
(from that website)

0.37175 -0.60150  0.60150 -0.37175
0.60150 -0.37175 -0.37175  0.60150
0.60150  0.37175  0.37175 -0.60150
0.37175  0.60150  0.60150  0.37175

Another example:
 4  1 -1  2
 1  4  1 -1
-1  1  4  1
 2 -1  1  4

Eigenvalues : 6.00000 4.56155 5.00000 0.43845
Eigenvectors:
(my result)
0.70711  0.43516 -0.00000  0.55735
0.00000  0.55735  0.70711 -0.43516
0.00000 -0.55735  0.70711  0.43516
0.70711 -0.43516  0.00000 -0.55735

(from that website)
0.70711 -0.43516 -0.00000 -0.55735
0.00000 -0.55735  0.70711  0.43516
0.00000  0.55735  0.70711 -0.43516
0.70711  0.43516  0.00000  0.55735
(BTW, I'm going to use it in inverse kinematic) The differences are the on ones in bold. I wonder if they're the same or it's my implementation which is incorrect ? Thanks a lot.

Share this post


Link to post
Share on other sites
Advertisement
Just to expand on Zipster....

if [p q r s]

is an eigenvector for a given eigenvalue, then any vector

[kp kq kr ks] (where k!=0)

is also an eigenvector for that same eigenvalue.

In your case k=-1

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!