Solve for particular solution for $y''+9y=-6\sin(3t)$ I got the two root $r=\pm 3i$.
I am using the method of undetermined coefficients to solve this equation.
I got $Y(t) =t(A\cos(3t)+B\sin(3t))$ since $α + iβ$ is a root of the characteristic equation, $s=1$.
But I am not sure.
 A: The general solution will be the sum of the $\color{blue}{\text{complementary solution}}$ and $\color{blue}{\text{particular solution}}$.
Complementary solution: Let $$y''+9y=0 \quad \overbrace{\implies}^{y=e^{rt}} \quad r^{2}+9=0 \implies r=\pm 3i $$So, fundamental set of solutions will be $C.F.S=\{e^{3it},e^{-3it}\}$ and therefore the complementary solution for ODE is $$\boxed{y_{c}(t)=Ae^{3it}+Be^{-3it} \quad  \overbrace{\implies }^{\text{apply Euler's indentity}} \quad  y_{c}(t)=Acos(3t)+B\sin(3t) }$$
Particular solution (undetermined coefficients): The particular solution to ODE is of the form $$y_{p}(t)=t^{s}(a\cos(3t)+b\sin(3t)) \quad \text{where} \quad s=1 \quad (\text{see the form of ODE}).$$So, we have that $$\boxed{y''_{p}+9y_{p}=-6\sin(3t) \overbrace{\implies}^{y_{p}=at\cos(3t)+bt\sin(3t)} a=1 \wedge b=0 \implies \boxed{y_{p}=t\cos(3t)}}.$$
General solution: Is the form $$\boxed{y=y_{c}+y_{p}}$$Therefore $$\boxed{y(t)=A\cos(3t)+B\sin(3t)+\color{blue}{t\cos(3t)}, \quad A,B \in \mathbb{F}}.$$where $\mathbb{F}$ is scalar field.
