Can integration in which a variable is linked to (itself + constant) be solved?: $\frac{df(x)}{dx}=f(x+5)$ $$\frac{df(x)}{dx}=f(x+5)$$
I am unable to solve this kind of integration using high school mathematics.
Please help.
 A: Since
$$ \frac {d e^{kx}}{dx} = k e^{kx} , \space e^ {k(x + 5)} = e^ {5k} e^ {kx},
$$
it seems like an exponential is the way to go. This leads to the equation
$$
k = e^{5k}.
$$
There's no elementary way to express the solution to this equation. It can be done in terms of a function called the product log function, $W(z)$, defined by $z = W(z) e^{W(z)}$ (more about this at the bottom). Using this gives
$$
k = e^{5k}\Longrightarrow -5k e^ {-5k}= -5\Longrightarrow-5k = W(-5)\Longrightarrow k = -W(-5)/5
$$
So the solution to the equation is $f(x) = C e^ {-xW(-5)/5}$ for an arbitrary constant $C$.
It's worth noting that this kind of differential equation, called a delay differential equation, is in general extremely difficult to solve. In this case, the simplicity of the equation allowed guessing the form of the solution, but that won't work for all of them.
Finally, some things about $W$. The first is that $W(-5)$ is a complex number.It has to be, as there is no real number such that $k = e^{5k}$. The second is that there is not a unique $W(-5)$ because $e^z$ has period $2\pi i$. So there are in fact infinitely many solutions to this equation, one for each complex number $W$ that satisfies $-5 = W e^{W}$. This is similar to the way that $\cos^{-1}z$ is not unique, but could be several different values that differ by multiples of $2\pi$. Finally
A: Just an ansatz or guess: Because differentiating $a^x$ gives a multiple of $a^x$, and also $a^{x+\mathrm{const}}$ is a multiple of $a^x$:  Try $f(x)=k\exp(ax)$, then:
$$\frac d{dx} f(x) = kae^{ax} \stackrel!= f(x+c) = ke^{a(x+c)} = ke^{ca}e^{ax}$$
with $c=5$. Dividing out $\exp(ax)$:
$$ ka \stackrel!= k\exp(ca)$$
so $k=0$ or $a = \exp(ca)$. To solve the latter, divide by $\exp(ca)$ and rewrite as
$$(-ca)\exp(-ca) = -c$$
and then apply Lambert-W:
$$-ca = W(-c) \quad \implies\quad a = -\frac1cW(-c)$$
Now for $c = 5$ there is no (real) solution because the minimum $-1/e$ of $x\mapsto xe^x$ is greater than $-5$.  But I am not familiar with $W$ and its branches, so there is likely a different branch of $W$ that gives (complex) solutions.
Or either there is no solution (except the trivial $k=0$) or the ansatz was too restricting.

That said, if you had used $c=-5$, there was the real solution
$$a = \frac15W(5) \approx1.326725/5 = 0.265345 \approx \ln 1.30388$$
so that $f(x) = k\cdot 1.30388^x$ where you can pick $k$ as you like.

Note: Here is a complex solution for $c=5$.
