Animating wave equation in Matlab

15 views (last 30 days)
Yusuf Hassan
Yusuf Hassan on 29 Nov 2013
Answered: Mischa Kim on 15 Jan 2014
Hi there.. I got an assignment on string vibration on PDE where I'm asked to Animate the standing wave,, I managed to get the equation but donno how to Animate it in Matlab,, I'll be grateful to anyone who can help..
file is attached..
  1 Comment
Leo
Leo on 15 Jan 2014
You could use a for loop i.e.
t=0
for t < T
plot(x,U(x,t))
t=t+dt
pause(0.5)
end
which will animate between time 0 and T.

Sign in to comment.

Answers (1)

Mischa Kim
Mischa Kim on 15 Jan 2014
Hello Yusuf, check this out.

Categories

Find more on Animation in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!