2D vector field video quiver
3 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
mehtap agirsoy
am 29 Jun. 2021
Kommentiert: mehtap agirsoy
am 29 Jun. 2021
Hey guys,
I wrote a code to create 2D flow field but there are some strangeness in my vector plot and the video. When I zoom the vector field there are lots of velocity vectors at the same point and in the video after a few msec previous vector fields are frozen on the screen and the rest flow over them. I don't understans the reason so i couldn't fix my code. If you're able to help I would be appreciate it. Thanks in advance.
3 Kommentare
Akzeptierte Antwort
Bjorn Gustavsson
am 29 Jun. 2021
You seem to never release the hold on the plots - the result is that all subsequent plots are added to the current one. So somewhere after your call to videoWriter do a hold off and move the hold on call to after the first plotting command in the loop. That way you will wipe the contents in the axes. You could also do a clf after the videoWriter-call.
HTH
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Annotations finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!