% This is Van der Pol's oscillator,
% the example offered by the documentation
% of ode45.m

fvdp = @(T,Y) [Y(2); (1 - Y(1)^2) * Y(2) - Y(1)];
[T,Y] = ode45 (fvdp, [0, 20], [2, 0]);

subplot(2,1,1)
plot(Y(:,1),Y(:,2),'-o') % Phase portrait looks horrible
title('core ode45')

% Now, with the "old" C:\Octave\OCTAVE~1.2\share\octave\packages\odepkg-0.8.5
pkg load odepkg

[T,Y] = ode45 (fvdp, [0, 20], [2, 0]);
subplot(2,1,2)
plot(Y(:,1),Y(:,2),'-o') % Plase portrait looks good.
title('ode45 from odepkg-0.8.5 package')

print comparison.png