Ode Explicit 9429D5
1. **Problem statement:** Solve the ordinary differential equation (ODE) $$y' = y - y^3$$ with the initial condition $$y(0) = R$$ where $$R > 0$$.
2. **Rewrite the ODE:** The equation can be written as $$\frac{dy}{dt} = y - y^3 = y(1 - y^2)$$.
3. **Separate variables:** We separate variables to integrate:
$$\frac{dy}{y(1 - y^2)} = dt$$.
4. **Partial fraction decomposition:** Decompose the left side:
$$\frac{1}{y(1 - y^2)} = \frac{A}{y} + \frac{B y + C}{1 - y^2}$$.
Since $$1 - y^2 = (1 - y)(1 + y)$$, we can also write:
$$\frac{1}{y(1 - y)(1 + y)} = \frac{A}{y} + \frac{B}{1 - y} + \frac{C}{1 + y}$$.
Multiply both sides by $$y(1 - y)(1 + y)$$:
$$1 = A(1 - y)(1 + y) + B y (1 + y) + C y (1 - y)$$.
Simplify:
$$1 = A(1 - y^2) + B y (1 + y) + C y (1 - y)$$.
Expand terms:
$$1 = A - A y^2 + B y + B y^2 + C y - C y^2$$.
Group by powers of $$y$$:
$$1 = A + y(B + C) + y^2(-A + B - C)$$.
Equate coefficients:
- Constant term: $$A = 1$$
- Coefficient of $$y$$: $$B + C = 0$$
- Coefficient of $$y^2$$: $$-A + B - C = 0$$
Substitute $$A=1$$:
$$-1 + B - C = 0 \implies B - C = 1$$.
From $$B + C = 0$$ and $$B - C = 1$$, add equations:
$$2B = 1 \implies B = \frac{1}{2}$$.
Then $$C = -B = -\frac{1}{2}$$.
5. **Rewrite integral:**
$$\int \frac{dy}{y(1 - y^2)} = \int \left( \frac{1}{y} + \frac{1/2}{1 - y} - \frac{1/2}{1 + y} \right) dy = \int dt$$.
6. **Integrate each term:**
$$\int \frac{1}{y} dy = \ln|y|$$
$$\int \frac{1/2}{1 - y} dy = -\frac{1}{2} \ln|1 - y|$$ (because derivative of $$1 - y$$ is $$-1$$)
$$\int -\frac{1/2}{1 + y} dy = -\frac{1}{2} \ln|1 + y|$$
So the integral becomes:
$$\ln|y| - \frac{1}{2} \ln|1 - y| - \frac{1}{2} \ln|1 + y| = t + C$$.
7. **Combine logarithms:**
$$\ln \left( \frac{|y|}{\sqrt{|1 - y| \cdot |1 + y|}} \right) = t + C$$.
Since $$\sqrt{|1 - y| \cdot |1 + y|} = \sqrt{|1 - y^2|}$$, we have:
$$\ln \left( \frac{|y|}{\sqrt{|1 - y^2|}} \right) = t + C$$.
8. **Exponentiate both sides:**
$$\frac{|y|}{\sqrt{|1 - y^2|}} = K e^{t}$$ where $$K = e^{C} > 0$$.
9. **Solve for $$y$$:**
Square both sides:
$$\frac{y^2}{|1 - y^2|} = K^2 e^{2t}$$.
Since $$y^2 < 1$$ or $$y^2 > 1$$ changes the sign inside absolute value, but initial condition $$y(0) = R > 0$$ and typically solution stays in $$|y| < 1$$ for stability, assume $$1 - y^2 > 0$$:
$$\frac{y^2}{1 - y^2} = K^2 e^{2t}$$.
Rearranged:
$$y^2 = K^2 e^{2t} (1 - y^2) = K^2 e^{2t} - K^2 e^{2t} y^2$$.
Bring terms with $$y^2$$ together:
$$y^2 + K^2 e^{2t} y^2 = K^2 e^{2t}$$
$$y^2 (1 + K^2 e^{2t}) = K^2 e^{2t}$$
$$y^2 = \frac{K^2 e^{2t}}{1 + K^2 e^{2t}}$$
Take positive root (since $$R > 0$$):
$$y = \frac{K e^{t}}{\sqrt{1 + K^2 e^{2t}}}$$.
10. **Apply initial condition:**
At $$t=0$$, $$y(0) = R$$:
$$R = \frac{K}{\sqrt{1 + K^2}}$$.
Square both sides:
$$R^2 = \frac{K^2}{1 + K^2}$$
Rearranged:
$$R^2 (1 + K^2) = K^2$$
$$R^2 + R^2 K^2 = K^2$$
$$R^2 = K^2 - R^2 K^2 = K^2 (1 - R^2)$$
$$K^2 = \frac{R^2}{1 - R^2}$$.
Since $$R > 0$$ and $$R < 1$$ for this to be valid, we have:
$$K = \frac{R}{\sqrt{1 - R^2}}$$.
11. **Final explicit solution:**
$$\boxed{y(t) = \frac{\frac{R}{\sqrt{1 - R^2}} e^{t}}{\sqrt{1 + \left( \frac{R}{\sqrt{1 - R^2}} \right)^2 e^{2t}}} = \frac{R e^{t}}{\sqrt{1 - R^2 + R^2 e^{2t}}}}$$.
This is the explicit solution for $$y' = y - y^3$$ with $$y(0) = R$$ and $$0 < R < 1$$.
If $$R \geq 1$$, the solution behavior changes and requires separate analysis.