Given that $3\sin x + 2\sin y = 4$. Find the maximum value of $3\cos x + 2\cos y$. 
Given that $3\sin x + 2\sin y = 4$. Find the maximum value of $3\cos x + 2\cos y$.

I wonder if calculus can be used to solve this problem? If not how to solve this? I am thinking about $(3\cos x + 2\cos y)^2=9\cos^2x+12\cos x\cos y + 4\cos^2y$ and work in this way but I don't quite see how.

Although Koro's solution is my favourite one, you can also solve it just using AM-GM as follows:

*

*Set $s=\sin x, t = \sin y$

*$\Rightarrow$ to maximize is $3\sqrt{1-s^2}+2\sqrt{1-t^2}$ subject to $3s+2t=4$ for $(s,t)\in [0,1]^2$
Since the objective function is non-negative you can maximize the square of it:
\begin{eqnarray*} 9(1-s^2)+4(1-t^2) + 12 \sqrt{(1-s^2)(1-t^2)}
& \stackrel{AM-GM}{\leq} & 13 -(9s^2+4t^2) + 12 \frac{2-s^2-t^2}2 \\
& \stackrel{9s^2+4t^2 =16-12st}{\leq} & 9 + 12st - 6(s^2+t^2)\\
& \stackrel{AM-GM}{\leq} & 9 + 6(s^2+t^2) - 6(s^2+t^2) \\
& = & 9
\end{eqnarray*}
Equality is reached for $s=t = \frac 45$, hence, for $\sin x = \sin y =\frac 45$.
