1 2 3 4 5 6 7 8
A=[0 1;-2 -3]; P = [2 1; 1 1] [V,lambda]=spec(A); B=[1;2]; Bhat=P*B disp(P,"P=") disp(Bhat,"B^=") disp(lambda,"lambda=")