You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
SBMLToolkit and SBMLImporter have a problem in that sbml provides a propensity and then which reactants get updated. Hence, the following reaction
k, X --> Y
in SBML is straightforwardly written as
k*X, X => Y
now, this is bad for jump simulations.
At some point, either in these packages, or in Catalyst, it would make sense to write a function which takes a reaction and, if it is not a mass action reaction, checks if it can be rewritten as such.
For a starter, with reactions encoded using =>, we could probably just check all, 0th (technically no diff, but still might be nicer to convert => to -->, 1st, 2nd, and 3rd order reaction, having alternatives for all possible combinations:
# 0th order
..., 0 => ...
# 1st order
... * X, X => ...
# 2nd order
... * X*Y, X + Y => ...
... * X^2, 2X => ...
# 3rd order
... * X*Y*Z, X + Y + Z => ...
... * X*Y^2, X + 2Y => ...
... * X^3, 3X => ...
and convert them appropriately.
I think it would make sense to write this in Catalyst, we might also be able to reuse it for other stuff. We could also make it work on some --> reactions, like rewriting
k*E, X --> Y
to
k, X + E --> Y + E
Finally, we could also write a "detector" which checks if such rewritings would be possible, and throws a warning when e.g. Jump simulations are carried out.
It needs not be perfect, but I think we should be able to, relatively easily, write something that covers 95% of cases.
The text was updated successfully, but these errors were encountered:
I think this is more of a SBMLToolkit reaction construction issue, since we generally expect users to specify their reaction as they want it represented.
I don't see it as an operation on a ReactionSystem though. It should be an internal operation within the SBML parsers, which should be detecting that the reaction they are parsing is mass action and building a correct Reaction in Catalyst.
It seems computationally inefficient to build an incorrect ReactionSystem and transform it instead of just building the correct system from the start.
SBMLToolkit and SBMLImporter have a problem in that sbml provides a propensity and then which reactants get updated. Hence, the following reaction
in SBML is straightforwardly written as
now, this is bad for jump simulations.
At some point, either in these packages, or in Catalyst, it would make sense to write a function which takes a reaction and, if it is not a mass action reaction, checks if it can be rewritten as such.
For a starter, with reactions encoded using
=>
, we could probably just check all, 0th (technically no diff, but still might be nicer to convert=>
to-->
, 1st, 2nd, and 3rd order reaction, having alternatives for all possible combinations:and convert them appropriately.
I think it would make sense to write this in Catalyst, we might also be able to reuse it for other stuff. We could also make it work on some
-->
reactions, like rewritingto
Finally, we could also write a "detector" which checks if such rewritings would be possible, and throws a warning when e.g. Jump simulations are carried out.
It needs not be perfect, but I think we should be able to, relatively easily, write something that covers 95% of cases.
The text was updated successfully, but these errors were encountered: