@@ -35,7 +35,7 @@ We first define the parameters, variables, differential equations and the output
35
35
using StructuralIdentifiability, ModelingToolkit
36
36
37
37
# define parameters and variables
38
- @variables t x4 (t) x5 (t) x6 (t) x7 (t) y1 (t) [output = true ] y2 (t) [output = true ]
38
+ @variables t x4 (t) x5 (t) x6 (t) x7 (t) y1 (t) y2 (t)
39
39
@parameters k5 k6 k7 k8 k9 k10
40
40
D = Differential (t)
41
41
@@ -44,11 +44,12 @@ eqs = [
44
44
D (x4) ~ - k5 * x4 / (k6 + x4),
45
45
D (x5) ~ k5 * x4 / (k6 + x4) - k7 * x5/ (k8 + x5 + x6),
46
46
D (x6) ~ k7 * x5 / (k8 + x5 + x6) - k9 * x6 * (k10 - x6) / k10,
47
- D (x7) ~ k9 * x6 * (k10 - x6) / k10,
48
- y1 ~ x4,
49
- y2 ~ x5
47
+ D (x7) ~ k9 * x6 * (k10 - x6) / k10
50
48
]
51
49
50
+ # define the output functions (quantities that can be measured)
51
+ measured_quantities = [y1 ~ x4, y2 ~ x5]
52
+
52
53
# define the system
53
54
de = ODESystem (eqs, t, name= :Biohydrogenation )
54
55
@@ -58,7 +59,7 @@ After that we are ready to check the system for local identifiability:
58
59
``` julia
59
60
# query local identifiability
60
61
# we pass the ode-system
61
- local_id_all = assess_local_identifiability (de, 0.99 )
62
+ local_id_all = assess_local_identifiability (de, measured_quantities = measured_quantities, p = 0.99 )
62
63
# [ Info: Preproccessing `ModelingToolkit.ODESystem` object
63
64
# 6-element Vector{Bool}:
64
65
# 1
@@ -73,7 +74,7 @@ We can see that all states (except $x_7$) and all parameters are locally identif
73
74
Let's try to check specific parameters and their combinations
74
75
``` julia
75
76
to_check = [k5, k7, k10/ k9, k5+ k6]
76
- local_id_some = assess_local_identifiability (de, to_check, 0.99 )
77
+ local_id_some = assess_local_identifiability (de, funcs_to_check = to_check, p = 0.99 )
77
78
# 4-element Vector{Bool}:
78
79
# 1
79
80
# 1
@@ -108,23 +109,24 @@ __Note__: as of writing this tutorial, UTF-symbols such as Greek characters are
108
109
``` julia
109
110
using StructuralIdentifiability, ModelingToolkit
110
111
@parameters b c a beta g delta sigma
111
- @variables t x1 (t) x2 (t) x3 (t) x4 (t) y (t) [output = true ]
112
+ @variables t x1 (t) x2 (t) x3 (t) x4 (t) y (t)
112
113
D = Differential (t)
113
114
114
115
eqs = [
115
116
D (x1) ~ - b * x1 + 1 / (c + x4),
116
117
D (x2) ~ a * x1 - beta * x2,
117
118
D (x3) ~ g * x2 - delta * x3,
118
- D (x4) ~ sigma * x4 * (g * x2 - delta * x3)/ x3,
119
- y~ x1
119
+ D (x4) ~ sigma * x4 * (g * x2 - delta * x3)/ x3
120
120
]
121
121
122
+ measured_quantities = [y~ x1]
123
+
122
124
123
125
ode = ODESystem (eqs, t, name= :GoodwinOsc )
124
126
125
- @time global_id = assess_identifiability (ode)
127
+ @time global_id = assess_identifiability (ode, measured_quantities = measured_quantities )
126
128
# 28.961573 seconds (88.92 M allocations: 5.541 GiB, 4.01% gc time)
127
- # Dict{Nemo.fmpq_mpoly , Symbol} with 7 entries:
129
+ # Dict{Num , Symbol} with 7 entries:
128
130
# c => :globally
129
131
# a => :nonidentifiable
130
132
# g => :nonidentifiable
@@ -140,23 +142,23 @@ Let us consider the same system but with two inputs and we will try to find out
140
142
``` julia
141
143
using StructuralIdentifiability, ModelingToolkit
142
144
@parameters b c a beta g delta sigma
143
- @variables t x1 (t) x2 (t) x3 (t) x4 (t) y (t) [output = true ] u1 (t) [input= true ] u2 (t) [input= true ]
145
+ @variables t x1 (t) x2 (t) x3 (t) x4 (t) y (t) u1 (t) [input= true ] u2 (t) [input= true ]
144
146
D = Differential (t)
145
147
146
148
eqs = [
147
149
D (x1) ~ - b * x1 + 1 / (c + x4),
148
150
D (x2) ~ a * x1 - beta * x2 - u1,
149
151
D (x3) ~ g * x2 - delta * x3 + u2,
150
- D (x4) ~ sigma * x4 * (g * x2 - delta * x3)/ x3,
151
- y~ x1
152
+ D (x4) ~ sigma * x4 * (g * x2 - delta * x3)/ x3
152
153
]
154
+ measured_quantities = [y~ x1]
153
155
154
156
# check only 2 parameters
155
157
to_check = [b, c]
156
158
157
159
ode = ODESystem (eqs, t, name= :GoodwinOsc )
158
160
159
- global_id = assess_identifiability (ode, to_check, 0.9 )
161
+ global_id = assess_identifiability (ode, measured_quantities = measured_quantities, funcs_to_check = to_check, p = 0.9 )
160
162
# Dict{Num, Symbol} with 2 entries:
161
163
# b => :globally
162
164
# c => :globally
0 commit comments