plot trajectory around fix points

1 visualización (últimos 30 días)
mostafa
mostafa el 27 de Abr. de 2014
Comentada: Roger Stafford el 27 de Abr. de 2014
hi
i want to plot trajectory around fix point for :
by thanks to Mischa Kim and how to draw a trajectory
if true
tspan=[0,1.5];
IC = 1.1 + (-1.1-1.1).*rand(300,2);
hold on
for ii = 1:length(IC(:,1))
[t,x]=ode45(@simple1,tspan,IC(ii,:));
plot(x(:,1),x(:,2),'r');
end
title('CE4-3 Trajectory XY')
xlabel('X')
ylabel('Y')
grid
end
and
if true
function xprime = simple1(t,x);
xprime=[x(2)^2+x(1)*x(2);x(2)^2 - x(2)*x(1)^3];
end
end
but my trajectory looks half .
  3 comentarios
mostafa
mostafa el 27 de Abr. de 2014
i fix that
function xprime = simple1(t,x);
xprime=[x(1)^2+x(1)*x(2);x(2)^2 - x(2)*x(1)^3]; end
Roger Stafford
Roger Stafford el 27 de Abr. de 2014
It still doesn't match! There is a minus sign which isn't present in the equation picture.

Iniciar sesión para comentar.

Respuestas (0)

Categorías

Más información sobre MATLAB en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by