23.1.457 problem 447

Internal problem ID [5064]
Book : Ordinary differential equations and their solutions. By George Moseley Murphy. 1960
Section : Part II. Chapter 1. THE DIFFERENTIAL EQUATION IS OF FIRST ORDER AND OF FIRST DEGREE, page 223
Problem number : 447
Date solved : Tuesday, September 30, 2025 at 11:31:12 AM
CAS classification : [[_homogeneous, `class C`], _rational, [_Abel, `2nd type`, `class A`]]

\begin{align*} \left (3-x -y\right ) y^{\prime }&=1+x -3 y \end{align*}
Maple. Time used: 0.077 (sec). Leaf size: 30
ode:=(3-x-y(x))*diff(y(x),x) = 1+x-3*y(x); 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {\left (x -1\right ) \operatorname {LambertW}\left (-2 c_1 \left (-2+x \right )\right )+2 x -4}{\operatorname {LambertW}\left (-2 c_1 \left (-2+x \right )\right )} \]
Mathematica. Time used: 0.055 (sec). Leaf size: 65
ode=(3-x-y[x])*D[y[x],x]==1+x-3*y[x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ \text {Solve}\left [\int _1^{\frac {2^{2/3} (2 x-y(x)-3)}{x+y(x)-3}}\frac {1}{K[1]^3-\frac {3 K[1]}{2^{2/3}}+1}dK[1]=\frac {1}{9} 2^{2/3} \log (x-2)+c_1,y(x)\right ] \]
Sympy. Time used: 0.711 (sec). Leaf size: 19
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-x + (-x - y(x) + 3)*Derivative(y(x), x) + 3*y(x) - 1,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = x + e^{C_{1} + W\left (2 \left (x - 2\right ) e^{- C_{1}}\right )} - 1 \]