MathGroup Archive 2006

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Graphics--combining graphics

  • To: mathgroup at
  • Subject: [mg66137] Re: [mg66108] Graphics--combining graphics
  • From: "David Annetts" <davidannetts at>
  • Date: Sun, 30 Apr 2006 04:22:05 -0400 (EDT)
  • Sender: owner-wri-mathgroup at


> I am trying to create an animation of a piecewise function.  
> I have a graph of a ball rolling and I would like to combine 
> an animation for one equation of motion for the first part 
> with another equation for the second part of the motion.  It 
> is easy enough to create the two animations individually, 
> however I am stumped on how to combine them into one 
> continuous animation. 
> Link to the forum page for this post:
> pageName=Special:Forum_ViewTopic&pid=10007#p10007
> Posted through [[postId=10007]]

Without access to some code, it's difficult to answer in anything other than
generalities but the way I'd approach this is to produce a list of images as
in ...

Img = (If[# < somevalue,
		code to produce motion for first part,
            code to produce motion for second part
	)& /@ Range[timevalues]

Another way to look at this is to write your separate animations to two
separate lists (say a1 & a2), join those lists (to form say a3) to for a
single list list which contains all your images.  You can then display this
list (Show[#]& /@ a3) and animate the cell (using Control-Y).

I also suggest looking at the ElasticCollision notebook on Dave Park's web
site ( as an excellent
example along the lines of what I think you're trying to do.



  • Prev by Date: Re: Graphics--combining graphics
  • Next by Date: Re: Why D[x', x] isn't 0 ?
  • Previous by thread: Re: Graphics--combining graphics
  • Next by thread: Re: Graphics--combining graphics