Skip to content

Commit

Permalink
up
Browse files Browse the repository at this point in the history
  • Loading branch information
TorkelE committed May 30, 2024
1 parent bfa8f90 commit c86c500
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
4 changes: 1 addition & 3 deletions docs/pages.jl
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,11 @@ pages = Any[
],
"Model simulation" => Any[
"model_simulation/simulation_introduction.md",
# Simulation introduction.
"model_simulation/simulation_plotting.md",
"model_simulation/simulation_structure_interfacing.md",
"model_simulation/ensemble_simulations.md",
# Stochastic simulation statistical analysis.
"model_simulation/ode_simulation_performance.md",
# ODE Performance considerations/advice.
# SDE Performance considerations/advice.
# Jump Performance considerations/advice.
# Finite state projection
Expand All @@ -51,7 +49,7 @@ pages = Any[
# ODE parameter fitting using Turing.
# SDE/Jump fitting.
"inverse_problems/behaviour_optimisation.md",
#"inverse_problems/structural_identifiability.md",
#"inverse_problems/structural_identifiability.md", # Broken on Julia v1.10.3, requires v1.10.2 or 1.10.4.
# Practical identifiability.
"inverse_problems/global_sensitivity_analysis.md",
"Inverse problem examples" => Any[
Expand Down
8 changes: 4 additions & 4 deletions docs/src/steady_state_functionality/bifurcation_diagrams.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ nothing # hide

Finally, we compute our bifurcation diagram using:
```@example ex1
bif_dia = bifurcationdiagram(bprob, PALC(), 2, opts_br; bothside = true)
bif_dia = bifurcationdiagram(bprob, PALC(), 2, (args...) -> opts_br; bothside = true)
nothing # hide
```
Where `PALC()` designates that we wish to use the pseudo arclength continuation method to track our solution. The third argument (`2`) designates the maximum number of recursions when branches of branches are computed (branches appear as continuation encounters certain bifurcation points). For diagrams with highly branched structures (rare for many common small chemical reaction networks) this input is important. Finally, `bothside = true` designates that we wish to perform continuation on both sides of the initial point (which is typically the case).
Expand All @@ -69,7 +69,7 @@ opt_newton = NewtonPar(tol = 1e-9, max_iterations = 1000)
opts_br = ContinuationPar(p_min = p_span[1], p_max = p_span[2],
dsmin = 0.001, dsmax = 0.01, max_steps = 1000,
newton_options = opt_newton)
bif_dia = bifurcationdiagram(bprob, PALC(), 2, opts_br; bothside=true)
bif_dia = bifurcationdiagram(bprob, PALC(), 2, (args...) -> opts_br; bothside = true)
nothing # hide
```
(however, in this case these additional settings have no significant effect on the result)
Expand All @@ -79,7 +79,7 @@ Let's consider the previous case, but instead compute the bifurcation diagram ov
```@example ex1
p_span = (2.0, 15.0)
opts_br = ContinuationPar(p_min = p_span[1], p_max = p_span[2], max_steps = 1000)
bif_dia = bifurcationdiagram(bprob, PALC(), 2, opts_br= true)
bif_dia = bifurcationdiagram(bprob, PALC(), 2, (args...) -> opts_br; bothside = true)
plot(bif_dia; xguide = "k1", yguide = "X")
```
Here, in the bistable region, we only see a single branch. The reason is that the continuation algorithm starts at our initial guess (here made at $k1 = 4.0$ for $(X,Y) = (5.0,2.0)$) and tracks the diagram from there. However, with the upper bound set at $k1=15.0$ the bifurcation diagram has a disjoint branch structure, preventing the full diagram from being computed by continuation alone. In this case it could be solved by increasing the bound from $k1=15.0$, however, this is not possible in all cases. In these cases, *deflation* can be used. This is described in the [BifurcationKit documentation](https://bifurcationkit.github.io/BifurcationKitDocs.jl/dev/tutorials/tutorials2/#Snaking-computed-with-deflation).
Expand All @@ -103,7 +103,7 @@ bprob = BifurcationProblem(kinase_model, u_guess, p_start, :d; plot_var = :Xp, u
p_span = (0.1, 10.0)
opts_br = ContinuationPar(p_min = p_span[1], p_max = p_span[2], max_steps = 1000)
bif_dia = bifurcationdiagram(bprob, PALC(), 2, opts_br; bothside = true)
bif_dia = bifurcationdiagram(bprob, PALC(), 2, (args...) -> opts_br; bothside = true)
plot(bif_dia; xguide = "d", yguide = "Xp")
```
This bifurcation diagram does not contain any interesting features (such as bifurcation points), and only shows how the steady state concentration of $Xp$ is reduced as $d$ increases.
Expand Down

0 comments on commit c86c500

Please sign in to comment.