% Schrodinger's equation on a lattice - ratio map clear u v x y; % nn = 6; % fix integer for possible periodic solutions yy(1) = 1; % initial condition ee = 2.*cos(pi./nn)+ .1; % E = energy eps = .0; % size of random perturbation steps = 6.*50; % number of iterations % for jj=1:steps yy(jj+1) = ee - 1./yy(jj) -eps.*randn(1); % ratio map u(jj) = yy(jj); % save values for plotting v(jj) = yy(jj+1); end; x = -5:.053:5; % curve describing the map y = ee-1./x; % hold plot(x,y) % plot nonlinear curve describing the map hold plot(u,v,'-.*') % % % Calculate products to test growth for k= 1:steps produ(k) = prod(u(1:k)); slog(k) = mean(log(abs(u(1:k)))); end; axis([-5 5 -10 10])