[Date Index]
[Thread Index]
[Author Index]
Re: Re: Sum
*To*: mathgroup at smc.vnet.net
*Subject*: [mg55288] Re: [mg55215] Re: Sum
*From*: DrBob <drbob at bigfoot.com>
*Date*: Fri, 18 Mar 2005 05:34:14 -0500 (EST)
*References*: <d192qe$ng4$1@smc.vnet.net> <200503170828.DAA21649@smc.vnet.net>
*Reply-to*: drbob at bigfoot.com
*Sender*: owner-wri-mathgroup at wolfram.com
>> x[k_]:= Exp[-k]
>> Sum[x, {k, 0, Infinity}]
>> - works fine
No, but this does:
x[k_] := Exp[-k]
Sum[x[k], {k, 0, Infinity}]
E/(-1 + E)
That's probably what you meant.
Bobby
On Thu, 17 Mar 2005 03:28:33 -0500 (EST), Ofek Shilon <ofek at simbionix.com> wrote:
> I believe the answer lies in an innocent looking line in the
> Mathematica book, under "Sum":
> "If a sum cannot be carried out explicitly by adding up a finite number
> of terms, Sum will attempt to find a symbolic result. In this case, f
> is first evaluated symbolically. "
> (f refers to the syntax Sum[f, {i, a}]). i.e., when the Sum cannot
> be converted to Plus, f (your x) is evaluated BEFORE the iterator
> variable i (your k). Thus, x is converted to the form Exp[-k] first,
> and is not affected by the "change" in k - in an infinite sum, the
> iterator does not really iterates \inf times.
>
> an easy workaround is to define the k-dependence explicitly:
>
> x[k_]:= Exp[-k]
> Sum[x, {k, 0, Infinity}]
>
> - works fine in Mathematica 5.1.0 on windows. no need to copy/paste
> long expressions, just add the index dependence as above.
>
>
>
>
--
DrBob at bigfoot.com
**References**:
**Re: Sum**
*From:* "Ofek Shilon" <ofek@simbionix.com>
Prev by Date:
**Re: GridLines**
Next by Date:
**nonLinearFit and nonLinearRegress**
Previous by thread:
**Re: Sum**
Next by thread:
** Re: Sum**
| |