Skip to main content

Table 4 The Hybrid Simulation Algorithm (Algorithm 2)

From: Fine-tuning anti-tumor immunotherapies via stochastic simulations

Require: (T0, E0, I0), t0, t stop .

1: initialize the simulation as for Algorithm 1;

2: while t < t stop do

3:    pick a value for Ï„ as in Algorithm 1;

4:    get θ next = min{θ i ∈ Θ | θ i >t}

5:    if Ï„ < θ next then

6:       fire a reaction as in Algorithm 1;

7:    else

8:       update (T, E, I(t)) to (T, E + w next , I(t + θ next )) and change clock to t + θ next ;

9:    end if

10: end while

  1. Input: initial state (T0, E0, I0), start time t0, stop time t stop .