@@ -710,8 +710,6 @@ function DiffEqBase.ODEProblem(rs::ReactionSystem, u0, tspan,
710
710
combinatoric_ratelaws = get_combinatoric_ratelaws (rs),
711
711
include_zero_odes = true , remove_conserved = false , remove_conserved_warn = true ,
712
712
checks = false , structural_simplify = false , kwargs... )
713
- u0map = symmap_to_varmap (rs, u0)
714
- pmap = symmap_to_varmap (rs, p)
715
713
osys = convert (ODESystem, rs; name, combinatoric_ratelaws, include_zero_odes, checks,
716
714
remove_conserved, remove_conserved_warn)
717
715
@@ -724,7 +722,7 @@ function DiffEqBase.ODEProblem(rs::ReactionSystem, u0, tspan,
724
722
osys = complete (osys)
725
723
end
726
724
727
- return ODEProblem (osys, u0map , tspan, pmap , args... ; check_length, kwargs... )
725
+ return ODEProblem (osys, u0 , tspan, p , args... ; check_length, kwargs... )
728
726
end
729
727
730
728
# NonlinearProblem from AbstractReactionNetwork
@@ -734,12 +732,10 @@ function DiffEqBase.NonlinearProblem(rs::ReactionSystem, u0,
734
732
combinatoric_ratelaws = get_combinatoric_ratelaws (rs),
735
733
remove_conserved = false , remove_conserved_warn = true , checks = false ,
736
734
check_length = false , all_differentials_permitted = false , kwargs... )
737
- u0map = symmap_to_varmap (rs, u0)
738
- pmap = symmap_to_varmap (rs, p)
739
735
nlsys = convert (NonlinearSystem, rs; name, combinatoric_ratelaws, include_zero_odes,
740
736
checks, all_differentials_permitted, remove_conserved, remove_conserved_warn)
741
737
nlsys = complete (nlsys)
742
- return NonlinearProblem (nlsys, u0map, pmap , args... ; check_length,
738
+ return NonlinearProblem (nlsys, u0, p , args... ; check_length,
743
739
kwargs... )
744
740
end
745
741
@@ -749,8 +745,6 @@ function DiffEqBase.SDEProblem(rs::ReactionSystem, u0, tspan,
749
745
name = nameof (rs), combinatoric_ratelaws = get_combinatoric_ratelaws (rs),
750
746
include_zero_odes = true , checks = false , check_length = false , remove_conserved = false ,
751
747
remove_conserved_warn = true , structural_simplify = false , kwargs... )
752
- u0map = symmap_to_varmap (rs, u0)
753
- pmap = symmap_to_varmap (rs, p)
754
748
sde_sys = convert (SDESystem, rs; name, combinatoric_ratelaws,
755
749
include_zero_odes, checks, remove_conserved, remove_conserved_warn)
756
750
@@ -764,7 +758,7 @@ function DiffEqBase.SDEProblem(rs::ReactionSystem, u0, tspan,
764
758
end
765
759
766
760
p_matrix = zeros (length (get_unknowns (sde_sys)), numreactions (rs))
767
- return SDEProblem (sde_sys, u0map , tspan, pmap , args... ; check_length,
761
+ return SDEProblem (sde_sys, u0 , tspan, p , args... ; check_length,
768
762
noise_rate_prototype = p_matrix, kwargs... )
769
763
end
770
764
@@ -784,8 +778,8 @@ struct JumpInputs{S <: MT.JumpSystem, T <: SciMLBase.AbstractODEProblem}
784
778
end
785
779
786
780
"""
787
- jumpinput = JumpInputs(rs::ReactionSystem, u0map , tspan,
788
- pmap = DiffEqBase.NullParameters;
781
+ jumpinput = JumpInputs(rs::ReactionSystem, u0 , tspan,
782
+ p = DiffEqBase.NullParameters;
789
783
name = nameof(rs),
790
784
combinatoric_ratelaws = get_combinatoric_ratelaws(rs),
791
785
checks = false, kwargs...)
@@ -817,13 +811,11 @@ plot(sol, idxs = :A)
817
811
function JumpInputs (rs:: ReactionSystem , u0, tspan, p = DiffEqBase. NullParameters ();
818
812
name = nameof (rs), combinatoric_ratelaws = get_combinatoric_ratelaws (rs),
819
813
checks = false , kwargs... )
820
- u0map = symmap_to_varmap (rs, u0)
821
- pmap = symmap_to_varmap (rs, p)
822
814
jsys = complete (convert (JumpSystem, rs; name, combinatoric_ratelaws, checks))
823
815
if MT. has_variableratejumps (jsys)
824
- prob = ODEProblem (jsys, u0map , tspan, pmap ; kwargs... )
816
+ prob = ODEProblem (jsys, u0 , tspan, p ; kwargs... )
825
817
else
826
- prob = DiscreteProblem (jsys, u0map , tspan, pmap ; kwargs... )
818
+ prob = DiscreteProblem (jsys, u0 , tspan, p ; kwargs... )
827
819
end
828
820
JumpInputs (jsys, prob)
829
821
end
@@ -847,11 +839,9 @@ function DiffEqBase.DiscreteProblem(rs::ReactionSystem, u0, tspan::Tuple,
847
839
name = nameof (rs),
848
840
combinatoric_ratelaws = get_combinatoric_ratelaws (rs),
849
841
checks = false , kwargs... )
850
- u0map = symmap_to_varmap (rs, u0)
851
- pmap = symmap_to_varmap (rs, p)
852
842
jsys = convert (JumpSystem, rs; name, combinatoric_ratelaws, checks)
853
843
jsys = complete (jsys)
854
- return DiscreteProblem (jsys, u0map , tspan, pmap , args... ; kwargs... )
844
+ return DiscreteProblem (jsys, u0 , tspan, p , args... ; kwargs... )
855
845
end
856
846
857
847
# JumpProblem from AbstractReactionNetwork
@@ -878,8 +868,6 @@ function DiffEqBase.SteadyStateProblem(rs::ReactionSystem, u0,
878
868
combinatoric_ratelaws = get_combinatoric_ratelaws (rs),
879
869
remove_conserved = false , remove_conserved_warn = true , include_zero_odes = true ,
880
870
checks = false , structural_simplify = false , kwargs... )
881
- u0map = symmap_to_varmap (rs, u0)
882
- pmap = symmap_to_varmap (rs, p)
883
871
osys = convert (ODESystem, rs; name, combinatoric_ratelaws, include_zero_odes, checks,
884
872
remove_conserved, remove_conserved_warn)
885
873
@@ -892,7 +880,7 @@ function DiffEqBase.SteadyStateProblem(rs::ReactionSystem, u0,
892
880
osys = complete (osys)
893
881
end
894
882
895
- return SteadyStateProblem (osys, u0map, pmap , args... ; check_length, kwargs... )
883
+ return SteadyStateProblem (osys, u0, p , args... ; check_length, kwargs... )
896
884
end
897
885
898
886
# ## Symbolic Variable/Symbol Conversions ###
0 commit comments