Skip to content

Commit

Permalink
Fix AIBECS function name (F instead of fun)
Browse files Browse the repository at this point in the history
  • Loading branch information
briochemc committed Aug 30, 2023
1 parent 71dc501 commit 69deb25
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name = "GNOM"
authors = ["Benoit Pasquier <briochemc@gmail.com>"]
version = "2.0.1"
version = "2.0.2"

[deps]
AIBECS = "ace601d6-714c-11e9-04e5-89b7fad23838"
Expand Down
4 changes: 2 additions & 2 deletions src/Nd_model/model_setup.jl
Original file line number Diff line number Diff line change
Expand Up @@ -439,9 +439,9 @@ p = Params()
x = ustrip.(mol/m^3, 10pM) * ones(nb)
x = [x; x]
# state function and its Jacobian
fun = AIBECSFunction(T_D, Gs, nb, Params)
F = AIBECSFunction(T_D, Gs, nb, Params)
# problem
prob = SteadyStateProblem(fun, x, p)
prob = SteadyStateProblem(F, x, p)

resetup = false # flag for plotting to avoid resetting everything up

Expand Down
4 changes: 2 additions & 2 deletions src/Nd_model/parameter_sensitivity_test.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

# This lines sets up the model (and `F`) only once,
# so that you rerunning this file will not repeat the entire model setup
!isdefined(Main, :fun) && include("model_setup.jl")
!isdefined(Main, :F) && include("model_setup.jl")

# This should create a new run name every time you run the file
# And add an empty runXXX file to the single_runs folder
Expand Down Expand Up @@ -88,7 +88,7 @@ for k in [:K_dust, :K_POC, :K_prec, :K_bSi]
# "opt" is a misnomer but it is simpler for plotting scripts

# Set the problem with the parameters above
prob = SteadyStateProblem(fun, x, p)
prob = SteadyStateProblem(F, x, p)

# solve the system
sol = solve(prob, CTKAlg(), preprint="Nd & εNd solve ", τstop=ustrip(s, 1e3Myr)).u
Expand Down
4 changes: 2 additions & 2 deletions src/Nd_model/single_run.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

# This lines sets up the model (and `F`) only once,
# so that you rerunning this file will not repeat the entire model setup
!isdefined(Main, :fun) && include("model_setup.jl")
!isdefined(Main, :F) && include("model_setup.jl")

# This should create a new run name every time you run the file
# And add an empty runXXX file to the single_runs folder
Expand Down Expand Up @@ -85,7 +85,7 @@ tp_opt = AIBECS.table(p)# table of parameters
jldsave(joinpath(archive_path, "model$(headcommit)_single_run$(run_num)_$(circname).jld2"); headcommit, tp_opt)

# Set the problem with the parameters above
prob = SteadyStateProblem(fun, x, p)
prob = SteadyStateProblem(F, x, p)

# solve the system
sol = solve(prob, CTKAlg(), preprint="Nd & εNd solve ", τstop=ustrip(s, 1e3Myr)).u
Expand Down
4 changes: 2 additions & 2 deletions src/Nd_model/single_run_PWtest.jl
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

# This lines sets up the model (and `F`) only once,
# so that you rerunning this file will not repeat the entire model setup
!isdefined(Main, :fun) && include("model_setup.jl")
!isdefined(Main, :F) && include("model_setup.jl")

# This should create a new run name every time you run the file
# And add an empty runXXX file to the single_runs folder
Expand Down Expand Up @@ -85,7 +85,7 @@ tp_opt = AIBECS.table(p)# table of parameters
jldsave(joinpath(archive_path, "model$(headcommit)_single_run$(run_num)_$(circname).jld2"); headcommit, tp_opt)

# Set the problem with the parameters above
prob = SteadyStateProblem(fun, x, p)
prob = SteadyStateProblem(F, x, p)

# solve the system
sol = solve(prob, CTKAlg(), preprint="Nd & εNd solve ", τstop=ustrip(s, 1e3Myr)).u
Expand Down

0 comments on commit 69deb25

Please sign in to comment.