Re: How come doesn't this work?

*To*: mathgroup at smc.vnet.net*Subject*: [mg75714] Re: How come doesn't this work?*From*: Jean-Marc Gulliet <jeanmarc.gulliet at gmail.com>*Date*: Wed, 9 May 2007 04:27:37 -0400 (EDT)*Organization*: The Open University, Milton Keynes, UK*References*: <f1phau$i6i$1@smc.vnet.net>

Anolethron wrote: > I know I have to put Evaluate In but it doesn't work still. > Taylor[n_] := Normal[Series[ArcTan[x], {x, 0, n}]] > > F = ArcTan[x] > Grafico[n_] = > Plot[{F, Taylor[n]} // Evaluate, {x, -Pi, Pi}, > DisplayFunction -> $DisplayFunction] Define Graphico with SetDelayed (as you have done for Taylor) rather than Set. Taylor[n_] := Normal[Series[ArcTan[x], {x, 0, n}]] F = ArcTan[x]; Clear[Grafico] Grafico[n_] := Plot[Evaluate[{F, Taylor[n]}], {x, -Pi, Pi}, DisplayFunction -> $DisplayFunction] Grafico[4]; Regards, Jean-Marc