I have the following differential equation: y''+y=\cos(t)\cos(2t) Maybe something can be done

I have the following differential equation:
$$\displaystyle{y}{''}+{y}={\cos{{\left({t}\right)}}}{\cos{{\left({2}{t}\right)}}}$$
Maybe something can be done to $$\displaystyle{\cos{{\left({t}\right)}}}{\cos{{\left({2}{t}\right)}}}$$ to make it easier to solve. Any ideas?

• Questions are typically answered in as fast as 30 minutes

Plainmath recommends

• Get a detailed answer even on the hardest topics.
• Ask an expert for a step-by-step guidance to learn to do it yourself.

Supoilign1964

I don't see an elegant solution , but it can be done by brute force using the method of variation of parameters.
The homogeneous differential equation $$\displaystyle{y}{''}{\left({t}\right)}+{y}{\left({t}\right)}={0}$$ has the two fundamental solutions $$\displaystyle{y}_{{1}}{\left({t}\right)}={\sin{{\left({t}\right)}}}$$ and $$\displaystyle{y}_{{2}}{\left({t}\right)}={\cos{{\left({t}\right)}}}$$
We must solve
$\left(\begin{array}{c}0\\ \cos(t)\cos(2t)\end{array}\right)=\left(\begin{array}{c}y_1&y_2\\ y_1'&y_2'\end{array}\right)\left(\begin{array}{c}u_1\\ u_2\end{array}\right)=\left(\begin{array}{c}\sin t&\cos t\\ -\cos t&\sin t\end{array}\right)\left(\begin{array}{c}u_1\\ u_2\end{array}\right)$
for $$\displaystyle{u}_{{1}}$$ and $$\displaystyle{u}_{{2}}$$ and find $$\displaystyle{U}_{{1}}$$ and $$\displaystyle{U}_{{2}}$$ such that $$\displaystyle{U}_{{1}}'={u}_{{1}}$$ and $$\displaystyle{U}_{{2}}'={u}_{{2}}$$
A particular solution will then be given by
$$\displaystyle{y}_{{0}}{\left({t}\right)}={U}_{{1}}{y}_{{1}}+{U}_{{2}}{y}_{{2}}$$ and $$\displaystyle{y}={y}_{{0}}+{c}_{{1}}{y}_{{1}}+{c}_{{2}}{y}_{{2}}$$
will be the general solution.
Since the matrix $$A(t)=\left(\begin{array}{c}\sin t&\cos t\\-\cos t&\sin t\end{array}\right)$$ is orthogonal, its inverse is its transpose, so
$\left(\begin{array}{c}u_1\\u_2\end{array}\right)=\left(\begin{array}{c}\sin t&-\cos t\\ \cos t&\sin t\end{array}\right)\left(\begin{array}{c}0\\ \cos(t)\cos(2t)\end{array}\right)=\left(\begin{array}{c}\cos^2(t)\cos(2t)\\\sin(t)\cos(t)\cos(2t)\end{array}\right)$
Note that $$\displaystyle{v}_{{2}}{\left({t}\right)}={\sin{{\left({t}\right)}}}{\cos{{\left({t}\right)}}}{\cos{{\left({2}{t}\right)}}}={\frac{{{1}}}{{{2}}}}{\sin{{\left({2}{t}\right)}}}{\cos{{\left({2}{t}\right)}}}={\frac{{{1}}}{{{4}}}}{\sin{{\left({4}{t}\right)}}},$$ so we can take
$$\displaystyle{U}_{{2}}{\left({t}\right)}=-{\frac{{{1}}}{{{16}}}}{\cos{{\left({4}{t}\right)}}}$$
On other hand, we get
$$\displaystyle{u}_{{1}}={{\cos}^{{2}}{\left({t}\right)}}{\cos{{\left({2}{t}\right)}}}={\cos{{\left({t}\right)}}}{\frac{{{1}}}{{{2}}}}{\left({\cos{{\left({3}{t}\right)}}}+{\cos{{\left({t}\right)}}}\right)}$$
$$\displaystyle={\frac{{{1}}}{{{2}}}}{\cos{{\left({t}\right)}}}{\cos{{\left({3}{t}\right)}}}+{\frac{{{1}}}{{{2}}}}{\cos{{\left({t}\right)}}}{\cos{{\left({t}\right)}}}={\frac{{{1}}}{{{4}}}}{\left({\cos{{\left({4}{t}\right)}}}+{\cos{{\left({2}{t}\right)}}}\right)}+{\frac{{{1}}}{{{4}}}}{\left({\cos{{\left({2}{t}\right)}}}+{1}\right)}$$
$$\displaystyle={\frac{{{1}}}{{{4}}}}{\cos{{\left({4}{t}\right)}}}+{\frac{{{1}}}{{{2}}}}{\cos{{\left({2}{t}\right)}}}+{\frac{{{1}}}{{{4}}}}$$
Integrating this gives
$$\displaystyle{U}_{{1}}{\left({t}\right)}={\frac{{{1}}}{{{16}}}}{\sin{{\left({4}{t}\right)}}}+{\frac{{{1}}}{{{4}}}}{\sin{{\left({2}{t}\right)}}}+{\frac{{{1}}}{{{4}}}}{t}$$
Now we can simplify the particular solution
$$\displaystyle{y}_{{0}}={U}_{{1}}{y}_{{1}}+{U}_{{2}}{y}_{{2}}=\ldots={\frac{{{1}}}{{{4}}}}{t}{\sin{{\left({t}\right)}}}-{\frac{{{1}}}{{{16}}}}{\cos{{\left({3}{t}\right)}}}+{\frac{{{5}}}{{{16}}}}{\cos{{\left({t}\right)}}}$$
using some further trig identities
You should at least check yourself that $$\displaystyle{y}{''}_{{0}}+{y}_{{0}}={\frac{{{1}}}{{{2}}}}{\left({\cos{{\left({t}\right)}}}+{\cos{{\left({3}{t}\right)}}}\right)}={\cos{{\left({t}\right)}}}{\cos{{\left({2}{t}\right)}}}$$
Therefore the general solution is
$$\displaystyle{y}{\left({t}\right)}={y}_{{0}}+{c}_{{1}}{y}_{{1}}+{c}_{{2}}{y}_{{2}}={\frac{{{1}}}{{{4}}}}{t}{\sin{{\left({t}\right)}}}-{\frac{{{1}}}{{{16}}}}{\cos{{\left({3}{t}\right)}}}+{\frac{{{5}}}{{{16}}}}{\cos{{\left({t}\right)}}}+{c}_{{1}}{\sin{{\left({t}\right)}}}+{c}_{{2}}{\cos{{\left({t}\right)}}}$$
for some real constants $$\displaystyle{c}_{{1}}$$ and $$\displaystyle{c}_{{2}}$$.

Have a similar question?
Charles Randolph
There's a general way of doing these things. You solve the homogeneous equation $$\displaystyle{y}{''}+{y}={0}$$, giving $$\displaystyle{C}_{{1}}{\cos{{\left({t}\right)}}}{\sin{{\left({t}\right)}}}+{C}_{{2}}{\sin{{\left({t}\right)}}}$$ for constants $$\displaystyle{C}_{{1}}$$ and $$\displaystyle{C}_{{2}}$$, then add to it a single solution $$\displaystyle{y}_{{p}}{\left({t}\right)}$$ to the inhomogeneous equation $$\displaystyle{y}{''}+{y}={\cos{{\left({t}\right)}}}{\cos{{\left({2}{t}\right)}}}={\frac{{{1}}}{{{2}}}}{\cos{{\left({3}{t}\right)}}}+{\frac{{{1}}}{{{2}}}}{\cos{{\left({t}\right)}}}$$. The resul will be the general solution to your differential equation
To find $$\displaystyle{y}_{{p}}{\left({t}\right)}$$, you try $$\displaystyle{y}_{{p}}{\left({t}\right)}={a}_{{1}}{\cos{{\left({3}{t}\right)}}}+{a}_{{2}}{\sin{{\left({3}{t}\right)}}}+{b}_{{1}}{t}{\cos{{\left({t}\right)}}}+{b}_{{2}}{t}{\sin{{\left({t}\right)}}}$$. You plug it in and solve for $$\displaystyle{a}_{{1}},{a}_{{2}},{b}_{{1}},$$ and $$\displaystyle{b}_{{2}}$$. Normally you just try combinations of $$\displaystyle{\cos{{\left({3}{t}\right)}}},{\sin{{\left({3}{t}\right)}}},{\cos{{\left({t}\right)}}}$$ and $$\displaystyle{\sin{{\left({t}\right)}}}$$, but since the latter two solve the homogeneous equation you have to stick a t in front. I will trust Theo Buehler is right and that $$\displaystyle{a}_{{1}}=-{\frac{{{1}}}{{{16}}}},\ {b}={\frac{{{1}}}{{{4}}}}$$ and $$\displaystyle{a}_{{2}}={b}_{{1}}={0}$$. Thus your general solution will be
$$\displaystyle{y}{\left({t}\right)}={C}_{{1}}{\cos{{\left({t}\right)}}}+{C}_{{2}}{\sin{{\left({t}\right)}}}-{\frac{{{1}}}{{{16}}}}{\cos{{\left({3}{t}\right)}}}+{\frac{{{1}}}{{{4}}}}{t}{\sin{{\left({t}\right)}}}$$
(The $$\displaystyle{\frac{{{5}}}{{{16}}}}{\cos{{\left({t}\right)}}}$$ term gets absorbed into the solution to the homogeneous equation).