Bernoull’s differential equation \begin{equation}\label{eq:bernoulli}\frac{dy}{dx}+P(x)y=Q(x)y^n\end{equation} is nonlinear for $n\ne 0, 1$. Assume $n>1$ and multiply \eqref{eq:bernoulli} by $\frac{1}{y^n}$. \begin{equation}\label{eq:bernoulli2}\frac{1}{y^n}\frac{dy}{dx}+P(x)\frac{1}{y^{n-1}}=Q(x)\end{equation} Let $z=\frac{1}{y^{n-1}}$. Then \begin{align*}\frac{dz}{dx}&=\frac{dz}{dy}\frac{dy}{dx}\\&=(1-n)\frac{1}{y^n}\frac{dy}{dx}\end{align*} The equation \eqref{eq:bernoulli2} is reduced to the linear equation \begin{equation}\label{eq:bernoulli3}\frac{dz}{dx}+(1-n)P(x)z=(1-n)Q(x)\end{equation}
Example. Solve the Bernoulli’s equation $$\frac{dy}{dx}-\frac{3}{x}y=-x^3y^2$$
Solution. The equation can be written as $$\frac{1}{y^2}\frac{dy}{dx}-\frac{3}{x}\frac{1}{y}=-x^3$$ Let $z=\frac{1}{y}$. Then $\frac{dz}{dx}=-\frac{1}{y^2}\frac{dy}{dx}$ and subsequently we obtain the first-order linear differential equation $$\frac{dz}{dx}+\frac{3}{x}z=x^3$$ The integrating factor $\mu(x)$ is given by $$\mu(x)=e^{\int\frac{3}{x}dx}=e^{\ln x^3}=x^3$$ and thus the solution $z(x)$ is $$z(x)=\frac{\int\mu Qdx}{\mu}=\frac{\int x^6dx}{x^3}=\frac{\frac{x^7}{7}+C}{x^3}$$ Since $z=\frac{1}{y}$, the final answer can be written as $$y\left(\frac{x^7}{7}+C\right)=x^3$$