When solving $\tan(3x) = \cot(4x)$, how to formulate the answer? when I solve the following equation:
$\tan(3x) = \cot(4x)$
I get the following solution:
$x = \frac{\pi}{14} + \frac{\pi n}{7}, n \in \mathbb{Z}$
But as x must be $\neq \frac{\pi}{6} + \frac{\pi k}{3}$ and $\neq \frac{\pi k}{4}$, with $k \in \mathbb{Z}$, there are values for n for which $x = \frac{\pi}{14} + \frac{\pi n}{7}, n \in \mathbb{Z}$ gives wrong solutions, e.g.:
for
$n = 3, x = \frac{\pi}{14} + \frac{3\pi}{7} = \frac{7\pi}{14} = \frac{\pi}{2}$
Which is not a solution because $\tan(3(\frac{\pi}{2}))$ is not defined (cosine is 0)
So how do I merge the solution $x = \frac{\pi}{14} + \frac{\pi n}{7}, n \in \mathbb{Z}$ with the domain? What is the algorithm?
Or, can I just write:
$x \in \{\frac{\pi}{14} + \frac{\pi n}{7}: n \in \mathbb{Z}\} \setminus \{\frac{\pi}{6} + \frac{\pi k}{3} : k \in \mathbb{Z} \} \setminus \{\frac{\pi k}{4} :k \in \mathbb{Z}\}$
Which is a bit ugly, I think.
What is the right way to do that?
Thanks for the attention!
 A: 
You get $\cos(7x)=0$ and $\cos(3x)\sin(4x) \ne 0$.
As you've already figured out
$\cos(7x) = 0 \implies x = \dfrac{2j+1}{14}\pi \quad (j \in \mathbb Z)$
$\cos(3x) = 0 \implies x = \dfrac{2k+1}{6}\pi \quad (k \in \mathbb Z)$
$\sin(4x) = 0 \implies x = \dfrac{\ell}{4} \pi \quad (\ell \in \mathbb Z)$
We look for coincidence of points
\begin{align}
   \dfrac{2j+1}{14}\pi &= \dfrac{2k+1}{6}\pi \\
   6j+3 &= 14k+7 \\
   3j - 7k &= 2 \\
   \hline
   j &= 7n + 3\\
   k &= 3n + 1\\
\hline
   \theta &\ne \dfrac{2n+1}{2}\pi
\end{align}
\begin{align}
   \dfrac{2j+1}{14}\pi &= \dfrac{\ell}{4} \pi \\
   4j+2 &= 7 \ell \\
   7 \ell - 4j &= 2 \\
   \hline
   j    &= 7n + 3\\
   \ell &= 4n + 2\\
\hline
   \theta &\ne \dfrac{2n+1}{2}\pi
\end{align}
So we have to require $j \ne 7n + 3$, which we can write as 
$j \not \equiv 3 \pmod 7$. In summary
$x = \dfrac{2j+1}{14}\pi\;$ where $\; j \not \equiv 3 \pmod 7$
A: Hint
Assuming that the equation is $$\tan(3x) - \cot(4x)=0$$ rewrite it as $$\frac{\sin(3x)}{\cos(3x)}-\frac{\cos(4x)}{\sin(4x)}=\frac{\sin(3x)\sin(4x)-\cos(3x)\cos(4x)}{\cos(3x)\sin(4x)}=-\frac{\cos(7x)}{\cos(3x)\sin(4x)}=0$$
I am sure that you can take from here.
A: If you can use the complex exponential definition of trig functions,
$$\sin(\theta) = \frac{e^{i\theta} - e^{-i\theta}}{2i}$$
$$\cos(\theta) = \frac{e^{i\theta} + e^{-i\theta}}{2}$$
$$\tan(\theta) = \frac{\sin(\theta)}{\cos(\theta)} = \frac{(e^{i\theta} - e^{-i\theta})}{i(e^{i\theta} + e^{-i\theta})}$$
$$\cot(\theta) = \frac{\cos(\theta)}{\sin(\theta)} = \frac{i(e^{i\theta} + e^{-i\theta})}{(e^{i\theta} - e^{-i\theta})}$$
Then your equation becomes:
$$\frac{(e^{i3x} - e^{-i3x})}{i(e^{i3x} + e^{-i3x})} = \frac{i(e^{i4x} + e^{-i4x})}{(e^{i4x} - e^{-i4x})}$$
$$(e^{i3x} - e^{-i3x})(e^{i4x} - e^{-i4x}) = -(e^{i3x} + e^{-i3x})(e^{i4x} + e^{-i4x})$$
$$e^{i7x} - e^{-ix} - e^{ix} + e^{-i7x} = -(e^{i7x} + e^{-ix} + e^{ix} + e^{-i7x})$$
$$2e^{i7x} + 2e^{-i7x} = 0$$
$$2(2\cos(7x)) = 0$$
$$\cos(7x) = 0$$
$$7x = \frac{\pi}{2} + \pi n, n \in \mathbb{Z}$$
$$x = \frac{\pi}{14} + \frac{\pi}{7}n$$
