A second-order non-constant coefficient differential equation I encountered the following second-order differential equation in my research:
$$x^2(1-x)^2y''+Ax(1-x)y'+By=0$$
where $y$ is a function of $x$ we are looking for, and $A$ and $B$ are constants. It looks kind of regular, but many ways failed at some subtle points. Can someone give me any suggestion on solving this equation? Thanks a lot!
 A: For the differential equation
\begin{align}
x^2(1-x)^2y''+Ax(1-x)y'+By=0
\end{align}
make the substitution $y(x) = x^{\mu} (1-x)^{\nu} g(x)$ to obtain the equation
\begin{align}
x(1-x) g'' + (A + 2 \mu - (2 \mu + 2 \nu) x ) g' + \left[ \frac{\nu (\nu - A - 1) + B}{1-x} + \frac{\mu (\mu + A - 1) + B}{x} - (\mu + \nu)(\mu + \nu -1) \right] g = 0. 
\end{align}
Let $\nu^{2} - (A+1) \nu + B=0$ and $\mu^{2} - (1-A)\mu + B =0$ to obtain
\begin{align}
\nu &= \frac{1}{2} \left( 1 + A + \sqrt{(1 + A)^{2} - 4 B} \right) \\
\mu &= \frac{1}{2} \left( 1 - A + \sqrt{(1-A)^{2} - 4 B} \right)
\end{align}
and
\begin{align}
x(1-x) g'' + (A + 2\mu - (2 \nu + 2 \mu)x)g' - (\mu + \nu)(\mu + \nu -1) g=0
\end{align}
which is the hypergeometric differential equation and has the first solution
\begin{align}
g(x) = {}_{2}F_{1}(\mu + \nu, \mu + \nu -1; A+2\mu ; x).
\end{align}
With this it is seen that
\begin{align}
y(x) = C_{0} \, x^{\mu} (1-x)^{\nu} \, {}_{2}F_{1}(\mu + \nu, \mu + \nu -1; A+2\mu ; x).
\end{align}
