Skip to content
Permalink
master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
% function rossler
function y = coupledrossler
a = 0.25; % 0.15 (defined phase) 0.3 (chaotic phase)
b = 0.4; % 0.4
c = 8.5; % 6 8.0
d = 0.97;
g = 0.1;
y0 = [1 1 0 0 1 0];
tspan = [1 30];
[t,y] = ode45(@f5,tspan,y0);
[sz dum] = size(y);
y0 =[y(sz,1) y(sz,2) y(sz,3) y(sz,4) y(sz,5) y(sz,6)];
tspan = [1 200];
options = odeset('OutputFcn',@odephas3);
[t,y] = ode45(@f5,tspan,y0,options);
figure(2)
plot(t,y(:,1),t,y(:,2),t,y(:,3))
figure(3)
plot(y(:,1),y(:,6))
title('x1-z2')
figure(4)
plot(y(:,2),y(:,6))
title('y1-z2')
figure(5)
plot(y(:,1),y(:,5))
title('x1-y2')
theta1 = atan2(y(:,2),y(:,1));
theta2 = atan2(y(:,5),y(:,4));
theta12 = atan2(y(:,2),y(:,4));
theta21 = atan2(y(:,5),y(:,1));
figure(6)
plot(theta1,theta2)
title('theta1 vs. theta2')
figure(7)
plot(theta21-theta12)
title('theta21-theta12')
phse = theta1 - theta2;
figure(8)
[temp bin] = maskbilevel(phse,-pi,pi,0,0);
plot(temp)
title('theta1-theta2')
Metric1 = sqrt(sum((temp.*bin).^2))/sqrt(sum(bin.^2))
d = y(:,1);
e = y(:,2);
f = y(:,3);
Printfile4('lout',t',d',e',f');
function yd = f5(t,y)
yp(1) = -d*y(2) - y(3) + g*(y(4) - y(1));
yp(2) = d*y(1) + a* y(2) + g*(y(5) - y(2));
yp(3) = b + y(3)*(y(1) - c) + g*(y(6) - y(3));
yp(4) = -1*d*y(5) - y(6) + g*(y(1) - y(4));
yp(5) = 1*d*y(4) + a* y(5) + g*(y(2) - y(5));
yp(6) = b + y(6)*(y(4) - c) + g*(y(3) - y(6));
yd = [yp(1);yp(2);yp(3);yp(4);yp(5);yp(6)];
end % end f5
end % end ltest