#### 1.18 Example 18

$y=xy^{\prime }+ay^{\prime }\left ( 1-y^{\prime }\right )$ Applying p-discriminant method gives\begin {align*} F & =-y+xy^{\prime }+ay^{\prime }\left ( 1-y^{\prime }\right ) =0\\ \frac {\partial F}{\partial y^{\prime }} & =x+a\left ( 1-y^{\prime }\right ) -ay^{\prime }=0\\ & =a+x-2ay^{\prime }=0 \end {align*}

We ﬁrst check that $$\frac {\partial F}{\partial y}=-1\neq 0$$.  Now we apply p-discriminant.  Eliminating $$y^{\prime }$$. Second equation gives $$y^{\prime }=\frac {a+x}{2a}$$. Substituting in the ﬁrst equation gives \begin {align*} -y+x\left ( \frac {a+x}{2a}\right ) +a\left ( \frac {a+x}{2a}\right ) \left ( 1-\left ( \frac {a+x}{2a}\right ) \right ) & =0\\ \frac {1}{4a}\left ( a^{2}+2ax-4ya+x^{2}\right ) & =0\\ y_{s} & =\frac {\left ( x+a\right ) ^{2}}{4a}\qquad a\neq 0 \end {align*}

Now we check if this satisﬁes the ode itself. We see it does. The general solution can be found to be $\Psi \left ( x,y,c\right ) =y-cx-ac\left ( 1-c\right ) =0$ Hence \begin {align*} \Psi \left ( x,y,c\right ) & =y-cx-ac\left ( 1-c\right ) =0\\ \frac {\partial \Psi \left ( x,y,c\right ) }{\partial c} & =-x-a\left ( 1-c\right ) +ac=0 \end {align*}

Eliminating $$c$$. Second equation gives $$c=\frac {a+x}{2a}$$. Substituting into the general solution gives\begin {align*} y-\left ( \frac {a+x}{2a}\right ) x-a\left ( \frac {a+x}{2a}\right ) \left ( 1-\left ( \frac {a+x}{2a}\right ) \right ) & =0\\ y_{s} & =\frac {\left ( x+a\right ) ^{2}}{4a}\qquad a\neq 0 \end {align*}

Which is the same obtained using p-discriminant. Hence this is the singular solution. The following plot shows the singular solution as the envelope of the family of general solution plotted using diﬀerent values of $$c$$. For this, $$a=1$$ was used.