def reactionString(self, i): """Reaction string for reaction number *i*""" s = '' nsp = _cantera.kin_nspecies(self.ckin) for k in range(nsp): nur = _cantera.kin_rstoichcoeff(self.ckin,k,i) if nur <> 0.0: if nur <> 1.0: if nur <> round(nur): s += str(nur)+' ' else: s += `int(nur)`+' ' s += self._sp[k]+' + ' s = s[:-2] if self.isReversible(i): s += ' <=> ' else: s += ' => ' for k in range(nsp): nup = _cantera.kin_pstoichcoeff(self.ckin,k,i) if nup <> 0.0: if nup <> 1.0: if nup <> round(nup): s += str(nup)+' ' else: s += `int(nup)`+' ' s += self._sp[k]+' + ' s = s[:-2] return s
def reactionString(self, i): """Reaction string for reaction number 'i'""" s = '' nsp = _cantera.kin_nspecies(self.ckin) for k in range(nsp): nur = _cantera.kin_rstoichcoeff(self.ckin, k, i) if nur <> 0.0: if nur <> 1.0: if nur <> round(nur): s += str(nur) + ' ' else: s += ` int(nur) ` + ' ' s += self._sp[k] + ' + ' s = s[:-2] if self.isReversible(i): s += ' <=> ' else: s += ' => ' for k in range(nsp): nup = _cantera.kin_pstoichcoeff(self.ckin, k, i) if nup <> 0.0: if nup <> 1.0: if nup <> round(nup): s += str(nup) + ' ' else: s += ` int(nup) ` + ' ' s += self._sp[k] + ' + ' s = s[:-2] return s
def productStoichCoeffs(self): """The array of product stoichiometric coefficients. Element [k,i] of this array is the product stoichiometric coefficient of species *k* in reaction *i*.""" nsp = _cantera.kin_nspecies(self.ckin) nr = _cantera.kin_nreactions(self.ckin) nu = zeros((nsp,nr),'d') for i in range(nr): for k in range(nsp): nu[k,i] = _cantera.kin_pstoichcoeff(self.ckin,k,i) return nu
def productStoichCoeffs(self): """The array of product stoichiometric coefficients. Element [k,i] of this array is the product stoichiometric coefficient of species k in reaction i.""" nsp = _cantera.kin_nspecies(self.ckin) nr = _cantera.kin_nreactions(self.ckin) nu = zeros((nsp, nr), 'd') for i in range(nr): for k in range(nsp): nu[k, i] = _cantera.kin_pstoichcoeff(self.ckin, k, i) return nu
def productStoichCoeff(self,k,i): """The stoichiometric coefficient of species *k* as a product in reaction *i*.""" return _cantera.kin_pstoichcoeff(self.ckin,k,i)
def productStoichCoeff(self, k, i): """The stoichiometric coefficient of species k as a product in reaction i.""" return _cantera.kin_pstoichcoeff(self.ckin, k, i)