Example #1
0
 def input_vars(self):
     """
     Returns a NodeList  (:class:`pynusmv.collections.NodeList`)
     exposing the input variables that exist in the trace language
     
     :return: a NodeList containing the input variables of the trace language
     """
     return NodeList(_trace.Trace_get_i_vars(self._ptr))
Example #2
0
 def symbols(self):
     """
     Returns a NodeList (:class:`pynusmv.collections.NodeList`)
     exposing the symbols of the trace language.
     
     :returns: a NodeList exposing the symbols of the trace language
     """
     return NodeList(_trace.Trace_get_symbols(self._ptr))
Example #3
0
 def state_frozen_vars(self):
     """
     Returns a NodeList  (:class:`pynusmv.collections.NodeList`)
     exposing the state and frozen variables that exist in the trace language
     
     :return: a NodeList containing the state and frozen variables of the 
         trace language
     """
     return NodeList(_trace.Trace_get_sf_vars(self._ptr))
Example #4
0
 def encode_to_bits(self, name_node):
     """
     Returns the list of bits variable names used to encode the SMV variable
     denoted by `name_node` in the boolean model.
     
     :param name_node: the node symbol representing the expression to break
         down to bits.
     :return: the list of bits names (in the form of nodes) which are used
         to encode `name_node`.
     """
     try:
         # raises a KeyError when 'name' is not found
         self.by_name[str(name_node)]
         # if found, its ok to just use 'symbol'
         return [name_node]
     except KeyError:
         # the encoder doesn't know 'name' we need to find the bits
         boolenc = self._bool_enc
         node_lst= NodeList(_bool.BoolEnc_get_var_bits(boolenc, name_node._ptr))
         return list(node_lst)
Example #5
0
File: fsm.py Project: yyaan/pynusmv
 def symbols_list(self):
     """
     :return: the set of symbols in the FSM
     """
     return NodeList(_sexp.SexpFsm_get_symbols_list(self._as_SexpFsm_ptr()))
Example #6
0
File: fsm.py Project: yyaan/pynusmv
 def variables_list(self):
     """
     :return: the set of variables in the FSM
     """
     return NodeList(_sexp.SexpFsm_get_vars_list(self._as_SexpFsm_ptr()))