2.3 problem 10.3.4

Internal problem ID [5057]

Book: Basic Training in Mathematics. By R. Shankar. Plenum Press. NY. 1995
Section: Chapter 10, Differential equations. Section 10.3, ODEs with variable Coefficients. First order. page 315
Problem number: 10.3.4.
ODE order: 1.
ODE degree: 1.

CAS Maple gives this as type [[_linear, `class A`]]

\[ \boxed {y+y^{\prime }=\left (x +1\right )^{2}} \] With initial conditions \begin {align*} [y \left (0\right ) = 0] \end {align*}

Solution by Maple

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

dsolve([diff(y(x),x)+y(x)=(x+1)^2,y(0) = 0],y(x), singsol=all)
 

\[ y \left (x \right ) = x^{2}+1-{\mathrm e}^{-x} \]

Solution by Mathematica

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

DSolve[{y'[x]+y[x]==(x+1)^2,{y[0]==0}},y[x],x,IncludeSingularSolutions -> True]
 

\[ y(x)\to x^2-e^{-x}+1 \]