0
$\begingroup$

Hi I am simulating a Fisher-Wright diffusion, it works

\[Mu] = ( # (1 - #)) &; \[Sigma] = (# (1 - #)/4) &;

FW = ItoProcess[\[DifferentialD]x[t] == \[Mu][t] \[DifferentialD]t + 
     Sqrt[\[Sigma][t]] \[DifferentialD]w[t], x[t], {x, 1/10}, t, 
   w \[Distributed] WienerProcess[]];

path = RandomFunction[FW //. ca, {0., 10, 0.01 }, 6];

lp = ListLinePlot[%]

but the negative values look suspicious (this could be investigated by Feller's boundary classification, but first thought is to add Abs under the square root, and hell breaks loose)

FW = ItoProcess[\[DifferentialD]x[t] == \[Mu][t] \[DifferentialD]t + 
     Sqrt[Abs[\[Sigma][t]]] \[DifferentialD]w[t], x[t], {x, 1/10}, t, 
   w \[Distributed] WienerProcess[]];

path = RandomFunction[FW //. ca, {0., 10, 0.01 }, 6];

lp = ListLinePlot[%]
$\endgroup$
  • $\begingroup$ Expression for ca is needed. $\endgroup$ – Edmund Nov 8 '18 at 22:31
  • $\begingroup$ Do you want \[Mu][t] and \[Sigma][t], or \[Mu][x[t]] and \[Sigma][x[t]]? $\endgroup$ – Chris K Nov 9 '18 at 0:53
  • $\begingroup$ Thanks, Chris K. Indeed, I was solving wrong equation. The results with and without abs are very plausible and quick now :) $\endgroup$ – florin Nov 15 '18 at 15:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.