MathGroup Archive 2005

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

Search the Archive

Re: Sum


mjumbo,
Sum has the attribute HoldAll, so its arguments are held in an
unevaluated form. Simply wrap the first argument of Sum with Evalaute


Sum[Evaluate[x], {k, 0, Infinity}]

Cheers,
Brian

mjumbo wrote:
> Can sombody explain me why
>
> Sum[Exp[- k], {k, 0, Infinity}]
>
> gives the correct result, while the following (imho equivalent)
statements
>
> x = Exp[-k]
> Sum[x, {k, 0, Infinity}]
>
> don't? What should I do to make it work? It is rather vexing to
copy/paste long expressions instead of using short placeholders like x.
> __________
> www.newmail.ru -- Íîâàÿ Ïî÷òà: âñå ïî-íîâîìó.


  • Prev by Date: Re: Re: Surface Normal
  • Next by Date: Re: Re: Does Mathematica 5 use multiple processors on SPARC?
  • Previous by thread: Re: Sum
  • Next by thread: numerical, bessel