<s>[INST] Solve system $\cos^2x+\cos^2y+\cos^2z=1,$ $\cos x+\cos y+\cos z=1,$ $x+y+z=\pi$ I want to solve the system:

$$\cos^2(x)+\cos^2(y)+\cos^2(z)=1,$$
$$\cos(x)+\cos(y)+\cos(z)=1,$$
$$x+y+z=\pi.$$

I tried to prove that only one of cosines can be not a zero, but I just prove that one or three cosines can not be zero.
I get, that $$\cos(x)~\cos(y)+\cos(x)~\cos(z)+\cos(y)~\cos(z)=0$$
Also after substituting
$$\cos(x) = 1 - \cos(y)-\cos(z),$$
we get $$\cos^2(y) + \cos^2(z)=\cos(y)+\cos(z) - \cos(y)\cos(z)$$
 [/INST] The hint.
Since $z=\pi-x-y$, we obtain
$$\cos{x}+\cos{y}-\cos(x+y)=1$$ or
$$2\cos\frac{x+y}{2}\cos\frac{x-y}{2}=2\cos^2\frac{x+y}{2}$$ or
$$\cos\frac{x+y}{2}\left(\cos\frac{x-y}{2}-\cos\frac{x+y}{2}\right)=0$$ or
$$\sin\frac{z}{2}\sin\frac{x}{2}\sin\frac{y}{2}=0.$$
I think the rest is smooth.
</s>