64.6.20 problem 20

Internal problem ID [13291]
Book : Differential Equations by Shepley L. Ross. Third edition. John Willey. New Delhi. 2004.
Section : Chapter 2, Miscellaneous Review. Exercises page 60
Problem number : 20
Date solved : Wednesday, March 05, 2025 at 09:34:49 PM
CAS classification : [[_homogeneous, `class A`], _rational, [_Abel, `2nd type`, `class A`]]

\begin{align*} y^{\prime }&=\frac {2 x +7 y}{2 x -2 y} \end{align*}

With initial conditions

\begin{align*} y \left (1\right )&=2 \end{align*}

Maple. Time used: 0.351 (sec). Leaf size: 18
ode:=diff(y(x),x) = (2*x+7*y(x))/(2*x-2*y(x)); 
ic:=y(1) = 2; 
dsolve([ode,ic],y(x), singsol=all);
 
\[ y = \frac {4 \sqrt {16-15 x}}{5}-2 x +\frac {16}{5} \]
Mathematica. Time used: 0.061 (sec). Leaf size: 68
ode=D[y[x],x]==(2*x+7*y[x])/(2*x-2*y[x]); 
ic={y[1]==2}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ \text {Solve}\left [\int _1^{\frac {y(x)}{x}}\frac {K[1]-1}{(K[1]+2) (2 K[1]+1)}dK[1]=\int _1^2\frac {K[1]-1}{(K[1]+2) (2 K[1]+1)}dK[1]-\frac {\log (x)}{2},y(x)\right ] \]
Sympy. Time used: 1.965 (sec). Leaf size: 22
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(Derivative(y(x), x) - (2*x + 7*y(x))/(2*x - 2*y(x)),0) 
ics = {y(1): 2} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = - 2 x + \frac {\sqrt {\frac {1024}{25} - \frac {192 x}{5}}}{2} + \frac {16}{5} \]