gfun[invborel] - convert an exponential into ordinary recurrence
Calling Sequence
invborel(expr, a(n), t, <homogeneous=bool>, <operator=name>)
Parameters
expr - linear recurrence with polynomial coefficients
a,n - name and index of the recurrence
t - (optional) 'diffeq'
homogeneous - (optional) boolean requesting homogeneous output; the default is false
operator - (optional) name used verbatim as the output operator; the default is equation
Description
- If
(a(n),n=0..infinity)is the sequence of numbers defined by the recurrenceexpr, the procedure computes the recurrence for the numbersn!*a(n). - If the optional fourth argument 'diffeq' is given,
expris taken as a linear differential equation with polynomial coefficients, and the procedure outputs a linear differential equation satisfied by its inverse Borel transform.
Laplace is used as a synonym of invborel.
- With
operator=name, output initial conditions are not computed. Homogeneous output is a polynomial in the supplied name and inhomogeneous output has the formL(name)=-q.
Examples
> with(gfun):
rec:={a(n)=n*a(n-1)+a(n-2),a(0)=0,a(1)=1}:
deq:=invborel(rec,a(n));
\[\{\left(-n^{2}-3 n -2\right) a \! \left(n \right)+\left(-n^{2}-4 n -4\right) a \! \left(n +1\right)+a \! \left(n +2\right), a \! \left(0\right) = 0, a \! \left(1\right) = 1\}\]
> rec2:=rectodiffeq(deq,a(n),f(t));
\[\left(-2 t^{2}-t +1\right) f \! \left(t \right)+\left(-4 t^{3}-3 t^{2}\right) \left(\frac{d}{d t}f \! \left(t \right)\right)+\left(-t^{4}-t^{3}\right) \left(\frac{d^{2}}{d t^{2}}f \! \left(t \right)\right)-t\]
> deq2:=borel(rec2,f(t),'diffeq');
\[\left(-t^{2}-t +1\right) f \! \left(t \right)-\left(\frac{d}{d t}f \! \left(t \right)\right) t^{2}-t\]
> diffeqtorec(deq2,f(t),a(n));
\[\{-a \! \left(n \right)+\left(-n -2\right) a \! \left(n +1\right)+a \! \left(n +2\right), a \! \left(0\right) = 0, a \! \left(1\right) = 1\}\]