66.1.33 problem Problem 47

Internal problem ID [13809]
Book : Differential equations and the calculus of variations by L. ElSGOLTS. MIR PUBLISHERS, MOSCOW, Third printing 1977.
Section : Chapter 1, First-Order Differential Equations. Problems page 88
Problem number : Problem 47
Date solved : Monday, March 31, 2025 at 08:13:35 AM
CAS classification : [[_1st_order, _with_linear_symmetries], _Clairaut]

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

With initial conditions

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

Maple. Time used: 0.548 (sec). Leaf size: 17
ode:=y(x) = x*diff(y(x),x)+diff(y(x),x)^2; 
ic:=y(2) = -1; 
dsolve([ode,ic],y(x), singsol=all);
 
\begin{align*} y &= 1-x \\ y &= -\frac {x^{2}}{4} \\ \end{align*}
Mathematica. Time used: 0.007 (sec). Leaf size: 21
ode=y[x]==x*D[y[x],x]+D[y[x],x]^2; 
ic={y[2]==-1}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\begin{align*} y(x)\to 1-x \\ y(x)\to -\frac {x^2}{4} \\ \end{align*}
Sympy. Time used: 1.412 (sec). Leaf size: 5
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-x*Derivative(y(x), x) + y(x) - Derivative(y(x), x)**2,0) 
ics = {y(2): -1} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = 1 - x \]