# how to solve this differential equation which cannot be reduced to homogeneous using standard methods

I came across this interesting question.

$$(y^2 + xy + 1)\,dx + (x^2 + xy + 1)\,dy =0.$$

I tried to make it homogeneous by using an integrating factor but could not proceed through.

NOTE: I am asking a question first time in this forum and don't know the exact format on how to ask a good question.

• You might start by putting $y(x)=z(x)-x$. That simplifies it a little. I think you can then solve it in terms of exponentials and the error function, but the result is not pretty. – almagest Sep 10 '14 at 18:11
• result is very pretty..final answer is (e^(xy))*(x+y) – PRP Sep 10 '14 at 18:14
• it.wikipedia.org/wiki/… Check this one: it is in italian but you don't really need the text, just the maths. It should be a case a bit more complicate than: en.wikipedia.org/wiki/Exact_differential_equation . Hope it helps! – MattAllegro Sep 10 '14 at 18:15

Rewrite as: $(x^2+x y(x)+1)y'(x)+y(x)^2+x y(x)+1 = 0$

Let $y(x) = \frac{v(x)-x^2-1}{x}$, which gives $y'(x)= \frac{v'(x)-2 x}{x}-\frac{v(x)-x^2-1}{x^2}$

Then $$-x^2+\frac{(-x^2+v(x)-1)^2}{x^2}+v(x)+(-2 x+v'(x)-\frac{-x^2+v(x)-1}{x^2}) v(x) = 0 \iff \frac{2 x^2+(-2 x^2+x v'(x)-1) v(x)+1}{x^2} = 0 \iff v'(x) = \frac{(2 x^2+1) (v(x)-1)}{x v(x)}$$ Then you have to divide both sides by $\frac{v(x)-1}{v(x)}$ and then integrate both sides with respect to $x$

$$\int \frac{v'(x) v(x)}{v(x)-1} \mathrm{d}x = \int \frac{2 x^2+1}{x} \mathrm{d}x \iff \log(v(x)-1)+v(x) = x^2+\log(x)+c_1$$ Now it gets kinda tricky, you have to use the Lambert-W function to solve for $v(x)$, but here goes;(I simplify constants too) $$v(x) = W(c_1 e^{x^2-1} x)+1$$ Sub $y(x)$ back; $$x^2+x y(x)+1 = W(c_1 e^{x^2-1} x)+1 \iff y(x) = \frac{-x^2+W(c_1 e^{x^2-1} x)}{x}$$

• answer is (e^(xy))*(x+y) – PRP Sep 10 '14 at 18:27
• I'm pretty sure this is the result as I checked for mistakes, according to the other answer, maple gives the same result too. Wolfram alpha gives a weird result that can be simplified to my result(I suppose, I didn't try it). – UserX Sep 10 '14 at 18:38
• are you saying (e^(xy))*(x+y) = c is wrong....? – PRP Sep 10 '14 at 18:40
• For this DE? I think so. – UserX Sep 10 '14 at 18:43
• @PRP Can you show solution is (x+y)e^(xy) ?? – MattAllegro Sep 10 '14 at 20:26