axiom-developer
[Top][All Lists]

## Re: [Axiom-developer] Issue 336

 From: Martin Rubey Subject: Re: [Axiom-developer] Issue 336 Date: 17 Mar 2007 22:47:46 +0100 User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.4

Waldek Hebisch <address@hidden> writes:

> > I should know, but I don't: is there a sensible definition of the binomial
> > coefficient which disagrees with the definition in terms of Gamma functions
> > at certain values?
> >
>
> P. Luschny argues in favour of another extension of factorial to analytic
> function:
>
>
> Presumably this will also give "sensible" definition of binomial
> coefficients.

Interesting reference, however, I doubt that the alternatives to Gamma are
interesting with respect to binomial coefficients - I have the feeling that

F(x+1)=(x+1)F(x)

is something rather important... (BTW, doesn't define that relation Gamma more
or less uniquely?, What other properties does one need to make it unique?)

> But I think that definition in terms of Gamma functions is simply much more
> popular and much more useful, so I would take it as canonocal definition.

Agreed, Well, it just occurred to me: if we postulate

binomial(n,k)+binomial(n,k+1)=binomial(n+1,k+1)

that forces, putting k=-1

binomial(n,-1) = binomial(n+1,0) - binomial(n,0) = 0

(or did I make a mistake?) I imagine that

binomial(n,k)=(-1)^k binomial(k-n-1, k)

also implies some non-pleasant stuff...

> > If the definition in terms of the Gamma function is "canonical", I'd
> > suggest to simplify only when the limit is unique. (Contrary to
> > Mathematica) So, as you and Mathworld say
> >
> > * for 0 <= k \in Z we return the product
> > * if we can prove that n<k, we return 0
>
> I think that we should produce a conditional expression:
>
> if (k in Z) and (n in Z) and (k <= n) and (n < 0) then
>    error
> else
>    ....

OK.

> Or use provisos.

Yes, that should be really high priority by now. Fortunately, meanwhile I am
quite sure that provisos *only* make sense for "expression like domains", so
they do not seem such a impossible thing anymore.

> But in the mean time I feel that we should simplify: we can not produce
> correct answer (because not simplifying may also give a wrong answer),

I do not understand this. Could you provide an example?

> so the best we can do is to try to be wrong in as rarely as possible.  I do
> not think we should just disable _all_ unjustified simplifications: it would
> a hard job and would make Axiom essentially useless (I do want to get rid of
> unjustified simplifications, but not by disabling them, rather I want to
> justify then if possible and use conditional expressions otherwise).  Since
> now we have a lot of unjustified simplifications disabling one of them may
> just trigger another one, sometimes worse.

To be honest, I doubt that this is the way to go. I'd rather stay
correct-correct, and fix things I break doing so in other ways. This should be
possible, shouldn't it?

> > I wonder about the case n=k. Why isn't that equal to 1? We obtain
> >
> > binomial(m,m)=limit(k->m, n->m) Gamma(n+1)/(Gamma(k+1)Gamma(n-k+1))
> >
> > isn't that limit equal to one?
>
> Take non-integer n.  Let k go to negative integer.  Then Gamma(n+1) and
> Gamma(n-k+1) stay finite, while Gamma(k+1) go to infinity.  So you get zero
> as one accumulation points.  Of course 1 is another accumulation point, so
> the limit does not exist.

thanks.

> In other words: binomial(n, n) has limit 1 when n goes to negative integer.
> But binomial(m, k) has no limit when (m, k) goes to (n, n) where n is a
> negative integer.

So, that raises the question whether to simplify binomial(n,n)... Note that
Mathworld defines it to be 0 when n<0.

> > In ibinom (that is, for FunctionSpaces over arbitrary R we currently have
> >
> > binomial(n,0)=1
> > binomial(n,n)=1
> > binomial(n,1)=n
> > binomial(n,n-1)=n
> >
> > If the above limit does not exist, they are all wrong, I guess...
>
> Only binomial(n,n)=1 and binomial(n,n-1)=n.

But for n<0, binomial(n, n-1) is undefined, isn't it?  If I didn't make a
mistake, this also questions:

> > BTW, does binomial(n,k)=binomial(n,n-k) hold always?

> The equality holds whenever definition via Gamma function works.  If you
> extend definition via continuity it still works.  But if one puts some
> arbitrary value in point of discontinuity then such extension may break
> equality.

Martin