42

Wikipedia says

The Ornstein–Uhlenbeck process can also be considered as the continuous-time analogue of the discrete-time AR(1) process.

I was wondering how the Ornstein–Uhlenbeck process can be considered as the continuous-time analogue of the discrete-time AR(1) process?

An Ornstein–Uhlenbeck process, $x_t$, satisfies the following stochastic differential equation: $$ dx_t = \theta (\mu-x_t)\,dt + \sigma\, dW_t $$ where $\theta > 0, \mu$ and $\sigma > 0$ are parameters and $W_t$ denotes the Wiener process.

The $AR(p)$ model, i.e. an autoregressive model of order $p$, is defined as $$ X_t = c + \sum_{i=1}^p \varphi_i X_{t-i}+ \varepsilon_t \, $$ where $\varphi_1, \ldots, \varphi_p$ are the parameters of the model, $c$ is a constant, and $\varepsilon_t$ is white noise.

Thanks and regards!

Tim
  • 47,382

3 Answers3

35

In case $p=1$ you have $$ x_{k+1} = c+a x_k + b\varepsilon_k $$ so that if you put $c = \theta\mu\Delta t$, $a = -\theta\Delta t$ and $b = \sigma\sqrt{\Delta t}$ you get $$ x_{k+1} = \theta(\mu - x_k)\Delta t + \sigma \varepsilon_k\sqrt{\Delta t} $$ which is exactly an Euler-Maryuama discretization of OU at times $(k\Delta t)_{k\in \Bbb N_0}$.

rubik
  • 9,344
SBF
  • 36,041
  • Very clear ... good answer. – Richi W Oct 03 '14 at 08:09
  • 3
    I remembered your answer and posted it a bit differently answering another question here. Don't you need the approximation $dX_t \approx X_{k+1}-X_k$ on the left hand side and then you put the $X_k$ on the rhs and get another paramter as the AR coefficient? – Richi W Apr 01 '15 at 13:15
  • @Richard seems to be the case – SBF Apr 01 '15 at 17:57
  • 1
    I am a little confused by the interpretation of the result above. If a=-theta*Delta t then theta=-a/(Delta t). In this case if you have a positive AR parameter such as 0.9 it will give rise to a negative theta say -0.9 (if Delta t=1 Delta t will always be positive). In this case if you get an observation above the mean (mu-x_k) will be negative and this value will be multiplied by a negative value meaning that the drift term will add to an observation that is already above the mean? Is this correct? – Bazman Sep 02 '15 at 15:25
  • Amazing Answer thanks! :) – ABIM Jun 17 '16 at 15:26
  • 1
    @Richard you are right, the answer as it is now is incorrect. What you describe is the way forward: you then obtain $a=1-\theta\Delta t$ (while $c$ is correct). In any case this provides only an approximation; see my answer for a solution which corresponds to an exact sampling of the OU process. – Luca Citi Apr 25 '17 at 22:36
  • @Bazman, you are also right. My comment above for Richard should also address your doubt. – Luca Citi Apr 25 '17 at 22:37
  • Should there not be a \Delta x_{t+1} on the left-hand-side (LHS) of the bottom equation? The OU process has a derivative on the LHS. You can move the X_t term on the RHS, but as presented it is confusing. – Dionysios Georgiadis Mar 05 '18 at 04:30
  • @DionysiosGerogiadis: you're right, thanks - feel free to suggest an edit – SBF Mar 05 '18 at 04:39
  • And what if the auto-regressive order $p>1$? – Confounded Jun 02 '20 at 11:59
25

Rather than using an approximation (like Euler-Maryuama), one can just sample* the continuous-time solution:

$$x(t)=x(0)\,e^{-\theta t}+\mu \,(1-e^{-\theta t})+\sigma \int _{0}^{t}e^{-\theta (t-s)}\,dW_{s}.\, $$

Writing $X_k=x(k\,\Delta t)$, the sampled process is described by the AR(1) process: $$ X_{k+1} = c + \varphi \,X_k + \varepsilon_k $$ where: \begin{align} X_0&=x(0),\\ \varphi &= e^{-\theta \Delta t},\\ c &= (1-\varphi)\mu, \\ \epsilon_k &\sim \mathcal{N}\Big(0,\frac{1}{2\theta}\sigma^2\big(1-e^{-2 \theta \Delta t}\big)\Big). \end{align}

* I mean sample, not sample

Luca Citi
  • 1,809
  • 2
    Could you please suggest an article from where your answer is taken. Thanks! – Shanks Jan 04 '19 at 14:45
  • This is a great answer as it indicates how to discretise the continuous process properly so that it has the same stationary distribution. – James Griffin Mar 31 '19 at 09:18
  • This works if one has a known close form solution for the SDE of the continuous-time process; but in most cases one does not. So, how do you "sample" then? – Confounded Jun 02 '20 at 13:01
  • 2
    @Confounded Sorry, I am not following you... The OP asked about the OU process, whose general form is $dx_t = \theta (\mu-x_t),dt + \sigma, dW_t$. For this process, I provided the corresponding AR(1) in my answer. If you are asking about general SDEs (not OUs), then my answer does not apply but, in general, there is no corresponding discrete-time AR(1) process either. – Luca Citi Jun 04 '20 at 18:24
  • @Shanks you asked for the article reference right. This comes directly from the wikipedia article--or at least the same derivation is basically there as well, in the "formal solution" section. https://en.wikipedia.org/wiki/Ornstein%E2%80%93Uhlenbeck_process – krishnab Dec 20 '20 at 05:49
4

Should be a comment on Ilya's answer but I don't have enough reputation --

Although the other answer does show how the AR process is equivalent to the OU process, keep in mind that the Euler-Maruyama discretization is just an approximation. In order to derive the exact relationship between the two models, you would have to integrate the OU process from time t to t+1, and then derive the various relationships between the parameters. Luckily there is a closed form solution to the OU SDE, so this is not too difficult.

EDIT: you could also use the Milstein Discretization, which is a more accurate approximation because it includes the convexity term from Ito's lemma. But it is still easier than the exact solution.

Paul
  • 557
  • 3
    Paul, I don't think in this case the Milstein Discretization and the Euler-Maruyama discretization yield a different result. Because the diffusion term does not have a state dependence – gota Oct 23 '15 at 14:38