tracing the path of a moving particle in using plot

8 次查看(过去 30 天)
Hi, I want to track the motion of a particle from start to end by tracing its path from start to finish. The particle is moving according to a set of rules. How do I do this?

回答(1 个)

Walter Roberson
Walter Roberson 2016-1-21
Insufficient information about what you want the graph to look like, what information is available, whether you want to simulate the particle moving along a path.
Perhaps you want to use the new-ish animatedLine() function. Or perhaps you want to modify my code from http://www.mathworks.com/matlabcentral/answers/220473-how-can-i-use-the-plot-function-to-show-two-moving-points-with-different-velocities#answer_180901
  2 个评论
cgo
cgo 2016-1-21
yes, i am sorry. i don't know how to explain it further. it is an animation, yes. as the particle moves around the screen, i want the see the trace of the path it is traveling. right now, i can see the particle moving, and that is it.
Walter Roberson
Walter Roberson 2016-1-21
If you have R2014b or later, just keep adding points with animatedline
You might also want to consider comet()

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 Animation 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by