Mathwizurd.com is created by David Witten, a mathematics and computer science student at Vanderbilt University. For more information, see the "About" page.

## Mar 29 Nonhomogeneous Equations with Constant Coefficients

This is very similar to the last post.

MathJax TeX Test Page Let's say you have $Ay'' + By' + Cy = f(x)$, you have to do two things. First, you find solution to the associated homogeneous differential equation. Why? Because let's say w is a particular solution to the nonhomogeneous differential equation, and y is the set of solutions to the homogeneous dif eq. The set of all solutions to the nonhomogeneous differential equation is y + w. That's because $L(y + w) = L(y) + L(w) = 0 + f(x) = f(x)$.

Second, you find the particular solution. I will demonstrate how to do this with an example.

# Example

MathJax TeX Test Page $$y'' + 4y' + 4y = 3x + 2$$ First, we solve the complementary y, or the homogeneous equation. $$y_c = c_1e^{-2x} + c_2xe^{-2x}$$ Now, we look at all of the terms in f(x) and all of its derivatives, we get that the particular equation equals $y_p = Ax + B$. We plug that in and we get $$4A + 4Ax + 4B = 3x + 2 \to 4Ax = 3x \to A = \frac{3}{4}$$ $$4A + 4B = 2 \to A + B = \frac{1}{2} \to B = -\frac{1}{4}$$ Our final equation is $y = y_c + y_p$ $$y = c_1e^{-2x} + c_2xe^{-2x} + \frac{3}{4}x - \frac{1}{4}$$

# Example- Repeat Roots

MathJax TeX Test Page $$y''' - y'' - 12y' = x - 2xe^{-3x}$$ First, we find the homogeneous solution. $$r^3 - r^2 - 12r = 0 \to r(r + 3)(r-4) = 0$$ $$y_c = c_1 + c_2e^{-3x} + c_3e^{4x}$$ Ignore $y_c$ for now, $y_p$ would be $Ax + B + Ce^{-3x} + Dxe^{-3x}$. However, let's factor in the repeated roots. Because there's already a constant coefficient, we multiply that term by x. However, there's already an x term! So we multiply that by x as well. Same thing with $e^{-3x}$. That's already in the $y_c$ solution. So, we multiply the $e^{-3x}$ terms by x, but that conflicts with $xe^{-3x}$, so we multiply that by x as well. Our new equation for $y_p$ is $$Ax^2 + Bx + Cxe^{4x} + Dx^2e^{-3x}$$

That's pretty much it. It's very similar to the homogeneous equation, there's a just an additive factor that pushes all of the solutions up from 0 to f(x).

David Witten