1
$\begingroup$

I have solve this differential equation :

$$\left\{\begin{aligned}\frac{dy}{dx} + y &= f(x) \\ y (0)&=0. \end{aligned}\right.$$ where $f (x) = \begin{cases}2 & \text{if } 0 \leq x < 1 \\ 0 &\text{if }x \geq 1.\end{cases}$
Please explain how to solve as it involves discontinuous function $f$.

$\endgroup$
4
  • 1
    $\begingroup$ This is not an exact differential equation. You'd need to multiply it by an integrating factor to get an exact differential equation. $\endgroup$ Sep 13, 2011 at 20:07
  • 1
    $\begingroup$ The integrating factor does not involve the function on the right. It would be the same integrating factor if the equation was $\frac{dy}{dx} + y = 0$. $\endgroup$ Sep 13, 2011 at 20:15
  • $\begingroup$ @ Robert Israel: Thanks, I got the I.F as e ^x. $\endgroup$
    – rupa
    Sep 13, 2011 at 20:18
  • $\begingroup$ @Robert Israel : Please suggest how to proceed beyond this. $\endgroup$
    – rupa
    Sep 13, 2011 at 20:24

1 Answer 1

1
$\begingroup$

Multiply by the integrating factor $e^x$ and then you can factor the LHS: $$(e^xy)'=e^xf(x).$$ Now integrate from $0$ to $x$ to get $$e^xy(x)-e^0y(0)=\int_0^xe^uf(u)du$$ but remember $y(0)=0$. Now divide by the integrating factor and you have $y(x)=e^{-x}\int_0^xe^uf(u)du$. We can evaluate this by (a) looking at $x\in[0,1)$ and then (b) looking at $x\ge1$ for a piecewised defined solution $y$ (note: in the latter case you will have to split $\int_0^x$ into $\int_0^1+\int_1^x$ to substitute for $f$).

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.