If \( \displaystyle\frac{dy}{dx}=e^{x-y}+x^2e^{-y} \), then the solution of the differential equation will be:-
Answer & explanation
Correct answer: option 2
The correct answer is Option (2) → \( e^y=e^x+\displaystyle\frac{x^3}{3}+C \), where C is an arbitrary constant
Taking \( e^{-y} \) out as a common factor, the variables separate:
\( \displaystyle \frac{dy}{dx}=e^{-y}\left(e^x+x^2\right) \)
\( \displaystyle e^y\,dy=\left(e^x+x^2\right)dx \)
Integrating both sides:
\( \displaystyle e^y=e^x+\frac{x^3}{3}+C \)
Why the other options are incorrect
Option (1) \( e^y=e^x+\displaystyle\frac{x^2}{2}+C \), where C is an arbitrary constant — Incorrect. This takes \( \int x^2\,dx=\frac{x^2}{2} \); the correct integral is \( \frac{x^3}{3} \).
Option (3) \( e^y=e^x+2x+C \), where C is an arbitrary constant — Incorrect. 2x is the derivative of \( x^2 \), not its integral.
Option (4) \( e^y=e^x+3x^2+C \), where C is an arbitrary constant — Incorrect. \( 3x^2 \) is the derivative of \( x^3 \), not the integral of \( x^2 \).