Solve the differential equation: $$x \frac{dy}{dx} = y(3-y)$$ where $x=2$ when $y=2$, giving $y$ as a function of $x$.
Can someone solve this and then explain what the second line about $x=2$, $y=2$ means?
Solve the differential equation: $$x \frac{dy}{dx} = y(3-y)$$ where $x=2$ when $y=2$, giving $y$ as a function of $x$.
Can someone solve this and then explain what the second line about $x=2$, $y=2$ means?
So you want to "solve" the initial value problem:
$\begin{cases} x y^\prime (x) = y(x)\ (3-y(x)) \\ y(2)=2 \end{cases}$.
Your ODE has a singular point in $x=0$ (for the coefficient of the $y^\prime (x)$ term vanishes), hence if the IVP has a solution it will have not to be defined in $x=0$.
Put the ODE in normal form, i.e. rewrite:
$\displaystyle y^\prime (x) =\frac{y(x)\ (3-y(x))}{x}$;
the function $f(x,y):= \frac{y (3-y)}{x}$ is of class $C^\infty$ in $(x,y)\in \Big(]-\infty ,0[\cup ]0,+\infty[\Big)\times \mathbb{R}$, hence the existence and uniqueness theorem applies and your IVP has unique local solution $y(x)$ whose graph passes through the point $(2,2)$.
The solution $y(x)$ is continuous in a neighbourhood $I_1$ of $x=2$ (because it has to be differentiable to satisfy the ODE), hence the composite function $f(x,y(x))$ is continuous in $I_1$; as $y^\prime (x)=f(x,y(x))$, then $y^\prime (x)$ is continuous in $I_1$, therefore $y(x)$ is a $C^1$ function in $I_1$. But then $y^\prime (x)$ is of class $C^1$ in $I_1$, for the composite function $f(x,y(x))$ is of class $C^1$ (apply the chain rule); therefore $y(x)$ is of class $C^2$... Bootstrapping, you see that $y(x)$ is of class $C^\infty$ in the neighbourhood $I_1$ of the initial point $2$.
Moreover, the solution $y(x)$ is also strictly increasing in a neighbourhood of $2$: in fact, $y(2)=2>0$ hence by continuity you can find a neighbourhood $I_2\subseteq I_1$ of $2$ in which $0<y(x)<3$, so:
$\displaystyle y^\prime (x)=\frac{y(x)\ (3-y(x))}{x} >0$,
thus $y(x)$ increases strictly.
Now you have all the ingredients to properly solve your problem: in fact, in $I_2$ you can divide both sides of the ODE by $y(x)\ (3-y(x))$ and rewrite:
$\displaystyle \frac{y^\prime (x)}{y(x)\ (3-y(x))} =\frac{1}{x}$;
now fix a point $x \in I_2$ and integrate both sides from $2$ to $x$:
$\displaystyle \int_2^x \frac{y^\prime (t)}{y(t)\ (3-y(t))}\ \text{d} t =\int_2^x \frac{1}{t}\ \text{d} t$
(I've introduced a dummy variable in the integrals); now the RHside gives you $\ln x -\ln 2$, hence you have to work on the LHside. Keeping in mind that $y(t)$ is strictly monotone hence invertible in $I_2$, we can make the change of variable $\theta =y(t)$: as $y(2)=2$ and $\text{d} \theta = y^\prime (t)\ \text{d} t$, you get:
$\displaystyle \begin{split}\int_2^x \frac{y^\prime (t)}{y(t)\ (3-y(t))}\ \text{d} t &= \int_2^{y(x)} \frac{1}{\theta (3-\theta)}\ \text{d} \theta \\ &=\frac{1}{3} \ln \theta - \frac{1}{3} \ln (3-\theta) \Big|_2^{y(x)} \\ &=\frac{1}{3} \left(\ln y(x) -\ln (3-y(x)) -\ln 2\right)\end{split}$.
Therefore the solution to your problem is implicitly determined by the equation:
$\displaystyle \ln \left( \frac{y(x)}{3-y(x)}\right) = \ln \frac{x^3}{4}$,
i.e.:
$\displaystyle \frac{4y(x)}{3-y(x)}=x^3$.
The latter equation is a rational algebraic equation w.r.t. $y(x)$ and can be solved with the usual tools, which yield:
$\displaystyle y(x)=\frac{3x^3}{4+x^3}$.
There is more that can be said, e.g. how the local solution $y(x)$ can be extended to a maximal solution... But that's another story.
its a simple problem just using separation of variable $ \ xy'=y(y-3)$ now using separation of variable the we ge $ \ {dy} \over{y(y-3)} $=$\ {dx} \over{x}$ just using partial fraction then $\ {1}\over{y(y-3)}$= $\ {A}\over{y}$+$\ {B}\over{(y-3)}$$\ {....>}$ eq (1) putting y=0,y=3 we get A=1/3,B=1/3 then putting in eq 1 and the integrated both side to get over solution interm of constant . then applying initial condition y(2)=2 to get c and then back substituited in general to get our required solution.
This is just an Initial Value Problem. You use the techniques you know to solve for the general solution. Here is a good resource: http://tutorial.math.lamar.edu/Classes/DE/Linear.aspx. More specifically, you should look at "Separable Equations"
The general solution in this case will have one arbitrary constant. You use the I.V.P to solve for this constant.
This is easy because it's separable variables. So solve $dy/(y(3-y))=dx/x$.