       Re: List of Interpolated functions inside plot

• To: mathgroup at smc.vnet.net
• Subject: [mg25235] Re: List of Interpolated functions inside plot
• From: Rainer Gruber <rainer.gruber at jk.uni-linz.ac.at>
• Date: Sun, 17 Sep 2000 04:47:14 -0400 (EDT)
• Organization: Johannes Kepler Universitaet Linz
• References: <8naq28\$esp@smc.vnet.net>
• Sender: owner-wri-mathgroup at wolfram.com

```Hi chris,

you should try it with Evaluate e. g.

Plot[Evaluate at Table[xyinterp[m][x], {m, 1, 10, 3}], {x, -5, 5}]

By the way: Without Evaluate you get no result not because of  "the value of x
needs to be defined pior to the execution of the Table command".
Plot has Attribute HoldAll an takes its arguments unevaluated. With Evaluate
you  suppress this Attribute and Plot gets the argument in an evaluated form.

"Krautschik, Chris G" wrote:

>  If have defined the following interpolation for arbitrary integer m:
>
> xyinterp[m_] := Interpolation[Table[{x, Sin[m x]}, {x, -5, 5, 0.25}]];
>
> I can plot a number of the interpolated functions on one plot as follows:
>
> Plot[ {xyinterp[x], xyinterp[x], xyinterp[x]}, {x,-5,5} ];
>
> Let's say I want to plot a large number of the functions of integer m but I
> like to use the Table command since typing can become quite tedious:
>
> Then
>
> Plot[ Table[xyinterp[m][x], {m, 1, 10, 3}],{x,-5,5} ]
>
> doesn't work because the value of x needs to be defined pior to the
> execution of the Table command. I have tried various forms of Hold but that
> doesn't seem to work.
>
> Any help or suggestions on how to make this work would be appreciated.
>
> thanks,
> Chris

```

• Prev by Date: Re: How to display the desired numerical precision?
• Next by Date: RE: ParametricPlot3D is buggy
• Previous by thread: Re: Use of Miscellaneous`RealOnly` Package
• Next by thread: point inside torus