Metabolic modeling with COBRApy
The computational simulation of biochemical pathways in cells is called metabolic modeling. In this approach, a matrix of reactions in a cell is defined, and a mass balance is set up so that we achieve a steady state. We can then try to optimize one of the outputs so that fluxes are diverted toward it – this is called Flux Balance Analysis (FBA). A constraint-based model provides reasonable ranges for fluxes and so requires less information, and models the cell at a steady state. A model with reaction rates, called a kinetic model, provides more detail but is more complex to build.
In FBA, we typically optimize an objective function. This is the output the model is trying to maximize. Typically, by default, we use the growth of the organism for this function. But often, we use something else, such as the output of a metabolite. For instance, if we were making biofuels, we might try to maximize the output of that molecule, even at the expense...