I want to simulate the paths of a stochastic process $$ dS_t = r S_t dt + \sigma S_t dW_t$$ Using the Forward Euler method, we can write: $$ S_{n+1} = (1 + r \Delta t_n + \sigma \Delta W_{n}) S_n $$
I was wondering if someone have a way to ensure the positivity for the Forward Euler approximation.
Thanks!
First, simulate the paths of the process $(X_t)$ defined by $$X_t=\sigma W_t+\left(r-\tfrac12\sigma^2\right)t,$$ using Euler's scheme $X^\varepsilon_0=0$ and$$X_{n+1}^{\varepsilon}=X_n^{\varepsilon}+\sigma\sqrt\varepsilon Z_n+\left(r-\tfrac12\sigma^2\right)\varepsilon,$$ for every positive $\varepsilon$ and every $n$, where the process $(Z_n)$ is i.i.d. standard normal. Second, deduce an approximation of $$S_t=S_0\cdot\exp(X_t),$$ through the formulas$$S_t\approx S^\varepsilon_{\lfloor t/\varepsilon\rfloor},\qquad S^\varepsilon_n=S_0\cdot\exp(X_n^\varepsilon).$$ Then the positivity of the process $S^\varepsilon$ is ensured.