How do I solve the differential equation $y' = (1-y)(1+6y)$? How can I solve this ODE?
$$\frac{\mathrm{d}y}{\mathrm{d}x} = (1-y)(1+6y)$$
I tried using classical Runge-Kutta, but the results are not satisfying. Can anyone suggest some other method? Please help.
 A: This equation does not have to be solved numerically because it can be solved explicitly. A linear change of the variable $w(x)=ay(cx)+b$ reduces it
to the equation $y'=1-y^2$ whose solution is hyperbolic tangent. 
A: Write
$$\frac{\mathrm{d}y}{(1-y)(1+6y)} = \mathrm{d}x$$
Decompose into partial fractions
$$\frac{1}{7}\left(\frac{1}{1-y} + \frac{6}{1+6y}\right) \mathrm{d}y = \mathrm{d}x$$
Rewrite as
$$\left(\frac{6}{6y+1} - \frac{1}{y-1}\right) \mathrm{d}y = 7 \,\mathrm{d}x$$
Integrate
$$\frac{6y+1}{y-1} = \beta \, \mathrm{e}^{7 x}$$
which can be rewritten as follows
$$y = \frac{\beta \, \mathrm{e}^{7 x}+1}{\beta \, \mathrm{e}^{7 x}-6}$$
If the initial condition $y_0 := y (0)$ is given, then $\beta = \dfrac{6 \,y_0 + 1}{y_0 - 1}$.
A: $$y'(x)=\left(1-y(x)\right)\left(1+6y(x)\right)\Longleftrightarrow$$
$$\frac{y'(x)}{\left(1-y(x)\right)\left(1+6y(x)\right)}=1\Longleftrightarrow$$
$$\int\frac{y'(x)}{\left(1-y(x)\right)\left(1+6y(x)\right)}\space\text{d}x=\int1\space\text{d}x\Longleftrightarrow$$

Substitute $u=y(x)$ and $\text{d}u=y'(x)\space\text{d}x$:

$$\int\frac{1}{\left(1-u\right)\left(1+6u\right)}\space\text{d}u=x+\text{C}\Longleftrightarrow$$

Use partial fractions:

$$\frac{6}{7}\int\frac{1}{1+6u}\space\text{d}u-\frac{1}{7}\int\frac{1}{u-1}\space\text{d}u=x+\text{C}\Longleftrightarrow$$

Substitute $s=1+6u$ and $\text{d}s=6\space\text{d}u$.
Substitute $p=u-1$ and $\text{d}p=\text{d}u$.

$$\frac{1}{7}\int\frac{1}{s}\space\text{d}s-\frac{1}{7}\int\frac{1}{p}\space\text{d}p=x+\text{C}\Longleftrightarrow$$
$$\frac{\ln\left|s\right|}{7}-\frac{\ln\left|p\right|}{7}=x+\text{C}\Longleftrightarrow$$
$$\frac{\ln\left|1+6y(x)\right|-\ln\left|y(x)-1\right|}{7}=x+\text{C}\Longleftrightarrow$$
$$\ln\left|\frac{1+6y(x)}{y(x)-1}\right|=7x+\text{C}\Longleftrightarrow$$
$$\left|\frac{1+6y(x)}{y(x)-1}\right|=\text{C}e^{7x}$$
So, for $y(x)$ we get two solutions:


*

*$$y(x)=\frac{\text{C}e^{7x}+1}{\text{C}e^{7x}-6}$$

*$$y(x)=\frac{\text{C}e^{7x}-1}{\text{C}e^{7x}+6}$$

