clear
global N G M
T = 4;
G = 1;
N = 2;
M = ones(1,N);
IC = rand(1 ,4*N);
tspan = [0 , T];
%tspan = zeros(1, 1+ T/dt);
%tspan(:) = 0:dt:T;
% carry out integration of system
options=odeset('RelTol ' ,1e-6,'AbsTol' ,1e-6);
[t ,y] = ode113('orbit2df' ,tspan ,IC,options);

figure(1)
clf

plot(y(: , 2*1-1), y(: , 2*1),'k')
hold on
plot(y(: , 2*2-1), y(: , 2*2),'b')
hold off
