I'm trying to evaluate an inflation linked derivative using the Jarrow-Yildirim model (2003).
It goes like that:
$dn(t) = [\theta_{n}(t) - a_{n}n(t)]dt + \sigma_{n}dW_{n}(t)$
$dr(t) = [\theta_{r}(t) - \rho_{r, i}\sigma_{r}\sigma_{i} - a_{r}r(t)]dt + \sigma_{r}dW_{r}(t)$
$di(t) = i(t)[n(t)-r(t)]dt + \sigma_{i}i(t)dW_{i}(t)$
where $n(t)$, $r(t)$ and $i(t)$ are respectively the nominal interest rate, the reel interest rate and the inflation index. $a_{n}$ and $a_{r}$ are known constants and $W_{n}(t)$, $W_{r}(t)$, $W_{i}(t)$ are standard Wiener processes. $\theta_{j}(t)$ is defined as follows:
$\theta_{j}(t) = \dfrac{\partial f_{j}(0, t)}{\partial T} + a_{j}f_{j}(0, t) + \dfrac{\sigma_{j}^{2}}{2a_{j}}(1- e^{-2a_{j}t}), j \in \{n, r \}$
The form of $f(0, t)$ can be obtained by the Nelson-Siegel model.
The solutions to the PDEs above are:
$n(t) = n(s)e^{-a_{n}(t-s)}+ \int_{s}^{t}e^{-a_{n}(t-u)}\theta_{n}(u)du + \sigma_{n}e^{-a_{n}t}\int_{s}^{t}e^{a_{n}u}dW_{n}(u)$
$r(t) = r(s)e^{-a_{r}(t-s)}+ \int_{s}^{t}e^{-a_{r}(t-u)}(\theta_{r}(u)-\rho_{r, i}\sigma_{r}\sigma_{i})du + \sigma_{r}e^{-a_{r}t}\int_{s}^{t}e^{a_{r}u}dW_{r}(u)$
$i(t) = i(s)e^{\int_{s}^{t}[n(u)-r(u)]du - \dfrac{\sigma^{2}_{i}}{2}(t-s) + \sigma_{i}(W_{t}-W_{s})}$
My question is concerning integrals under $n(t)$ and $r(t)$. Since i'm doing a Monte-Carlo simulation, I only need to find what laws drive those terms so I can simulate them.
First, $\int_{s}^{t}e^{-a_{n}(t-u)}\theta_{n}(u)du$ and $\int_{s}^{t}e^{-a_{r}(t-u)}(\theta_{r}(u)-\rho_{r, i}\sigma_{r}\sigma_{i})du$ are deterministic integrals but somehow, i'm having trouble to solve them. Since $\theta_{n}$ and $\theta_{r}$ are functions of time, should I only integrate each component of these terms with respect to time?
Also, it seems like $\sigma_{n}e^{-a_{n}t}\int_{s}^{t}e^{a_{n}u}dW_{n}(u)$ and $\sigma_{r}e^{-a_{r}t}\int_{s}^{t}e^{a_{r}u}dW_{r}(u)$ are respectively equivalent in law to $\dfrac{\sigma_{n}e^{-a_{n}t}}{\sqrt{2a_{n}}} \sqrt{e^{2a_{n}t}-e^{2a_{n}s}} \epsilon_{1}$ and $\dfrac{\sigma_{r}e^{-a_{r}t}}{\sqrt{2a_{r}}} \sqrt{e^{2a_{r}t}-e^{2a_{r}s}} \epsilon_{2}$ where $\epsilon_{1}$ and $\epsilon_{2}$ ~ $N(0, 1)$. Can someone familiar with such terms validate my answer?
These terms somehow look really messy. And it seems you also made many typos
I'll start with your last question. According to my calculation, your observation is right.
Regarding the first question, I think for the first integral, you have written wrongly $a_r$ instead of $a_n$ ( in the exponential's power). The second integral looks okay.
As for how to integrate them, I don't think it is that complicated because it seems that :
$ e^{a_it} \theta_i(t)= \frac{\partial(g_i)}{\partial t}(t)+\text{some explicit functions}$
where $g_i(t)= e^{a_it}f_i(0,t)$