Skip to content

Commit

Permalink
Create free pool concentration objects for components of lipid and ca…
Browse files Browse the repository at this point in the history
…rbohydrate for use in rate laws
  • Loading branch information
YinHoon committed Feb 26, 2020
1 parent b4a11e8 commit d62c6ba
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion wc_model_gen/eukaryote/metabolism.py
Expand Up @@ -374,8 +374,16 @@ def gen_rate_laws(self):
cytosol = model.compartments.get_one(id='c')
beta = self.options['beta']

# Rate law for carbohydrate formation
# Rate laws for carbohydrate and lipid formation
for reaction in model.submodels.get_one(id='macromolecular_formation').reactions:
for reactant in reaction.get_reactants():
if not reactant.distribution_init_concentration:
conc_model = model.distribution_init_concentrations.create(
species=reactant,
mean=0.,
units=unit_registry.parse_units('molecule'),
comments='Set to zero assuming there is no free pool concentration')
conc_model.id = conc_model.gen_id()
substrates = [[i.species_type.id] for i in reaction.get_reactants()]
expressions, all_species, all_parameters, all_volumes, all_observables = utils.gen_response_functions(
model, beta, reaction.id, 'macromolecular', cytosol, substrates)
Expand Down

0 comments on commit d62c6ba

Please sign in to comment.