MHB Solving a first-order differential equation

Click For Summary
The discussion revolves around solving a specific first-order differential equation, which is identified as exact due to the condition that the partial derivatives of its components are equal. The initial attempt to solve the equation leads to an incorrect solution, prompting a request for clarification on the correct method. The correct approach involves integrating the first term with respect to x and recognizing the need for an arbitrary function of y, which is derived through differentiation. Ultimately, the solution is refined to a more accurate expression, and participants express a commitment to practicing further on exact differential equations.
Saitama
Messages
4,244
Reaction score
93
Problem:
Solve the differential equation:
$$\left(\frac{1}{x}-\frac{y^2}{(x-y)^2}\right)\,dx+\left(\frac{x^2}{(x-y)^2}-\frac{1}{y}\right)\,dy=0$$

Attempt:
Let
$$M=\left(\frac{1}{x}-\frac{y^2}{(x-y)^2}\right)$$
and
$$N=\left(\frac{x^2}{(x-y)^2}-\frac{1}{y}\right)$$
I noticed that
$$\frac{\partial M}{\partial y}=\frac{\partial N}{\partial x}$$
Hence, the given D.E is an exact D.E. Thus the solution of the D.E is:
$$y=\int M (\text{y constant}) \,dx+\int N (\text{terms independent of x})\,dy$$
The first integral is:
$$\int M\,dx=\ln x+\frac{y^2}{x-y}$$
The second integral is:
$$\int N\,dy=\int \frac{-1}{y} \,dy=-\ln y$$
Hence, the solution is:
$$y=\ln \frac{x}{y}+\frac{y^2}{x-y}+C$$
But this is incorrect. :confused:

Any help is appreciated. Thanks!
 
Physics news on Phys.org
Pranav said:
Problem:
Solve the differential equation:
$$\left(\frac{1}{x}-\frac{y^2}{(x-y)^2}\right)\,dx+\left(\frac{x^2}{(x-y)^2}-\frac{1}{y}\right)\,dy=0$$

Attempt:
Let
$$M=\left(\frac{1}{x}-\frac{y^2}{(x-y)^2}\right)$$
and
$$N=\left(\frac{x^2}{(x-y)^2}-\frac{1}{y}\right)$$
I noticed that
$$\frac{\partial M}{\partial y}=\frac{\partial N}{\partial x}$$
Hence, the given D.E is an exact D.E. Thus the solution of the D.E is:
$$y=\int M (\text{y constant}) \,dx+\int N (\text{terms independent of x})\,dy$$
The first integral is:
$$\int M\,dx=\ln x+\frac{y^2}{x-y}$$
The second integral is:
$$\int N\,dy=\int \frac{-1}{y} \,dy=-\ln y$$

This is incorrect, because the first term of $N$ has a $y$ in it.

Here's how I was taught to do exact equations: your goal is to recognize that if the equation is exact, it can be made to look like this:
$$f_x(x,y) \, dx+f_y(x,y) \, dy=0.$$
Hence, you integrate the first term w.r.t. (that's an abbreviation for "with respect to") $x$, and that's your solution $f(x,y)$. But it'll have an arbitrary function of $y$ in it that you have to get a handle on. In your case,
$$f(x,y)= \frac{y^2}{x-y}+ \ln(x)+g(y).$$
So, we differentiate w.r.t. $y$ to obtain
$$f_y(x,y)= \frac{y(2x-y)}{(x-y)^2}+g'(y),$$
which we set equal to what it should be. That is, we set
$$ \frac{y(2x-y)}{(x-y)^2}+g'(y)= \frac{x^2}{(x-y)^2}- \frac{1}{y}.$$
Solving for $g'(y)$ yields
$$g'(y)= \frac{y-1}{y}.$$
Integrating yields
$$g(y)=y- \ln(y)+C.$$
Hence, the solution is
$$f(x,y)= \frac{y^2}{x-y}+y+ \ln \left( \frac{x}{y} \right)+C.$$
 
Hi Ackbach! :)

Ackbach said:
Here's how I was taught to do exact equations: your goal is to recognize that if the equation is exact, it can be made to look like this:
$$f_x(x,y) \, dx+f_y(x,y) \, dy=0.$$

Sorry if this is going to be silly but how do I make it look like that in the given case? Is the following condition:
$$\frac{\partial M}{\partial y}=\frac{\partial N}{\partial x}$$
of no use while solving the exact D.Es? :confused:

I understand what you have done after this.

Sorry for the delay in reply. :o
 
Pranav said:
Hi Ackbach! :) Sorry if this is going to be silly

Not silly at all, I assure you.

but how do I make it look like that in the given case?

By following the procedure I outlined in the previous post. The result of that procedure is $f(x,y)$, which you can differentiate to obtain either $f_x$ or $f_y$. If you have
$$f_x(x,y) \, dx+ f_y(x,y) \, dy=0,$$
then you solve the DE by integrating to obtain $f(x,y)=C$.

Is the following condition:
$$\frac{\partial M}{\partial y}=\frac{\partial N}{\partial x}$$
of no use while solving the exact D.Es? :confused:

It is definitely of use. Without knowing that this is the case, you cannot know in advance whether the procedure I outlined (or your integration method, assuming it's correct) will work.

I understand what you have done after this.

Sorry for the delay in reply. :o

We're pretty laid-back here, so no problem, mate.
 
Ackbach said:
By following the procedure I outlined in the previous post. The result of that procedure is $f(x,y)$, which you can differentiate to obtain either $f_x$ or $f_y$. If you have
$$f_x(x,y) \, dx+ f_y(x,y) \, dy=0,$$
then you solve the DE by integrating to obtain $f(x,y)=C$.

It is definitely of use. Without knowing that this is the case, you cannot know in advance whether the procedure I outlined (or your integration method, assuming it's correct) will work.

Thanks a lot Ackbach! I think I understand the procedure. Will be practicing some more questions to make myself comfortable with exact D.Es. :)
 

Similar threads

  • · Replies 16 ·
Replies
16
Views
3K
  • · Replies 1 ·
Replies
1
Views
548
  • · Replies 3 ·
Replies
3
Views
4K
  • · Replies 3 ·
Replies
3
Views
998
  • · Replies 1 ·
Replies
1
Views
1K
Replies
2
Views
2K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 3 ·
Replies
3
Views
2K