# Separable Variables-Differential Equations

• Feb 2nd 2008, 03:34 PM
yellowrose
Separable Variables-Differential Equations
Hello,

I am having trouble solving the 2 following problems.

Given the differential equation solve by separation of variables.

1. sec^2(x) dy + csc(y) dx =0

I have tried to get the y's on the left and the x's on the right and integrate, but I cannot get the correct solution. This is what I have so far....

1/(csc(y)) dy = 1/(sec^2(x))

But I'm just not getting 4cos(y)=2x+sin(2x)+c

2. dy/dx = (xy + 3x - y-3) / (xy - 2x + 4y -8)

On this problem I am not sure where to start.

Any help is greatly appreciated. Thanks!
• Feb 2nd 2008, 03:43 PM
Jhevon
Quote:

Originally Posted by yellowrose
Hello,

I am having trouble solving the 2 following problems.

Given the differential equation solve by separation of variables.

1. sec^2(x) dy + csc(y) dx =0

I have tried to get the y's on the left and the x's on the right and integrate, but I cannot get the correct solution. This is what I have so far....

1/(csc(y)) dy = 1/(sec^2(x))

But I'm just not getting 4cos(y)=2x+sin(2x)+c

$\sec^2 x ~dy + \csc y ~dx = 0$

$\Rightarrow \sec^2 x ~dy = - \csc y ~dx$

$\Rightarrow \sin y ~dy = - \cos^2 x ~dx$

now continue
• Feb 2nd 2008, 03:52 PM
mr fantastic
Quote:

Originally Posted by yellowrose
Hello,

I am having trouble solving the 2 following problems.

Given the differential equation solve by separation of variables.

1. sec^2(x) dy + csc(y) dx =0

I have tried to get the y's on the left and the x's on the right and integrate, but I cannot get the correct solution. This is what I have so far....

1/(csc(y)) dy = 1/(sec^2(x))

Mr F says: $\Rightarrow \sin y \, dy = \cos^2 x \, dx \Rightarrow \int \sin y \, dy = \int \cos^2 x \, dx$.

Note that from the double angle formula $\cos (2x) = 2 \cos^2 x - 1$, $\cos^2 x = \frac{1}{2} (\cos(2x) + 1)$.

[snip]4cos(y)=2x+sin(2x)+c
[snip]

..
• Feb 2nd 2008, 04:01 PM
mr fantastic
Quote:

Originally Posted by yellowrose
[snip]

2. dy/dx = (xy + 3x - y-3) / (xy - 2x + 4y -8)

On this problem I am not sure where to start.

Any help is greatly appreciated. Thanks!

Note that $\frac{dy}{dx} = \frac{xy + 3x - y-3}{xy - 2x + 4y} = \frac{y(x - 1) + 3(x - 1)}{y(x + 4) - 2(x + 4)}$

$= \frac{y + 3}{y\left(\frac{x+4}{x-1} \right) - 2\left(\frac{x+4}{x-1} \right)} = \frac{y + 3}{\left(\frac{x+4}{x-1} \right) (y - 2)} = \left(\frac{x-1}{x+4} \right) \left( \frac{y + 3}{y - 2} \right)$.

*Ahem* or you could just spot that $\frac{xy + 3x - y-3}{xy - 2x + 4y} = \frac{x(3 + y) - (3 + y)}{x(y - 2) + 4(y - 2)} = \frac{(x - 1)(3 + y)}{(x + 4)(y - 2)}$ .......

I'll come back to this point if you still need help with it. Suffice to say, it's now separable .....
• Feb 2nd 2008, 04:10 PM
yellowrose
Quote:

Originally Posted by Jhevon
$\sec^2 x ~dy + \csc y ~dx = 0$

$\Rightarrow \sec^2 x ~dy = - \csc y ~dx$

$\Rightarrow \sin y ~dy = - \cos^2 x ~dx$

now continue

I integrated that and got
-cos(y)=-.5(sin(x)cos(x)+x)+c

I'm sorry I just can't figure out how to get this into simplier terms. So that I just have a y on the left.
• Feb 2nd 2008, 04:15 PM
Jhevon
Quote:

Originally Posted by yellowrose
I integrated that and got
-cos(y)=-.5(sin(x)cos(x)+x)+c

I'm sorry I just can't figure out how to get this into simplier terms. So that I just have a y on the left.

well, you could take the arccosine of both sides (remove the minus signs). but i don't think you have to get the answer any simpler than what you have
• Feb 2nd 2008, 04:21 PM
yellowrose
Quote:

Originally Posted by mr fantastic
..

Thanks for your help. I understand that I need to use the rule you gave me, but I'm not sure how. Do I use this before or after I integrate? I guess I'm just really confused about this problem.
• Feb 2nd 2008, 04:30 PM
mr fantastic
Quote:

Originally Posted by yellowrose
Thanks for your help. I understand that I need to use the rule you gave me, but I'm not sure how. Do I use this before or after I integrate? I guess I'm just really confused about this problem.

The rule I gave for $cos^2 x$ gets used before integrating .... it's used to facilitate the integration of $cos^2 x$.
• Feb 2nd 2008, 04:37 PM
mr fantastic
Quote:

Originally Posted by mr fantastic
Note that $\frac{dy}{dx} = \frac{xy + 3x - y-3}{xy - 2x + 4y} = \frac{y(x - 1) + 3(x - 1)}{y(x + 4) - 2(x + 4)}$

$= \frac{y + 3}{y\left(\frac{x+4}{x-1} \right) - 2\left(\frac{x+4}{x-1} \right)} = \frac{y + 3}{\left(\frac{x+4}{x-1} \right) (y - 2)} = \left(\frac{x-1}{x+4} \right) \left( \frac{y + 3}{y - 2} \right)$.

*Ahem* or you could just spot that $\frac{xy + 3x - y-3}{xy - 2x + 4y} = \frac{x(3 + y) - (3 + y)}{x(y - 2) + 4(y - 2)} = \frac{(x - 1)(3 + y)}{(x + 4)(y - 2)}$ .......

I'll come back to this point if you still need help with it. Suffice to say, it's now separable .....

Some further help:

$\frac{dy}{dx} = \left(\frac{x-1}{x+4} \right) \left( \frac{y + 3}{y - 2} \right) \Rightarrow \int \frac{y - 2}{y + 3} \, dy = \int \frac{x-1}{x+4} \, dx$.

Note that:

$\frac{y - 2}{y + 3} = \frac{(y + 3) - 5}{y + 3} = 1 - \frac{5}{y + 3}$

$\frac{x - 1}{x + 4} = \frac{(x + 4) - 5}{x + 4} = 1 - \frac{5}{x + 4}$
• Feb 2nd 2008, 04:40 PM
yellowrose
Quote:

Originally Posted by mr fantastic
Note that $\frac{dy}{dx} = \frac{xy + 3x - y-3}{xy - 2x + 4y} = \frac{y(x - 1) + 3(x - 1)}{y(x + 4) - 2(x + 4)}$

$= \frac{y + 3}{y\left(\frac{x+4}{x-1} \right) - 2\left(\frac{x+4}{x-1} \right)} = \frac{y + 3}{\left(\frac{x+4}{x-1} \right) (y - 2)} = \left(\frac{x-1}{x+4} \right) \left( \frac{y + 3}{y - 2} \right)$.

*Ahem* or you could just spot that $\frac{xy + 3x - y-3}{xy - 2x + 4y} = \frac{x(3 + y) - (3 + y)}{x(y - 2) + 4(y - 2)} = \frac{(x - 1)(3 + y)}{(x + 4)(y - 2)}$ .......

I'll come back to this point if you still need help with it. Suffice to say, it's now separable .....

I separated them, took the integral of both sides, raised it to the e, and got
e^y(y+3)^5=e^x(x+4)^5
but the ans states e^x(y+3)^5=e^y(x+4)^5
could you tell me what I'm doing different....or is what I have still correct? Thanks!
• Feb 2nd 2008, 05:06 PM
mr fantastic
Quote:

Originally Posted by yellowrose
I separated them, took the integral of both sides, raised it to the e, and got
e^y(y+3)^5=e^x(x+4)^5
but the ans states e^x(y+3)^5=e^y(x+4)^5
could you tell me what I'm doing different....or is what I have still correct? Mr F says: Your answer is not the same as the book's answer. The exponent terms are switched!
Thanks!

Quote:

Originally Posted by mr fantastic
Some further help:

$\frac{dy}{dx} = \left(\frac{x-1}{x+4} \right) \left( \frac{y + 3}{y - 2} \right) \Rightarrow \int \frac{y - 2}{y + 3} \, dy = \int \frac{x-1}{x+4} \, dx$.

Note that:

$\frac{y - 2}{y + 3} = \frac{(y + 3) - 5}{y + 3} = 1 - \frac{5}{y + 3}$

$\frac{x - 1}{x + 4} = \frac{(x + 4) - 5}{x + 4} = 1 - \frac{5}{x + 4}$

So you have:

$\int 1 - \frac{5}{y + 3} \, dy = \int 1 - \frac{5}{x+4} \, dx$

$\Rightarrow y - 5 \ln |y + 3| = x - 5 \ln |x + 4| + C$

$\Rightarrow y + \ln |x + 4|^5 = x + \ln |y + 3|^5 + C$

Exponentiate both sides, and let $A = e^C$:

$\Rightarrow e^y (x + 4)^5 = Ae^x (y + 3)^5$

which is the same as you book's answer (except that your book did a very bad thing (Puke) and either forgot to include the arbitrary constant of integration or conveniently set A = 1).

I could guess what mistake you made, but I'll bet that the mistake is obvious in hindsight (Rofl)