Solve the first-order differential equation (y')^2 - (y')^3…
Solve the first-order differential equation $(y')^2 - (y')^3 = y^2$ using the parameter (Lagrange-type differentiation) method.
Explanation of Method
Parameter substitution $p=y'$, elimination of $x$ via $dy=p\,dx$, integration by substitution and partial fractions.
Step 1: Introduce the parameter and solve for $y$
Let $p=y'$. The equation $p^2-p^3=y^2$ gives $y^2=p^2(1-p)$, so
\[ y=p\sqrt{1-p} \](taking the positive square-root branch; the branch $y=-p\sqrt{1-p}$ is discussed in the Remarks). This requires $1-p\ge 0$, i.e. $p\le 1$.
Step 2: Form $dx$ from $dy=p\,dx$
Differentiating $y=p\sqrt{1-p}$ with \texttt{sympy} gives
\[ \frac{dy}{dp}=\frac{2-3p}{2\sqrt{1-p}} \]Since $dy=p\,dx$, we have $dx=\dfrac{1}{p}\dfrac{dy}{dp}\,dp$, so
\[ \frac{dx}{dp}=\frac{2-3p}{2p\sqrt{1-p}} \]This matches the source's stated expression exactly.
Step 3: Integrate via $u=\sqrt{1-p}$
With $u=\sqrt{1-p}$ (so $p=1-u^2$, $dp=-2u\,du$), the integrand becomes rational in $u$ and partial fractions give
\[ \int \frac{2-3p}{2p\sqrt{1-p}}\,dp = 3\sqrt{1-p}+\ln\left|\frac{\sqrt{1-p}-1}{\sqrt{1-p}+1}\right| + C \]\texttt{sympy.integrate} was run directly on $\dfrac{2-3p}{2p\sqrt{1-p}}$ and reproduced this antiderivative exactly (up to the sign convention inside the log, which is immaterial under the absolute value). The source's integration is correct.
Step 4: Gold-standard verification
Differentiating the claimed \[ x(p)=\ln\left|\frac{1-\sqrt{1-p}}{1+\sqrt{1-p}}\right|+3\sqrt{1-p}+C,\qquad y(p)=p\sqrt{1-p} \] with \texttt{sympy} and forming the ratio $\dfrac{dy/dp}{dx/dp}$ simplifies identically to $p$, confirming $dy/dx=p=y'$ as required. Direct substitution also confirms $y^2=p^2-p^3$ identically. No errors were found in this derivation — the source's Steps agree with sympy at every stage.
Result
Final answer:
Verified — no correction needed. The parametric general solution is
\[ x=\ln\left|\frac{1-\sqrt{1-p}}{1+\sqrt{1-p}}\right|+3\sqrt{1-p}+C,\qquad y=p\sqrt{1-p},\qquad p\in[0,1] \]Remark (domain and the mirror branch): strictly, $y^2=p^2(1-p)\ge 0$ only forces $p\le 1$ (negative $p$ is also admissible), so the restriction to $p\in[0,1]$ is a convenient choice rather than a strict necessity; at $p=0$ the parametrization has a logarithmic singularity ($x\to-\infty$), which is an asymptote of the solution curve, not a domain violation. The negative branch $y=-p\sqrt{1-p}$ was also checked with \texttt{sympy}: it yields the mirror solution $x=-3\sqrt{1-p}-\ln\left|\frac{1-\sqrt{1-p}}{1+\sqrt{1-p}}\right|+C$, i.e. the same family reflected through the origin, and requires no separate derivation.