• Support PF! Buy your school textbooks, materials and every day products Here!

Solve ODE reducible to exact equation

  • Thread starter mahler1
  • Start date
  • #1
222
0
Homework Statement .

Find all the solutions of the equation:
##\dfrac{\sin(y)}{x}dx+(\dfrac{y}{x}\cos(y)-\dfrac{\sin(y)}{y})dy=0## knowing that the equation admits an integrating factor ##u## of the form ##u(x,y)=h(\dfrac{x}{y})##

The attempt at a solution.

If I call ##M(x,y)=\dfrac{\sin(y)}{x}## and ##N(x,y)=\dfrac{y}{x}\cos(y)-\dfrac{\sin(y)}{y}## then, in order to be an exact differential equation, ##M## and ##N## must satisfy ##M_y=N_x##, but ##M_y=\dfrac{\cos(y)}{x}≠-\dfrac{y\cos(y)}{x^2}=N_x##, so this is not an exact differential equation.

As the exercise suggests, I've tried to propose an integrating factor ##u## of the form ##u(x,y)=h(\dfrac{x}{y})##, but, since up to know I've only solved equations where the integrating factor depended just on one of the variables, I got stuck in the middle of the problem.

So, ##u## must satisfy:

##(uM)dx+(uN)dy=0##

Then, ##(uM)_y=(uN)_x \iff u_yM+uM_y=u_xN+uN_x \iff xh_yM+hM_y=\dfrac{1}{y}h_xN+hN_x##.

Calculating all these partial derivatives gives:

##xh_y\dfrac{\sin(y)}{x}+h\dfrac{\cos(y)}{x}=\dfrac{1}{y}h_x(\dfrac{ycos(y)}{x}-\dfrac{\sin(y)}{y})+h(-\dfrac{ycos(y)}{x^2})##

At this point I got stuck and I don't know what and how to integrate in order to find ##u(x,y)##
 

Answers and Replies

  • #2
vela
Staff Emeritus
Science Advisor
Homework Helper
Education Advisor
14,632
1,268
You didn't differentiate correctly. You should have, for example,
\begin{align*}
(uM)_y &= \frac{\partial}{\partial y} \left[ h\left(\frac{x}{y}\right) \frac{\sin y}{x}\right] \\
&= h'\left(\frac{x}{y}\right)\left(-\frac{x}{y^2}\right) \frac{\sin y}{x} + h\left(\frac{x}{y}\right) \frac{\cos y}{x} \\
&= -h'\left(\frac{x}{y}\right) \frac{\sin y}{y^2} + h\left(\frac{x}{y}\right) \frac{\cos y}{x}
\end{align*}
 
  • Like
Likes 1 person
  • #3
222
0
You didn't differentiate correctly. You should have, for example,
\begin{align*}
(uM)_y &= \frac{\partial}{\partial y} \left[ h\left(\frac{x}{y}\right) \frac{\sin y}{x}\right] \\
&= h'\left(\frac{x}{y}\right)\left(-\frac{x}{y^2}\right) \frac{\sin y}{x} + h\left(\frac{x}{y}\right) \frac{\cos y}{x} \\
&= -h'\left(\frac{x}{y}\right) \frac{\sin y}{y^2} + h\left(\frac{x}{y}\right) \frac{\cos y}{x}
\end{align*}
Thanks, I'll correct it and see if I can get a nicer expression.
 
  • #4
222
0
You didn't differentiate correctly. You should have, for example,
\begin{align*}
(uM)_y &= \frac{\partial}{\partial y} \left[ h\left(\frac{x}{y}\right) \frac{\sin y}{x}\right] \\
&= h'\left(\frac{x}{y}\right)\left(-\frac{x}{y^2}\right) \frac{\sin y}{x} + h\left(\frac{x}{y}\right) \frac{\cos y}{x} \\
&= -h'\left(\frac{x}{y}\right) \frac{\sin y}{y^2} + h\left(\frac{x}{y}\right) \frac{\cos y}{x}
\end{align*}
After vela's correction, I got:

##(uM)_y=-h'(\dfrac{x}{y})(\dfrac{\sin(y)}{y^2})+h(\dfrac{x}{y})(\dfrac{\cos(y)}{x})##.
##(uN)_x=h'(\dfrac{x}{y})(\dfrac{\cos(y)}{x}-\dfrac{\sin(y)}{y^2})-h(\dfrac{x}{y})\dfrac{y\cos(y)}{x^2})##.
So, ##(uM)_y=(uN)_x## if and only if

##-h'(\dfrac{x}{y})\dfrac{\sin(y)}{y^2}+h(\dfrac{x}{y})\dfrac{\cos(y)}{x}=h'(\dfrac{x}{y})(\dfrac{\cos(y)}{x}-\dfrac{\sin(y)}{y^2})-h(\dfrac{x}{y})\dfrac{y\cos(y)}{x^2})## if and only if

##h(\dfrac{x}{y})\dfrac{\cos(y)}{x}=h'(\dfrac{x}{y})(\dfrac{\cos(y)}{x})-h(\dfrac{x}{y})\dfrac{y\cos(y)}{x^2})##.

Then

##h(\dfrac{x}{y})(\dfrac{\cos(y)}{x}+\dfrac{y\cos(y)}{x^2})=h'(\dfrac{x}{y})(\dfrac{\cos(y)}{x})##

##1+\dfrac{y}{x}=\dfrac{h'\dfrac{x}{y}}{h\dfrac{x}{y}}##. If I make the substitution ##z=\dfrac{x}{y}##, then the equation reduces to:

##1+\dfrac{1}{z}=\dfrac{h'(z)}{h(z)}##.

So

##\int (1+\dfrac{1}{z})dz=\int \dfrac{dh}{h} \iff z+ln(z)+k=ln(h)##.

Then, ##h=ze^z=\dfrac{x}{y}e^{\dfrac{x}{y}}##. Now I have to go back to the original equation, which it will be reduced to an exact equation by this integrating factor.

Is this correct?
 
  • #5
vela
Staff Emeritus
Science Advisor
Homework Helper
Education Advisor
14,632
1,268
Yes, it is!
 
  • Like
Likes 1 person
  • #7
lurflurf
Homework Helper
2,432
132
Good work.
Let me offer a suggestion.
I would change variable z=x/y first to make things less messy
$$\frac{\sin(y)}{x}\mathrm{d}x+\left( \frac{y}{x}\cos(y)-\frac{\sin(y)}{y}\right)\mathrm{d}y=0\\
\text{becomes}\\
\sin(y)\frac{\mathrm{d}z}{z}+\frac{1}{z}\cos(y)\mathrm{d}y=0$$
 
  • Like
Likes 1 person
  • #8
222
0
Good work.
Let me offer a suggestion.
I would change variable z=x/y first to make things less messy
$$\frac{\sin(y)}{x}\mathrm{d}x+\left( \frac{y}{x}\cos(y)-\frac{\sin(y)}{y}\right)\mathrm{d}y=0\\
\text{becomes}\\
\sin(y)\frac{\mathrm{d}z}{z}+\frac{1}{z}\cos(y)\mathrm{d}y=0$$
Good remark.
 

Related Threads on Solve ODE reducible to exact equation

  • Last Post
Replies
4
Views
2K
  • Last Post
Replies
2
Views
1K
Replies
5
Views
3K
Replies
4
Views
1K
Replies
7
Views
1K
  • Last Post
Replies
2
Views
1K
Replies
10
Views
298
  • Last Post
Replies
2
Views
805
  • Last Post
Replies
11
Views
2K
  • Last Post
Replies
3
Views
7K
Top