Homework Help: Is this a linear or seperable differential equation?

1. May 29, 2010

pegasi

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

Solve the initial value problem of the following DE, given that y(0) = 0

dy/dx = (20-2y)/(5-x)

2. Relevant equations

Integrating factor for Linear DE's: e ^ ($$\int$$P(x)dx) where Linear DE is of form dy/dx + P(x)y = Q(x).

3. The attempt at a solution

Hi,
I'm having trouble understanding why my technique doesen't work. I suspect this differential equation needs to be treated as a linear one, but if this is the case I have no idea why it must be treated this way? Why does my approach not work?

Instead of solving for a linear DE, I thought that this equation could be separated:

1/(20-2y) dy = 1/(5-x) dx

integrate both sides:
$$\int$$1/(20-2y) dy = $$\int$$1/(5-x) dx

-1/2 ln|10-y| = -ln|5-x| + C

ln|10-y| = 2ln|5-x| - 2C

10-y = (5-x)^2 + e^(-2C)

rewrite e^(-2C) as C...

10-y = (5-x)^2 + C

sub in x=0 and y=0

10 = 25 + C

C = -15

10-y = (5-x)^2 - 15

y = 10x - x^2

However my book states that the answer is actually y = 4x - (2/5)x^2

Any help anyone could provide will be very much appreciated. I don't need this done for me, I just want to know why my approach does not work (or what trivial mistake I have made and overlooked), and what alternative approach I should use instead.

PS, apologies for the strange formatting, the latex integral signs are oversized, I do not know how to write latex...

2. May 29, 2010

HallsofIvy

Here's your error. $e^{a+b}e^ae^b$, not $e^a+ e^b$
You should have $10- y= (5-x)^2e^{-2C}$ and, writing $e^{-2C}$ as "C" as you do below, [/quote]10- y= C(5- x)^2[/quote]

3. May 29, 2010

pegasi

Thank you! I'm glad it was an algebraic error not some kind of misconception. I need to give constants more thought it seems.