Mathematica 9 is now available
Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2012

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

Search the Archive

Re: Animations in Graphs

  • To: mathgroup at smc.vnet.net
  • Subject: [mg128307] Re: Animations in Graphs
  • From: Bob Hanlon <hanlonr357 at gmail.com>
  • Date: Sat, 6 Oct 2012 01:48:52 -0400 (EDT)
  • Delivered-to: l-mathgroup@mail-archive0.wolfram.com
  • Delivered-to: l-mathgroup@wolfram.com
  • Delivered-to: mathgroup-newout@smc.vnet.net
  • Delivered-to: mathgroup-newsend@smc.vnet.net
  • References: <20121005065007.9F8036871@smc.vnet.net>

myR = Table[r, {r, 0, 1, .1}];

u[r_, \[Theta]_] = 1/(2*Pi)*((1 - r^2)/
     (1 - 2*r*Cos[\[Theta]] + r^2));

Plot[Evaluate[
  Tooltip[u[#, \[Theta]], #] & /@ myR],
 {\[Theta], -Pi/2, Pi/2},
 PlotRange -> {0, 3.25},
 AspectRatio -> 2/3,
 Frame -> True,
 Axes -> False]

Plot3D[u[r, \[Theta]],
 {\[Theta], -Pi/2, Pi/2},
 {r, 0, 1},
 PlotRange -> {0, 4},
 AspectRatio -> 2/3,
 ClippingStyle -> None]

Animate[
 Plot[u[r, \[Theta]], {\[Theta], -Pi/2, Pi/2},
  PlotRange -> {0, 3.25},
  GridLines -> Automatic,
  Frame -> True,
  PlotStyle -> {Thick, Red}],
 {r, 0, 1, 0.1},
 AnimationRunning -> False]

Manipulate[
 Plot[u[r, \[Theta]], {\[Theta], -Pi/2, Pi/2},
  PlotRange -> {0, 3.25},
  GridLines -> Automatic,
  Frame -> True,
  PlotStyle -> {Thick, Red}],
 {r, 0, 1, 0.01, Appearance -> "Labeled"}]


Bob Hanlon


On Fri, Oct 5, 2012 at 2:50 AM,  <psudharaka at gmail.com> wrote:
> Hi everyone,
>
> I produced the following graph but it wont animate.
>
> MyR = Table[r, {r, 0, 1, .1}];
>
> u[\[Theta]_] = 1/(2*Pi)*((1 - r^2)/(1 - 2*r*Cos[\[Theta]] + r^2));
> Plot[u[MyR, \[Theta]], {\[Theta], -Pi/2, Pi/2},
> PlotRange -> {0, 3.25}, PlotStyle -> {Red}, AspectRatio -> 2/3]
>
>
> This following code doesn't produce any errors or Mathematica complaining but nothing happens when I hit play.
>
> Animate[Plot[u[\[Theta]], {\[Theta], -Pi/2, Pi/2}, PlotRange -> {0, 3.25}, GridLines -> Automatic, Frame -> True, PlotStyle -> {Thick, Red}], {r, 0, 1, 0.1}, AnimationRunning -> False]
>
> Thank you and your help is much appreciated.
>



  • Prev by Date: Re: Kernel exits
  • Next by Date: Re: Clearing all variables and definitions: i.e. "resetting" mathematica
  • Previous by thread: Animations in Graphs
  • Next by thread: How to plot function & integral with vector variable ?