Differential Equations
Differential Equations
Allen Star Batch
Grade 12

Question:

Let $\frac{dy}{dx}+y = f(x)$ where $y$ is a continuous function of $x$ with $y(0) = 1$ and $f(x) = \begin{cases} e^{-x}, & \text{if } x \le 2 \\ e^{-2}, & \text{if } x > 2 \end{cases}$. Which is of the following hold(s) good?
$y(1) = 2e^{-1}$
$y'(1) = -e^{-1}$
$y(3) = -2e^{-3}$
$y'(3) = -2e^{-3}$

Step-by-Step Solution

Key Concept: Use an integrating factor to convert the linear ODE into an exact differential, then integrate and apply initial conditions for each domain.
Given $\frac{dy}{dx} + y = f(x)$ where $f(x) = e^x$, the integrating factor is $e^x$. Multiplying through: $ye^x = \int e^x f(x)dx + C$. For $0 \leq x \leq 2$, we have $ye^x = \int e^{2x}dx + C = \frac{e^{2x}}{2} + C$. Using $y(0)=1$: $C=1$, so $ye^x = x+1$ giving $y = \frac{x+1}{e^x}$. Then $y(1) = \frac{2}{e}$ and $y'(1) = \frac{e-(2e)}{e^2} = -\frac{1}{e}$. For $x > 2$, we have $ye^x = \int e^{x-2}dx = e^{x-2} + C'$ which continues the solution piecewise.
Correct Answer: 1,2,4

Master Differential Equations with Mathbee

Practice this topic under real exam conditions with strict timers, or ask our AI Mentor to explain the concepts step-by-step.

Start Practicing for Free