I am trying to iterate the following equation $$ x_{k}(n+1)=x_k (n)-\epsilon (x_{k+1}(n)-2x_k(n) +x_{k-1}(n))+\sqrt{\epsilon}\; \eta_{k}(n) $$ where $n$ denotes which time step I'm on and $k$ is the location on the string with periodic boundary conditions, $\epsilon$ is the size of the time step and $\eta$ is a random variate from a gaussian distribution with mean 0 and variance 1. $\eta$ is re-picked after each time step and is varies from location to location. I generated my initial $x$ randomly with
x[0] = RandomReal[{0, π}, 10]
which gives me 10 real numbers between 0 and $\pi$, which are my 1D lattice site variables. I then define $\eta$ by
η[0] = RandomVariate[NormalDistribution[0, 1], 10]
which gives me 10 random numbers from my distribution. I am taking the time step to be $\epsilon =1/100$ Then to define my iteration equation I write
x[[j]][n_ + 1] := x[[j]][n] - ϵ (x[[j + 1]][n] - 2 x[[j]][n] + x[[j + 1]][n]) + Sqrt[ϵ] η[[j]][n]
but this failed to iterate when I tried when just looking at a sigle site and its neighbors. If someone could be so kind as to help me put in periodic boundary conditions, as well as to get the iteration to work, I would be grateful. I am using Mathematica 8. Thank you.