MathGroup Archive 2011

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

Search the Archive

Re: How to add window with values a,b

  • To: mathgroup at smc.vnet.net
  • Subject: [mg117497] Re: How to add window with values a,b
  • From: Bob Hanlon <hanlonr at cox.net>
  • Date: Mon, 21 Mar 2011 06:13:02 -0500 (EST)


When you enter a value in an InputField, a second output cell will be generated. Select this second output cell and hide it with menu command:  Cell | Cell Properties | Open (uncheck). 

If you reevaluate the input cell, cleanup is again required.

Perhaps someone else will know how to avoid this.

Manipulate[Column[{
   Row[{"a = " InputField[
       Dynamic[a], Number, FieldSize -> 4],
     Spacer[75],
     "b = " InputField[
       Dynamic[b], Number, FieldSize -> 4]}],
   Plot[x^5 + a x + b, {x, -4, 4},
    PlotRange -> {-500, 500},
    ImageSize -> 300],
   "Real Roots = " <> ToString[
     Select[x /. NSolve[x^5 + a x + b == 0, x],
      Element[#, Reals] &]]}],
 {a, -100, 100},
 {{b, 0}, -100, 100,
  ControlType -> VerticalSlider},
 ControlPlacement -> {Top, Left}]


Bob Hanlon

---- Artur <grafix at csl.pl> wrote: 

=============
Dear Bob,
I was think about two interractive Windows when I will have possibility 
write two numbers from the range and ruler will be stay automatically on 
these two and vice versa (vice versa only working in Your procedure)
Best wishes
Artur

W dniu 2011-03-19 11:21, Bob Hanlon pisze:
> Manipulate[
>   Plot[x^5 + a x + b, {x, -4, 4},
>    PlotRange ->  {-500, 500}],
>   {a, -100, 100, Appearance ->  "Labeled"},
>   {{b, 0}, -100, 100, Appearance ->  "Labeled"}]
>
> Bob Hanlon
>
> ---- Artur<grafix at csl.pl>  wrote:
>
> =============
> Dear Mathematica Gurus,
> I would like to add to plot draw two windows with exact position of
> ruler for a and b (as numbers)
>
> Clear[a, b]; Manipulate[Plot[x^5 + a x + b, {x, -4, 4}], {a, -100, 100},
> {b, -100, 100}]
>
> How to do that?
> Best wishes
> Artur
>



  • Prev by Date: Re: Vs. 2.2 Notebooks in vs. 7.0?
  • Next by Date: Re: How to kill slave kernel securely?
  • Previous by thread: Re: How to add window with values a,b
  • Next by thread: NonlinearModelFit: Freezing parameters