2
$\begingroup$

Consider the following stochastic differential equation

Ie = 0.5; a = 0.7; b = 0.8; \[Tau] = 12.5;
q[v_, w_] := v - v^3/3 - w + Ie;
p[v_, w_] := 1/\[Tau] (v + a - b w);
\[Sigma] = 1;
sol2 = RandomFunction[
   ItoProcess[{\[DifferentialD]v[t] == 
      q[v[t], w[t]] \[DifferentialD]t + \[Sigma] \[DifferentialD]W[
          t], \[DifferentialD]w[t] == 
      p[v[t], w[t]] \[DifferentialD]t}, {v[t], 
     w[t]}, {{v, w}, {0.1, 0.1}}, t, 
    W \[Distributed] WienerProcess[0, \[Sigma]]], {0, 50, 0.001}];

ListLinePlot[sol2, PlotRange -> All]

How can I manually have the time step change from 0.001 to 0.000001 whenever v[t]<0?

$\endgroup$

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.