This is documentation for an obsolete product.
Current products and services

Documentation / DynamicVisualizer / Creating Animations /

6.2 Creating Animations

Please note that these examples require the pendulum created in the preceding section.

Simple animations can be made directly in Mathematica and sent to Dynamic Visualizer.


However, it is possible to calculate entire animation sequences and then send them to Dynamic Visualizer. If a list is sent to Dynamic Visualizer using Visualize, each part of the list is interpreted as a command, or list of commands, at each frame of the animation. So the equivalent of the just-described loop would be the following.



Notice that the animation uses DV`SetOptions instead of SetOptions. SetOptions executes immediately, whereas DV`SetOptions does nothing by itself. Animations built up in this way are faster, because they do not rely on Mathematica, and they can be played again or saved to a disk.

Creating animations in Dynamic Visualizer.

To move more than one object per frame, simply include the DV`SetOptions commands within a sublist. For example, you could move the camera and the model simultaneously.


Here is the first frame of the animation where the camera and model are moved to their desired positions.



Now you have the tools to create the pendulum animation, using the objects created in the preceding section.

As you have defined the invariant point to be at the anchor point of the pendulum, you do not need to move the objects; simply rotating them about this point is sufficient to make the pendulum swing to and fro.


By supplying a list to DV`SetOptions you set the orientation of both objects simultaneously.


Once an animation has been created, it can be repeated or looped in Dynamic Visualizer and saved to disk as a movie.