polytope_basis: Gets the polytope basis for a reaction system. The basis will...

Description Usage Arguments Value Examples

View source: R/kcone.R

Description

Gets the polytope basis for a reaction system. The basis will be normalized such that each vertex has a length of one.

Usage

1
2
polytope_basis(s_matrix, m_terms = rep(1, ncol(s_matrix)),
  zero_eq = NA)

Arguments

s_matrix

The stochiometric matrix.

m_terms

The metabolic terms for each reaction. Default to calculation of flux cone.

zero_eq

An optional matrix of additional equality contraints. Must have as many columns as reactions in 's_matrix'.

Value

A matrix containing the basis vectors (normalized to a sum of 1) in its columns.

Examples

1
2
3
S <- matrix(c(1,0,0,1,-1,0, 0, -1), nrow=2)
rownames(S) = c('A', 'B')
V <- polytope_basis(S)

cdiener/dycone documentation built on Sept. 9, 2018, 1:20 p.m.