function []=hw5_2_14(A) % finds right and left eigenvectors of (optional input) matrix A if nargin==0 A=[8,-1,-5; -4,4,-2; 18,-5,-7]; end % A*V=D*V where cols of V are right e-vects and diag of D are e-vals [V,D]=eig(A); disp('right e-vects (as cols)') V % V2'*A=V2'*D where rows of V2' are left e-vects and D is the same as before [V2,D]=eig(A'); disp('left e-vects (as rows)') V2'