# Homework Help: Finding the integrating factor (ODEs)

1. Oct 1, 2009

### Novark

Finding the integrating factor (ODEs) [Solved]

Working on this problem, I can't figure out why we take the derivative of $$\mu$$ with respect to y, and what to do when our integrating factor is a function of both x and y. In the case below, it ended up being separable, but what can you do if it's not?

1. The problem statement, all variables and given/known data

Find an integrating factor and solve the given equation.

$$y{\cdot}dx + (2xy - e^{-2y}){\cdot}dy = 0$$

2. Relevant equations

$$\frac{d\mu}{dy} = \frac{M_y - N_x}{N}{\cdot}\mu$$

3. The attempt at a solution

$$M(x,y) = y$$
$$N(x,y) = (2xy - e^{-2y})$$

So,

$$M_y = 1$$
$$N_x = 2y$$

$$\frac{d\mu}{dy} = \frac{1 - 2y}{(2xy - e^{-2y})}{\cdot}\mu \Rightarrow \frac{d\mu}{\mu} = \frac{1 - 2y}{(2xy - e^{-2y})}{\cdot}dy$$

$$ln(\mu) = \int{\frac{1 - 2y}{(2xy - e^{-2y})}}{\cdot}dy$$

If someone could refresh me on the methods to integrate the above, that would also be much appreciated. What I really want to know, however, is why we choose $$\mu$$ with respect to y instead of x, and how to find our integrating factor when $$\mu$$ is not separable.

Last edited: Oct 2, 2009
2. Oct 1, 2009

### LCKurtz

First, you need to realize that, just as an equation may not be exact, it may also not have an integrating factor that is a pure function of just x or y. Say you start with:

M(x,y)dx + N(x,y)dy = 0

Of course your first test would be to see if Nx = My. If so, it is exact and you proceed with exact methods. But what if it isn't exact. Maybe, if we are lucky, we can find an integrating factor of the form μ(x) or μ(y) that will make it exact. So let's try it:

μ(x)M(x,y)dx + μ(x)N(x,y)dy = 0

Let's try the exactness test on this. We need

(μ(x)N(x,y))x = (μ(x)M(x,y))y

μ'(x)N(x,y) + μ(x)Nx(x,y) = μ(x)My(x,y)

$$\mu'(x) = \frac {\mu(x)(M_y(x,y) - N_x(x,y))}{N(x,y)}$$

We can only hope to find μ(x) as a pure function of x if there are no y's on the right hand side. So before we even try to find such a μ(x), we should test the given equation to see if

$$\frac {M_y(x,y) - N_x(x,y)}{N(x,y)}$$

is a pure function of x.

Trying the same thing for a pure function of y we get:

μ(y)M(x,y)dx + μ(y)N(x,y)dy = 0

Testing for exactness:

μ(y)Nx(x,y) = μ(y)My(x,y) + μ'(y)M(x,y)

$$\mu'(y) = \frac {\mu(y)(N_x(x,y) - M_y(x,y))}{M(x,y)}$$

For this to work there needs to be no x on the right side, so:

$$\frac {M_y(x,y) - N_x(x,y)}{M(x,y)}$$

must be a pure function of y.

In your example, neither of the two tests work, which explains why you didn't get a pure function of y to integrate and your method failed.

Last edited: Oct 2, 2009
3. Oct 1, 2009

### Novark

Thanks for the reply LC - I understand what you're saying.

In this case, however - my professor said that the integrating factor $$\mu$$ is a function of y only.

How should I proceed with finding my function $$\mu$$ by integrating with respect to y, and how will this affect the rest of the problem?

Last edited: Oct 1, 2009
4. Oct 1, 2009

### LCKurtz

The above test shows that a pure function of y can't be an integrating factor. Maybe the problem has a typo or something.

5. Oct 2, 2009

### Novark

I just checked the answer at the back of the book, it gives the following answers:

$${\mu}(y) = \frac{e^{2y}}{y}$$

$$xe^{2y}-ln|y| = c$$

$$y = 0$$

I've written the question down correctly, too. Do I have an error in my math anywhere? I've checked it over, and I think it is correct...

Any ideas?

6. Oct 2, 2009

### LCKurtz

Hmmm, that looks correct. Unless I have a mistake, apparently the condition above is sufficient but not necessary. I'll have to think about it some more tomorrow. Interesting.

7. Oct 2, 2009

### Novark

Still no luck in figuring this one out...

Anyone have any ideas?

8. Oct 2, 2009

### LCKurtz

Hello Novark. I finally had time this morning to get back to this. There was a typo in my post in the test for an integrating factor just a function of y. I have edited and corrected it. To test for an integrating factor a pure function of y you need:

$$\frac {N_x(x,y) - M_y(x,y)}{M(x,y)}$$

to be a function of y only. I had mis-typed the denominator as N(x,y). You will see that your equation does indeed satisfy this criteria which is why you could find a function of y for an integrating factor.

(At least I tried to edit that post to fix the denominator. It looks corrected when I try to edit it but it is still displaying wrong at the moment)

Last edited: Oct 2, 2009
9. Oct 2, 2009

### Novark

Makes perfect sense now!

Thanks again LC!