The solution of $\frac{dy}{dx} - y = 1, y(0) = 1$ is given by
Answer & explanation
Correct answer: option 4
The correct answer is Option (4) → $y = 2e^x - 1$ ##
Given that, $\frac{dy}{dx} - y = 1$
$\Rightarrow \frac{dy}{dx} = 1 + y$
$\Rightarrow \frac{dy}{1 + y} = dx \quad \text{[using variable separable method]}$
On integrating both sides, we get
$\log(1 + y) = x + C \dots(i)$
When $x = 0$ and $y = 1$, then
$\log 2 = 0 + C$
$\Rightarrow C = \log 2$
The required solution is
$\log(1 + y) = x + \log 2 \quad [∵C = \log 2]$
$\log(1 + y) - \log 2 = x$
$\Rightarrow \log\left(\frac{1 + y}{2}\right) = x$
$\Rightarrow \frac{1 + y}{2} = e^x$
$\Rightarrow 1 + y = 2e^x$
$\Rightarrow y = 2e^x - 1$