ode45 events using problem
显示 更早的评论
[T,Z] = ode45(@bouncing, [0 12], [100 0],'tspan','options','events');
options = odeset('events');
events(t,z) = [y(1)-10,1,-1]
value = y(1)-10;
isterminal = 1;
direction = -1;
axis([-5 5 0 120])
a = 0;
y = Z(:,1);
while a < 69
viscircles([0,y(1+a)],10,'Linewidth',10');
pause(0.1);
cla;
a = a+1;
end
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 App Building 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!