Mathematica Stack Exchange is a question and answer site for users of Mathematica. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is it possible to presserve my animation and manipulation plots in the pdf?

share|improve this question
Do you mean CDF (Computable Document Format) or PDF (Portable Document Format)? – Silvia Apr 25 '13 at 19:45
PDF is animation capable, but you will be in much less pain with conversions if you just use CDF - as @Silvia recommended. – Vitaliy Kaurov Apr 25 '13 at 20:00
@VitaliyKaurov I guess converting to animation in PDF would be highly difficult, if not impossible.. I personally like to see a convertor to Asymptote. – Silvia Apr 25 '13 at 20:06
No I actually do mean pdf. As in files which are read by Acrobe. – Hawk Apr 25 '13 at 20:08
Reason is because I need to include the animation in my LaTeX – Hawk Apr 25 '13 at 20:10
up vote 10 down vote accepted

You can export animations to SWF:

movie = Animate[Plot[Sin[x + a], {x, 0, 10}], {a, 0, 5}];
Export["movie.swf", movie]

You can import them in LaTeX (see TeX SE):


(I had to insert the dimensions manually.)

share|improve this answer
I often use media9 to insert mp4s in my beamer presentations. However on OS X, it looks like only Adobe Reader can display them. Preview and Skim simply display a blank page – R. M. Apr 26 '13 at 1:41
Preview (or native Mac pdf) does not support SWF/GIF/etc plugins. – Michael E2 Apr 26 '13 at 2:40
I noticed that if I don't specify the video dimension, nothing shows up. Why is that? – Hawk Apr 27 '13 at 17:42
@jak Do you mean in the LaTeX file? I know a lot about Plain TeX but little about LaTeX. It looks like the default size is 0pt x 0pt. (Put rules around it -- they show up as a dot.) You should ask on Perhaps there's a way to automatically read the image size. – Michael E2 Apr 27 '13 at 21:25

Actually, *.avi or *. SWF can be read by Adobe Acrobat Pro.

You can try as Michael E2 did:

movie = Animate[Plot[Sin[x + a], {x, 0, 10}], {a, 0, 5}];
Export["C:\\movie.avi", movie]

Use Adobe Acrobat Pro to open the file exported, i.e., C:\movie.avi.

Double click on the figure will animate it.

enter image description here

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.