import itertools # make sure that we are not allowed to build the sum of two automata with # different dictionaries. aut1 = spot.translate('Xa') aut2 = spot.translate('Xb', dict=spot.make_bdd_dict()) try: spot.sum(aut1, aut2) exit(2) except RuntimeError: pass opts = spot.option_map() opts.set('output', spot.OUTPUTLTL) opts.set('tree_size_min', 15) opts.set('tree_size_max', 15) opts.set('wf', False) opts.set('seed', 0) opts.set('simplification_level', 0) spot.srand(0) rg = spot.randltlgenerator(2, opts) dict = spot.make_bdd_dict() def produce_phi(rg, n): phi = [] while len(phi) < n:
State: 2 [!0&1] 3 [0 | !1] 5 State: 3 {0} [!0] 3 [0] 5 State: 4 [0&1] 1 [0&!1] 4 [!0&!1] 2&4 [!0&1] 1&2 State: 5 [t] 5 --END--""" opts = spot.option_map() opts.set('output', spot.OUTPUTLTL) opts.set('tree_size_min', 15) opts.set('tree_size_max', 15) opts.set('seed', 0) opts.set('simplification_level', 0) spot.srand(0) rg = spot.randltlgenerator(2, opts) for a in produce_automaton(produce_phi(rg, 1000)): test_assert(a) test_assert(spot.dualize(a), spot.dualize(spot.dualize(a))) aut = spot.automaton(""" HOA: v1 States: 1