axiom-developer
[Top][All Lists]

## [Axiom-developer] [Axiom-mail] beginner question about sum(...)

 From: Kostas Oikonomou Subject: [Axiom-developer] [Axiom-mail] beginner question about sum(...) Date: Mon, 24 Jan 2005 08:24:55 -0600

```Bill,

Thanks very much for the elucidation.  By way of background, I have been using
Mathematica
for about 10 years, and I'm contemplating a switch to Axiom.

It seems that Axiom is, let's say, "conceptually", very advanced in the sense
of its domains,
types, categories, etc.  Perhaps we could call that its abstract mathematical
knowledge.  This
is notably absent from Mathematica, until at least v5.0, which is almost
current.

But I was disappointed by the sum(1/k^2, k=1..n) example.  I saw that Gosper's
method is
implemented in sum.spad.pamphlet, but this (rather simple) sum needs symbolic
manipulation
of gamma and psi functions, which is not there.  More generally, special
functions seem to be
handled only numerically.  At least for my prospective use of Axiom, this
points to a rather big
"hole". And I wonder how many others of this sort there are.

I also tried sum(1/(k*(k+a)), k=1..n).  That was also returned unevaluated,
although Gosper's
method should handle it.  Why is that?  I don't mind reading the book, so if
somewhere there is
a discussion of (limitations of) symbolic evaluation, please point me there.

Kostas

> Kostas,
>
> My previous reply did not address the issue of the reason why
> Axiom returns the sum unevaluated. Here is what I could find out:
>
> On Sunday, January 23, 2005 11:08 AM you wrote:
>>
>> I am trying to make Axiom evaluate sum(1/k^2, k=1..n).  It
>> returns the sum unevaluated.
>
> I expect the reason that it returns unevaluated is because Axiom
> is simply incomplete. For example Maple gives:
>
>> sum(1/k^2, k=1..n);
>                                       1   2
>                      -Psi(1, n + 1) + - Pi
>                                       6
>
> Axiom does have the Polygamma function, so we can write:
>
> (3) -> f1(n)==sum(1/k^2, k=1..n)
>                                                                    Type:
> Void
> (4) -> f2(n)==-polygamma(1,n+1)+1/6*%pi^2
>                                                                    Type:
> Void
> (5) -> f2(5)
>    Compiling function f2 with type PositiveInteger -> DoubleFloat
>
>    (5)  1.463611111111111
>                                                             Type:
> DoubleFloat
> (6) -> f1(5)
>    Compiling function f1 with type PositiveInteger -> Union(Fraction
>       Polynomial Integer,Expression Integer)
>
>         5269
>    (6)  ----
>         3600
>                                           Type: Union(Expression
> Integer,...)
> (7) -> %::DFLOAT
>
>    (7)  1.4636111111111112
>                                                             Type:
> DoubleFloat
> (8) ->
>
> ---------
>
> Regards,
> Bill Page.
>
>

_______________________________________________
Axiom-mail mailing list