fastFVA

cleanFilesFastFVA(userInteraction)[source]

Clean log and result files generated by fastFVA

Usage

cleanFiles(userInteraction)

Input

  • userInteraction – Boolean variable for requesting explicitly if the files should be removed
fastFVA(model, optPercentage, osenseStr, solverName, rxnsList, matrixAS, cpxControl, strategy, rxnsOptMode, printLevel)[source]

Flux variablity analysis optimized for the CPLEX solver. Solves LPs of the form:

\[\begin{split}\forall ~ v_j: ~&~ max/min ~&~ v_j\\ ~&~ s.t. ~&~ Sv = b\\ ~&~ ~&~ l_b \leq v \leq u_b\end{split}\]

If the optional fields are supplied, following LPs are solved

\[\begin{split}\forall ~ v_j: ~&~ max/min ~&~ v_j\\ ~&~ s.t. ~&~ Av (c_sense) b\\ ~&~ ~&~ l_b \leq v \leq u_b\end{split}\]

fastFVA returns vectors for the initial FBA in FBASOL together with matrices FVAMIN and FVAMAX containing the flux values for each individual min/max problem. Note that for large models the memory requirements may become prohibitive. To save large fvamin and fvamax matrices, toggle v7.3 in Preferences -> General -> MAT-Files

If a rxnsList vector is specified then only the corresponding entries in minFlux and maxFlux are defined (all remaining entries are zero).

Usage

[minFlux, maxFlux, optsol, ret, fbasol, fvamin, fvamax, statussolmin, statussolmax] = fastFVA(model, optPercentage, osenseStr, solverName, rxnsList, matrixAS, cpxControl, strategy, rxnsOptMode)

Inputs

  • model – COBRA model structure
    • .S - (required) Stoichiometric matrix
    • .b - (required) Right hand side vector
    • .c - (required) Objective coefficients
    • .lb - (required) Lower bounds
    • .ub - (required) Upper bounds
    • .A - (optional) Stoichiometric matrix (with constraints)
    • .csense - (optional) Type of constraints, csense is a vector with elements E (equal), L (less than) or G (greater than).
  • optPercentage – Only consider solutions that give you at least a certain percentage of the optimal solution (default = 100, equivalent to optimal solutions only)
  • osenseStr – Objective (‘min’ or ‘max’) (default ‘max’)
  • solverName – name of the solver, default: ibm_cplex

Optional inputs

  • matrixASA or S - choice of the model matrix, coupled (A) or uncoupled (S)
  • cpxControl – Parameter set of CPLEX loaded externally
  • rxnsList – List of reactions to analyze (default all rxns, i.e. 1:length(model.rxns)`)
  • strategy – Paralell distribution strategy of reactions among workers
    • 0 = Blind splitting: default random distribution
    • 1 = Extremal dense-and-sparse splitting: every worker receives dense and sparse reactions, starting from both extremal indices of the sorted column density vector
    • 2 = Central dense-and-sparse splitting: every worker receives dense and sparse reactions, starting from the beginning and center indices of the sorted column density vector
  • rxnsOptMode – List of min/max optimizations to perform: * 0 = only minimization; * 1 = only maximization; * 2 = minimization & maximization;
  • printLevel – Verbose level (default: 1) * 0 = mute * 1 = default

Outputs

  • minFlux – Minimum flux for each reaction
  • maxFlux – Maximum flux for each reaction
  • optsol – Optimal solution (of the initial FBA)
  • ret – Zero if success (global return code from FVA)

Optional outputs

  • fbasol – Initial FBA in FBASOL
  • fvamin – matrix with flux values for the minimization problem
  • fvamax – matrix with flux values for the maximization problem
  • statussolmin – vector of solution status for each reaction (minimization)
  • statussolmax – vector of solution status for each reaction (maximization)

Example

load modelRecon1Biomass.mat % Human reconstruction network (Recon1)
setWorkerCount(4);
[minFlux,maxFlux] = fastFVA(model, 90);

Note

S. Gudmundsson and I. Thiele, Computationally efficient Flux Variability Analysis. BMC Bioinformatics, 2010, 11:489

Note

  • Matlab R2014a fully tested on UNIX and DOS Systems
  • Matlab R2015b throws compatibility errors with CPLEX 12.6.3 on DOS Systems
  • Matlab R2016b and the MinGW64 compiler are not compatible with the CPLEX 12.6.3 library

The version of fastFVA only supports the CPLEX solver. The code has been tested with CPLEX 12.6.2, 12.6.3, 12.7.0 and 12.7.1. Install CPLEX (64-bit) as explained here. A particular interface, such as TOMLAB, is not needed in order to run fastFVA. Please note that only the 64-bit versions of CPLEX 12.7.1 are supported. In order to run the code on 32-bit systems, the appropriate MEX files need to be generated using generateMexFastFVA().