src.model_balancing.util ======================== .. py:module:: src.model_balancing.util .. autoapi-nested-parse:: This module containts a few mathematical utility functions for model balancing. Module Contents --------------- .. py:function:: B_matrix(Nc: int, col_subs: numpy.ndarray, col_prod: numpy.ndarray) -> numpy.ndarray Build the B matrix for the :math:`\eta^{kin}` expression. row_subs : np.ndarray A column from the substrate stoichiometric matrix. We assume coefficients represent reactant molecularities so only integer values are allowed. row_prod : np.ndarray A column from the product stoichiometric matrix. We assume coefficients represent reactant molecularities so only integer values are allowed. .. py:function:: logistic(x: numpy.ndarray) -> numpy.ndarray elementwise calculation of :math:`\log(1 + e^x)`