Hey I'm kind of new to MALAB, so bear with me please!
I'm trying to plot the real and imaginary parts of the eigenvalue results in my for loop, as a function of I from [0,4].
Here's my code:
figurehold onfor I = 0:0.1:4 p = [-1/3 0 -1 (I-2)] r = roots(p) x = r(3) A = [(1 - x^2) -40 ; 1/800 -1/40] e = eig(A) plot(I,real(e(1)),'r-',I,imag(e(1)),'b-')end
My plot keeps coming up empty, and no error shows up. what can i do?
Best Answer