Example 1. Solve the equation

$$
3 e^{x} \tan y d x+\left(2-e^{x}\right) \sec ^{2} y d y=0
$$
Solution. Divide both sides of the equation by the product $\operatorname{tg} y \cdot\left(2-e^{x}\right)$:

$$
\frac{3 e^{x} d x}{2-e^{x}}+\frac{\sec ^{2} y d y}{\operatorname{tg} y}=0
$$

We obtained an equation with separated variables. Integrating it, we find

$$
-3 \ln \left|2-e^{x}\right|+\ln |\operatorname{tg} y|=C_{1} .
$$

After exponentiation, we get

$$
\frac{|\operatorname{tg} y|}{\left|2-e^{x}\right|^{3}}=e^{c_{1}}, \text { or }\left|\frac{\operatorname{tg} y}{\left(2-e^{x}\right)^{3}}\right|=e^{c_{1}},
$$

from which

$$
\frac{\operatorname{tg} y}{\left(2-e^{x}\right)^{3}}= \pm e^{c_{1}}
$$

Denoting $\pm e^{C_{1}}=C$, we will have

$$
\frac{\operatorname{tg} y}{\left(2-e^{x}\right)^{3}}=C \quad \text { or } \quad \operatorname{tg} y-C\left(2-e^{x}\right)^{3}=0 .
$$

When dividing by the product $\operatorname{tg} y \cdot\left(2-e^{x}\right)$, it was assumed that neither of the factors is zero. Setting each factor to zero, we get respectively

$$
y=k \pi(k=0, \pm 1, \pm 2, \ldots), \quad x=\ln 2
$$

By direct substitution into the original equation, we verify that $y=$ $k \pi$ and $x=\ln 2$ are solutions of this equation. They can be formally obtained from the general integral when $C=0$ and $C=\infty$. The latter means that the constant $C$ is replaced by $\frac{1}{C_{2}}$, after which the general integral will take the form

$$
\operatorname{tg} y-\frac{1}{C_{2}}\left(2-e^{x}\right)^{3}=0, \quad \text { or } \quad C_{2} \operatorname{tg} y-\left(2-e^{x}\right)^{3}=0 .
$$

Setting $C_{2}=0$ in the last equality, which corresponds to $C=\infty$, we will have that $\left(2-e^{x}\right)^{3}=0$, from which we obtain the solution $x=\ln 2$ of the original equation. Thus, the functions $y=k \pi, k=0, \pm 1, \pm 2, \ldots$ and $x=\ln 2$ are particular solutions of the given equation. Therefore, the final answer will be:

$$
\operatorname{tg} y-C\left(2-e^{x}\right)^{3}=0
$$