% % Written by: % -- % John L. Weatherwax 2006-09-08 % % email: wax@alum.mit.edu % % Please send comments and especially bug reports to the % above email address. % %----- u=[0;1]; %u=[1;0]; %u=[.5;.5]; A=[.8 .3; .2 .7]; x = u; k = [0:1:7]; while length(x) <= 7 u = A * u; x = [ x u ]; end plot(k,x,'o'); axis( [ min(k) max(k) 0 1 ] ); xlabel('iterate number');