Problem 215
Easy Trajectories

Solve (x+2y+1)y'-(x+2y-1)=0

Solve $(x+2y+1)y'-(x+2y-1)=0$.

Explanation of Method

Independently re-derive the substitution $u=x+2y$, the separable reduction, and the partial-fractions-style integration with \texttt{sympy}, then re-verify the final implicit relation (and its exponential alternative form) by implicit differentiation, confirming the original ODE is reproduced exactly.

Step 1: Confirm the substitution and separable reduction

With $u=x+2y$, $\dfrac{dy}{dx}=\tfrac12\!\left(\dfrac{du}{dx}-1\right)$, and $\dfrac{dy}{dx}=\dfrac{u-1}{u+1}$, \texttt{sympy} confirms $\dfrac{du}{dx}=\dfrac{3u-1}{u+1}$, matching the source exactly.

Step 2: Confirm the integration independently

\texttt{sp.integrate}$\!\left(\dfrac{u+1}{3u-1},u\right)=\dfrac{u}{3}+\dfrac49\ln|3u-1|$, matching the source's result term-by-term. Multiplying by $9$ and back-substituting $u=x+2y$ reproduces $3(x+2y)+4\ln|3x+6y-1|=9x+C_2$, and simplifying gives the source's stated forms \[3y+2\ln|3x+6y-1|=3x+C\qquad\Longleftrightarrow\qquad 3x+6y-1=Ke^{\frac{3(x-y)}{2}}.\]

Step 3: Verify both forms by implicit differentiation from scratch

Implicit-differentiating $F=3y+2\ln|3x+6y-1|-3x=0$ with \texttt{sympy} and solving $F_x+F_yy'=0$ for $y'$ gives $y'=\dfrac{x+2y-1}{x+2y+1}$ — \texttt{sympy}-confirmed identical to the original ODE's own $y'=\dfrac{x+2y-1}{x+2y+1}$, residual $0$. Separately, implicit-differentiating the exponential form $3x+6y-1=Ke^{3(x-y)/2}$, then eliminating $K$ using the same relation, gives the identical result $y'=\dfrac{x+2y-1}{x+2y+1}$, residual $0$ — both forms check out independently, confirming the source's own verification (step 9) was correct.


Result

Final answer:

Every step reproduced independently with \texttt{sympy}, including both boxed forms of the answer, each confirmed by implicit differentiation to exactly reproduce the original ODE: \[\boxed{\,3y+2\ln|3x+6y-1|=3x+C\,}\qquad\text{equivalently}\qquad\boxed{\,3x+6y-1=Ke^{\frac{3(x-y)}{2}}\,}\]