1.23 problem 40

Internal problem ID [12440]

Book: DIFFERENTIAL and INTEGRAL CALCULUS. VOL I. by N. PISKUNOV. MIR PUBLISHERS, Moscow 1969.
Section: Chapter 8. Differential equations. Exercises page 595
Problem number: 40.
ODE order: 1.
ODE degree: 1.

CAS Maple gives this as type [_linear]

\[ \boxed {y^{\prime } x +y=-x} \]

Solution by Maple

Time used: 0.0 (sec). Leaf size: 13

dsolve((x+y(x))+x*diff(y(x),x)=0,y(x), singsol=all)
 

\[ y \left (x \right ) = -\frac {x}{2}+\frac {c_{1}}{x} \]

Solution by Mathematica

Time used: 0.038 (sec). Leaf size: 17

DSolve[(x+y[x])+x*y'[x]==0,y[x],x,IncludeSingularSolutions -> True]
 

\[ y(x)\to -\frac {x}{2}+\frac {c_1}{x} \]