LREtools/HypergeometricTerm/HypergeometricSolution - Maple Help

Home : Support : Online Help : LREtools/HypergeometricTerm/HypergeometricSolution

LREtools[HypergeometricTerm]

 HypergeometricSolution
 return the hypergeometric solution of linear difference equation depending on a hypergeometric term

 Calling Sequence HypergeometricSolution(eq, var) HypergeometricSolution(eq, var, term, cert)

Parameters

 eq - linear difference equation depending on a hypergeometric term var - function variable for which to solve, for example, z(n) term - hypergeometric term cert - certificate of the right hand side

Description

 • The HypergeometricSolution(eq, var, term, cert) command returns the hypergeometric solution of the linear difference equation eq. If such a solution does not exist, the function returns NULL.
 • The hypergeometric term in the linear difference equation is specified by a name, for example, t. The meaning of the term is defined by the parameter term. It can be specified directly in the form of an equation, for example, $t=n!$, or specified as a list consisting of the name of term variable and the consecutive term ratio, for example, $\left[t,n+1\right]$.
 • If the third parameter is omitted, then the input equation can contain a hypergeometric term directly (not a name). In this case, the procedure extracts the term from the equation, transforms the equation to the form with a name representing a hypergeometric term, and then solves the transformed equation.
 • In the current state, the procedure handles only equations with hypergeometric right hand sides. Here the term "hypergeometric" means that for the right hand side $R\left(x,t\left(x\right)\right)$ the ratio $\frac{R\left(x+1,t\left(x+1\right)\right)}{R\left(x\right)}$ is a rational function in $x$ and $t$ (such a ratio is referred to as "certificate"). For the two argument case the procedure computes and checks the certificate. For the four argument case the certificate should be given directly in cert parameter and equation eq should be homogeneous.
 • The search for a hypergeometric solution is reduced to searching a rational solution by change of the function variable $y\left(x\right)=z\left(x\right)R\left(x,t\left(x\right)\right)$, where $R\left(x,t\left(x\right)\right)$ is the right hand side and $z\left(x\right)$ is a new function variable that should be rational.
 • The solution is the function, corresponding to var. The solution may involve arbitrary constants of the form, for example, _c1 and _c2.

Examples

 > $\mathrm{with}\left(\mathrm{LREtools}\left[\mathrm{HypergeometricTerm}\right]\right):$
 > $\mathrm{eq}≔y\left(x+1\right)-y\left(x\right)-{\left({2}^{x+1}\right)}^{x+1}{x}^{2}-5{\left({2}^{x+1}\right)}^{x+1}x-27{\left({2}^{x+1}\right)}^{x+1}+{x}^{2}{\left({2}^{x}\right)}^{x}+3{\left({2}^{x}\right)}^{x}x+23{\left({2}^{x}\right)}^{x}$
 ${\mathrm{eq}}{≔}{y}{}\left({x}{+}{1}\right){-}{y}{}\left({x}\right){-}{\left({{2}}^{{x}{+}{1}}\right)}^{{x}{+}{1}}{}{{x}}^{{2}}{-}{5}{}{\left({{2}}^{{x}{+}{1}}\right)}^{{x}{+}{1}}{}{x}{-}{27}{}{\left({{2}}^{{x}{+}{1}}\right)}^{{x}{+}{1}}{+}{{x}}^{{2}}{}{\left({{2}}^{{x}}\right)}^{{x}}{+}{3}{}{\left({{2}}^{{x}}\right)}^{{x}}{}{x}{+}{23}{}{\left({{2}}^{{x}}\right)}^{{x}}$ (1)
 > $\mathrm{sol}≔\mathrm{HypergeometricSolution}\left(\mathrm{eq},y\left(x\right)\right)$
 ${\mathrm{sol}}{≔}\frac{\left({{x}}^{{2}}{+}{3}{}{x}{+}{23}\right){}\left({\left({{2}}^{{x}{+}{1}}\right)}^{{x}{+}{1}}{}{{x}}^{{2}}{+}{5}{}{\left({{2}}^{{x}{+}{1}}\right)}^{{x}{+}{1}}{}{x}{+}{27}{}{\left({{2}}^{{x}{+}{1}}\right)}^{{x}{+}{1}}{-}{{x}}^{{2}}{}{\left({{2}}^{{x}}\right)}^{{x}}{-}{3}{}{\left({{2}}^{{x}}\right)}^{{x}}{}{x}{-}{23}{}{\left({{2}}^{{x}}\right)}^{{x}}\right)}{{2}{}{t}{}{{x}}^{{2}}{+}{10}{}{t}{}{x}{-}{{x}}^{{2}}{+}{54}{}{t}{-}{3}{}{x}{-}{23}}{,}\left[{t}{,}{4}\right]$ (2)
 > $\mathrm{IsSolution}\left(\mathrm{sol},\mathrm{eq},y\left(x\right)\right)$
 ${\mathrm{true}}$ (3)
 > $\mathrm{simplify}\left(\mathrm{SubstituteTerm}\left(\mathrm{sol},x\right)\right)$
 ${\left({{2}}^{{x}}\right)}^{{x}}{}\left({{x}}^{{2}}{+}{3}{}{x}{+}{23}\right)$ (4)
 > $\mathrm{eq}≔{2}^{x}y\left(x+1\right)-\frac{y\left(x\right)}{{2}^{x}}-{2}^{x}{\left(x+1\right)}^{2}{\left({2}^{x+1}\right)}^{x+1}+\frac{{x}^{2}{\left({2}^{x}\right)}^{x}}{{2}^{x}}$
 ${\mathrm{eq}}{≔}{{2}}^{{x}}{}{y}{}\left({x}{+}{1}\right){-}\frac{{y}{}\left({x}\right)}{{{2}}^{{x}}}{-}{{2}}^{{x}}{}{\left({x}{+}{1}\right)}^{{2}}{}{\left({{2}}^{{x}{+}{1}}\right)}^{{x}{+}{1}}{+}\frac{{{x}}^{{2}}{}{\left({{2}}^{{x}}\right)}^{{x}}}{{{2}}^{{x}}}$ (5)
 > $\mathrm{sol}≔\mathrm{HypergeometricSolution}\left(\mathrm{eq},y\left(x\right)\right)$
 ${\mathrm{sol}}{≔}\frac{{{x}}^{{2}}{}\left({\left({{2}}^{{x}{+}{1}}\right)}^{{x}{+}{1}}{}{\left({{2}}^{{x}}\right)}^{{2}}{}{{x}}^{{2}}{+}{2}{}{\left({{2}}^{{x}{+}{1}}\right)}^{{x}{+}{1}}{}{\left({{2}}^{{x}}\right)}^{{2}}{}{x}{+}{\left({{2}}^{{x}}\right)}^{{2}}{}{\left({{2}}^{{x}{+}{1}}\right)}^{{x}{+}{1}}{-}{{x}}^{{2}}{}{\left({{2}}^{{x}}\right)}^{{x}}\right)}{{2}{}{{t}}^{{2}}{}{{x}}^{{2}}{+}{4}{}{{t}}^{{2}}{}{x}{+}{2}{}{{t}}^{{2}}{-}{{x}}^{{2}}}{,}\left[{t}{,}{4}\right]$ (6)
 > $\mathrm{IsSolution}\left(\mathrm{sol},\mathrm{eq},y\left(x\right)\right)$
 ${\mathrm{true}}$ (7)
 > $\mathrm{simplify}\left(\mathrm{SubstituteTerm}\left(\mathrm{sol},x\right)\right)$
 ${{x}}^{{2}}{}{\left({{2}}^{{x}}\right)}^{{x}}$ (8)
 > $\mathrm{eq0}≔ty\left(x+1\right)-\frac{y\left(x\right)}{t}$
 ${\mathrm{eq0}}{≔}{t}{}{y}{}\left({x}{+}{1}\right){-}\frac{{y}{}\left({x}\right)}{{t}}$ (9)
 > $\mathrm{cert}≔\frac{{t}^{2}\left(32{t}^{4}{x}^{2}+128{t}^{4}x+128{t}^{4}-{x}^{2}-2x-1\right)}{-{x}^{2}+2{t}^{4}{x}^{2}+4{t}^{4}x+2{t}^{4}}$
 ${\mathrm{cert}}{≔}\frac{{{t}}^{{2}}{}\left({32}{}{{t}}^{{4}}{}{{x}}^{{2}}{+}{128}{}{{t}}^{{4}}{}{x}{+}{128}{}{{t}}^{{4}}{-}{{x}}^{{2}}{-}{2}{}{x}{-}{1}\right)}{{2}{}{{t}}^{{4}}{}{{x}}^{{2}}{+}{4}{}{{t}}^{{4}}{}{x}{+}{2}{}{{t}}^{{4}}{-}{{x}}^{{2}}}$ (10)
 > $\mathrm{sol}≔\mathrm{HypergeometricSolution}\left(\mathrm{eq0},y\left(x\right),\left[t,2\right],\mathrm{cert}\right)$
 ${\mathrm{sol}}{≔}\left[\frac{{{x}}^{{2}}}{{2}{}{{t}}^{{4}}{}{{x}}^{{2}}{+}{4}{}{{t}}^{{4}}{}{x}{+}{2}{}{{t}}^{{4}}{-}{{x}}^{{2}}}{,}\frac{{2}{}{{t}}^{{2}}{}\left({32}{}{{t}}^{{4}}{}{{x}}^{{2}}{+}{128}{}{{t}}^{{4}}{}{x}{+}{128}{}{{t}}^{{4}}{-}{{x}}^{{2}}{-}{2}{}{x}{-}{1}\right)}{{2}{}{{t}}^{{4}}{}{{x}}^{{2}}{+}{4}{}{{t}}^{{4}}{}{x}{+}{2}{}{{t}}^{{4}}{-}{{x}}^{{2}}}\right]{,}\left[{t}{,}{2}\right]$ (11)
 > $\mathrm{eq}≔\mathrm{eq0}-\left(\mathrm{Product}\left(\mathrm{subs}\left(x=n,t={2}^{n},\mathrm{cert}\right),n=0..x-1\right)\right)$
 ${\mathrm{eq}}{≔}{t}{}{y}{}\left({x}{+}{1}\right){-}\frac{{y}{}\left({x}\right)}{{t}}{-}\left({\prod }_{{n}{=}{0}}^{{x}{-}{1}}{}\frac{{\left({{2}}^{{n}}\right)}^{{2}}{}\left({32}{}{{n}}^{{2}}{}{\left({{2}}^{{n}}\right)}^{{4}}{+}{128}{}{n}{}{\left({{2}}^{{n}}\right)}^{{4}}{+}{128}{}{\left({{2}}^{{n}}\right)}^{{4}}{-}{{n}}^{{2}}{-}{2}{}{n}{-}{1}\right)}{{2}{}{{n}}^{{2}}{}{\left({{2}}^{{n}}\right)}^{{4}}{+}{4}{}{n}{}{\left({{2}}^{{n}}\right)}^{{4}}{+}{2}{}{\left({{2}}^{{n}}\right)}^{{4}}{-}{{n}}^{{2}}}\right)$ (12)
 > $s≔\mathrm{sol}\left[1\right]\left[1\right]\left(\mathrm{Product}\left(\mathrm{subs}\left(x=n,t={2}^{n},\mathrm{sol}\left[1\right]\left[2\right]\right),n=0..x-1\right)\right)$
 ${s}{≔}\frac{{{x}}^{{2}}{}\left({\prod }_{{n}{=}{0}}^{{x}{-}{1}}{}\frac{{2}{}{\left({{2}}^{{n}}\right)}^{{2}}{}\left({32}{}{{n}}^{{2}}{}{\left({{2}}^{{n}}\right)}^{{4}}{+}{128}{}{n}{}{\left({{2}}^{{n}}\right)}^{{4}}{+}{128}{}{\left({{2}}^{{n}}\right)}^{{4}}{-}{{n}}^{{2}}{-}{2}{}{n}{-}{1}\right)}{{2}{}{{n}}^{{2}}{}{\left({{2}}^{{n}}\right)}^{{4}}{+}{4}{}{n}{}{\left({{2}}^{{n}}\right)}^{{4}}{+}{2}{}{\left({{2}}^{{n}}\right)}^{{4}}{-}{{n}}^{{2}}}\right)}{{2}{}{{t}}^{{4}}{}{{x}}^{{2}}{+}{4}{}{{t}}^{{4}}{}{x}{+}{2}{}{{t}}^{{4}}{-}{{x}}^{{2}}}$ (13)
 > $\mathrm{IsSolution}\left(s,\left[t,2\right],\mathrm{eq},y\left(x\right)\right)$
 ${\mathrm{true}}$ (14)