MathGroup Archive 2004

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

Search the Archive

Re: Problem with animate

  • To: mathgroup at
  • Subject: [mg47340] Re: Problem with animate
  • From: bobhanlon at (Bob Hanlon)
  • Date: Tue, 6 Apr 2004 06:36:23 -0400 (EDT)
  • References: <c4rd13$m9n$>
  • Sender: owner-wri-mathgroup at

As you stated, n has a value.  Either clear n before using it as an iterator or
use a module to make it local.

Module[{n}, Animate[Plot[Sin[n x],{x,0,2 Pi}],{n,1,6,1}]];

Bob Hanlon

In article <c4rd13$m9n$1 at>, "Phil Light"
<usenet at> wrote:

<< I am trying to use animate as shown in the documentation with v5, but 
instead of producing a graph for each value of n as expected, I only get one 
graph uses the value of n before the Animate command:

<< Graphics`Animation`

Animate[Plot[Sin[n x],{x,0,2 Pi}],{n,1,6,1}]

<<<Single graph for value of n before this command, in this case 35>>>

Animate[-Graphics-, {35, 1, 6, 1}]

Anyone know what I'm doing wrong?

  • Prev by Date: Re: Problem with AltGr key on german keyboard
  • Next by Date: All combinations
  • Previous by thread: Problem with animate
  • Next by thread: Re: Problem with animate