# Thread: Separating the variables or some other way?

1. ## Separating the variables or some other way?

Hello all,

I'm being confused by a differential equation problem. Solve:

(2x + 4x^2) dy/dx = e^y

My approach has been to transfer the function of x to the right i.e. 1/it and then the e^y to the right yielding e^-y, and then the usual separating the variables method with partial fractions to integrate the right hand side. However, to find y, I ultimately end up with the log of a log, and I was wondering if this is bad news, and whether I should perhaps be using an entirely different method.

Any help appreciated.

2. Originally Posted by DangerousDave
Hello all,

I'm being confused by a differential equation problem. Solve:

(2x + 4x^2) dy/dx = e^y

My approach has been to transfer the function of x to the right i.e. 1/it and then the e^y to the right yielding e^-y, and then the usual separating the variables method with partial fractions to integrate the right hand side. However, to find y, I ultimately end up with the log of a log, and I was wondering if this is bad news, and whether I should perhaps be using an entirely different method.

Any help appreciated.
$(2x + 4x^2) \frac{dy}{dx} = e^y$

$e^{-y} dy = \frac{1}{x(2+4x)} dx$

Your original conclusion that this is a seperable equation and that you must use partial fractions on the R.H.S is correct.

Let's just work through it.

Partial Fractions,

$\frac{A}{x} + \frac{B}{2+4x} = \frac{A(2+4x) + B(x)}{x(2+4x)}$

$2A = 1$

$4A + B = 0$

$A= \frac{1}{2}$ and $B = -2$

So the R.H.S becomes

$\frac{1}{2} \int \frac{1}{x} dx - 2 \int \frac{1}{2+4x}dx$

$\frac{1}{2} lnx - \frac{1}{2} ln(2+4x) + C$

So far so good.

Now the L.H.S

$\int e^{-y} dy = - e^{-y}$

L.H.S = R.H.S

$-e^{-y}=\frac{1}{2} lnx - \frac{1}{2} ln(2+4x) + C$

$e^{-y}=\frac{1}{2} ln(2+4x) - \frac{1}{2} lnx - C$

Clearly to bring down Y we would use ln as you suggested. Is there any problem with having (as an example)

$ln ( \frac{1}{2} ln(2+4x) )$

$\frac{1}{2} ln(2+4x)$

Well, this will evaluate to a number! So essentially, we'll have ln(some number) which is clearly no problem. So to answer your question, this is not a problem.

But you should note for

$ln ( \frac{1}{2} ln(2+4x) )$

We have the restriction that,

$\frac{1}{2} ln(2+4x) \ge 1$

Other then that, we are fine!

3. Originally Posted by DangerousDave
Hello all,

I'm being confused by a differential equation problem. Solve:

(2x + 4x^2) dy/dx = e^y

My approach has been to transfer the function of x to the right i.e. 1/it and then the e^y to the right yielding e^-y, and then the usual separating the variables method with partial fractions to integrate the right hand side. However, to find y, I ultimately end up with the log of a log, and I was wondering if this is bad news, and whether I should perhaps be using an entirely different method.

Any help appreciated.
$\frac{dx}{2x+4x^2}=\frac{dy}{e^Y}\Rightarrow$

$\int\frac{dx}{2x+4x^2}=\int\frac{dy}{e^y}$

By partial fractions, we obtain:

$\frac{1}{2}\int\frac{1}{x}dx-\int\frac{1}{1+2x}dx=-e^{-y}$

Try finishing from here.

4. Originally Posted by dwsmith
$\frac{dx}{2x+4x^2}=\frac{dy}{e^Y}\Rightarrow$

$\int\frac{dx}{2x+4x^2}=\int\frac{dy}{e^y}$

By partial fractions, we obtain:

$\frac{1}{2}\int\frac{1}{x}dx-\int\frac{1}{1+2x}dx=-e^{-y}$

Try finishing from here.
He can solve the problem. He wanted to know if there's any implication of having

$ln(ln(something))$

Which is what you'll get when you finish this problem.

5. Many thanks for your help. Is it definitely going to be a log of a log in the answer then? There is no alternative method that will produce an alternative neater formulation? (I only ask because these problems usually seem to pan out a bit neater, and when it's messy(ish) then I start to think I did it wrong)