Possible bug in dynamicFBA function?

46 views
Skip to first unread message

Laurence

unread,
Jan 20, 2020, 12:31:53 PM1/20/20
to COBRA Toolbox

Hi

 

I’m trying to use dynamic FBA. I have attempted to implement dynamic FBA (as described by Varma and Palsson, 1994), but found that the substrate concentrations that I found don't match the dynamicFBA function in the Cobra toolbox. I found the source of the difference by looking at the source code of the dynamicFBA function, and am wondering if this is due to a bug or because I’m misunderstanding something.

 

In the Varma/Palsson paper, the simulation is divided into a series of timepoints, and substrate concentrations at the current timepoint is calculated by the following equation:

In the dynamicFBA function, the X0 in the equation represents the biomass at the previous timepoint, and the function uses the variable ‘biomass’ in place of the X0 in this equation. However, the 'biomass' variable is updated to store the biomass at the current timepoint (on line 108 in the function's source code) before substrate concentrations are calculated (on line 113). As I understand it, this means biomass at the current timepoint (i.e X0+Dt) is being used to calculate the current concentrations, instead of X0.


Am I understanding this correctly? Is this a bug, or is there some reason for this difference between the code and Varma/Palsson's method that I’ve missed?

 

I attach code that compares my solutions to the solution from the function and shows how changing the point at which biomass is updated changes results, in case this helps illustrate the difference.

 

Thanks

 

Laurence Legon

dFBAcompForForum.m
Reply all
Reply to author
Forward
0 new messages