61.30.1 problem 149

Internal problem ID [12570]
Book : Handbook of exact solutions for ordinary differential equations. By Polyanin and Zaitsev. Second edition
Section : Chapter 2, Second-Order Differential Equations. section 2.1.2-5
Problem number : 149
Date solved : Monday, March 31, 2025 at 05:39:33 AM
CAS classification : [_Gegenbauer]

\begin{align*} \left (-x^{2}+1\right ) y^{\prime \prime }+n \left (n -1\right ) y&=0 \end{align*}

Maple. Time used: 0.024 (sec). Leaf size: 52
ode:=(-x^2+1)*diff(diff(y(x),x),x)+n*(n-1)*y(x) = 0; 
dsolve(ode,y(x), singsol=all);
 
\[ y = -\left (x -1\right ) \left (x +1\right ) \left (\operatorname {hypergeom}\left (\left [1+\frac {n}{2}, \frac {3}{2}-\frac {n}{2}\right ], \left [\frac {3}{2}\right ], x^{2}\right ) c_2 x +c_1 \operatorname {hypergeom}\left (\left [1-\frac {n}{2}, \frac {1}{2}+\frac {n}{2}\right ], \left [\frac {1}{2}\right ], x^{2}\right )\right ) \]
Mathematica. Time used: 0.108 (sec). Leaf size: 56
ode=(1-x^2)*D[y[x],{x,2}]+n*(n-1)*y[x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to i c_2 x \operatorname {Hypergeometric2F1}\left (\frac {1}{2}-\frac {n}{2},\frac {n}{2},\frac {3}{2},x^2\right )+c_1 \operatorname {Hypergeometric2F1}\left (\frac {n-1}{2},-\frac {n}{2},\frac {1}{2},x^2\right ) \]
Sympy. Time used: 0.320 (sec). Leaf size: 94
from sympy import * 
x = symbols("x") 
n = symbols("n") 
y = Function("y") 
ode = Eq(n*(n - 1)*y(x) + (1 - x**2)*Derivative(y(x), (x, 2)),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = \frac {\left (C_{1} \sqrt {x^{2}} {{}_{2}F_{1}\left (\begin {matrix} \frac {1}{4} - \frac {\sqrt {\left (2 n - 1\right )^{2}}}{4}, \frac {\sqrt {\left (2 n - 1\right )^{2}}}{4} + \frac {1}{4} \\ \frac {3}{2} \end {matrix}\middle | {x^{2}} \right )} + C_{2} {{}_{2}F_{1}\left (\begin {matrix} - \frac {\sqrt {\left (2 n - 1\right )^{2}}}{4} - \frac {1}{4}, \frac {\sqrt {\left (2 n - 1\right )^{2}}}{4} - \frac {1}{4} \\ \frac {1}{2} \end {matrix}\middle | {x^{2}} \right )}\right ) \sqrt [4]{x^{2}}}{\sqrt {x}} \]