Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HOTFIX: Homo-Dimer Reaction Propensities #878

Merged
merged 1 commit into from
Oct 26, 2022

Conversation

BryanRumsey
Copy link
Contributor

Case 1

This case is impossible to catch since python dictionaries don't support duplicate keys.

r1 = gillespy2.Reaction(
    name="r1", reactants={"s1":1, "s1":1}, products={"s1":1, "s2":1}, rate=0.1
)

Case 2

S1 = gillespy2.Species(name="s1", initial_value=999)
r2 = gillespy2.Reaction(
    name="r2", reactants={"s1":1, S1:1}, products={"s1":1, "s2":1}, rate=0.1
)

Propensity Bug

r2
	Reactants
		s1: 1
	Products
		s1: 1
		s2: 1
	Propensity Function: (0.1*s1)

Fixed Propensity

r2
	Reactants
		s1: 2
	Products
		s1: 1
		s2: 1
	Propensity Function: (((0.1*s1)*(s1-1))/vol)

Case 3

r3 = gillespy2.Reaction(
    name="r3", reactants={"s1":1}, products={"s1":1, "s2":1}, rate=0.1
)
r3.add_reactant("s1", 1)

Propensity Bug

r3
	Reactants
		s1: 1
	Products
		s1: 1
		s2: 1
	Propensity Function: (0.1*s1)

Fixed Propensity

r3
	Reactants
		s1: 2
	Products
		s1: 1
		s2: 1
	Propensity Function: (((0.1*s1)*(s1-1))/vol)

closes #876

@BryanRumsey BryanRumsey added this to the 1.7.2 Release milestone Oct 6, 2022
@BryanRumsey BryanRumsey self-assigned this Oct 6, 2022
@BryanRumsey BryanRumsey mentioned this pull request Oct 6, 2022
@briandrawert briandrawert merged commit f2a34de into develop Oct 26, 2022
@briandrawert briandrawert deleted the hotfix-hdma-propensities branch October 26, 2022 20:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants