Loopless flux balance analysis (ll-FBA)
Here we wil add loopless constraints to a flux balance model to ensure that the resultant solution is thermodynamically consistent. As before, we will use the core E. coli model, which we can download using download_model
:
using COBREXA
download_model(
"http://bigg.ucsd.edu/static/models/e_coli_core.json",
"e_coli_core.json",
"7bedec10576cfe935b19218dc881f3fb14f890a1871448fc19a9b4ee15b448d8",
)
"e_coli_core.json"
Additionally to COBREXA and the JSON model format package. We will also need a solver which can solve mixed-interger linear programs, such as HiGHS.
import JSONFBCModels
import HiGHS
model = load_model("e_coli_core.json")
JSONFBCModels.JSONFBCModel(#= 95 reactions, 72 metabolites =#)
Running a loopless FBA (ll-FBA)
One can directly use loopless_flux_balance_analysis
to solve an FBA problem based on model
where loopless constraints are added to all fluxes. This is the direct approach.
solution = loopless_flux_balance_analysis(model; optimizer = HiGHS.Optimizer)
ConstraintTrees.Tree{Float64} with 7 elements:
:coupling => ConstraintTrees.Tree{Float64}(#= 0 elements =#)
:flux_stoichiometry => ConstraintTrees.Tree{Float64}(#= 72 elements =#)
:fluxes => ConstraintTrees.Tree{Float64}(#= 95 elements =#)
:loopless_constraints => ConstraintTrees.Tree{Float64}(#= 5 elements =#)
:loopless_directions => ConstraintTrees.Tree{Float64}(#= 75 elements =#)
:loopless_driving_forces => ConstraintTrees.Tree{Float64}(#= 75 elements =#)
:objective => 0.873922
Loopless constraints can also be added to any model (e.g. enzyme constrained models). Refer to the source code of loopless_flux_balance_constraints
for guidance.
This page was generated using Literate.jl.