3

How can I solve the ODE:

$f'(x) = f(x) - f(x-1)$ where $f(0)= 0$, and $x \geq 0$

Note: I am trying to solve a problem where it came up and I haven't done DE for years and thus not sure where to start.

Ѕᴀᴀᴅ
  • 35,369
  • 1
    I don't think that this would be considered an ordinary differential equation, in ODEs the function itself as well as the derivatives are all evaluated at the same point. – flawr Sep 23 '18 at 18:42
  • 5
    This is not an ODE, but a delay differential equation. – Kusma Sep 23 '18 at 18:42
  • 1
    corrected the question – melatonin15 Sep 23 '18 at 18:43
  • 2
    One solution is $f(x)=0$. – Kusma Sep 23 '18 at 18:47
  • 3
    One solution is $f(x) = constant$. The other solution can be found by considering $f(x) = exp(C*x)$. – M. Wind Sep 23 '18 at 18:59
  • I am interested in the solution of the form $f(x) = exp(Cx)$ since I am trying to solve this problem: You are given black-box which returns a random number between 0 and 1(uniform distribution).You keep generating random numbers X1,X2,X3 and so on and store the sum of all those random numbers. You stop as soon as the sum exceeds 1.What is the expected number of random variables used in the process?

    I formulated this problem as the above differential equation. Now, if I show $exp(x)$ satisfies the condition at $x=0$ and the differential equation, is that enough?

    – melatonin15 Sep 23 '18 at 19:10
  • 1
    No, that is not enough. Because the overall solution is $f(x) = A + B * exp(C*x)$, where $C$ follows from substution into the original equation. The parameters $A$ and $B$ are free, and determined by the boundary conditions. – M. Wind Sep 23 '18 at 19:21
  • Yes. $B=-A$ and $C$ is a constant which we can express in terms of W Lambert function – Jakobian Sep 23 '18 at 19:23
  • 1
    $C$ turns out to be $0$. Not terribly interesting. – robjohn Sep 23 '18 at 19:35
  • 2
    We can define $f$ pretty freely on $[-1,0]$ and compute $f$ on $[0,1]$ via integration, then $[1,2]$, and so on. That is, there are many possible solutions. – robjohn Sep 23 '18 at 19:44
  • @robjohn, not sure what you mean. Could you please elaborate? – melatonin15 Sep 23 '18 at 20:11
  • @hi15: I was going to use the example of $f(x)=x$ on $[-1,0]$, but that turns out to be a solution for all $x\in\mathbb{R}$. So let's try $f(x)=-x^2$ on $[-1,0]$. Then we need to solve $f(x)-f'(x)=-(x-1)^2$ which leads to the solution of $-x^2-1+e^x$ on $[0,1]$, which then leads to the solution of $-x^2+(2-x)e^{x-1}+e^x-2$ on $[1,2]$, etc. – robjohn Sep 23 '18 at 21:52
  • Actually, $f(x)=cx$ is a solution for any $c$ and all $x\in\mathbb{R}$. – robjohn Sep 23 '18 at 22:03
  • Why we can't take laplace transform, get $\mathcal{L}(f)(s)=0$ for all $s$ big, and then obtain $f=0$? – Veridian Dynamics Sep 24 '18 at 00:25

0 Answers0