Skip to content

Commit

Permalink
Merge f4842e8 into 670c5be
Browse files Browse the repository at this point in the history
  • Loading branch information
TorkelE committed Jun 7, 2024
2 parents 670c5be + f4842e8 commit 554beeb
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions docs/src/introduction_to_catalyst/introduction_to_catalyst.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ We first import the basic packages we'll need:

```@example tut1
# If not already installed, first hit "]" within a Julia REPL. Then type:
# add Catalyst DifferentialEquations Plots Latexify
# add Catalyst OrdinaryDiffEq Plots Latexify
using Catalyst, DifferentialEquations, Plots, Latexify
using Catalyst, OrdinaryDiffEq, Plots, Latexify
```

We now construct the reaction network. The basic types of arrows and predefined
Expand Down Expand Up @@ -160,7 +160,7 @@ underlying problem.

At this point we are all set to solve the ODEs. We can now use any ODE solver
from within the
[DifferentialEquations.jl](https://docs.sciml.ai/DiffEqDocs/stable/solvers/ode_solve/)
[OrdinaryDiffEq.jl](https://docs.sciml.ai/DiffEqDocs/stable/solvers/ode_solve/)
package. We'll use the recommended default explicit solver, `Tsit5()`, and then
plot the solutions:

Expand All @@ -169,7 +169,7 @@ sol = solve(oprob, Tsit5(), saveat=10.)
plot(sol)
```
We see the well-known oscillatory behavior of the repressilator! For more on the
choices of ODE solvers, see the [DifferentialEquations.jl
choices of ODE solvers, see the [OrdinaryDiffEq.jl
documentation](https://docs.sciml.ai/DiffEqDocs/stable/solvers/ode_solve/).

---
Expand All @@ -182,6 +182,9 @@ Gillespie's `Direct` method, and then solve it to generate one realization of
the jump process:

```@example tut1
# imports the JumpProcesses packages
using JumpProcesses
# redefine the initial condition to be integer valued
u₀map = [:m₁ => 0, :m₂ => 0, :m₃ => 0, :P₁ => 20, :P₂ => 0, :P₃ => 0]
Expand Down Expand Up @@ -237,6 +240,9 @@ model by creating an `SDEProblem` and solving it similarly to what we did for OD
above:

```@example tut1
# imports the StochasticDiffEq package for SDE simulations
using StochasticDiffEq
# SDEProblem for CLE
sprob = SDEProblem(bdp, u₀, tspan, p)
Expand Down

0 comments on commit 554beeb

Please sign in to comment.