MathGroup Archive 2009

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

Search the Archive

Re: newbie: can't Manipulate ListPlot of recurrence

  • To: mathgroup at smc.vnet.net
  • Subject: [mg96823] Re: newbie: can't Manipulate ListPlot of recurrence
  • From: dh <dh at metrohm.com>
  • Date: Wed, 25 Feb 2009 04:08:09 -0500 (EST)
  • References: <go0j40$n0f$1@smc.vnet.net>


Hi Tom,

you can not use y for two things, table-generator and 

Manupulate-variable. Here is the corrected version:

Manipulate[

  ListPlot[(y = y0; Table[y = a y (1 - y), {50}]),

   Joined -> True], {{a, 3.5}, 0, 4}, {{y0, 0.4}, 0, 1}]

Daniel



Tom Roche wrote:

> summary: I'm trying to Manipulate the logistic map. I can ListPlot it,

> but when I try to Manipulate, the UI behaves weirdly.

> 

> details:

> 

> As advertised by the Subject:, I'm new to Mathematica (specifically

> 7.0.0 for Students for 32-bit Windows on XP Pro) so please excuse any

> lapses in terminology. I'd also appreciate pointers to specific docs

> rather than just an RTFM.

> 

> I'm trying to model the logistic map y=a y (1-y):

> 

> http://en.wikipedia.org/wiki/Logistic_map

> http://mathworld.wolfram.com/LogisticMap.html

> http://www.phy.duke.edu/~palmer/notebooks/LogisticMap.nb

> 

> To start with I just tried to plot it, which works:

> 

> Clear[a, y];

> a=3.5;

> y=0.4;

> ListPlot[Table[y=a y (1-y),{50}],Joined->True]

> 

> I'd like to Manipulate a and y, but when I try to

> 

> Clear[a, y];

> Manipulate[

>   ListPlot[Table[y=a y (1-y),{50}],Joined->True], {{a, 3.5}, 0,  4},

> {{y, 0.4}, 0, 1}]

> 

> I get weird behavior:

> 

> 1 initially the y slider oscillates

> 

> 2 initially the plot displays but flashes (apparently between two

>   phases) until I click one of the sliders

> 

> 3 the y slider will not move

> 

> 4 the a slider can be dragged, but to no effect (i.e. the plot does

>   not change)

> 

> 5 there are no error messages

> 

> What am I doing wrong? and how can I Manipulate this map?

> 

> TIA, Tom Roche <Tom_Roche at pobox.com>

> 




  • Prev by Date: Re: listing user defined, independent variables
  • Next by Date: Re: newbie: how to define, typeset a multi-rule function?
  • Previous by thread: Re: newbie: can't Manipulate ListPlot of recurrence
  • Next by thread: Re: newbie: can't Manipulate ListPlot of recurrence