Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #6612

Re: Solve equation with summation?

From Andrzej Kozlowski <akoz@mimuw.edu.pl>
Newsgroups comp.soft-sys.math.mathematica
Subject Re: Solve equation with summation?
Date 2011-11-22 10:32 +0000
Organization Steven M. Christensen and Associates, Inc and MathTensor, Inc.
Message-ID <jaftoe$r88$1@smc.vnet.net> (permalink)
References <201111210928.EAA14795@smc.vnet.net>

Show all headers | View raw


This is exactly as it should be. In Mathemaitcs Sum is not an algebraic 
operator but only a Head of an expression. If the arguments of Sum are 
the kind that Mathematica knows how to evaluate it will do so, if not it 
will leave the expression unevaluated. No algebraic operations on this 
expression will have any effect. It seems that people who expect 
something else to happen imagine that Sum is something like Plus, for 
which you can do things like

Simplify[x (a/x + b/x + c/x)]

a+b+c

This will also work:

Simplify[x Sum[a[i]/x, {i, 1, 3}]]

a(1)+a(2)+a(3)

but only because in such a case Sum is evaluated and the result of the 
evaluation is Plus[...]. Only then algebraic transformations can be 
performed. Nothing of that kind will  happen here

Simplify[x*Sum[a[i]/x, {i, 1, n}]]

x*Sum[a[i]/x, {i, 1, n}]

and there is no reason to expect that it will. If you want to be able to 
do such transformations on Sum you have to write the code for it 
yourself. The reason for this behaviour is almost certainly because 
people at WRI believe that this sort of code for Sum would not be 
seriously useful (beyond what most users can either do by hand or by 
simple programming).

Andrzej Kozlowski 



On 21 Nov 2011, at 10:28, Dana DeLouis wrote:

> Hi.  A simpler example than Solve for this issue might be to just 
multiply.
>
> t = Sum[Subscript[a, i]/x, {i, 1, n}]
>
> If you multiply the above by x, then the x should cancel.
>
> However, it still remains unevaluated. 
>
> FullSimplify[x*t]
>
> x*Sum[Subscript[a, i]/x, {i, 1, n}]
>
> As a side note, saying that x was not zero didn't help either.
>
> x * Sum[Subscript[a, i]/x, {i, 1, n}, Assumptions -> x != 0]
> <unevaluated>
>
> Because if x was zero, then you have  Power::Infy
>
> Sum[Subscript[a, i]/0, {i, 1, n}]
>
> Power::infy:Infinite expression 1/0 encountered. >>
> ComplexInfinity
>
> = = = = = = =
>
>
>
> On Nov 18, 6:22 am, Ivan <ive...@gmail.com> wrote:
>> For a summation like \sum_{i=1}^n a_i/x = 1,
>>
>>  Solve[Sum[Subscript[a, i], {i, 1, n}]/x == 1, x]
>>
>> gives a correct solution.
>>
>> However, by putting x into the summation:
>>
>>  Solve[Sum[Subscript[a, i]/x, {i, 1, n}] == 1, x]
>>
>> gives an empty set, why?
>
>
>

Back to comp.soft-sys.math.mathematica | Previous | Next | Find similar | Unroll thread


Thread

Re: Solve equation with summation? Andrzej Kozlowski <akoz@mimuw.edu.pl> - 2011-11-22 10:32 +0000

csiph-web