<s>[INST] How were amplitudes of the $\cos$ and $\sin$ chosen? I don't understand why we use $\displaystyle\sqrt{1^2+\left(\frac{1}{2}\right)^2}$ in the below transformation. Can someone help to explain?
from
$$f(x)=\frac{3}{5}-\frac{3}{5}e^t\left(\cos(2t)+\frac{1}{2}\sin(2t)\right)$$
transform to
$$f(x)=\frac{3}{5}-\frac{3}{5}\sqrt{1^2+\left(\frac{1}{2}\right)^2}e^t\left(\frac{1}{\sqrt{1^2+\left(\frac{1}{2}\right)^2}}\cos(2t)+\frac{\frac{1}{2}}{\sqrt{1^2+\left(\frac{1}{2}\right)^2}}\sin(2t)\right)$$
let $\displaystyle\frac{1}{\sqrt{1^2+\left(\frac{1}{2}\right)^2}}=\cos\phi$ and $\displaystyle\frac{\frac{1}{2}}{\sqrt{1^2+\left(\frac{1}{2}\right)^2}}=\sin\phi$,
$$f(x)=\frac{3}{5}-\frac{3}{5}\sqrt{1^2+\left(\frac{1}{2}\right)^2}e^t(\cos\phi\cos(2t)+\sin\phi\sin(2t))$$
 [/INST] Let’s concentrate on the important part, which is of the form
$$
f(x)=a\cos x+b\sin x
$$
which we want to express as
$$
f(x)=A(\cos\varphi\cos x+\sin\varphi\sin x)
$$
A necessary (and sufficient) condition is that
$$
A\cos\varphi=a,\qquad A\sin\varphi=b
$$
and therefore $a^2=A^2\cos^2\varphi$, $b^2=A^2\sin^2\varphi$. Hence
$$
A^2=a^2+b^2
$$
We want $A>0$ (not necessary, but convenient), so we get
$$
A=\sqrt{a^2+b^2},\quad \cos\varphi=\frac{a}{A},\quad \sin\varphi=\frac{b}{A}
$$
The last two requirements can be fulfilled, because $(a/A,b/A)$ is a point on the unit circle.
</s>