0

I am using the CurveGraphics6 NB to try and do some 3D related phase portraits and graphics.

The following works and produces an animation.

pic = NDSolve[( {
   {x'[t] == 2 y[t] (z[t] + 1)},
   {y'[t] == -x[t] (z[t] + 1)},
   {z'[t] == -(z[t])^3},
   {x[0] == z[0] == 0},
   {y[0] == 1}} ), 
   {x, y, z}, {t, -9, 9}, Animate -> True, PlotPoints -> 600, 
 ImageSize -> 300, HeadLength3D -> 1/30, DefaultDuration -> 40] // Last

I then attempt:

  Export["temp.gif", pic]

It exports the gif, but not the animation. What am I doing wrong?

I also welcome if anyone has ideas on how to better show this in 3D.

I do not see how to use the nice 3D Phase Portrait on the system above and maybe someone will be kind enough to provide guidance (as that is what I was really after).

Amzoti
  • 1,065
  • 10
  • 19
  • 1
    Is there an animation? I don't see anything moving... In any case, that's probably unrelated to your question. In order to export an animation as gif, you should export a list of frames, not a single dynamic image. – rm -rf Mar 08 '14 at 22:17
  • But wouldn't it be really nice if Mathematica did allow direct export of a Manipulate or Animate to an animated gif, at least if it had a single control variable that varied discretely? – murray Mar 08 '14 at 23:11
  • @rm-rf: You should see a point circling around the portrait. Thanks for the input. – Amzoti Mar 08 '14 at 23:15
  • @murray: Agreed. It would be great to have export what you see. If is has an animation or even variable parameters, and a single export to gif could capture it. Regards – Amzoti Mar 08 '14 at 23:16
  • Ah yes, you're right. Sorry about that :) – rm -rf Mar 08 '14 at 23:33
  • @murray and OP: take a look here http://community.wolfram.com/groups/-/m/t/86994;jsessionid=F81DC17EA304180AFB319A45B4E93E9A.wlp1?p_p_auth=83wbyBRj – Dr. belisarius Mar 09 '14 at 03:44
  • @belisarius: Thank you, I will give that a go! Regards – Amzoti Mar 09 '14 at 03:47
  • Or here http://mathematica.stackexchange.com/a/4231/193 (by the same author, but you can upvote him there :) – Dr. belisarius Mar 09 '14 at 03:47
  • @belisarius: Oh! I had missed your cited post, and I never knew that one can in fact directly export a Manipulate to an independent animation -- provided you use, say, .mov or .avi format rather than .gif. – murray Mar 09 '14 at 15:26
  • But here http://community.wolfram.com/groups/-/m/t/86994;jsessionid=F81DC17EA304180AFB319A45B4E93E9A.wlp1?p_p_auth=83wbyBRj you have the way for going from .mov or .avi to animated .gif. – Dr. belisarius Mar 09 '14 at 17:28

1 Answers1

1

You can't export this in the same way you might a Mathematica animation - the "animation" you see is a Dynamic object, updated via Clock. This is why the documentation for the package says you need Mathematica to use the new features, Player to just see them in action.

If you want to generate an animated GIF, you'll need to parse out the various objects in the generated "animation", and turn them into a list of the base plot and the "animated" point, which you can then use to export to a GIF.

ciao
  • 25,774
  • 2
  • 58
  • 139