MATLAB program-To study Vander pol’s equation using MATLAB

 

 

%Vander pol equation using MATLAB
tspan=[0,20];           %A vector specifying the interval of integration,
z0=[0.5,0];              %A vector of initial conditions.
[t,z]=ode23('vander',tspan,z0);     %Solve initial value problems for ordinary differential equations (ODEs)
x=z(:,1);
y=z(:,2);
%figure(1)
plot(t,x,'m',t,y,'k')
grid;
ylim([-3 2])
title('displacement and velocity against time')
xlabel('time')
ylabel('x & y')
%figure(2);
plot(x,y)
grid;
title('phase pole or vander pole equation')
xlabel('displacement')
ylabel('velocity')

 

 

output:

Click on image to enlarge:

 

vander pole op

Click here to download all MATLAB program.. SEM 7 Advance control system Instrumentation