# Solving $f'(x) +f(x)=cf(x-1)$

To show that $f(x) =Ae^{nx}$ for constant $n$ and $A$ starting with this thing:

$$f'(x) +f(x)=cf(x-1)$$

Where $c$ is constant and $c\not= 0$.

If it wasn't for the $f(x-1)$ bit, I would just use the integrating factor where $I=e^x$ and plug it into the equation. But the $f(x)$ throws me off, so I would have to put it into a form like $\frac{dy}{dx}+y=?$, in order to feel ok about it.

EDIT: Oh as somebody rightly pointed out this is only for the condition when $n$ satistfies $$n+1 = ce^{-n}$$

-
wikipedia is not the way. –  Magpie Aug 12 '12 at 19:44
Have you tried using the Fourier transform? Also using the substitution $g(x) = f(x)e^x$ you get the easier-looking equation $g'(x) = ce*g(x-1)$. –  Cocopuffs Aug 12 '12 at 19:45
hmm. though it could work, I don't think I am supposed to. I suspected I might need to do an expansion though? That equation does not look easier! –  Magpie Aug 12 '12 at 20:00
FWIW, a DDE often requires a bit more work to solve than an ODE. At least @Norbert has told you the name of what you're dealing with. –  Ｊ. Ｍ. Aug 13 '12 at 4:02

If you plug in $f(x) = A e^{kx}$ you find that this satisfies your equation whenever $k+1 = c e^{-k}$.

So for every (real or complex) $k$ satisfying: $$k+1 = c e^{-k}$$ You have a solution of the form $A e^{kx}$

By linearity, arbitrary linear combinations of solutions are solutions. Even if you're just looking for real solutions, you still have to consider complex $k$ because if $$k = a + i b$$ satisfies:

$$k+1 = c e^{-k}$$

Then it follows, that $\cos(bx) e^{ax}$ and $\sin(bx) e^{ax}$ are solutions.

Since (for $c \ne 0$) $k + 1 = c e^{-k}$ has infinitely many complex solutions, this gives an infinite-dimensional family of solutions of your equation.

-

It is not true that any solution of the given equation has the form $Ae^{nx}$. It does have solutions of that form, however, and you can find them by simply plugging $f(x)=Ae^{nx}$ into the equation and solving for $n$ ($A$ drops out immediately, assuming $A\ne0$).

The general solution allows $f(x)$ to be an arbitrary (well, not too pathological) function in some interval of length 1, say, for $x\in[0,1]$. From there you can get the solution on $[1,2]$ by considering the right hand side a known function (since $x\in[1,2]$ implies $x-1\in[0,1]$, so $f(x-1)$ is known), and using the method of integrating factors. Next, you get the solution on $[2,3]$, and so forth.

-
That's true, well spotted. It is only true if n satisfies $$n+1 = ce^{-n}$$ I should put that in the question too.. –  Magpie Aug 12 '12 at 20:02
No, I think you missed my point. That is the equation when you try to find a solution of the given form, but even so, there are other solutions which don't have that form. (I edited my answer a wee bit to clarify.) –  Harald Hanche-Olsen Aug 12 '12 at 20:12
Assuming you want the solution on all of $\mathbb R$, you also have to go backwards, with $f(x-1) = (f'(x) + f(x))/c$, to get solutions on $[-1,0]$, $[-2,-1]$, etc. The trouble is, unless your initial function is chosen very carefully, you will find that $f$ is not differentiable at some negative integer. –  Robert Israel Aug 12 '12 at 21:05
can you elaborate on this please? –  Magpie Aug 13 '12 at 19:38
Well, you get a possible problem already at $x=0$. You want continuity there, right? The limit of $f(x)$ as $x\to0$ from the right will be $f(0)$ (part of the given data), while the limit from the left will be $(f'(1)+f(1))/c$. So you'd better have $f(0)=(f'(1)+f(1))/c$ for the given data, or you're in trouble already. Next, you'll need $f(x-2)=(f'(x-1)+f(x-1))/c=(f''(x)+2f'(x)+f(x))/c^2$, and you get further conditions in order to have continuity at $x=-1$, and so forth. The details get messier with each step, unless you can ferret out a pattern to use. –  Harald Hanche-Olsen Aug 14 '12 at 11:38

Let's solve this using the 'method of steps'.

Let's suppose that for $x\in (-1,0)$ (the initial 'step') we choose $$\tag{0} f(x)=\theta(x)=1+x$$ (this initial function is kind of arbitrary and doesn't need to verify the delayed D.E.)
then we will have for $x\in (0,1)$ and since $f(x-1)\in(-1,0)$ :

$$f'(x)+f(x)=c\theta(x-1)=c(1+x-1)=cx$$ The solution of this is : $$f(x)=c(x-1)+C_0 e^{-x}$$ Since we had $f(0)=1$ from the initial step and to assume continuity we will suppose that $f(0)=1=-c+C_0$ or $C_0=1+c$

$$\tag{1} f(x)=c(x-1)+(1+c)e^{-x}$$

You may continue with this system from step to step. In the next interval $(1,2)$ the $f(x-1)$ at the right will be the $f$ from the previous step $(1)$ and so on... You could search a more general formula but this is not always possible.

-
Thanks, I had not heard of this method, it is something I will definitely look into. –  Magpie Aug 13 '12 at 19:41
@Magpie: you are welcome! These papers from Falbo or Heffernan could help you (Driver's 1977 book 'Ordinary and delay differential equations' too!). –  Raymond Manzoni Aug 13 '12 at 20:28
Thanks! That maple stuff will be handy too. –  Magpie Aug 14 '12 at 0:16