# When $f(x+1)-f(x)=f'(x)$, what are the solutions for $f(x)$?

The question is:

When $f(x+1)-f(x)=f'(x)$, what are the solutions for $f(x)$?

The most obvious solution is a linear function of the form $f(x)=ax+b$. Is this the only solution?

Edit

I should add that $f:\mathbb R\to\mathbb R$ to the question.

-
We surely know that $f$ is in $C^\infty$. If we would know it is analytic we could use a taylor series to get the unique solution $f(x)=ax+b$. So every other solution must be in $C^\infty$ but can't be analytic. – Dominic Michaelis May 12 '13 at 21:16
Two small observations: (1) If $f$ is a solution, then so is $f'$, $f''$, etc. (2) For any $x_0 \in \mathbb{R}$, the Mean Value Theorem yields an infinite (strictly increasing) sequence $\{x_0, x_1, \ldots\}$ with $f'(x_0) = f'(x_1) = \cdots$. – Jesse Madnick May 12 '13 at 21:20
Hasn't this been asked here before? – GEdgar May 12 '13 at 22:42
$f(x)=c$ is also an obvious solution as each side becomes zero. – JB King May 12 '13 at 23:19
If we take Fourier transform of the both sides, we get $F\cdot e^{iw} - F = F\cdot (iw)$, grouping the fourier image $F$, we get $F=\frac {iw} {e^{iw}-1}$. If we take the inverse fourier of the right hand, we'd get the $f$. – mbaitoff May 13 '13 at 8:50

This is an example of a delay differential equation, and it has a very large number of solutions. I will begin by discussing solutions $f\colon[0,\infty)\to\mathbb{R}$, and then extend to solutions on the real line.

Suppose first that we have defined $f$ on the interval $[0,1]$, say $f(x) = f_0(x)$ for some differentiable function $f_0\colon[0,1]\to\mathbb{R}$. For extending solutions forwards, the best way to write the equation is $$f(x+1) \;=\; f(x) + f'(x).$$ Using this equation, it is not hard to define $f$ on the interval $[1,2]$. Specifically, if $x\in[1,2]$, then $$f(x) \;=\; f_0(x-1) + f_0'(x-1).$$ Note that this function will only be differentiable if $f_0$ was twice differentiable on $[0,1]$. Moreover, the derivatives at $1$ will only match up if $f_0'(1) = f_0'(0) + f_0''(0)$. Assuming this is the case, it is easy to extend again to $[2,3]$. Specifically, if $x\in[2,3]$, then $$f(x) \;=\; f(x-1) + f'(x-1) \;=\; f_0(x-2) + 2 f_0'(x-2) + f_0''(x-2).$$ In general, assuming that:

1. The function $f_0$ is $C^\infty$ on $[0,1]$ and,
2. $f_0^{(k)}(1) = f_0^{(k)}(0) + f_0^{(k+1)}(0)$ for all $k\geq 0$,

we can extend $f$ to all of $[0,\infty)$ by the formula $$f(x) \;=\; \sum_{k=0}^{\lfloor x\rfloor} \,\binom{\lfloor x\rfloor}{k}f_0^{(k)}(x-\lfloor x\rfloor)$$

Now let's discuss how to extend backwards. Assuming we have defined $f$ on $[0,\infty)$, the formula for $f$ on $[-1,0]$ is determined by the initial-value problem $$f'(x) + f(x) \;=\; f_0(x+1),\qquad f(0) = f_0(0).$$ This is a first-order differential equation, so it must have a solution. Moreover, assuming $f_0$ is $C^\infty$ on $[0,1]$, it follows from the Picard-Lindelöf Theorem that there is a unique $C^\infty$ solution for $f$ on $[-1,0]$. Note that the derivatives at $0$ will automatically match, since $f_0(1) - f(0) = f_0'(0)$. Continuing in this fashion, we can extend any solution backwards all the way to $-\infty$.

We conclude that any function $f_0\colon[0,1]\to\mathbb{R}$ satisfying the two conditions listed above extends to a solution on the entire real line.

Edit: Incidentally, there is a simple integral formula for $f$ on $(-\infty,0]$, which can be used to compute values for $f$ on a computer: $$f(x) \;=\; f(0) + e^{-x-1}\int_{x+1}^1 e^{t}\,f(t)\,dt$$ This can also be used to provide an alternative proof that the function extends backwards, without appealing to existence and uniqueness of ODE's. I found this formula by solving the initial value problem $f(x) + f'(x) = f(x+1)$ using integrating factors.

-
If we normalize $f_0(0)=f_0'(0)=0$, and if we suppose that $0$ is in the support of $f_0$, is there any simple example of $f_0$? – 23rd May 12 '13 at 21:43
Not that I'm aware of. For example, I would guess that the functions $f_0(x) = ax+b$ are the only analytic possibilities for $f_0$. For other examples of $f_0$, you need to start with something like a bump function on $[0,1]$. – Jim Belk May 12 '13 at 22:03
To be more precise, something like $f_0(x) = \mathrm{exp}\left(-x^{-2}(x-1)^{-2}\right)$ would work well. I've added an explicit formula for the negative part above which should make it possible to define the function $f$ effectively in a computer algebra system. – Jim Belk May 12 '13 at 22:24
Yes, your example definitely works. It was my mistake to say $0$ in the support of $f_0$. Actually I want a litte more: $f_0^{(k)}(0)\ne 0$ for some $k\ge 2$ to exclude bump functions, and now I see achille hui has cleared my doubts. Thank you for your replies. – 23rd May 13 '13 at 4:16

Let $\lambda = \alpha + \beta i \in \mathbb{C}$ be any root of the equation $\lambda = e^{\lambda} - 1$ subject to $\beta \ge 0$ and $\delta$ any real number, then $$f(x) = \Re( e^{\lambda x + i\delta} ) = e^{\alpha x} \cos(\beta x + \delta)\tag{*}$$ will be a $C^{\infty}$ solution for the functional equation $f'(x) = f(x+1) - f(x)$.

For example, $\lambda = e^{\lambda} -1$ has a root at $\sim 2.088843015613044 + 7.461489285654254 i$.
This gives us following $C^{\infty}$ solution:

$$f(x) \sim e^{ 2.088843015613044\,x}\,\cos(7.461489285654254\,x)$$

Other solutions can be constructed by forming linear combination of solutions of the form in $(*)$. Please note that $\lambda = e^{\lambda} - 1$ has a double root at $\lambda = 0$, there are two solutions at $\lambda = 0$ which one can use:

$$\Re( e^{\lambda x} )\Big|_{\lambda = 0} = 1 \quad\quad\text{ and }\quad\quad \frac{\partial}{\partial \lambda} \Re( e^{\lambda x} )\Big|_{\lambda = 0} = x$$

-
Very nice! I would have guessed that there weren't any analytic solutions beyond $f(x) =ax + b$. – Jim Belk May 12 '13 at 23:32
However, your claim that an arbitrary solution can be constructed from these is not obvious to me. Is there some reason that the solution space is the closure of the span of these solutions? – Jim Belk May 12 '13 at 23:40
@JimBelk Sorry for the confusion. I'm not claiming arbitrary solutions can be constructed from these. – achille hui May 13 '13 at 0:04
"Other solutions" simply means there are more solutions that can be constructed, not that every solution can necessarily be constructed in this way. – anon May 13 '13 at 0:05
Note that $\lambda = e^\lambda - 1 \stackrel{\lambda\neq 1}\Longleftrightarrow -e^{-1} = -(1+\lambda)e^{-(1+\lambda)} \Leftrightarrow \lambda = -(1+W(-e^{-1}))$ where W is the Lambert W function (it has multiple branches; the only two real-valued λs solving this are λ=0 and λ=∞, all "sensible" solutions are complex valued) edit Why did I even bother calculating this by hand? alpha can do... – Tobias Kienzler May 14 '13 at 7:10

Commenting to achille hui's answer, the idea of choosing $\lambda$ comes from the observation that the translation operator $\tau_{h} f (x) = f(x+h)$ corresponds to the exponential of the differential operator

$$\tau_{h}f(x) = \sum_{n=0}^{\infty} \frac{f^{(n)}(x)}{n!}h^{n} = e^{h d/dx} f(x).$$

on the space of analytic functions. So writing $D = d/dx$, the given equation can be transformed into

$$e^{D}f(x) - f(x) = Df(x) \quad \Longleftrightarrow \quad (e^{D} - 1 - D)f(x) = 0.$$

By making an ansatz that a solution $f(x)$ has the form $f(x) = e^{\lambda x}$, it is easy to see that the equation above is equivalent to $e^{\lambda} - 1 - \lambda = 0$, the very starting point of the achille hui's answer.

-
(+1) Yup, this is part of the motivation of my answer. Another one is when one view the functional equation as a problem of finding eigenvectors, the operator involved commute with the translation operator $e^{tD}$, this suggest one to look at common eigenvector for both operators. i.e. ansatz of the form $e^{\lambda x}$. – achille hui May 13 '13 at 1:55
Since the $e^{\lambda x}$ form the Eigenbase of $D$, doesn't this somehow indicate that all solutions are obtainable as superpositions of the valid $\lambda$ solutions, similar to Fourier series but summing over the branches of the Lambert W function (see my other comment) instead of integers? (also @achillehui) – Tobias Kienzler May 14 '13 at 7:20

Partial answer. If $f(x)$ is the a polinomial function say $f(x)=\sum_{k=0}^na_kx^k$ then $$\sum_{k=0}^na_k(x+1)^k-\sum_{k=0}^na_kx^k=\sum_{k=0}^nka_kx^{k-1}$$ For $x=1$ we have $$\sum_{k=0}^na_k2^k-\sum_{k=0}^na_k=\sum_{k=0}^nka_k$$ If $n=2$ then $a_0+2a_1+4a_2-a_0-a_1+a_2=a_1+2a_2\implies a_2=0.$ In general case for all $n>1$ we have for any no root $x_0$ of $f(x)$ or $p(x)= (x+1)^n-x^n$ that $$\sum_{k=0}^na_k(x_0+1)^k-\sum_{k=0}^na_kx_0^k-\sum_{k=0}^nka_kx^{k-1}=0 \implies [(x_0+1)^n-x_0^n]a_n=0\implies a_n=0$$

Soon the solution can not be a polynomial of degree greater than 1.

-

An exponential function $a^x$ with base $a$ satisfying the equation

$$a^a-ea=0$$

is the solution.

The equation has two roots:

$${\large a}_1=0.2592463566483049762658328267922644867392517823397669639360784269929\ldots$$

$${\large a}_2=2.2399778876565500700638977660928972654111884831688969821454636850130\ldots$$

See this question for more details:

Closed form solution to $\frac{1}{a-1}= \log a$

-