62.6.2 problem Ex 2

Internal problem ID [12820]
Book : An elementary treatise on differential equations by Abraham Cohen. DC heath publishers. 1906
Section : Chapter 2, differential equations of the first order and the first degree. Article 13. Linear equations of first order. Page 19
Problem number : Ex 2
Date solved : Tuesday, January 28, 2025 at 04:24:48 AM
CAS classification : [_linear]

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

Solution by Maple

Time used: 0.001 (sec). Leaf size: 19

dsolve(x*diff(y(x),x)+(1+x)*y(x)=exp(x),y(x), singsol=all)
 
\[ y = \frac {{\mathrm e}^{x}+2 c_{1} {\mathrm e}^{-x}}{2 x} \]

Solution by Mathematica

Time used: 0.064 (sec). Leaf size: 27

DSolve[x*D[y[x],x]+(1+x)*y[x]==Exp[x],y[x],x,IncludeSingularSolutions -> True]
 
\[ y(x)\to \frac {e^x+2 c_1 e^{-x-1}}{2 x} \]