[Math] Solving the following non-separable differential equation: $y’=\ln(x+y)$

ordinary differential equations

I'm getting stuck trying to separate, and thus solve this differential equation. Here $y' := \frac{\mathrm dy}{\mathrm dx}$

$$y'=\ln(x+y)$$

Is this differential separable using elementary functions? WolframAlpha is mentioning something about the Exponential integral ($\text{E}_i$). We haven't been taught about this $\text{E}_i$ term…

Best Answer

The differential equation cannot be solved in terms of a finite number of elementary functions. In this answer, we do not restrict ourselves to elementary functions.


One can reduce this to a separable ODE by substituting: $$v=x+y \implies \frac{dv}{dx}=1+\frac{dy}{dx}$$ This gives: $$\frac{dv}{dx}=\ln(v)+1$$ One can separate both sides and integrate: $$\int \frac{1}{\ln(v)+1}~dv=\int dx$$ The left hand side cannot be integrated in terms of elementary functions as you mentioned. However, it can be evaluated using the Exponential Integral $\operatorname*{Ei}(x)$.


The trick here is to substitute: $$u=\ln(v)+1 \implies v=e^{u-1} \implies dv=e^{u-1}~du$$ This gives: $$\int \frac{e^{u-1}}{u}~du=\int dx \tag{1}$$ It follows from the definition that: $$\int \frac{e^u}{u}~du=\operatorname*{Ei}(u)+C$$ Putting $(1)$ in that form gives: $$\frac{1}{e}\int \frac{e^u}{u}~du=\int dx$$ $$\frac{\operatorname*{Ei}(u)}{e}=x+c \tag{2}$$ All that remains to do now is to substitute back to obtain an implicit solution for $y(x)$.

Related Question