Séminaire Lotharingien de Combinatoire, B24b (1990), 28 pp.

THREE RECITATIONS ON HOLONOMIC SYSTEMS

AND HYPERGEOMETRIC SERIES

DORON ZEILBERGER ^{1}

Preface: These “recitations” were given in the 24^{th} session of the “Séminaire Lotharingien”, held in the Spring of 1990, somewhere in the Vosges mountains. I thank Dominique Foata for inviting me, and letting me sample one of these charming seminars that preserve the spirit that Oberwolfach lost a long time ago. I would like to thank Peter Paule and Volker Strehl for the invitation to include them in this special issue of the JSC, and for many helpful comments.

Foreword

When we teach calculus we have lectures and recitations. These notes are meant as “recitations” or something like “Schaum outlines” for the theory. The role of the “lectures” or “textbook” is provided by Gosper’s path-breaking paper “A Decision Procedure for Indefinite summation”, Proc. Nat. Acad. Sci. USA 75 (1978), 40-42, and by the following papers by myself and my collaborators, Gert Almkvist and Herb Wilf.

[AZ] (With Gert Almkvist) The method of differentiating under the integral sign, J. Symbolic Computation 10, 571-591 (1990).

[WZ1] (With H. S. Wilf) Rational functions certify combinatorial identities, J. Amer. Math. Soc. 3, 147-158 (1990).

[WZ2] (With H. S. Wilf) Towards computerized proofs of identities, Bulletin of the Amer. Math. Soc. 23, 77-83 (1990).

[Z1] A Holonomic systems approach to special functions identities, J. of Computational and Applied Math. 32, 321-368 (1990).

[Z2] A Fast Algorithm for proving terminating hypergeometric identities, Discrete Math 80, 207-211 (1990).

[Z3]The method of creative telescoping, J. Symbolic Computation 11, 195-204 (1991).

In addition, the following papers give further expositions by myself.

1 Department of Mathematics, Temple University, Philadelphia, PA 19122, USA.

(zeilberg@math.temple.edu). Supported in part by the NSF.

Updated version, February 22, 1995, of a paper that appeared in Publ. I.R.M.A. Strasbourg, 1993, 461/S-34, Actes 24^{e} Séminaire Lothringien, p. 5-37.

[Z5] Identities in search of identity, J. Theoretical Computer Science 117, 23-38 (1993).

[Z6] Theorems for a price: Tomorrow’s semi-rigorous mathematical culture, Notices of the Amer. Math. Soc. 40 # 8 (Oct. 1993), 978-981. Reprinted (followed by a critique by George Andrews) in: Math. Intell. 16 #1 11-14.

There also appeared superb expositions by Pierre Cartier [C], on the general theory, and by Tom Koornwinder [K], on the fast algorithm and its q-analog. Excellent treatments of Gosper’s algorithm and of the fast algorithm are given in sections 5.7 and 5.8 of [GPK] below. The former section also appears in the first edition, the latter section is new to the second edition. More recently, Herb Wilf [W] wrote beautiful lecture notes.

[C] P. Cartier, Démonstration “automatique” d’identités et fonctions hypergéométriques [d’apres D. Zeilberger], Séminaire Bourbaki, exposé n^{o} 746, Astérisque 206, 41-91, SMF, 1992.

[GKP] R. L. Graham, D. E. Knuth, and O. Patashnik, Concrete Mathematics, Second Edition, Addison-Wesley, Reading, 1993.

[K] T. H. Koornwinder, Zeilberger’s algorithm and its q-analogue, J. of Computational and Applied Math. 48, 91-111 (1993).

[W] H.S. Wilf, “Identities and their computer proofs”, SPICE lecture notes 31, 1993. Available by anonymous ftp to ftp.cis.upenn.edu as file

pub/wilf/lecnotes.ps.

The following papers offer important extensions, implementations, and applications.

[PS] P. Paule and M. Schorn, A Mathematica version of Zeilberger’s algorithm for proving binomial coefficient identities, J. Symbolic Comp., to appear.

[Ko1] W. Koepf, REDUCE package for the indefinite and definite summation , Konrad-Zuse-Zentrum für Informationstechnik Berlin (ZIB), Technical Report TR 94-9, 1994.

[Ko2] W. Koepf, Algorithms for the Indefinite and Definite Summation, Konrad-Zuse-Zentrum für Informationstechnik Berlin (ZIB), Technical Report TR 94-33, 1994.

[St1] V. Strehl, Binomial sums and identities, Maple Technical Newsletter 10, 37-49 (1993).

Recitation I: Elimination

The process of elimination consists of getting simple, or desirable, equations out of a given system of equations. For example

(i) 2x + 3y − 5 = 0, (ii) 3x − y − 2 = 0.

In order to eliminate x, we do

3(i) − 2(ii) = 6x + 9y − 15 − 6x + 2y + 4 = 0

getting 11y − 11 = 0 and hence y = 1.

The resultant of two polynomials P (x) and Q(x) is obtained by eliminating x between them. The vanishing of the resultant is the condition that they have a common root. For example, if f = ax^{2} + bx + c and g = a′x^{2} + b′x + c′, then we have

( \begin{matrix}a & b & c & 0 \\ 0 & a & b & c \\ a′ & b′ & c′ & 0 \\ 0 & a′ & b′ & c′ \end{matrix} ) ( \begin{matrix}x^{3} \\ x^{2} \\ x \\ 1 \end{matrix} ) = ( \begin{matrix}0 \\ 0 \\ 0 \\ 0 \end{matrix} ) .

Eliminating x, one gets the determinant of the above matrix (the so-called Sylvester matrix), which is the resultant.

The discriminant of a polynomial P (x) is the resultant of P (x) and P′(x), and its vanishing gives the condition that it has a double root. For example, for the generic second degree polynomial, P (x) = ax^{2} + bx + c, eliminating x from P (x) and P′(x) yields

−4aP (x) + (b + 2ax)P′(x) = b^{2} − 4ac.

For systems of polynomial equations with several variables

P_{1}(x_{1}, …, x_{n}) = 0, …, P_{m}(x_{1}, …, x_{n}) = 0,

we can eliminate m − 1 variables, getting a polynomial equation

Q(x_{1}, …, x_{n−m+1}) = 0.

BUCHBERGER’S AMAZING GRÖBNER BASES DO THAT FAST.

The Joy of Operator Notation

Let N be the shift operator in n : Nf(n) := f(n + 1).

Example: Prove that

F_{n+4} = F_{n+2} + 2F_{n+1} + F_{n},

where F_{n} are the Fibonacci numbers.

Verbose Proof:

F_{n+2} − F_{n+1} − F_{n} = 0,  (i)
F_{n+3} − F_{n+2} − F_{n+1} = 0,  (ii)
F_{n+4} − F_{n+3} − F_{n+2} = 0;  (iii)
F_{n+4} − F_{n+2} − 2F_{n+1} − F_{n} = 0.  (i) + (ii) + (iii)

Terse Proof:

(N^{2} − N − 1)F_{n} = 0 ⇒ (N^{2} + N + 1)(N^{2} − N − 1)F_{n} = 0 ⇒ (N^{4} − N^{2} − 2N − 1)F_{n} = 0.

If a sequence satisfies one recurrence, then it satisfies an infinite number of other recurrences:

P (N, n)a(n) = 0 ⇒ [Q(N, n)P (N, n)]a(n) = 0

for every operator Q(N, n).

In two variables, (n, k), we introduce the shift operators N, K acting on discrete functions F (n, k), by

NF (n, k) := F (n + 1, k), KF (n, k) := F (n, k + 1).

For example, the Pascal triangle equality

\binom{n + 1}{k + 1} = \binom{n}{k + 1} + \binom{n}{k}

is written, in operator notation, as

(NK − K − 1)\binom{n}{k} = 0.

If a discrete function F (n, k) satisfies two partial linear recurrences

P (N, K, n, k)F (n, k) = 0, Q(N, K, n, k)F (n, k) = 0,

then it satisfies many, many others: {A(N, K, n, k)P (N, K, n, k) + B(N, K, n, k)Q(N, K, n, k)}F (n, k) = 0,

where A and B can be any linear partial recurrence operators.

So far, everything was true for arbitrary linear recurrence operators. From now on we will only allow linear recurrence operators with polynomial coefficients. The set of linear recurrence operators with polynomial coefficients, denoted by C < n, k, N, K > is a (non-commutative) associative algebra generated by N, K, n, k subject to the relations NK = KN, Nk = kN, Kn = nK, nk = kn, Nn = (n + 1)N, Kk = (k + 1)K. By a clever choice of the operators A and B, we can get the operator in the braces above, call it R(N, K, n), to be independent of k.

Now write R(N, K, n) = S(N, n)+(K−1)\overline{R}(N, K, n), where S(N, n) := R(N, 1, n). Since R(N, K, n)F (n, k) ≡ 0, we have

S(N, n)F (n, k) = (K − 1)[−\overline{R}(N, K, n)F (n, k)].

Calling the function inside the square brackets above G(n, k), we get

S(N, n)F (n, k) = (K − 1)G(n, k).

Note that if F (n, ±∞) = 0 for every n, then the same is true of G(n, ±∞). Now summing the above w.r.t. k yields

S(N, n)(∑_{k} F (n, k)) = ∑_{k}(G(n, k + 1) − G(n, k)) = 0.

So a(n) := ∑_{k} F (n, k) satisfies the recurrence S(N, n)a(n) = 0.

Example:

F (n, k) = \frac{n!}{(k! (n − k)!},
\frac{F (n + 1, k)}{F (n, k)} = \frac{n + 1}{n − k + 1},  (i)
\frac{F (n, k + 1)}{F (n, k)} = \frac{n − k}{k + 1} .  (ii)

Cross multiply:

(n − k + 1)F (n + 1, k) − (n + 1)F (n, k) = 0,  (i)
(k + 1)F (n, k + 1) − (n − k)F (n, k) = 0,  (ii)

In operator notation,

(i) [(n − k + 1)N − (n + 1)]F ≡ 0, (ii) [(k + 1)K − (n − k)]F ≡ 0. Expressing the operators in descending powers of k, we get

(i) [(−N)k + (n + 1)N − (n + 1)]F ≡ 0, (ii) [(K + 1)k − n]F ≡ 0. Eliminating k, we get

(K + 1)(i) + N(ii) = {(K + 1)[(n + 1)N − (n + 1)] + N(−n)}F ≡ 0, which becomes

(n + 1)[NK − K − 1]F ≡ 0.

So we got that R(N, K, n) = (n+1)[NK−K−1], S(N, n) = R(N, 1, n) = (n+1)[N −2], and so we have proved the deep result that

a(n) := ∑_{k} \binom{n}{k}

satisfies

(n + 1)(N − 2)a(n) ≡ 0,

i.e., in everyday notation, (n + 1)[a(n + 1) − 2a(n)] ≡ 0, and hence, since a(0) = 1, we get that a(n) = 2^{n}.

Important observation of Gert Almkvist: So far we had two stages:

R(N, K, n) = A(N, K, n, k)P (N, K, n, k) + B(N, K, n, k)Q(N, K, n, k), (i)
R(N, K, n) = S(N, n) + (K − 1)\overline{R}(N, K, n),  (ii)
S(N, n) = AP + BQ + (K − 1)(−\overline{R}),

where \overline{R} has the nice but superfluous property of not involving k! WHAT A WASTE. So we are led to formulate the following.

Modified Elimination Problem:

Input: Linear partial recurrence operators with polynomial coefficients P (N, K, n, k) and Q(N, K, n, k). Find operators A, B, C such that

S(N, n) := AP + BQ + (K − 1)C

does not involve K and k.

Remark. Note something strange: we are allowed to multiply P and Q by any operator from the left , but not from the right, while we are allowed to multiply K − 1 by any operator from the right, but not from the left. In other words we have to find a non-zero operator, depending on n and N only, in the ambidextrous “ideal” generated by P, Q, K − 1, but of course this is not an ideal at all. It would be very nice if one had a Gröbner basis algorithm for doing that. Nobuki Takayama made considerable progress (“An approach to the zero recognition problem by Buchberger’s algorithm”, J. Symbolic Computation 14, 265-282 (1992).

Let a discrete function F (n, k) be annihilated by two operators P and Q, that are “independent” in some technical sense (i.e. the form a holonomic ideal, see [Z1], [Ca]). Performing the elimination process above (and the holonomicity guarantees that we’ll be successful), we get the operators A, B, C and S(N, n). Now let

G(n, k) = C(N, K, n, k)F (n, k),

we have

S(N, n)F (n, k) = (K − 1)G(n, k).

It follows that

a(n) := ∑_{k} F (n, k),

satisfies

S(N, n)a(n) ≡ 0.

Let’s apply the elimination method to find a recurrence operator annihilating a(n), with

F (n, k) := \binom{n}{k}\binom{b}{k} = \frac{n!b!}{k!^{2}(n − k)!(b − k)!},

and thereby prove and discover the Vandermonde-Chu identity. We have

\frac{F (n + 1, k)}{F (n, k)} = \frac{(n + 1)}{(n − k + 1)},

\frac{F (n, k + 1)}{F (n, k)} = \frac{(n − k)(b − k)}{(k + 1)^{2}}.

Cross multiplying,

(n − k + 1)F (n + 1, k) − (n + 1)F (n, k) = 0,  (i)
(k + 1)^{2}F (n, k + 1) − (n − k)(b − k)F (n, k) = 0.  (ii)

In operator notation:

[(n − k + 1)N − (n + 1)]F = 0,
[(k + 1)^{2}K − (nb − bk − nk + k^{2})]F = 0.

So F is annihilated by the two operators P and Q, where

P = (n − k + 1)N − (n + 1) ; Q = (k + 1)^{2}K − (nb − bk − nk + k^{2}).

We would like to find a good operator that annihilates F. By good we mean “independent of k”, modulo (K − 1) (where the multiples of (K − 1) that we are allowed to throw out are right multiples).

Let’s first write P and Q in descending powers of k, modulo (K − 1):

P = (−N)k + (n + 1)N − (n + 1) ; Q = (n + b)k − nb + (K − 1)k^{2} ;

and then eliminate k modulo (K − 1). However, we must be careful to remember that left multiplying a general operator G by (K − 1)JUNK does not yield, in general, (K − 1)JUNK′. In other words,

Warning:

OPERATOR(N, K, n, k)(K − 1)(JUNK) ≠ (K − 1)(JUNK′).

Left multiplying P by n+b+1, left multiplying Q by N and adding yields

(n + b + 1)P + NQa = (n + b + 1)[−Nk + (n + 1)N − (n + 1)]
+ N[(n + b)k − nb + (K − 1)k^{2}]

= (n + 1)[(n + 1)N − (n + b + 1)] + (K − 1)[Nk^{2}].

So, in the above notation,

S(N, n) = (n + 1)[(n + 1)N − (n + b + 1)],  \overline{R} = Nk^{2}.  (*)

It follows that

a(n) := ∑_{k} \binom{n}{k}\binom{b}{k}

satisfies

((n + 1)N − (n + b + 1))a(n) ≡ 0,

or, in everyday notation,

(n + 1)a(n + 1) − (n + b + 1)a(n) ≡ 0,

i.e.,

a(n + 1) = \frac{n + b + 1}{n + 1}a(n) ⇒ a(n) = \frac{(n + b)!}{n!}C,

for some constant independent of n, and plugging in n = 0 yields that 1 = a(0) = b! C and hence C = 1/b!. We have just discovered, and proved at the same time, the Vandermonde-Chu identity.

Note that once we have found the eliminated operator S(N, n) and the corresponding R̄ in (∗) above, we can present the proof without mentioning how we obtained it. In this case \overline{R} = Nk^{2}, so in the above notation

G(n, k) = −\overline{R}F (n, k) = −Nk^{2}F (n, k) = \frac{−(n + 1)!b!}{(k − 1)!^{2}(n − k + 1)!(b − k)!}.

So all we have to present are S(N, n) and G(n, k) above and ask the readers to believe or prove for themselves the purely routine assertion that

S(N, n)F (n, k) = G(n, k + 1) − G(n, k).

Dixon’s Identity by Elimination:

We will now apply the elimination procedure to derive and prove the celebrated Dixon identity of 1903. It states that

∑_{k}(−1)^{k}\binom{n + a}{n + k}\binom{n + b}{b + k}\binom{a + b}{a + k} = \frac{(n + a + b)!}{n! a! b!}.

Equivalently,

∑_{k} \frac{(−1)^{k}}{(n + k)! (n − k)! (b + k)! (b − k)! (a + k)! (a − k)!}

= \frac{(n + a + b)!}{n! a! b! (n + a)! (n + b)! (a + b)!} .

Calling the summand on the left F (n, k), we have

\begin{aligned}\frac{F (n + 1, k)}{F (n, k)} & = \frac{1}{(n + k + 1)(n − k + 1)}, \\ \frac{F (n, k + 1)}{F (n, k)} & = \frac{(−1)(n − k)(b − k)(a − k)}{(n + k + 1)(b + k + 1)(a + k + 1)}. \end{aligned}

It follows that F (n, k) is annihilated by the operators

P = N(n+k)(n−k)−1, Q = K(n+k)(a+k)(b+k)+(n−k)(a−k)(b−k). Rewrite P and Q in descending powers of k, modulo K − 1:

P = −Nk^{2} + (Nn^{2} − 1),

Q = 2(n + a + b)k^{2} + 2nab + (K − 1)((n + k)(a + k)(b + k)).

Now eliminate k^{2}, to get the following operator that annihilates F (n, k):

2(n + a + b + 1)P + NQ

= 2(n + a + b + 1)(Nn^{2} − 1) + N(2nab)

+ (K − 1)(N(n + k)(a + k)(b + k)),

which equals N[2n(n + a)(n + b)] − 2(n + a + b + 1) + (K − 1)(N(n + k)(a + k)(b + k)).

In the above notation we have found that the following operator annihilates a(n) := ∑_{k} F (n, k):

\begin{aligned}S(N, n) & = N[2n(n + a)(n + b)] − 2(n + a + b + 1) \\ & = 2(n + 1)(n + a + 1)(n + b + 1)N − 2(n + a + b + 1). \end{aligned}

Also

\overline{R}(N, K, n, k) = (N(n + k)(a + k)(b + k)),

and

\begin{aligned}G(n, k) & = −\overline{R}F (n, k) \\ & = \frac{(−1)^{k−1}}{(n + k)! (n + 1 − k)! (b + k − 1)! (b − k)! (a + k − 1)! (a − k)!} . \end{aligned}

Once we have found S(N, n) and G(n, k) all we have to do is present them and ask the readers to verify that

S(N, n)F (n, k) = G(n, k + 1) − G(n, k).

Homework :

1. Using the elimination method of this recitation find a recurrence satisfied by

a(n) := ∑_{k=0}^{n} \binom{n − k}{k}.

(No credit for other methods!)

2. Find a recurrence satisfied by

a(n) := ∑_{k} \binom{n}{k}\binom{n + k}{k}.

3(*). Using the method of this recitation, evaluate, if possible, the following sum :

a(n) := ∑_{k} \frac{(a + k − 1)! (b + k − 1)! (c − a − b + n − k − 1)!}{k! (n − k)! (c + k − 1)!}.

If you succeeded you would have rediscovered and reproved the Pfaff-Saalschütz identity.

4.(**) Prove

∑_{k_{1},k_{2}} \frac{(−1)^{k_{1}+k_{2}}(k_{1} + k_{2})!}{k_{1}!^{2}k_{2}!^{2}(n − k_{1})! (m − k_{2})!} = c(n)δ_{n,m}.

5. (100 F) Using elimination prove E3376 (AMM, March 1990):

∑_{i=0}^{n} ∑_{j=0}^{n} \binom{i + j}{j}^{2}\binom{4n − 2i − 2j}{2n − 2j} = (2n + 1)\binom{2n}{n}^{2}.

Note: This was partially solved by Peter Paule, see a forthcoming paper joint with George Andrews [“J. Symbolic Computation” 16, 147-153 (1993)]. Then it was completely solved by Peter Paule [“Solution of a Seminaire Homework Example (28th SLC)”, RISC-Linz Report Series No. 92-52, (1992).]

Recitation II. Gosper’s Algorithm: A Decision Procedure for Indefinite Hypergeometric summation

Here I will describe and motivate Gosper’s algorithm [Proc. Nat. Acad. Sci. USA, 40-42 (1979)]. As will be explained in Recitation 3, Gosper’s algorithm for indefinite summation turned out to be even more important for definite summation .

As we all know, a series ∑_{n} a(n) is called geometric if the ratio of con-

secutive terms are constant:

\frac{a(n)}{a(n − 1)} = CONSTANT.

It is called hypergeometric if

\frac{a(n)}{a(n − 1)} = RATIONAL FUNCTION OF n.

The sequence {a(n)} itself is called a hypergeometric sequence, or, more often CLOSED FORM (or CF for short). It is easy to see that every CF sequence can be expressed as

RATIONAL FUNCTION(n)z^{n} · \frac{∏_{i}(a_{i}n + b_{i})!}{∏_{j}(a′_{j}n + b′_{j})!}.

Given a CF, a(n), Gosper asked, and brilliantly answered, whether S(n) :=

∑_{i=0}^{n} a(i) is also CF, modulo a constant.

This is the discrete analog of Liouville’s problem of “integration in finite form”. Since the discrete is much harder, and composition of discrete functions is badly behaved, we must be content with a much narrower definition of CF. The continuous counterpart of what we call CF would be functions f(x) whose logarithmic derivatives are rational functions, and hence functions of the form

exp(R_{0}(x)) ∏_{i} R_{i}(x)^{λ_{i}}, R_{i} rational,

which is much narrower than Liouville’s definition that allows algebraic functions and compositions.

Going back to Gosper’s problem, it can be phrased as follows.

Input: CF sequence a(n).

Output: CF S(n) such that S(n) − S(n − 1) = a(n) , or the statement “does not exist”.

Of course, S(n) CF implies a(n) CF.

Proof:

\frac{a(n)}{a(n − 1)} = \frac{S(n) − S(n − 1)}{S(n − 1) − S(n − 2)}

= \frac{S(n)/S(n − 1) − 1}{1 − S(n − 2)/S(n − 1)}

= RATIONAL (n).

You can find many “good” a(n) by working backwards. Start with a CF S(n), compute a(n) := S(n) − S(n − 1), and compare the forms of S(n) and a(n).

Example 1: S(n) = n!. Then

a(n) = n! − (n − 1)! = (n − 1)(n − 1)!.

Note that a(n) has two parts: (n−1), the “polynomial part”, which we call p(n), and (n − 1)!, the “pure factorial part”. Gosper’s algorithm depends on such a decomposition. In anticipation of Gosper’s algorithm let us see how a(n)/a(n − 1) looks like:

\frac{a(n)}{a(n − 1)} = \frac{n − 1}{n − 2} · \frac{(n − 1)}{1} = \frac{p(n)}{p(n − 1)} \frac{q(n)}{r(n)}.

The \frac{p(n)}{p(n − 1)} is there because of the polynomial part, and the \frac{q(n)}{r(n)} is due

to the “pure factorial part”. Anyway, with these names for the parts of

\frac{a(n)}{a(n − 1)}, we get that S(n) = n!, in terms of a(n) = (n − 1)(n − 1)!, is

S(n) = \frac{a(n)n}{n − 1} = \frac{a(n)q(n + 1)}{p(n)}.

Example 2: S(n) = (n + 3)n!.

We have, a(n) = S(n) − S(n − 1) = (n + 3)n! − (n + 2)(n − 1)! = [(n + 3)n − (n + 2)](n − 1)! = (n^{2} + 2n − 2)(n − 1)!. Here the “polynomial part”, p(n), is n^{2} + 2n − 2 and the “pure factorial part” is (n − 1)!. Now

\frac{a(n)}{a(n − 1)} = \frac{p(n)}{p(n − 1)} \frac{(n − 1)}{1}.

In anticipation of things to come, and as in the previous example, let us call (n−1) above q(n) and r(n), 1. In other words, if we write a(n) = p(n)\overline{a}(n), where p(n) is the polynomial part and \overline{a}(n) is the pure factorial part, then

\frac{q(n)}{r(n)} := \frac{\overline{a}(n)}{\overline{a}(n − 1)}.

Recall that now we are working backwards, and that we already know the answer S(n) = (n + 3)n!. Let’s see how it is expressible in terms of a(n) and its derived quantities, p(n), q(n), r(n):

S(n) = (n + 3)n! = (n − 1)! (n + 3)n = \overline{a}(n)(n + 3)q(n + 1),

where \overline{a}(n) is the “pure factorial part”, \frac{a(n)}{p(n)}. Thus it was possible to

write S(n) = \overline{a}(n)q(n + 1)f(n), for some polynomial f(n), in this case of degree 1. We will see that this is always possible, and forms the essence of Gosper’s algorithm.

The above examples motivate the following way of “guessing the answer”

S(n) = \frac{a(n)q(n + 1)}{p(n)}f(n),

where p(n) is the “polynomial part” of a(n), obtained in the decomposition a(n) = p(n)\overline{a}(n), of a(n) as a product of polynomial part p(n) and “pure

factorial part” \overline{a}(n), and q(n) is the numerator of \frac{\overline{a}(n)}{\overline{a}(n − 1)}. In other words,

p(n), q(n), r(n) are the polynomials featuring in the writing of \frac{a(n)}{a(n − 1)} as

\frac{a(n)}{a(n − 1)} = \frac{p(n)}{p(n − 1)} \frac{q(n)}{r(n)}

and p(n) is maximal w.r.t. a(n)/a(n − 1) being able to be written thus. It can be seen that q(n) and r(n) satisfy

g.c.d.(q(n), r(n + j)) = 1 for every integer j ≥ 0.

If not, there exists a j ≥ 0 such that

g(n) := g.c.d.(q(n), r(n + j)) ≠ 1.

Let

q′(n) := \frac{q(n)}{g(n)}, r′(n) := \frac{r(n)}{g(n − j)}, p′(n) := p(n)g(n)g(n−1) … g(n−j+1).

Of course,

\frac{a(n)}{a(n − 1)} = \frac{p′(n)}{p′(n − 1)} \frac{q′(n)}{r′(n)}.

The above procedure gives an effective and efficient way to find p(n), q(n), r(n). Start with p(n) := 1 (or rather with the polynomial factor in front of a(n)), and get an initial decomposition

\frac{a(n)}{a(n − 1)} = \frac{p(n)}{p(n − 1)} \frac{q(n)}{r(n)}.

Now check whether there exists a j ≥ 0 such that q(n) and r(n + j) have a common factor. To find whether there exists such a j, let

R(j) := Resultant_{n}(q(n), r(n + j)),

and find the non-negative integer roots of R(j) = 0. In most applications q(n) and r(n) come already factored:

q(n) = ∏_{α}(n − α), r(n) = ∏_{β}(n − β).

In this case it is easier to compute all the differences β −α and see if there is a non-negative integer amongst them.

Sooner or later, we would arrive at a decomposition

\frac{a(n)}{a(n − 1)} = \frac{p(n)}{p(n − 1)} \frac{q(n)}{r(n)},

with g.c.d.(q(n), r(n + j)) = 1 for every integer j ≥ 0. Motivated by the above experimentation, we set (i.e. make a change of dependent variables):

S(n) = \frac{a(n)q(n + 1)}{p(n)}f(n).

In the above, everything is known except f(n). A priori, f(n) is just another CF sequence, but the nice surprise is that:

Claim. The only way that S(n) is CF is for f(n) to be a rational function.

Proof:

f(n) = \frac{p(n)S(n)}{q(n + 1)a(n)}

= \frac{p(n)S(n)}{q(n + 1)(S(n) − S(n − 1))}

= \frac{p(n)}{q(n + 1)(1 − S(n − 1)/S(n))},

and thus must be a rational function, if S(n) is CF.

What does S(n) − S(n − 1) = a(n) say about f(n)?. It is easily seen that the equation for f(n) is

q(n + 1)f(n) − r(n)f(n − 1) = p(n).  (∗)

This is the “FUNCTIONAL EQUATION FOR f(n)”.

Surprise. The only way that f(n) can be a rational function is for it to be a polynomial.

Proof: A starred homework exercise.

Hint: Suppose f(n) = c(n)/d(n), d(n) ≠ 1. Let j be the largest integer such that gcd(d(n), d(n+j) = g(n) ≠ 1, and arrive at a contradiction from the functional equation, the assumption on q(n), r(n) and the maximality of j.

How to solve the functional equation? We need an upper bound for the degree of f(n). Equating degrees, we get

deg f + max(deg q, deg r) = deg p.

So unless there is some fluke, L := deg f = deg p − max(deg q, deg r).

The fluke happens when the two leading coefficients of q(n+1) and r(n) are such that it is possible for a higher degree polynomial f(n) to exist, which will make the leading coefficient of the left side vanish, and hence make it still possible for the degree of f(n) to be higher. This must be checked, and then one has to take a larger L. All this is described in Gosper’s paper. For pedagogical reasons, we won’t worry about it here. However, as pointed out by Petr Lisonek, Peter Paule, and Volker Strehl, this case comes up pretty often, especially in the context of the fast algorithm. See their paper: “Improvements of the degree settings in Gosper’s algorithm”, JSC 16, 243-253 (1993).

Having found an upper bound for the degree L of f(n), we set

f(n) = ∑_{i=0}^{L} f_{i}n^{i},

plug into (∗), compare coefficients and solve the resulting system of linear equations.

Example 1: Find out whether ∑_{n}(n − 1)(n − 1)! has closed form.

Solution: Here a(n) = (n − 1)(n − 1)!. Step 1 is:

\frac{a(n)}{a(n − 1)} = \frac{n − 1}{n − 2} · \frac{n − 1}{1},

so initially, p(n) = n − 1, q(n) = n − 1, and r(n) = 1. Obviously, g.c.d.(q(n), r(n + j)) = 1, for every j ≥ 0, so these values for p(n), q(n), r(n) are the final ones. The functional equation reads

nf(n) − f(n − 1) = n − 1,

L := deg f = 1 − 1 = 0, so f = f_{0}. Plugging this into the functional equation we get

nf_{0} − f_{0} = n − 1.

Equating coefficients of n and n^{0}, we get the two equations

f_{0} = 1, −f_{0} = −1.

The solution is f_{0} = 1, so f(n) = 1, and thus

S(n) = \frac{a(n)q(n + 1)f(n)}{p(n)} = \frac{(n − 1)(n − 1)! · n · 1}{(n − 1)} = n! .

Checking we see that indeed n! − (n − 1)! = (n − 1)(n − 1)!. Example 2: Is the sum S(n) := ∑_{i=0}^{n} i! expressible in closed form?

Solution: Here a(n) = n!, so \frac{a(n)}{a(n − 1)} = n. Here p(n) = 1, q(n) = n, and r(n) = 1. The functional equation is

(n + 1)f(n) − f(n − 1) = 1.

This is impossible since the degree of f should be −1. Homework:

1. Is the sum ∑_{m=0}^{n} \frac{(2m)!}{m! (m + 1)!} expressible in closed form? (Ans.: No.)

2. (Amer. Math. Monthly, Nov. 1989, problem E3352). Prove

∑_{n=0}^{∞} \frac{1}{n! (n^{4} + n^{2} + 1)} = \frac{e}{2}.

3. Can the harmonic numbers H_{n} = ∑_{i=1}^{n} \frac{1}{i} be expressed in closed form? (You are supposed to use Gosper’s algorithm, but it is possible to prove this using asymptotics, as shown by Gilbert Labelle.)

4. We all know that, for any fixed A, ∑_{k=1}^{A} \binom{A}{k} = 2^{A}. Is there a closed form expression in n, for the partial sums of the binomial coefficients

S(n) := ∑_{k=0}^{n} \binom{A}{k}?

5. Find, if possible, ∑_{n=0}^{m} \frac{(4n − 3)(2n − 2)!}{(n − 1)!}.

Recitation III: From Indefinite Hypergeometric Summation To Definite Hypergeometric summation and WZ Pairs

Gosper’s algorithm for indefinite summation is the basis for my algorithm for definite summation, but not in the obvious way! Most definite identities

∑_{k=−∞}^{∞} F (n, k) = NICE(n) have ∑_{k=−∞}^{m} F (n, k) = UGLY(n, m).

If ∑_{k=−∞}^{m} F (n, k) = NICE(n, m), then Gosper’s method can be used to find

NICE(n, m), and ∑_{k=−∞}^{∞} F (n, k) = NICE(n, ∞) = NICE(n). Whenever that

is the case the definite identity is trivial. To take a metaphor from calcu-

lus, ∫_{−∞}^{∞} e^{−x^{2}}dx = \sqrt{π} is deep since the corresponding indefinite integral

∫_{−∞}^{x} e^{−t^{2}} dt is not expressible in closed form, while ∫_{−∞}^{∞} xe^{−x^{2}} dx = \frac{1}{2} is

shallow, since the integrand has an antiderivative that is expressible in closed form.

My fast algorithm starts with a definite sum a(n) := ∑_{k} F (n, k) and

finds a homogeneous linear recurrence equation with polynomial coefficients satisfied by a(n). If the recurrence is first order, then a(n) can be easily expressed explicitly, otherwise we must be content with the recurrence. The algorithm is not guaranteed to find the minimal recurrence, although it usually does. Marko Petkovsek has recently come up with a beautiful algorithm that decides when a linear recurrence has closed form solutions. The combination of my fast algorithm and Petkovsek’s algorithm [Hypergeometric solutions of linear recurrence equations with polynomial coefficients, J. Symbolic Computation 14, 243-264 (1992)] completely solves the problem of deciding when a definite hypergeometric sum can be expressed in closed form.

Let’s first consider the special case of sums a(n) = ∑_{k} F (n, k), for which

a(n) satisfies a first order recurrence, so that one has an “identity”. For that important special case, Herb Wilf made a brilliant observation that at first only seemed to be a minor simplification, and like all great discoveries, seems obvious by hindsight, but it led to the conceptual breakthrough of WZ pairs [WZ1-2], and WZ forms [Z4].

Wilf’s brilliant idea. Instead of trying to prove ∑_{k} F (n, k) = NICE(n)

try to prove ∑_{k} \frac{F (n, k)}{NICE(n)} = 1.

Renaming the summand on the left side of the above F (n, k), we are left with the task of proving, for given Closed Forms F (n, k), identities of

the form ∑_{k} F (n, k) = 1.

Let us call the left side a(n). We have to prove that a(n) ≡ 1. It is always trivial to check, in any given instance, that a(0) = 1. The assertion that a(n) ≡ 1 would then follow by induction if we can show that

a(n + 1) − a(n) ≡ 0, i.e., ∑_{k}(F (n + 1, k) − F (n, k)) = 0.

Big Surprise (Gosper’s Missed Opportunity). Although ∑_{k} F (n, k) is

(usually) not indefinitely summable, in the vast majority of cases,

∑_{k}(F (n + 1, k) − F (n, k))

is!, i.e., there exists a closed form G(n, k) such that

F (n + 1, k) − F (n, k) = G(n, k + 1) − G(n, k). (WZ)

The pair (F, G) is called a WZ pair. To prove ∑_{k} F (n, k) ≡ 1, all we

have to do is present the “certificate” G, and the reader can then check that (F, G) is a WZ pair. The proof then follows upon summing (WZ) with respect to k.

Thanks to Gosper’s algorithm, we can always find the G(n, k) whenever it exists, and we know that its form is

RATIONAL(n, k)[F (n + 1, k) − F (n, k)] = RATIONAL(n, k)[F (n + 1, k)/F (n, k) − 1]F (n, k)

= R(n, k)F (n, k) (say).

Hence it is enough to give the RATIONAL function R(n, k).

Example: ∑_{k} \binom{n}{k} = 2^{n}. Here F (n, k) = \frac{n!}{k! (n − k)! 2^{n}} and

F (n + 1, k) − F (n, k) = \frac{−(n − 2k + 1)n!}{2^{n+1}k! (n − k + 1)!}. Using Gosper’s algorithm, we

find that the antidifference of this w.r.t. k is

nusum(%, k) = \frac{−n!}{2^{n+1}(n − k + 1)!(k − 1)!}.

So

G(n, k) = \frac{−1}{2^{n+1}} \binom{n}{k − 1}.

Bonus. Buy one identity and get one identity free.

Summing (WZ) w.r.t. n, we get

0 = ∑_{n}(F (n + 1, k) − F (n, k)) = ∑_{n}(G(n, k + 1) − G(n, k)),

and hence

∑_{n} G(n, k) = C,

where C is a constant independent of k, which can be easily evaluated by plugging in k = 0. This is called the dual identity.

In practice the above procedure will yield C = ∞, i.e., the sum diverges. However one can get new non-trivial identities in two different ways. The first one is by summing, not from n = −∞ to n = ∞, but rather from n = 0 to n = ∞. When we do that, we get

∑_{n=0}^{∞} G(n, k) = ∑_{j≤k−1}(f_{j} − F (0, j)).

Here f_{j} is defined by f_{j} := lim_{n→∞} F (n, j), which is usually a triviality to compute. I refer the reader to [WZ1], cited at the beginning of these notes, for several interesting examples. In addition, the identities in the very last section of Bailey’s book Generalized Hypergeometric Series, that seemed hitherto mysterious and artificial, all emerge as companion identities of well known ones.

A second way of obtaining a companion identity is by introducing “shadows”. This has the advantage that one still gets standard identities in which the right hand side has closed form.

Shadow. The operation of shadowing is like discrete “analytic continuation”. The expression n! is meaningless for n negative, or if you wish has a singularity there.

But what makes n! what it is? The defining property is that a(n) := n! satisfies the recurrence equation a(n) = na(n − 1), with the initial condition a(0) = 1. If we try to use it to define the value of a(n) at n = −1, by plugging n = 0, we get a(0) = 0a(−1). So there is no function a(n) that is defined for all integers n and that satisfies a(n) = na(n − 1). But what is so great about the positive integers? We can ask that a(n) = na(n − 1)

holds for negative integers! We get \overline{a}(n) = \frac{(−1)^{n}}{(−n − 1)!}.

We call \overline{a}(n) above the shadow of n!. It satisfies the same recurrence as that of n!, but is defined for the set of negative integers rather than positive integers.

More generally, the shadow of a factorial of a linear expression: (an + bk + c)!, with a, b integers and c any indeterminate, is defined by

(an + bk + c)! → \frac{(−1)^{an+bk+c}}{(−an − bk − c − 1)!}.

The shadow of (an + bk + c)! satisfies the same linear recurrence equations with polynomial coefficients as (an+bk +c)! since F (n+1, k)/F (n, k) and F (n, k + 1)/F (n, k) give the same RATIONAL functions respectively for both F (n, k) = (an+bk+c)! and F (n, k) = (−1)^{an+bk+c}/(−an−bk−c−1)!. Thus everything that is true for one, as far as elimination and Gosper’s algorithm are concerned, is also true for the other, and for the purposes of the present theory, they are completely equivalent. The only difference is in their domain of definition, and when they vanish.

Finally if one has F (n, k) equal to a power times a quotient of products of such linear terms, one can apply the shadow treatment to any number of the terms (an + bk + c)! that appear on either the numerator or denominator, getting 2^{# of such terms} possibilities for equivalent F (n, k). So if one has a sum ∑_{k} F (n, k) which diverges for n, one can always find an

equivalent F (n, k) for which the sum converges for a “half discrete line” in n.

In practice, the default shadowing of such a summand F (n, k) would be obtained by shadowing each term (an + bk + c)! for which a + b ≠ 0 and leaving all terms of the form (an − ak + c)! alone.

Recall the WZ pair that arose above, when we proved that the sum of the binomial coefficients n!/(k!(n − k)!) was 2^{n}:

(F, G) := (\frac{1}{2^{n}} \binom{n}{k} , −\frac{1}{2^{n+1}} \binom{n}{k − 1}).

The dual sum ∑_{n} G(n, k) diverges for every k. To make it meaningful,

consider the shadow WS pair:

(\overline{F} , \overline{G}) := (\frac{(−1)^{n+k}}{2^{n}} \binom{−k − 1}{−n − 1} , \frac{(−1)^{n+k}}{2^{n+1}} \binom{−k}{−n − 1}).

Now \overline{G}(n, k) has compact support w.r.t. n for all negative k, and we deduce

∑_{n} \frac{(−1)^{n+k}}{2^{n+1}} \binom{−k}{−n − 1} = C for each negative k.

Making the transformation k ← −k, n ← −n − 1, we get

∑_{n}(−2)^{n}\binom{k}{n} = (−1)^{k}.

So it turned out that the dual of (1 + 1)^{n} = 2^{n} is (1 − 2)^{k} = (−1)^{k}.

Exercise: Find the dual identity to the binomial theorem

∑_{k} \binom{n}{k}x^{k} = (1 + x)^{n}.

Many identities have free parameters. By specializing we get “new” identities, that are trivially implied by the original, more general identities. Now comes an important empirical observation:

Observation. The dual of a specialization is not, in general, a specialization of the dual.

It follows that one can crank out lots of brand new identities, complete with proofs, that a priori are highly non-trivial, by iterating specialization and dualizing.

Example (SPECIALIZE AND DUALIZE)*: The general Vandermonde identity is

∑_{k} \binom{n}{k}\binom{a}{k} = \binom{n + a}{a}.

Its dual identity is just another rendition of same, with changed parameters. But now specialize n = a:

∑_{k} \binom{n}{k}^{2} = \binom{2n}{n}.

The dual of this is (check!)

∑_{k}(3k − 2n)\binom{n}{k}^{2}\binom{2k}{k} = 0.

This is A BRAND NEW IDENTITY, unknown to Askey. It has a q-analog derived from the q-version of WZ, that was unknown to Andrews, and even whose limiting case was brand new, and it took George Andrews three densely packed pages, using five different identities, to prove.

WHAT IS THE SECRET BEHIND THE WZ MIRACLE?

If F (n, k) is Closed Form, it is holonomic. Indeed, we have that

\frac{F (n + 1, k)}{F (n, k)} = \frac{A(n, k)}{B(n, k)}, \frac{F (n, k + 1)}{F (n, k)} = \frac{C(n, k)}{D(n, k)},

for some polynomials A, B, C, D. (Of course they must satisfy the obvious compatibility condition,) so, introducing the operators

P := B(n, k)N − A(n, k), Q := D(n, k)K − C(n, k),

we see that F (n, k) is annihilated by both P and Q. By the first lecture, we know that there exist operators X(N, K, n, k) and Y (N, K, n, k) and Z(N, K, n, k) such that

S(N, n) := X(N, K, n, k)P (N, K, n, k) + Y (N, K, n, k)Q(N, K, n, k) + (K − 1)C(N, K, n, k)

is independent of K and k. Calling G(n, k) := C(N, K, n, k)F (n, k), we get that S(N, n)F (n, k) = (K − 1)G(n, k), or in everyday notation,

S(N, n)F (n, k) = G(n, k + 1) − G(n, k).

Important Observation. If F (n, k) is Closed Form, so is G(n, k).

Proof:

N^{i}K^{j}F (n, k) = F (n + i, k + j) = \frac{F (n + i, k + j)}{F (n, k)} · F (n, k)
= [RATIONAL(n, k)]F (n, k).

Since, for any operator C(N, K, n, k), C(N, K, n, k)F (n, k) is a linear combination, with coefficients that are polynomials in n and k, of terms as above, it follows that

C(N, K, n, k)F (n, k) = RATIONAL(n, k)F (n, k).

Going back to proving identities of the form ∑_{k} F (n, k) = 1, we want

to prove that a(n) := ∑_{k} F (n, k) satisfies the recurrence (N − 1)a(n) = 0.

The elimination algorithm gives a recurrence S(N, n)a(n) ≡ 0, that came from

S(N, n)F (n, k) ≡ G(n, k + 1) − G(n, k),

for some closed form G(n, k) (that is a multiple of F (n, k) by a RATIONAL function). Let the order of S(N, n) be ORDER. To complete the proof that a(n) ≡ 1, all we have is to check that this is true for n = 0, …, ORDER−1, and then check that S(N, n)1 ≡ 0. Equivalently, we have to see whether S(N, n) is a left multiple of N − 1.

The WZ miracle takes place exactly when the elimination algorithm actually gives us S(N, n) = N − 1, and not a left multiple of it. It turns out that in the vast majority of cases we are lucky, and for those cases, it suffices to have the WZ theory, and not the more general theory behind it. However,

(i) Sometimes we are not lucky, and S(N, n) is not first order

(ii) What if we don’t know the answer? In WZ theory, you should know or guess, the answer.

(iii) What if the sum doesn’t evaluate in closed form. The general holonomic machinery promises us that the sum satisfies a linear recurrence equation with polynomial coefficients, that should be possible to find by elimination, using the method of Recitation I. However, elimination is very slow.

The question is:

IS THERE A FAST ALGORITHM FOR FINDING THE RECURRENCE S(N, n) AND THE ACCOMPANYING “CERTIFICATE” G(n, k)?

The answer is: YES.

A simplistic way would be to “guess” empirically the recurrence

S(N, n)a(n) = 0

satisfied by a(n) and then use Gosper’s algorithm, w.r.t. k to find a closed form G(n, k) such that

S(N, n)F (n, k) = G(n, k + 1) − G(n, k).

However, this has two drawbacks. One is practical: we don’t know what the degrees of the coefficients of S(N, n) are going to be, and we have to keep trying bigger and bigger degrees. The other is philosophical: this is empirical guessing. Finally, we are not guaranteed that it is going to work. We do know, for sure that there exists an operator S(N, n) s.t. S(N, n)F (n, k) = G(n, k + 1) − G(n, k), for some closed form G(n, k) that is a multiple of F (n, k) by a RATIONAL function. This implies that S(N, n)a(n) ≡ 0.

But the converse is not true: a(n) may satisfy a lower order recurrence, S_{1}(N, n)a(n) ≡ 0. This recurrence will be found empirically, but Gosper’s algorithm will fail when we try to find nusum(S_{1}(N, n)F (n, k), k). To conclusively and rigorously prove that S_{1}(N, n)a(n) ≡ 0, we (or rather our computers) “divide” S(N, n) by S_{1}(N, n): S(N, n) = T (N, n)S_{1}(N, n), and make sure that there is no remainder. Since the elimination algorithm guarantees that S(N, n)a(n) ≡ 0, we know that T (N, n)[S_{1}(N, n)a(n)] = 0, and hence S_{1}(N, n)a(n) ≡ 0, provided it is true for the first few values of n, which we already know is true, since we found S_{1}(N, n) empirically at the first place.

So what we really want is a FAST algorithm for finding an operator S(N, n) and an accompanying closed form function G(n, k) such that

S(N, n)F (n, k) = G(n, k + 1) − G(n, k).  (∗)

Let’s suppose that we already know S(N, n) by other means, but still have to find G(n, k). Then, it can be found using Gosper’s algorithm! This follows from the fact that S(N, n)F (n, k) is closed form itself, as shown above, and hence Gosper’s algorithm with respect to k would produce the closed form anti-difference G(n, k) whenever it exists, (and it does exist thanks to the assumption.)

The problem is that we don’t know S(N, n) beforehand. We have to find both S(N, n) and G(n, k) at the same time, from scratch, starting from the input F (n, k). The pleasant surprise is:

GOSPER’S ALGORITHM CAN BE EXTENDED TO MANUFACTURE BOTH G(n, k) AND S(N, n) AT THE SAME TIME!

What we do is a little like Lagrange multipliers. We first “guess” the order I of the recurrence, and write S(N, n) in generic form

S(N, n) := ∑_{i=0}^{I} s_{i}(n)N^{i},

where the coefficients s_{i}(n), which are polynomials in n, have to be determined. In practice there is no “guessing” at all, since we start with I = 0 and do-loop our way up until we are successful. The general holonomic theory and elimination procedure of recitation 1 guarantees us success eventually. Furthermore, it’s possible to give a priori upper bound for I.

We now work with the generic s_{i}(n) as though we knew what they were, and form

\begin{aligned}H(n, k) := S(N, n)F (n, k) & = ∑_{i=0}^{I} s_{i}(n)F (n + i, k) \\ & = [∑_{i=0}^{I} s_{i}(n)\frac{F (n + i, k)}{F (n, k)}]F (n, k). \end{aligned}

The quantity in square brackets is a certain RATIONAL function, whose numerator is a LINEAR EXPRESSION IN THE s_{0}(n), …, s_{I}(n).

Note that when we do Gosper w.r.t. k, n is a mere auxiliary parameter and all the calculations are done in the field of RATIONAL functions in n. So, let’s do Gosper w.r.t. k and let’s take a look at the functional equation for the polynomial f(k) that determines the closed form anti-difference of H(n, k) above:

p(k) = q(k + 1)f(k) − r(k)f(k − 1).

Recall that we find f(k) by expressing it in generic form f(k) = f_{0} + f_{1}k + ⋯ + f_{L}k^{L}, plugging in the functional equation and comparing coefficients of respective powers of k. This gives a system of linear equations in f_{0}, f_{1}, …, f_{L}, where the right sides involve certain expressions in the s_{i}(n). In fact we are asking for s_{i}(n) that will make the equations solvable. The miracle is that the s_{i}(n) occur linearly. So what we have, in fact, is a linear system of equations with unknowns f_{0}, …, f_{L} and s_{0}, …, s_{I}. If the system is not solvable, then it means that there does not exist any recurrence S(N, n), of order I, such that (*) is true, and we must try again, replacing I by I +1. The general proof above guarantees that we are going to be successful eventually.

Example: Let’s find a recurrence for a(n) := ∑_{k} \frac{1}{k!(n − k)!}.

Here F (n, k) = 1/(k!(n − k)!). We first try I = 0 and fail (this means that the corresponding indefinite sum does not exist in closed form), we then try I = 1 and set S(N, n) = s_{0}(n) + s_{1}(n)N. Now

H(n, k) = S(N, n)F (n, k) = s_{0}(n)F (n, k) + s_{1}(n)F (n + 1, k)

= \frac{s_{0}(n)}{k!(n − k)!} + \frac{s_{1}(n)}{k!(n + 1 − k)!}

= \frac{s_{0}(n)(n + 1 − k) + s_{1}(n)}{k!(n + 1 − k)!}.

We now do Gosper’s algorithm, as described in recitation II, “pretending” that we know what s_{0}(n) and s_{1}(n) are. Using the notation of the last recitation (which coincides with Gosper’s notation), we have initially

\begin{aligned}p(k) & = (n + 1 − k)s_{0}(n) + s_{1}(n), \\ \frac{q(k)}{r(k)} & = \frac{((k − 1)!(n − k + 2)!}{k!(n + 1 − k)!} = \frac{(n + 2 − k)}{k}, \end{aligned}

so initially q(k) = n + 2 − k and r(k) = k. Now we must make sure that

g.c.d.(q(k), r(k + j)) = 1 for every integer j ≥ 0.

Since n + 2 − k and k + j never have a common factor, this is certainly true, so the final p(k), q(k), and r(k) are given by

p(k) = (n + 1 − k)s_{0}(n) + s_{1}(n), q(k) = n + 2 − k, r(k) = k.

Substituting this into Gosper’s functional equation:

q(k + 1)f(k) − r(k)f(k − 1) = p(k),

we get, in this case, (n − k + 1)f(k) − kf(k − 1) = (n + 1 − k)s_{0}(n) + s_{1}(n).

The degree, in k, of the right side, is 1, while the degree of the left side is 1 + deg_{k} f. So deg_{k} f = 1 − 1 = 0. We thus set f(k) := f_{0} above, and get

(n − k + 1)f_{0} − kf_{0} = (n + 1 − k)s_{0}(n) + s_{1}(n).

Comparing coefficients of k^{1} and k^{0} respectively yields 2 homogeneous linear equations for the three unknowns f_{0}, s_{0} and s_{1}:

(n + 1)f_{0} = (n + 1)s_{0}(n) + s_{1}(n),  (i)
−2f_{0} = −s_{0}(n).  (ii)

Normalizing f_{0} = f = 1, we get the solution: s_{0} = 2, s_{1} = −(n + 1), and hence

f(k) = 1, S(N, n) = s_{0} + s_{1}N = 2 − (n + 1)N.

Implementing f(k), we get that G(n, k) of (*) is given by

\begin{aligned}G(n, k) & = \frac{H(n, k)}{p(k)}q(k + 1)f(k) \\ & = \frac{1}{k!(n − k + 1)!} · (n − k + 1) · 1 = \frac{1}{k!(n − k)!}. \end{aligned}

We have just found the recurrence satisfied by a(n) := ∑_{k} \frac{1}{k!(n − k)!}.

It is (2−(n+1)N)a(n) = 0, i.e. 2a(n)−(n+1)a(n+1) = 0, so a(n+1) = (2/(n + 1))a(n) which implies the closed form answer a(n) = 2^{n}/n!. The proof consists in presenting the “proof certificate” G(n, k) = 1/(k!(n−k)!), and urging the readers to verify, or believe that

2F (n, k) − (n + 1)F (n + 1, k) = G(n, k) − G(n, k − 1.

The proof then follows by summing w.r.t. k.

Homework: Using the algorithm of this recitation, find recurrences for the following binomial coefficients sums:

∑_{k}^{n} \binom{n − k}{k},  (1)

∑_{k} \binom{n}{k}^{2},  (2)

∑_{k} \binom{n}{k}\binom{n + k}{k}.  (3)

Postscript

Everything here has been q-ified. There is a q-analog of Gosper’s algorithm, and of its extension described above, that would have appeared in my paper “The method of creative telescoping for q-series”, that became unnecessary because of Tom Koornwinder’s brilliant paper [K]. There is also a continuous analog that appeared in my paper with Almkvist [AZ] cited at the beginning of these notes.

The next step would be to find a FAST algorithm for multisums. It follows from the general holonomic theory that whenever F (n, k_{1}, …, k_{r}) is closed form, there exists an operator S(N, n), and closed form

G_{1}(n, k_{1}, …, k_{r}), …, G_{r}(n, k_{1}, …, k_{r}),

such that S(N, n)F (n, k_{1}, …, k_{r}) = [G_{1}(n, k_{1}, …, k_{r}) − G_{1}(n, k_{1} − 1, …, k_{r})]

+ ⋯ + [G_{r}(n, k_{1}, …, k_{r}) − G_{1}(n, k_{1}, …, k_{r} − 1)].

From this follows, upon summing, w.r.t. k_{1}, …, k_{r}, that

a(n) := ∑_{k_{1},...,k_{r}} F (n, k_{1}, …, k_{r}),

satisfies that recurrence

S(N, n)a(n) ≡ 0.

However, using elimination is prohibitive. To find a FAST algorithm for multi-sum definite summation, we must first find a multi-sum generalization of Gosper’s algorithm. This algorithm would input a closed form F (k_{1}, …, k_{r}) and decide whether there exist closed form G_{i}(k_{1}, …, k_{r}), (i = 1, …, r) and find them in the affirmative case, such that:

F = ∑_{i=1}^{r} Δ_{i}G_{i}.

Epilogue written Feb. 1995 (for this version)

The above was done in the following papers:

[WZ3] H.S. Wilf and D. Zeilberger, An algorithmic proof theory for hypergeometric (ordinary and “q”) multisum/integral identities, Invent. Math. 108, 575-633 (1992).

[WZ4] H.S. Wilf and D. Zeilberger, RATIONAL function certification of hypergeometric multi-integral/sum/”q” identities, Bulletin of the Amer. Math. Soc. 27 148-153 (1992).

[Z4] Closed Form (pun intended!), in: ”Special volume in memory of Emil Grosswald”, M. Knopp and M. Sheingorn, Contemporary Mathematics 143 579-607, AMS, Providence (1993).

Peter Paule found a great way to simplify the computer-generated proofs for single-q-sums, see:

[Pau] P. Paule, Simple Computer Proofs for Rogers-Ramanujan type Identities, Elec. J. of Combinatorics 1 (1994), R10.

He and his students are currently developing farther ramifications as well specialization and dualizations.

Ira Gessel, has made a systematic study of specialization and dualization.

My former student Sheldon Parnes has extended the algoritm for ‘algebraic kernels’, like in the generating function for the Jacobi polynomials. See:

[EP] S.B. Ekhad and S. Parnes, A WZ-style proof of Jacobi polynomials’ generating function, Discrete Mathematics 110, 263-264 (1992).

[Par] S. Parnes, A differential view of hypergeometric functions: algorithms and implementation, Ph.D. thesis, Temple University, 1993. [Available from University Microfilms, Ann Arbor, MI.]

My student John Majewicz has extended Sister Celine’s technique and WZ-certification to Abel-type sums. See:

[EM] S.B. Ekhad and J.E. Majewicz, A short WZ-style proof of Abel’s identity, preprint, available by anon. ftp to ftp.math.temple.edu in file

/pub/ekhad/abel.tex.

[Ma] J.E. Majewicz, WZ-style certification procedures and Sister’s Celine’s technique for Abel-type sums, preprint, available by anon. ftp to

ftp.math.temple.edu in file /pub/jmaj/abel sum.tex.

Lily Yen, in a brilliant Penn thesis, under the direction of Herb Wilf, has found effective a priori bounds for the number of special cases one should check a given identity in order to (rigorously!) know that it is true in general, in:

[Y] L. Yen, Contributions to the proof theory of hypergeometric identities, Ph.D. thesis, University of Pennsylvania, 1993. [Available from University Microfilms, Ann Arbor, MI.]

A beautiful exposition, as well as an AXIOM implementation, was written by Joachim Hornegger, in his Erlangen Diplomarbeit under the direction of Volker Strehl:

[Ho] J. Hornegger, Hypergeometrische Summation und polynomiale Rekursion, Diplomarbeit, Erlangen, 1992.