# Thread: Homogeneous DE of the first order

1. ## Homogeneous DE of the first order

I must solve $\displaystyle \dot x + x\cos t=0$.
I realize it's separable, and solving it I reach $\displaystyle x=e^{-\sin (t) + C}$ where $\displaystyle C$ is a constant.

However, solving it via the integrating factor method, I do not reach the same result.
The IF is $\displaystyle e^{\sin t}$.
Multiplying both sides by it, I get $\displaystyle \frac{dx}{dt} e^{\sin t}+x\cos (t) e^{\sin t}=0$.
Integrating with respect to t, I get $\displaystyle e^{\sin t}x=0$.
Now clearly $\displaystyle x\equiv 0$.
What am I doing wrong?

2. Originally Posted by arbolis
I must solve $\displaystyle \dot x + x\cos t=0$.
I realize it's separable, and solving it I reach $\displaystyle x=e^{-\sin (t) + C}$ where $\displaystyle C$ is a constant.

However, solving it via the integrating factor method, I do not reach the same result.
The IF is $\displaystyle e^{\sin t}$.
Multiplying both sides by it, I get $\displaystyle \frac{dx}{dt} e^{\sin t}+x\cos (t) e^{\sin t}=0$.
Integrating with respect to t, I get $\displaystyle e^{\sin t}x=0$.
Now clearly $\displaystyle x\equiv 0$.
What am I doing wrong?
What I think we need to do at $\displaystyle \frac{\,d}{\,dt}\left[xe^{\sin t}\right]=0$ is integrate both sides and say that $\displaystyle xe^{\sin t}={\color{red}C}$ in order to avoid getting the trivial solution for an answer. From here then, we get $\displaystyle x=Ce^{-\sin t}$ which is the answer you got from solving it using separation of variables.

Does this help?

3. Originally Posted by Chris L T521
What I think we need to do at $\displaystyle \frac{\,d}{\,dt}\left[xe^{\sin t}\right]=0$ is integrate both sides and say that $\displaystyle xe^{\sin t}={\color{red}C}$ in order to avoid getting the trivial solution for an answer. From here then, we get $\displaystyle x=Ce^{-\sin t}$ which is the answer you got from solving it using separation of variables.

Does this help?
Bright!
Yes it helps, a lot.
By the way your tutorial is really great! I'm going to use it often these days.