Skip to content

Commit eab9fd9

Browse files
authored
Fix offset in parameter check for lumping (#123)
1 parent aba5cbb commit eab9fd9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/simulator/optimization.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -409,10 +409,10 @@ function optimization_limits!(lims, config, mapper, param, model)
409409
if !isnothing(lumping)
410410
for lno in 1:maximum(lumping)
411411
pos = findfirst(isequal(lno), lumping)
412-
ref_val = vals[pos + offset]
412+
ref_val = vals[pos]
413413
for (i, l) in enumerate(lumping)
414414
if l == lno
415-
if vals[i + offset] != ref_val
415+
if vals[i] != ref_val
416416
error("Initial values for $param_k differed for lumping group $lno at position $i")
417417
end
418418
end

0 commit comments

Comments
 (0)