Thermoqp

driver_testThermoQP[source]

objective

thermoFlux2QNty(model, solution, param)[source]

Given a steady state thermodynamically feasible flux vector, v, such that

S*v = b

l <= v <= u

Compute q and g = N’*y such that

N*diag(q)*g = b - B*w

where the stoichiometric matrix and flux vector are split into internal and external components: S = [N B] and v = [z; w],

thermoQP(model, q, param)[source]

Compute an approximately thermodynamically feasible flux by minimising the Euclidean norm, weighted by the conductances provided in q.

INPUT
  • model – (the following fields are required - others can be supplied)

    • S - m x 1 Stoichiometric matrix

    • c - n x 1 Linear objective coefficients

    • lb - n x 1 Lower bounds

    • ub - n x 1 Upper bounds

  • qn x 1 vector of reaction conductances

OPTIONAL INPUTS
  • model

    • dxdt - m x 1 change in concentration with time

    • csense - m x 1 character array with entries in {L,E,G} (The code is backward compatible with an m + k x 1 csense vector, where k is the number of coupling constraints)

    • C - k x n Left hand side of C*v <= d

    • d - k x n Right hand side of C*v <= d

    • dsense - k x 1 character array with entries in {L,E,G}

  • osenseStr – Maximize (‘max’)/minimize (‘min’) (opt, default = ‘max’)

OUTPUT

sol – sol object:

  • f - Objective value

  • v - Reaction rates (Optimal primal variable, legacy FBAsolution.x)

  • y - Dual

  • w - Reduced costs

  • s - Slacks (tbc)

  • stat - Solver status in standardized form: