original_docstring: 
          Computes the kinetic rate of the reaction. 
          
          INPUTS:
          ------
            assignUB: Assigns the computed kinetic rate to the upper bound
                      on reaction flux, if True, and does not do this if False
            assignLB: Assigns the "negative" of the computed kinetic rate (assuming that 
                      this rate is positive) to the lower bound on reaction flux
                      (e.g., for exchange reactions), if True, and does 
                      not do this if False
          assignFlux: Assigns the computed kinetic rate to the reaction flux
                      if True, and does not do this if False 
          concentration_key: The key to access the concetration in case compounds'
                      concentrations are stored in the form of a dictionary. For example, 
                      if the keys of this dictionary represent time points,  
                      then flux_key can refer to a speciic time point. 
  
          Note that concentrations must appear as 'C[compound_id]'
          in the kinetic expression to be able to compute the kinetic
          rate automatically (C will be in the form of a dictionary) 
  
          OUTPUT:
          ------
          kinetic_rate:  A global variable storing the kientic rate of the reaction
          
docstring: Computes the kinetic rate of the reaction.
  INPUTS.
  
  Assigns the computed kinetic rate to the upper bound
  on reaction flux, if True, and does not do this if False
  assignLB: Assigns the "negative" of the computed kinetic rate (assuming that
  this rate is positive) to the lower bound on reaction flux
  , if True, and does
  not do this if False
  assignFlux: Assigns the computed kinetic rate to the reaction flux
  if True, and does not do this if False
  concentration_key: The key to access the concetration in case compounds'
  concentrations are stored in the form of a dictionary. For example,
  if the keys of this dictionary represent time points,
  then flux_key can refer to a speciic time point.
  
  Note that concentrations must appear as 'C[compound_id]'
  in the kinetic expression to be able to compute the kinetic
  rate automatically (C will be in the form of a dictionary)
  
  
  
  A global variable storing the kientic rate of the reaction
docstring_tokens: Computes the kinetic rate of the reaction . INPUTS . Assigns the computed kinetic rate to the upper bound on reaction flux if True and does not do this if False assignLB : Assigns the " negative " of the computed kinetic rate ( assuming that this rate is positive ) to the lower bound on reaction flux if True and does not do this if False assignFlux : Assigns the computed kinetic rate to the reaction flux if True and does not do this if False concentration_key : The key to access the concetration in case compounds ' concentrations are stored in the form of a dictionary . For example if the keys of this dictionary represent time points then flux_key can refer to a speciic time point . Note that concentrations must appear as ' C [ compound_id ] ' in the kinetic expression to be able to compute the kinetic rate automatically ( C will be in the form of a dictionary ) A global variable storing the kientic rate of the reaction
code: def kinetic_rate_calc(self,assignLB = False, assignUB= False, assignFlux = False, concentration_key = None):
          """
          Computes the kinetic rate of the reaction. 
          
          INPUTS:
          ------
            assignUB: Assigns the computed kinetic rate to the upper bound
                      on reaction flux, if True, and does not do this if False
            assignLB: Assigns the "negative" of the computed kinetic rate (assuming that 
                      this rate is positive) to the lower bound on reaction flux
                      (e.g., for exchange reactions), if True, and does 
                      not do this if False
          assignFlux: Assigns the computed kinetic rate to the reaction flux
                      if True, and does not do this if False 
          concentration_key: The key to access the concetration in case compounds'
                      concentrations are stored in the form of a dictionary. For example, 
                      if the keys of this dictionary represent time points,  
                      then flux_key can refer to a speciic time point. 
  
          Note that concentrations must appear as 'C[compound_id]'
          in the kinetic expression to be able to compute the kinetic
          rate automatically (C will be in the form of a dictionary) 
  
          OUTPUT:
          ------
          kinetic_rate:  A global variable storing the kientic rate of the reaction
          """
          # A list of tuples, which is then converted to a dicitonary containing the list of
          # metabolites participating in the kinetic equation and their concentration
          C = []
          if self.kinetic_compounds == None:
              self.kinetic_compounds = self.compounds
  
          for m in self.kinetic_compounds:
              if m.concentration == None:
                  raise userError("'concentration' for metaboltie " + m.id + ' is not defined')
              else:
                  if concentration_key == None: 
                      if type(m.concentration) is int or type(m.concentration) is float:
                          C.append((m.id,m.concentration))
                      else:
                          raise TypeError('A number expected for concentraiton of compound ' + m.id + '. A ' + str(type(m.concentration)) + ' is given.')
                  elif concentration_key != None:
                      if type(m.concentration) is dict:
                          C.append((m.id,m.concentration[concentration_key]))
                      else:
                          raise TypeError('A dictionary expected for concentraiton of compound ' + m.id + '. A ' + str(type(m.concentration)) + ' is given.')
  
          C = dict(C)
          exec 'self.kinetic_rate = ' +  self.kinetics        
          if assignLB == True:
              self.flux_bounds[0] = - self.kinetic_rate
          if assignUB == True:
              self.flux_bounds[1] = self.kinetic_rate
          if assignFlux == True:
              if concentration_key == None and type(self.flux) is not dict:
                  self.flux = self.kinetic_rate            
              elif concentration_key == None and type(self.flux) is dict and self.warnings:
                  print 'WARNING! Kineetic rate of the reaction will overwrite reaction.flux, which is the form of a dictionary.'
              elif concentration_key != None and type(self.flux) is dict:
                  self.flux[concentration_key] = self.kinetic_rate            
              elif concentration_key != None and type(self.flux) is not dict:
                  self.flux = self.kinetic_rate
code_tokens: def kinetic_rate_calc ( self , assignLB = False , assignUB = False , assignFlux = False , concentration_key = None ) : C = [ ] if self . kinetic_compounds == None : self . kinetic_compounds = self . compounds for m in self . kinetic_compounds : if m . concentration == None : raise userError ( "'concentration' for metaboltie " + m . id + ' is not defined' ) else : if concentration_key == None : if type ( m . concentration ) is int or type ( m . concentration ) is float : C . append ( ( m . id , m . concentration ) ) else : raise TypeError ( 'A number expected for concentraiton of compound ' + m . id + '. A ' + str ( type ( m . concentration ) ) + ' is given.' ) elif concentration_key != None : if type ( m . concentration ) is dict : C . append ( ( m . id , m . concentration [ concentration_key ] ) ) else : raise TypeError ( 'A dictionary expected for concentraiton of compound ' + m . id + '. A ' + str ( type ( m . concentration ) ) + ' is given.' ) C = dict ( C ) exec 'self.kinetic_rate = ' + self . kinetics if assignLB == True : self . flux_bounds [ 0 ] = - self . kinetic_rate if assignUB == True : self . flux_bounds [ 1 ] = self . kinetic_rate if assignFlux == True : if concentration_key == None and type ( self . flux ) is not dict : self . flux = self . kinetic_rate elif concentration_key == None and type ( self . flux ) is dict and self . warnings : print 'WARNING! Kineetic rate of the reaction will overwrite reaction.flux, which is the form of a dictionary.' elif concentration_key != None and type ( self . flux ) is dict : self . flux [ concentration_key ] = self . kinetic_rate elif concentration_key != None and type ( self . flux ) is not dict : self . flux = self . kinetic_rate
short_docstring: Computes the kinetic rate of the reaction.
short_docstring_tokens: Computes the kinetic rate of the reaction .
comment: """
          Computes the kinetic rate of the reaction. 
          
          INPUTS:
          ------
            assignUB: Assigns the computed kinetic rate to the upper bound
                      on reaction flux, if True, and does not do this if False
            assignLB: Assigns the "negative" of the computed kinetic rate (assuming that 
                      this rate is positive) to the lower bound on reaction flux
                      (e.g., for exchange reactions), if True, and does 
                      not do this if False
          assignFlux: Assigns the computed kinetic rate to the reaction flux
                      if True, and does not do this if False 
          concentration_key: The key to access the concetration in case compounds'
                      concentrations are stored in the form of a dictionary. For example, 
                      if the keys of this dictionary represent time points,  
                      then flux_key can refer to a speciic time point. 
  
          Note that concentrations must appear as 'C[compound_id]'
          in the kinetic expression to be able to compute the kinetic
          rate automatically (C will be in the form of a dictionary) 
  
          OUTPUT:
          ------
          kinetic_rate:  A global variable storing the kientic rate of the reaction
          """$SEP$# A list of tuples, which is then converted to a dicitonary containing the list of$SEP$# metabolites participating in the kinetic equation and their concentration