2. It is known that $\frac{\cos x-\sin x}{\sin y}=\frac{1}{3 \sqrt{2}} \operatorname{ctg} \frac{x+y}{2}$ and $\frac{\sin x+\cos x}{\cos y}=-6 \sqrt{2} \operatorname{tg} \frac{x+y}{2}$. Find all possible values of the expression $\operatorname{tg}(x+y)$, given that there are at least three.
Answer: $-1, \frac{12}{35}$ or $-\frac{12}{35}$.

Solution. Multiplying the two given equations, we get $\frac{\cos ^{2} x-\sin ^{2} x}{\cos y \sin y}=-2$, which is equivalent to the following on the domain of definition:

$$
\cos 2 x=-2 \sin y \cos y \Leftrightarrow \cos 2 x+\cos \left(2 y-\frac{\pi}{2}\right)=0 \Leftrightarrow 2 \cos \left(x+y-\frac{\pi}{4}\right) \cos \left(x-y+\frac{\pi}{4}\right)=0
$$

from which it follows that either $x+y-\frac{\pi}{4}=\frac{\pi}{2}+\pi k, k \in \mathbb{Z}$, or $x-y+\frac{\pi}{4}=\frac{\pi}{2}+\pi k, k \in \mathbb{Z}$.

In the first case, we get that $x+y=\frac{3 \pi}{4}+\pi k, k \in \mathbb{Z}$, from which it immediately follows that $\operatorname{tg}(x+y)=$ $-1$.

In the second case, $x=y+\frac{\pi}{4}+\pi k, k \in \mathbb{Z}$. By introducing an additional angle, we can transform the numerator of the fraction on the left side of the second equation: $\sin x+\cos x=\sqrt{2}\left(\frac{1}{\sqrt{2}} \sin x+\frac{1}{\sqrt{2}} \cos x\right)=$ $\sqrt{2} \cos \left(x-\frac{\pi}{4}\right)$. Substituting the expression for $x$ here, we get

$$
\sqrt{2} \cos \left(y+\frac{\pi}{4}+\pi k-\frac{\pi}{4}\right)=\sqrt{2} \cos (y+\pi k)=\sqrt{2}(\cos y \cos \pi k-\sin y \sin \pi k)=(-1)^{k} \sqrt{2} \cos y
$$

The second equation then takes the form $(-1)^{k} \sqrt{2}=-6 \sqrt{2} \operatorname{tg} \frac{x+y}{2}$. From this, $\operatorname{tg} \frac{x+y}{2}$ can take the values $\pm \frac{1}{6}$. Therefore, $\operatorname{tg}(x+y)=\frac{2 \operatorname{tg} \frac{x+y}{2}}{1-\operatorname{tg}^{2} \frac{x+y}{2}}=\frac{2 \cdot\left( \pm \frac{1}{6}\right)}{1-\frac{1}{36}}= \pm \frac{12}{35}$.

Since the problem states that the expression $\operatorname{tg}(x+y)$ can take at least 3 different values, all three cases are possible.

Remark. It is not difficult to verify that all 3 cases are realizable.

In the first case, we get the system

$\left\{\begin{array}{l}\frac{\sqrt{2} \cos \left(x-\frac{\pi}{4}\right)}{\cos y}=-6 \sqrt{2} \operatorname{tg} \frac{x+y}{2}, \\ x=\frac{3 \pi}{4}-y+\pi k, k \in \mathbb{Z}\end{array} \Leftrightarrow\left\{\begin{array}{l}\frac{\cos \left(\frac{\pi}{2}-y+\pi k\right)}{\cos y}=-6 \operatorname{tg}\left(\frac{3 \pi}{8}+\frac{\pi k}{2}\right), \\ x=\frac{3 \pi}{4}-y+\pi k, k \in \mathbb{Z}\end{array} \Leftrightarrow\left\{\begin{array}{l}(-1)^{k} \operatorname{tg} y=-6 \operatorname{tg}\left(\frac{3 \pi}{8}+\frac{\pi k}{2}\right), \\ x=\frac{3 \pi}{4}-y+\pi k, k \in \mathbb{Z} .\end{array}\right.\right.\right.$

Obviously, the first equation has solutions (the tangent takes any value), and therefore the system has solutions.

In the second case, substituting $x$ not only into the left side of the second equation but also into the right side: $(-1)^{k} \sqrt{2}=-6 \sqrt{2} \operatorname{tg}\left(y+\frac{\pi}{8}+\frac{\pi k}{2}\right) \Leftrightarrow \operatorname{tg}\left(y+\frac{\pi}{8}+\frac{\pi k}{2}\right)=\frac{(-1)^{k}}{6}$. It is easy to see that this equation has solutions for any integer $k$, so both values of $\operatorname{tg}(x+y)$ can be taken.