Advertisement
Guest User

Untitled

a guest
May 24th, 2016
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.37 KB | None | 0 0
  1. Remove["Global`*"]
  2.  
  3. m = {{1, -a + b, 3}, {b, -6, 4}, {3, b, 0}};
  4.  
  5. VecMat[a_, b_] = Eigenvectors[m];
  6.  
  7. VecMatQ[a_, b_] = VecMat[a, b]*Conjugate[VecMat[a, b]];
  8.  
  9. PosVec[a_, b_] =
  10. Table[Position[VecMatQ[a, b][[i]], Max[VecMat[a, b][[i]]]], {i, 1, 3}] // Flatten;
  11.  
  12. PosVec[1, 1] // MatrixForm
  13.  
  14. Table[Position[VecMatQ[1, 1][[i]], Max[VecMat[1, 1][[i]]]], {i, 1, 3}] // Flatten
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement