Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #10161

Re: problem with Manipulate

From Peter Breitfeld <phbrf@t-online.de>
Newsgroups comp.soft-sys.math.mathematica
Subject Re: problem with Manipulate
Date 2012-05-20 06:35 +0000
Organization Steven M. Christensen and Associates, Inc and MathTensor, Inc.
Message-ID <jpa3be$454$1@smc.vnet.net> (permalink)
References <jp54ri$gq0$1@smc.vnet.net>

Show all headers | View raw


"Physics is Everything....Almost" wrote:

> Why does    Manipulate[ Plot[Sin[x (1+ a x)], {x,0,6} ], (a,0,2} ]  work....
> BUT..... the following doesn't....
> tmp = Plot[Sin[x (1+ a x)], {x,0,6} ]
> Manipulate[ tmp , (a,0,2}]
> I checked Attributes of Manipulate and saw   HoldAll......but Hold what??
> thanks.....Jerry Blimbaum
>

Manipulate doesn't know, that tmp is dependend on a. So write instead:

tmp[a_] := Plot[Sin[x (1 + a x)], {x, 0, 6}]
Manipulate[tmp[a], {a, 0, 2}]

-- 
_________________________________________________________________
Peter Breitfeld | Bad Saulgau, Germany | http://www.pBreitfeld.de

Back to comp.soft-sys.math.mathematica | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

problem with  Manipulate "Physics is Everything....Almost" <fizzycist@knology.net> - 2012-05-18 09:30 +0000
  Re: problem with  Manipulate Dushan Mitrovich <dushanm@nnips.net> - 2012-05-19 09:49 +0000
  Re: problem with  Manipulate esetlzn <esetlzn@gmail.com> - 2012-05-19 09:51 +0000
  Re: problem with  Manipulate DC <b.gatessucks@gmail.com> - 2012-05-19 09:52 +0000
  Re: problem with  Manipulate Peter Breitfeld <phbrf@t-online.de> - 2012-05-20 06:35 +0000

csiph-web