Jon L. answered 02/13/14
Tutor
New to Wyzant
College Math, Statistics, Finance, Actuarial Science at a Discount!
We approach this through the use of an integrating factor.
1. Rearrange the terms
y' - y = x2
2. Find the integrating factor I
I = exp( int [0,x] -1 dt ) = exp(-x)
3. Using the integrating factor I and simplifying the expression
d/dx (yI) = x2I
4. Integrate both sides
y exp(-x) = int x2 exp(-x) dx
5. Integrate the right hand side by parts (see note below)
y exp(-x) = -exp(-x) (x2 + 2x + 2) + C
6. Multiply both sides by exp(x)
y = C exp(x) - x2 - 2x - 2
Note: Integrate x2 exp(-x) by parts, where int u dv = uv - int v du
1. Let u = x2 and dv = exp(-x)
2. Then du = 2x and v = -exp(-x)
3. int x2 exp(-x) dx = -exp(-x) x2 + int exp(-x) 2x dx
3a. Now let u = 2x and dv = exp(-x)
3b. Then du = 2 and v = -exp(-x)
3c. int exp(-x) 2x dx = -exp(-x) 2x + int exp(-x) 2 dx = -exp(-x) 2x - 2 exp(-x) + C
4. int x2 exp(-x) dx = -exp(-x) x2 - exp(-x) 2x - exp(-x) 2 + C
5. int x2 exp(-x) dx = -exp(-x) (x2 + 2x + 2) + C