Plotting animations (time-evolution)

Join the discussion
Ask a follow-up here, or get your own question answered by working scientists, mathematicians and engineers — people, not an autocomplete.
Real named experts · corrections over time · the nuance an AI answer skips
2 replies · 2K views
WWCY
Messages
476
Reaction score
15
Hi all,

I have a spatial probability density function that is dependent on ##x##, space and ##t##, time.

I am able to make a plot for spatial probability density for each point in time by specifying ##t## values by using the fplot function.

However, I want an animation that allows me to see how probability density evolves from say ##t[0 , 5]##.

Are there any MATLAB functions that could help me achieve this?

Many thanks in advance.
 
Physics news on Phys.org
In the loop over time, simply plot the pdf at every step on the same plot. As the calculation goes, it will appear as an animation.
 
DrClaude said:
In the loop over time, simply plot the pdf at every step on the same plot. As the calculation goes, it will appear as an animation.

I believe I understand what you mean. I'll give it a shot, thank you!