Join the Most Relevant JEE Main 2025 Test Series & get 99+ percentile! Join Now
Search any question & find its solution
Question: Answered & Verified by Expert
The solution of the differential equation $\frac{d y}{d x}+y=\cos x$ is
MathematicsDifferential EquationsJEE Main
Options:
  • A $y=\frac{1}{2}(\cos x+\sin x)+c e^{-x}$
  • B $y=\frac{1}{2}(\cos x-\sin x)+c^{-x}$
  • C $y=\cos x+\sin x+c e^{-x}$
  • D None of these
Solution:
2140 Upvotes Verified Answer
The correct answer is: $y=\frac{1}{2}(\cos x+\sin x)+c e^{-x}$
It is linear equation of the form $\frac{d y}{d x}+P y=Q$
So, I.F. $=e^{\int 1 d x}=e^x$
Hence solution is $y \cdot e^x=\int \cos x \cdot e^x d x+c$
$\Rightarrow y=\frac{1}{2}(\cos x+\sin x)+c e^{-x}$

Looking for more such questions to practice?

Download the MARKS App - The ultimate prep app for IIT JEE & NEET with chapter-wise PYQs, revision notes, formula sheets, custom tests & much more.