29.12.2 problem 321

Internal problem ID [4921]
Book : Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
Section : Various 12
Problem number : 321
Date solved : Monday, January 27, 2025 at 09:50:40 AM
CAS classification : [[_homogeneous, `class C`], _rational, _Riccati]

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

Solution by Maple

Time used: 0.324 (sec). Leaf size: 34

dsolve((x-a)^2*diff(y(x),x)+k*(x+y(x)-a)^2+y(x)^2 = 0,y(x), singsol=all)
 
\[ y \left (x \right ) = \frac {\left (-x +a \right ) \left (c_{1} k \left (-x +a \right )-1\right )}{-1+\left (k +1\right ) \left (-x +a \right ) c_{1}} \]

Solution by Mathematica

Time used: 0.228 (sec). Leaf size: 50

DSolve[(x-a)^2 D[y[x],x]+k(x+y[x]-a)^2+y[x]^2==0,y[x],x,IncludeSingularSolutions -> True]
 
\begin{align*} y(x)\to \frac {k (a-x)}{k+1}+\frac {1}{\frac {k+1}{a-x}+c_1} \\ y(x)\to \frac {k (a-x)}{k+1} \\ \end{align*}