Ask Uncle Colin: A Differential Equation
Dear Uncle Colin,
What’s the correct method to find the general solution of $y’‘+4y’+4y=(3+x)e^{-2x}$? I’ve got the complementary function just fine (it’s $y=Ae^{-2x}+Bxe^{-2x}$), but I’m going in circles with the particular integral.
- Differential Equation’s Solutions Are Really Gruesome; Ugly Exponential Scariness
Hi, DESARGUES, and thanks for your message!
I know of two approaches to this.
The standard logic
If the left-hand side was something that didn’t lead to $e^{-2x}$s knocking around, we’d need a linear constant on the right. However, because the solution has already ‘used up’ $x^0 e^{-2x}$ and $x^1 e^{-2x}$, we need the next two: a linear combination of $x^2 e^{-2x}$ and $x^3 e^{-2x}$.
But I don’t like that. It’s a bit too “here are the rules. Remember the rules. Do not attempt to understand the rules. Do not collect £200.”
How I’d approach it
I’d approach this differently from the get-go, changing the variable to make everything nicer.
If I say $y = z e^{-2x}$, I get $y’ = e^{-2x}\br{z’-2z}$ and $y’’ = e^{-2x}\br{z’‘-4z’ + 4z }$.
Substituting these into the equation makes it $e^{-2x} z’’ =(3+x)e^{-2x}$.
Since $e^{-2x}$ is never zero, we can divide through, leaving us with $z’’ = (3+x)$. That’s a Much Easier Thing To Solve.
Integrating once: $z’ = 3x+ \frac{1}{2}x^2 + A$; integrating again gives $z = \frac{3}{2}x^2 + \frac{1}{6}x^3 + Ax + B$.
Now, given that $y = z e^{-2x}$, we can write down the answer as $y = e^{-2x} \br{\frac{1}{6}x^3 + \frac{3}{2}x^2 + Ax + B}$.
Hope that helps!
- Uncle Colin
* Edited 2018-09-13 to fix a typo. Thanks to Adam Atkinson for spotting it.