more off
x0 = rand(4,1)
xdes = [1;2;3;4]

u = inv(Co)*(xdes - (A^4)*x0)  % For derivation in class...

clear x
x(:,1) = x0
for n=1:4
    fprintf('Step %d: u=%.4f...\n',n,u(5-n))
    x(:,n+1) = A*x(:,n) + B*u(5-n)
    input(' ','s')
end
