inside: Evaluates whether a given point lies within a given k-cone....

Description Usage Arguments Value Examples

Description

Evaluates whether a given point lies within a given k-cone. Assumes a pointed cone (all reactions irreversible).

Usage

1
inside(x, s_matrix, m_terms, tol = sqrt(.Machine$double.eps))

Arguments

x

A single point (vector) or multiple points (matrix with points as columns) to be checked.

s_matrix

The stochiometric matrix of the k-cone to be used.

m_terms

The metabolic terms of the k-cone.

tol

The numerical accuracy of the check. Defaults to the square of the double accuracy.

Value

A single boolean of vector of booleans indicating whether the point(s) lie within the k-cone.

Examples

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

# Check whether a random point falls within the flux cone
inside(runif(ncol(S)), S, rep(1,ncol(S))) # probably not true

cdiener/dycone documentation built on May 13, 2019, 2:41 p.m.