Personal Website:
Scott Congreve

Teaching

Download<< Back

function vdpol_limit

%% Solve Van der Pol's oscillator over long time period
a = 1.1;
figure;

x0 = [-1;6];
% Plot initial point
plot(x0(1),x0(2),'r*');
hold on;
[~,x]=ode23s(@(t,x)vdpol(t,x,a), [0,1000], x0);
plot(x(:,1),x(:,2),'r');

xlabel('x_1');
ylabel('x_2');
xlim([-4 4]);
ylim([-7 11]);

%% Estimate $\omega$-limit numerically for Van der Pol's oscillator
%
% Cuts off the first N entries of long solve
N=200;

X=x(N:end,:);
figure;
% Plot initial point
plot(x0(1),x0(2),'k*');
hold on;
plot(X(:,1),X(:,2),'k');

xlabel('x_1');
ylabel('x_2');
xlim([-4 4]);
ylim([-7 7]);