First Order Derivative II

• Feb 18th 2009, 12:40 PM
Simplicity
First Order Derivative II
$\frac{\mathrm{d}y}{\mathrm{d}x} = y - 2, \ \ \ y(0)=1$

Is this solveable to get $y(x)=...$. When I used seperation of variable I got $c=\ln (-1)$ which isn't possible. Can someone solve it? Thanks in advance.
• Feb 18th 2009, 12:45 PM
running-gag
Hi

Don't forget the absolute value !

Integrating $\frac{u'(x)}{u(x)}$ gives $\ln(|u(x)|)$
• Feb 18th 2009, 12:49 PM
Simplicity
Quote:

Originally Posted by running-gag
Hi

Don't forget the absolute value !

Integrating $\frac{u'(x)}{u(x)}$ gives $\ln(|u(x)|)$

Is this even case when:

$-1 = e^c$

$\ln (-1) = c$

It's not from the integration so it is still $\ln (-1) = \ln (1)$?
• Feb 18th 2009, 12:53 PM
running-gag
No, look :

$\frac{dy}{dx} = y - 2, \ \ \ y(0)=-1$

$\frac{dy}{y-2} = dx, \ \ \ y(0)=-1$

$\ln(|y(x)-2|) = x + c, \ \ \ y(0)=-1$

$\ln(|y(0)-2|) = c, \ \ \ y(0)=-1$

$\ln(3) = c$
• Feb 18th 2009, 01:00 PM
Simplicity
Quote:

Originally Posted by running-gag
No, look :

$\frac{dy}{dx} = y - 2, \ \ \ y(0)=-1$

$\frac{dy}{y-2} = dx, \ \ \ y(0)=-1$

$\ln(|y(x)-2|) = x + c, \ \ \ y(0)=-1$

$\ln(|y(0)-2|) = c, \ \ \ y(0)=-1$

$\ln(3) = c$

No, Sorry, I wrote the question wrong:

$\frac{dy}{dx} = y - 2, \ \ \ y(0)=1$

It's 1 and not -1.
• Feb 18th 2009, 01:32 PM
Simplicity
And $\ln 1 = 0$.

Which would give equation $y=x+2$ which when you differentiate does not give the required solution.

$\frac{\mathrm{d}y}{\mathrm{d}x} = y - 2, \ \ \ y(0)=1$

Can someone please solve my confusion. (Worried)
• Feb 19th 2009, 08:48 AM
running-gag
$\frac{dy}{dx} = y - 2, \ \ \ y(0)=1$

$\frac{dy}{y-2} = dx, \ \ \ y(0)=1$

$\ln(|y(x)-2|) = x + c, \ \ \ y(0)=1$

$\ln(|y(0)-2|) = c, \ \ \ y(0)=1$

$\ln(1) = c$

$c = 0$

$\ln(|y(x)-2|) = x, \ \ \ y(0)=1$

$|y(x)-2| = e^x, \ \ \ y(0)=1$

$y(x)-2 = e^x$ or $-y(x)+2 = e^x$

$y(x) = e^x + 2$ or $y(x) = -e^x + 2$

$y(0) = 1$ therefore $y(x) = -e^x + 2$