rec*rec - Maple Help

gfun

 rec+rec
 termwise sum of two holonomic recurrences
 rec*rec
 termwise product of two holonomic recurrences
 cauchyproduct
 Cauchy product of two holonomic recurrences

 Calling Sequence rec+rec(rec1, rec2, u(n)) rec*rec(rec1, rec2, u(n)) cauchyproduct(rec1, rec2, u(n))

Parameters

 rec1, rec2 - linear recurrences with polynomial coefficients u - name; recurrence name n - name; index of the recurrence u

Description

 • The gfun[rec+rec](rec1, rec2, u(n)) command returns a termwise sum of two holonomic recurrences, rec1 and rec2.
 If $a\left(n\right)$ and $b\left(n\right)$ are the sequences defined by rec1 and rec2 respectively, the gfun[rec+rec] function returns a recurrence for $a\left(n\right)+b\left(n\right)$.
 • The gfun[rec*rec](rec1, rec2, u(n)) command returns a termwise product of two holonomic recurrences, rec1 and rec2.
 If $a\left(n\right)$ and $b\left(n\right)$ are the sequences defined by rec1 and rec2 respectively, the gfun[rec*rec] function returns a recurrence for $a\left(n\right)b\left(n\right)$.
 • The gfun[cauchyproduct](rec1, rec2, u(n)) command returns the Cauchy product of the two holonomic recurrences, rec1 and rec2.
 If $a\left(n\right)$ and $b\left(n\right)$ are the sequences defined by rec1 and rec2 respectively, the gfun[cauchyproduct] function returns a recurrence for their Cauchy product or convolution $c\left(n\right)=\sum _{i=0}^{n}a\left(i\right)b\left(n-i\right)$.

Examples

 > $\mathrm{with}\left(\mathrm{gfun}\right):$
 > $\mathrm{rec1}≔u\left(n+1\right)=\left(n+1\right)u\left(n\right):$
 > $\mathrm{rec2}≔u\left(n+1\right)=2u\left(n\right):$
 > $\mathrm{rec+rec}\left(\mathrm{rec1},\mathrm{rec2},u\left(n\right)\right)$
 $\left\{\left({2}{}{{n}}^{{2}}{+}{2}{}{n}\right){}{u}{}\left({n}\right){+}\left({-}{{n}}^{{2}}{-}{3}{}{n}{+}{2}\right){}{u}{}\left({n}{+}{1}\right){+}\left({n}{-}{1}\right){}{u}{}\left({n}{+}{2}\right){,}{u}{}\left({0}\right){=}{{\mathrm{_t}}}_{{2}}{+}{{\mathrm{_C}}}_{{0}}{,}{u}{}\left({1}\right){=}{{\mathrm{_t}}}_{{2}}{+}{2}{}{{\mathrm{_C}}}_{{0}}{,}{u}{}\left({2}\right){=}{2}{}{{\mathrm{_t}}}_{{2}}{+}{4}{}{{\mathrm{_C}}}_{{0}}{,}{u}{}\left({3}\right){=}{6}{}{{\mathrm{_t}}}_{{2}}{+}{8}{}{{\mathrm{_C}}}_{{0}}\right\}$ (1)
 > $\mathrm{rec*rec}\left(\mathrm{rec1},\mathrm{rec2},u\left(n\right)\right)$
 $\left({-}{2}{}{n}{-}{2}\right){}{u}{}\left({n}\right){+}{u}{}\left({n}{+}{1}\right)$ (2)
 > $\mathrm{cauchyproduct}\left(\mathrm{rec1},\mathrm{rec2},u\left(n\right)\right)$
 $\left\{\left({2}{}{n}{+}{4}\right){}{u}{}\left({n}\right){+}\left({-}{4}{-}{n}\right){}{u}{}\left({n}{+}{1}\right){+}{u}{}\left({n}{+}{2}\right){,}{u}{}\left({0}\right){=}{{\mathrm{_C}}}_{{0}}{,}{u}{}\left({1}\right){=}{3}{}{{\mathrm{_C}}}_{{0}}\right\}$ (3)