Skip to content

Commit

Permalink
fix fig 418
Browse files Browse the repository at this point in the history
  • Loading branch information
sosiristseng committed Oct 5, 2023
1 parent 294c8de commit ba9f98c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions docs/figs/ch4-18.jl
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,16 @@ function model418!(D, u, p, t)
end

function ainf(k1)
ps = LVector(k1 = k1, k2 = 5.0, k3 = 5.0, k4 = 5.0, k5 = 2.0, n = 4)
ps = LVector(k1 = k1, k2 = 5., k3 = 5., k4 = 5., k5 = 2., n = 4.)
u0 = LVector(a=0., b=0.)
prob = SteadyStateProblem(model418!, u0, ps)
sol = solve(prob)
sol = solve(prob, DynamicSS(Rodas5()))
return sol.u.a
end

#---
fig = plot(
ainf, 0, 1000,
ainf, 0., 1000.,
title = "Fig 4.18",
xlabel = "K1" , ylabel= "Steady state [A]",
legend=nothing, ylim=(0, 4), xlim=(0, 1000)
Expand Down

0 comments on commit ba9f98c

Please sign in to comment.