- #1
jdawg
- 367
- 2
Homework Statement
I think this problem is supposed to be pretty simple, but I have almost no knowledge of how to use matlab. I was told to use this function: [V,D]=eig(A) to give me the eigenvectors (columns of matrix V) and the diagonal matrix with eigenvales in the diagonal ( matrix D). I also need to check the matrix with A=VDV-1.
Homework Equations
The Attempt at a Solution
I don't feel like this is right, but this is what I tried:
Here is what I typed in the script:
%1
A=[1 -3 3 3; -1 4 -3 -3; -2 0 1 1; 1 0 0 0]
[V,D]=eig(A)
V.*D.*inv(V)
And here is what came out:
A =
1 -3 3 3
-1 4 -3 -3
-2 0 1 1
1 0 0 0V =
-0.0000 0.0000 0.0000 0.5607
-0.0000 -0.7071 0.7071 -0.7476
0.7071 -0.7071 0.7071 -0.3271
-0.7071 0.0000 0.0000 0.1402D =
0.0000 0 0 0
0 1.0000 0 0
0 0 1.0000 0
0 0 0 4.0000ans =
1.0e+07 *
-0.0000 0 0 0
0 -1.0712 0 0
0 0 -1.0712 0
0 0 0 0.0000
[/B]
Last edited: