Skip to content

Commit

Permalink
DOC: fix imports in doc page
Browse files Browse the repository at this point in the history
  • Loading branch information
jpfairbanks committed Jun 8, 2024
1 parent b33b06c commit 6283fc3
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion docs/src/AlgebraicPetri.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,22 @@ You can construct a [`ContinuousResourceSharer`](@ref) from an Open Petri Net fo
2. OpenLabelledPetriNet
3. OpenLabelledReactionNet

````@example
````@example AlgPetri
using AlgebraicPetri
using AlgebraicDynamics
Brusselator = LabelledPetriNet([:A, :B, :D, :E, :X, :Y],
:t1 => (:A => (:X, :A)),
:t2 => ((:X, :X, :Y) => (:X, :X, :X)),
:t3 => ((:B, :X) => (:Y, :D, :B)),
:t4 => (:X => :E)
)
````

You just call the constructor for ContinuousResourceSharer on an Open Petri Net.
The constructor knows where to use labels or integers for the state variables.
It also knows to get parameters from the ReactionNet and enclose them into the dynamics.

````@example AlgPetri
open_bruss = Open([:A, :D], Brusselator, [:A, :B])
rs = ContinuousResourceSharer{Float64}(open_bruss)
````

0 comments on commit 6283fc3

Please sign in to comment.