General solution of the differential equation $\frac{dy}{dx} = 2e^{x-y}$

138 Views Asked by At

I am learning about general solutions to differential equations and would like to ask whether my solution is mathematically correct.

I was asked to find the general solution to the differential equation

$$\frac{dy}{dx} = 2e^{x-y}$$

So I did the following -

$$\int e^y dy = 2\int e^x dx$$ $$e^y = 2 e^x + C $$ $$y = \ln (2 e^x + C) $$

Now, my book says that the solution in the form $y = f(x)$ is $y = \ln (2 e^x + C) $.

However, I progressed further and did the following:

$$y = \ln (2 e^x + C) $$ $$ = \ln (e^{{x}^{2}} + C) $$ $$y = x^2 + C' $$

where $C'$ is a modified constant from the original constant $C$.

Is this an acceptable solution?

2

There are 2 best solutions below

1
On BEST ANSWER

You went wrong in two places. First you replaced $2e^x$ with $e^{x^2}$. It seems you were thinking about $2 \ln a= \ln (a^2)$, but note that the $2$ is outside the log here. Second, you are thinking that $e^{x^2}=(e^x)^2$, but the convention is that $e^{x^2}=e^{(x^2)}$ because you can replace $(e^x)^2$ by $e^{2x}$

0
On

Note this inequality: $$2e^x\neq e^{x^2}$$