# solve the differential equation (2xy+3y^2)dx-(2xy+x^2)dy=0

*print*Print*list*Cite

### 1 Answer

You should come up with the following substitution such that:

`y = x*u(x)`

Differentiating with respect to x, using the product rule, yields:

`(dy)/(dx) = u(x) + x(du(x))/(dx)`

You need to write the equation such that:

`2xy + 3y^2 + (2xy+x^2)(-(dy)/(dx)) = ` 0

Substituting `x*u(x)` for y and `u(x) + x(du(x))/(dx)` for `(dy)/(dx)` :

`2x*x*u(x) + 3x^2u^2(x) + (2x^2u(x) + x^2)(-u(x)-x(du(x))/(dx)) = 0`

You need to factor out `x^2` such that:

`x^2(2u(x) + 3u^2(x)- 2u^2(x) - 2x*u(x)(du(x))/(dx) - u(x) - x(du(x))/(dx)) = 0`

`x^2(u(x) + u^2(x) - x(du(x))/(dx) - 2x*u(x)(du(x))/(dx)) = 0`

You need to divide by `x^2` such that:

`u(x) + u^2(x) - x(du(x))/(dx) - 2x*u(x)(du(x))/(dx) = 0`

You need to isolate the terms that contain (du(x))/(dx) to the left side such that:

`(du(x))/(dx)(-x - 2x*u(x)) = -u(x)- u^2(x)`

`(du(x))/(dx) = (u(x) + u^2(x))/(x(1 + 2u(x)))`

You need to separate the variables such that:

`(1 + 2u(x))/(u(x) + u^2(x)) du(x) = (dx)/x`

You need to integrate both sides such that:

`int (1 + 2u(x))/(u(x) + u^2(x)) du(x) = int (dx)/x`

You should use substitution to solve the indefinite integral to the left side such that:

`u(x) + u^2(x) = t => (1 + 2u(x))du(x) = dt`

`int (dt)/t = int (dx)/x`

`ln(u(x) + u^2(x)) = ln x + c => ln(u(x)(1 + u(x))) = ln x + c`

Using logarithmic identities yields:

`ln u(x) + ln(u(x) + 1) = ln x + c`

`u(x) + u^2(x) = e^(ln x + c) =>u^2(x) -u(x) - e^(ln x + c) = 0`

You need to use quadratic formula such that:

`u(x)_(1,2) = (-1+-sqrt(1 + 4e^(ln x + c)))/2`

You need to substitute back `x*u(x)` for y such that:

`y_(1,2) = (-x+-xsqrt(1 + 4e^(ln x + c)))/2`

**Hence, evaluating the solutions to the given first order non-lineary differential equation yields `y_(1,2) = (-x+-xsqrt(1 + 4e^(ln x + c)))/2.` **