@@ -225,16 +225,18 @@ Finally, to efficiently simulate the new jump process we must also specify a
225225dependency graph. This indicates when a given jump occurs, which jumps in the
226226system need to have their rates and/or rate bounds recalculated (for example,
227227due to depending on changed components in `u`). We also assume the convention
228- that a given jump depends on itself. Since the first (birth) jump modifies the
229- population size `u[1]`, and the second (death) jump occurs at a rate
230- proportional to `u[1]`, when the first jump occurs we need to recalculate both
231- of the rates. In contrast, death does not change `u[1]`, and so the dependencies
232- of the second (death) jump are only itself. Note that the indices in the graph
233- correspond to the order in which the jumps appear when the problem is
234- constructed. The graph below encodes the dependents of the birth and death jumps
235- respectively
228+ that a given jump depends on itself. Internally, JumpProcesses preserves the
229+ relative ordering of jumps of each distinct type, but always reorders all
230+ `ConstantRateJump`s to appear before any `VariableRateJump`s. As such, the
231+ `ConstantRateJump` representing the death process will have internal index 1,
232+ and our new bounded `VariableRateJump` for birth will have internal index 2.
233+ Since birth modifies the population size `u[1]`, and death occurs at a rate
234+ proportional to `u[1]`, when birth occurs we need to recalculate both of rates.
235+ In contrast, death does not change `u[1]`, and so when death occurs we only need
236+ to recalculate the death rate. The graph below encodes the dependents of the
237+ death (`dep_graph[1]`) and birth (`dep_graph[2]`) jumps respectively
236238```@example tut1
237- dep_graph = [[1,2 ], [2]]
239+ dep_graph = [[1], [1, 2]]
238240```
239241
240242We can then construct the corresponding problem, passing both jumps to
0 commit comments