88.12.7 problem 9

Internal problem ID [24063]
Book : Elementary Differential Equations. By Lee Roy Wilcox and Herbert J. Curtis. 1961 first edition. International texbook company. Scranton, Penn. USA. CAT number 61-15976
Section : Chapter 2. Differential equations of first order. Miscellaneous Exercises at page 55
Problem number : 9
Date solved : Thursday, October 02, 2025 at 09:56:41 PM
CAS classification : [[_homogeneous, `class C`], _exact, _rational, [_Abel, `2nd type`, `class A`]]

\begin{align*} \left (x +2 y+2\right ) y^{\prime }&=3 x -y-1 \end{align*}
Maple. Time used: 0.094 (sec). Leaf size: 30
ode:=(x+2*y(x)+2)*diff(y(x),x) = 3*x-y(x)-1; 
dsolve(ode,y(x), singsol=all);
 
\[ y = -1-\frac {\frac {c_1 x}{2}+\frac {\sqrt {7 c_1^{2} x^{2}+2}}{2}}{c_1} \]
Mathematica. Time used: 0.075 (sec). Leaf size: 59
ode=(x+2*y[x]+2)*D[y[x],{x,1}]==3*x-y[x]-1; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)&\to \frac {1}{2} \left (-\sqrt {7 x^2+4+4 c_1}-x-2\right )\\ y(x)&\to \frac {1}{2} \left (\sqrt {7 x^2+4+4 c_1}-x-2\right ) \end{align*}
Sympy. Time used: 0.997 (sec). Leaf size: 39
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-3*x + (x + 2*y(x) + 2)*Derivative(y(x), x) + y(x) + 1,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ \left [ y{\left (x \right )} = - \frac {x}{2} - \frac {\sqrt {C_{1} + 7 x^{2}}}{2} - 1, \ y{\left (x \right )} = - \frac {x}{2} + \frac {\sqrt {C_{1} + 7 x^{2}}}{2} - 1\right ] \]