Non-Homogeneous ODE Solver
Solve $ay” + by’ + cy = g(t)$ using the Method of Undetermined Coefficients.
System (LHS)
Forcing Function g(t)
Initial Conditions
Solution Components
System Response
Method of Undetermined Coefficients
Non-homogeneous differential equations describe systems driven by an external force, such as a motor vibrating a bridge or a voltage source in a circuit. The general solution consists of two parts: $$ y(t) = y_h(t) + y_p(t) $$
1. The Homogeneous Solution ($y_h$): This represents the system’s natural behavior (transient response). We find this by setting the right-hand side to zero and solving $ay” + by’ + cy = 0$ using the characteristic equation $ar^2 + br + c = 0$.
2. The Particular Solution ($y_p$): This represents the steady-state response driven by the forcing function $g(t)$. The Method of Undetermined Coefficients involves making an educated “guess” for the form of $y_p$ based on $g(t)$, substituting it into the ODE, and solving for the coefficients.
Common Guesses Table
- If $g(t) = Ke^{rt}$, guess $y_p = Ae^{rt}$.
- If $g(t) = K \sin(\omega t)$, guess $y_p = A\sin(\omega t) + B\cos(\omega t)$.
- If $g(t) = P_n(t)$ (polynomial), guess a polynomial of degree $n$.
Warning (Resonance): If your guess contains a term that is already part of the homogeneous solution $y_h$, you must multiply your guess by $t$ (or $t^2$) until it is unique. This tool handles this automatically!