75.13.4 problem 321

Internal problem ID [16838]
Book : A book of problems in ordinary differential equations. M.L. KRASNOV, A.L. KISELYOV, G.I. MARKARENKO. MIR, MOSCOW. 1983
Section : Chapter 2 (Higher order ODEs). Section 13. Basic concepts and definitions. Exercises page 98
Problem number : 321
Date solved : Monday, March 31, 2025 at 03:23:54 PM
CAS classification : [[_2nd_order, _quadrature]]

\begin{align*} \left (x -1\right ) y^{\prime \prime }&=1 \end{align*}

Maple. Time used: 0.001 (sec). Leaf size: 20
ode:=(x-1)*diff(diff(y(x),x),x) = 1; 
dsolve(ode,y(x), singsol=all);
 
\[ y = \ln \left (x -1\right ) \left (x -1\right )+\left (c_1 -1\right ) x +c_2 +1 \]
Mathematica. Time used: 0.005 (sec). Leaf size: 22
ode=(x-1)*D[y[x],{x,2}]==1; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to (x-1) \log (x-1)+(-1+c_2) x+c_1 \]
Sympy. Time used: 0.280 (sec). Leaf size: 20
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq((x - 1)*Derivative(y(x), (x, 2)) - 1,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{1} + C_{2} x + x \log {\left (x - 1 \right )} - x - \log {\left (x - 1 \right )} \]