jjtapia / nfsim

Automatically exported from code.google.com/p/nfsim
0 stars 0 forks source link

Local functions on products #12

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
In principle, it should be possible to define a local function based on the 
properties of the products of a rule. As an example, one might want to base the 
rate of dissociation of a species on the sizes of the produced aggregates, with 
large aggregates having a smaller rate of dissociation because they are less 
likely to diffuse away before rebinding. The rule might look like:

L(s!+,s!1).R(s!1)->%x:L(s!+,s)+%y:R(s) km2*if(both_large(x,y)>0.5,p,1.0)

where

1. p<<1
2. both_large(x,y) = FunctionProduct("large(x)","large(y)")
3. large(x) = if(Rtot(x)>T,1.0,0.0)
4. T is a threshold (integer)
5. Molecules Rtot R()

Original issue reported on code.google.com by lh64@cornell.edu on 13 Mar 2015 at 3:14

GoogleCodeExporter commented 9 years ago
A more general idea would be to introduce the concept of catalysts (and local 
functions on catalysts) to BioNetGen/NFSim, similar to Modifiers in SBML: 
species that are neither reactants nor products but that have an effect in the 
RateLaw. 

As such local function on products would be an special case of this were a 
product catalyzes its own reaction. We currently have no syntax to represent 
this so this might require some more discussion though.

Original comment by jjta...@gmail.com on 13 Mar 2015 at 3:20

GoogleCodeExporter commented 9 years ago
Note: One way to implement this is to use reject sampling, i.e., test the 
product sizes after a rule has been fired and then accept the reaction with 
probability 'p' if both products satisfy the condition.

Original comment by lh64@cornell.edu on 13 Mar 2015 at 3:25