tgba_complete: rename as complete and export in Python

* src/twaalgos/complete.cc, src/twaalgos/complete.hh
(tgba_complete, tgba_complete_here): Rename as...
(complete, complete_here): ... these.  Also fix useless output of
acceptance marks on transition leading to the sink when the automaton
does not use state-based acceptance.
* src/tests/ikwiad.cc, src/twaalgos/dtgbacomp.cc,
src/twaalgos/dtgbasat.cc, src/twaalgos/postproc.cc,
src/twaalgos/product.cc: Adjust.
* wrap/python/spot_impl.i: Export these function.
* wrap/python/tests/automata.ipynb: Test spot.complete().
This commit is contained in:
Alexandre Duret-Lutz 2015-10-02 16:45:39 +02:00
parent afe5b2a1c0
commit 5e07e8384d
9 changed files with 257 additions and 37 deletions

View file

@ -1178,9 +1178,9 @@ checked_main(int argc, char** argv)
if (opt_complete)
{
tm.start("determinization");
a = tgba_complete(a);
tm.stop("determinization");
tm.start("completion");
a = complete(a);
tm.stop("completion");
}
if (opt_dtbasat >= 0)

View file

@ -21,7 +21,7 @@
namespace spot
{
unsigned tgba_complete_here(twa_graph_ptr aut)
unsigned complete_here(twa_graph_ptr aut)
{
unsigned n = aut->num_states();
unsigned sink = -1U;
@ -104,6 +104,8 @@ namespace spot
}
// In case the automaton use state-based acceptance, propagate
// the acceptance of the first edge to the one we add.
if (!aut->has_state_based_acc())
acc = 0U;
aut->new_edge(i, sink, missingcond, acc);
}
}
@ -117,7 +119,7 @@ namespace spot
return sink;
}
twa_graph_ptr tgba_complete(const const_twa_ptr& aut)
twa_graph_ptr complete(const const_twa_ptr& aut)
{
auto res = make_twa_graph(aut, {
true, // state based
@ -125,7 +127,7 @@ namespace spot
true, // deterministic
true, // stutter inv.
});
tgba_complete_here(res);
complete_here(res);
return res;
}

View file

@ -1,6 +1,6 @@
// -*- coding: utf-8 -*-
// Copyright (C) 2013, 2014, 2015 Laboratoire de Recherche et Développement
// de l'Epita.
// Copyright (C) 2013, 2014, 2015 Laboratoire de Recherche et
// Développement de l'Epita.
//
// This file is part of Spot, a model checking library.
//
@ -25,15 +25,15 @@ namespace spot
{
/// \brief Complete a twa_graph in place.
///
/// If the tgba has no acceptance set, one will be added. The
/// If the TωA has no acceptance set, one will be added. The
/// returned value is the number of the sink state (it can be a new
/// state added for completion, or an existing non-accepting state
/// that has been reused as sink state because it had no outgoing
/// transitions apart from self-loops.)
SPOT_API unsigned tgba_complete_here(twa_graph_ptr aut);
SPOT_API unsigned complete_here(twa_graph_ptr aut);
/// \brief Clone a tgba and complete it.
/// \brief Clone a twa and complete it.
///
/// If the tgba has no acceptance set, one will be added.
SPOT_API twa_graph_ptr tgba_complete(const const_twa_ptr& aut);
/// If the twa has no acceptance set, one will be added.
SPOT_API twa_graph_ptr complete(const const_twa_ptr& aut);
}

View file

@ -178,7 +178,7 @@ namespace spot
{
// Simply complete the automaton, and complement its
// acceptance.
auto res = cleanup_acceptance_here(tgba_complete(aut));
auto res = cleanup_acceptance_here(complete(aut));
res->set_acceptance(res->num_sets(),
res->get_acceptance().complement());
return res;

View file

@ -1339,7 +1339,7 @@ namespace spot
}
else
{
tgba_complete_here(a);
complete_here(a);
}
if (states == -1 && max_states == -1)

View file

@ -156,7 +156,7 @@ namespace spot
|| (type_ == Monitor && a->num_sets() == 0))
{
if (COMP_)
a = tgba_complete(a);
a = complete(a);
if (SBACC_)
a = sbacc(a);
return a;
@ -207,7 +207,7 @@ namespace spot
a = m;
}
if (COMP_)
a = tgba_complete(a);
a = complete(a);
return a;
}
@ -216,7 +216,7 @@ namespace spot
if (type_ == BA)
a = do_degen(a);
if (COMP_)
a = tgba_complete(a);
a = complete(a);
if (SBACC_)
a = sbacc(a);
return a;
@ -380,7 +380,7 @@ namespace spot
in = dba;
}
const_twa_graph_ptr res = tgba_complete(in);
const_twa_graph_ptr res = complete(in);
if (target_acc == 1)
{
if (sat_states_ != -1)
@ -457,7 +457,7 @@ namespace spot
sim = dba ? dba : sim;
if (COMP_)
sim = tgba_complete(sim);
sim = complete(sim);
if (SBACC_)
sim = sbacc(sim);

View file

@ -136,8 +136,8 @@ namespace spot
unsigned left_state,
unsigned right_state)
{
return product_aux(tgba_complete(left),
tgba_complete(right),
return product_aux(complete(left),
complete(right),
left_state, right_state, false);
}

View file

@ -111,6 +111,7 @@
#include "twaalgos/dot.hh"
#include "twaalgos/degen.hh"
#include "twaalgos/copy.hh"
#include "twaalgos/complete.hh"
#include "twaalgos/emptiness.hh"
#include "twaalgos/gtec/gtec.hh"
#include "twaalgos/lbtt.hh"
@ -255,6 +256,7 @@ namespace std {
%include "twaalgos/degen.hh"
%include "twaalgos/dot.hh"
%include "twaalgos/copy.hh"
%include "twaalgos/complete.hh"
%include "twaalgos/emptiness.hh"
%include "twaalgos/gtec/gtec.hh"
%include "twaalgos/lbtt.hh"

View file

@ -17,7 +17,8 @@
"pygments_lexer": "ipython3",
"version": "3.4.3+"
},
"name": ""
"name": "",
"signature": "sha256:6b034a8346695a3f327fd50e8c768209ea3d931598b99d5d80508685976c255e"
},
"nbformat": 3,
"nbformat_minor": 0,
@ -176,7 +177,7 @@
"</svg>\n"
],
"text": [
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7fe49c07cf30> >"
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7f2998ab6540> >"
]
}
],
@ -315,7 +316,7 @@
"</svg>"
],
"text": [
"<IPython.core.display.SVG object>"
"<IPython.core.display.SVG at 0x7f2999748ef0>"
]
}
],
@ -468,7 +469,7 @@
"</svg>"
],
"text": [
"<IPython.core.display.SVG object>"
"<IPython.core.display.SVG at 0x7f29980f6400>"
]
}
],
@ -568,7 +569,7 @@
"</svg>\n"
],
"text": [
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7fe49c065360> >"
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7f2998a8be40> >"
]
}
],
@ -638,7 +639,7 @@
"</svg>\n"
],
"text": [
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7fe49c0654b0> >"
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7f2998a8bed0> >"
]
}
],
@ -714,7 +715,7 @@
"</svg>\n"
],
"text": [
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7fe49c065270> >"
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7f2998a8b840> >"
]
}
],
@ -837,7 +838,7 @@
"</svg>"
],
"text": [
"<IPython.core.display.SVG object>"
"<IPython.core.display.SVG at 0x7f299809eda0>"
]
}
],
@ -1027,7 +1028,7 @@
"</svg>"
],
"text": [
"<IPython.core.display.SVG object>"
"<IPython.core.display.SVG at 0x7f29980bb710>"
]
}
],
@ -1174,7 +1175,7 @@
"</svg>\n"
],
"text": [
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7fe49c0652d0> >"
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7f2998a280f0> >"
]
}
],
@ -1275,7 +1276,7 @@
"</svg>\n"
],
"text": [
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7fe49c065150> >"
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7f2998a28120> >"
]
}
],
@ -1393,7 +1394,7 @@
"</svg>\n"
],
"text": [
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7fe49c0651e0> >"
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7f2998a28150> >"
]
}
],
@ -1493,7 +1494,7 @@
"</svg>\n"
],
"text": [
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7fe49c065300> >"
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7f2998a28180> >"
]
}
],
@ -1967,7 +1968,7 @@
"</svg>\n"
],
"text": [
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7fe49c04ad80> >"
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7f2998a8bde0> >"
]
}
],
@ -2170,7 +2171,7 @@
"</svg>\n"
],
"text": [
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7fe49f10ec90> >"
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7f2998a8bfc0> >"
]
}
],
@ -2186,6 +2187,221 @@
"metadata": {},
"outputs": [],
"prompt_number": 20
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"spot.complete(a)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 21,
"svg": [
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n",
"<!DOCTYPE svg PUBLIC \"-//W3C//DTD SVG 1.1//EN\"\n",
" \"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd\">\n",
"<!-- Generated by graphviz version 2.38.0 (20140413.2041)\n",
" -->\n",
"<!-- Title: G Pages: 1 -->\n",
"<svg width=\"376pt\" height=\"164pt\"\n",
" viewBox=\"0.00 0.00 376.00 163.63\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
"<g id=\"graph0\" class=\"graph\" transform=\"scale(1 1) rotate(0) translate(4 159.627)\">\n",
"<title>G</title>\n",
"<polygon fill=\"white\" stroke=\"none\" points=\"-4,4 -4,-159.627 372,-159.627 372,4 -4,4\"/>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g id=\"node2\" class=\"node\"><title>0</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"black\" cx=\"56\" cy=\"-23.6271\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"56\" y=\"-19.9271\" font-family=\"Lato\" font-size=\"14.00\">0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g id=\"edge1\" class=\"edge\"><title>I&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M1.15491,-23.6271C2.79388,-23.6271 17.1543,-23.6271 30.6317,-23.6271\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"37.9419,-23.6271 30.9419,-26.7772 34.4419,-23.6271 30.9419,-23.6272 30.9419,-23.6272 30.9419,-23.6272 34.4419,-23.6271 30.9418,-20.4772 37.9419,-23.6271 37.9419,-23.6271\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge2\" class=\"edge\"><title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M49.6208,-40.6644C48.3189,-50.485 50.4453,-59.6271 56,-59.6271 60.166,-59.6271 62.4036,-54.4847 62.7128,-47.7704\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"62.3792,-40.6644 65.8541,-47.5089 62.5434,-44.1606 62.7076,-47.6567 62.7076,-47.6567 62.7076,-47.6567 62.5434,-44.1606 59.561,-47.8045 62.3792,-40.6644 62.3792,-40.6644\"/>\n",
"<text text-anchor=\"start\" x=\"51.5\" y=\"-78.4271\" font-family=\"Lato\" font-size=\"14.00\">1</text>\n",
"<text text-anchor=\"start\" x=\"48\" y=\"-63.4271\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#b276b2\">\u2778</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g id=\"node3\" class=\"node\"><title>1</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"black\" cx=\"160\" cy=\"-91.6271\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"160\" y=\"-87.9271\" font-family=\"Lato\" font-size=\"14.00\">1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g id=\"edge3\" class=\"edge\"><title>0&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M65.0461,-39.5832C71.116,-50.1043 80.3787,-63.4106 92,-71.6271 104.628,-80.5557 121.282,-85.5508 134.826,-88.3162\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"141.986,-89.634 134.531,-91.4648 138.544,-89.0004 135.101,-88.3668 135.101,-88.3668 135.101,-88.3668 138.544,-89.0004 135.672,-85.2688 141.986,-89.634 141.986,-89.634\"/>\n",
"<text text-anchor=\"start\" x=\"104.5\" y=\"-102.427\" font-family=\"Lato\" font-size=\"14.00\">a</text>\n",
"<text text-anchor=\"start\" x=\"92\" y=\"-88.4271\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#f17cb0\">\u2776</text>\n",
"<text text-anchor=\"start\" x=\"108\" y=\"-88.4271\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#b276b2\">\u2778</text>\n",
"</g>\n",
"<!-- 2 -->\n",
"<g id=\"node4\" class=\"node\"><title>2</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"black\" cx=\"269\" cy=\"-34.6271\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"269\" y=\"-30.9271\" font-family=\"Lato\" font-size=\"14.00\">2</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;2 -->\n",
"<g id=\"edge4\" class=\"edge\"><title>0&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M74.0815,-22.4553C79.7775,-22.1168 86.1595,-21.7938 92,-21.6271 154.698,-19.8372 170.775,-19.7328 233,-27.6271 236.671,-28.0929 240.534,-28.7222 244.3,-29.4136\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"251.345,-30.7926 243.87,-32.5392 247.91,-30.1202 244.475,-29.4478 244.475,-29.4478 244.475,-29.4478 247.91,-30.1202 245.08,-26.3565 251.345,-30.7926 251.345,-30.7926\"/>\n",
"<text text-anchor=\"start\" x=\"154.5\" y=\"-39.4271\" font-family=\"Lato\" font-size=\"14.00\">!a</text>\n",
"<text text-anchor=\"start\" x=\"144\" y=\"-25.4271\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#5da5da\">\u24ff</text>\n",
"<text text-anchor=\"start\" x=\"160\" y=\"-25.4271\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#b276b2\">\u2778</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g id=\"edge5\" class=\"edge\"><title>1&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M152.502,-75.1398C146.816,-62.8931 137.362,-46.7854 124,-37.6271 111.512,-29.0678 94.8589,-25.5604 81.2799,-24.1966\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"74.0982,-23.641 81.3203,-21.0404 77.5877,-23.911 81.0773,-24.181 81.0773,-24.181 81.0773,-24.181 77.5877,-23.911 80.8343,-27.3216 74.0982,-23.641 74.0982,-23.641\"/>\n",
"<text text-anchor=\"start\" x=\"103.5\" y=\"-56.4271\" font-family=\"Lato\" font-size=\"14.00\">b</text>\n",
"<text text-anchor=\"start\" x=\"100\" y=\"-41.4271\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#b276b2\">\u2778</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge6\" class=\"edge\"><title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M151.021,-107.543C148.679,-117.777 151.672,-127.627 160,-127.627 166.376,-127.627 169.625,-121.853 169.746,-114.554\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"168.979,-107.543 172.872,-114.159 169.36,-111.022 169.741,-114.502 169.741,-114.502 169.741,-114.502 169.36,-111.022 166.61,-114.844 168.979,-107.543 168.979,-107.543\"/>\n",
"<text text-anchor=\"start\" x=\"143\" y=\"-145.427\" font-family=\"Lato\" font-size=\"14.00\">a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"144\" y=\"-131.427\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#5da5da\">\u24ff</text>\n",
"<text text-anchor=\"start\" x=\"160\" y=\"-131.427\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#b276b2\">\u2778</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;2 -->\n",
"<g id=\"edge7\" class=\"edge\"><title>1&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M167.91,-75.2258C173.659,-63.768 183.007,-49.2139 196,-41.6271 210.315,-33.2685 229.009,-31.6683 243.761,-32.0794\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"251.072,-32.4526 243.92,-35.2416 247.576,-32.2741 244.081,-32.0957 244.081,-32.0957 244.081,-32.0957 247.576,-32.2741 244.241,-28.9498 251.072,-32.4526 251.072,-32.4526\"/>\n",
"<text text-anchor=\"start\" x=\"196\" y=\"-59.4271\" font-family=\"Lato\" font-size=\"14.00\">!a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"198.5\" y=\"-45.4271\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#faa43a\">\u2777</text>\n",
"<text text-anchor=\"start\" x=\"214.5\" y=\"-45.4271\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#b276b2\">\u2778</text>\n",
"</g>\n",
"<!-- 3 -->\n",
"<g id=\"node5\" class=\"node\"><title>3</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"black\" cx=\"350\" cy=\"-103.627\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"350\" y=\"-99.9271\" font-family=\"Lato\" font-size=\"14.00\">3</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;3 -->\n",
"<g id=\"edge8\" class=\"edge\"><title>1&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M173.474,-103.976C179.696,-109.273 187.664,-114.87 196,-117.627 240.31,-132.284 295.524,-120.365 326.037,-111.352\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"332.881,-109.255 327.111,-114.318 329.534,-110.281 326.188,-111.306 326.188,-111.306 326.188,-111.306 329.534,-110.281 325.265,-108.294 332.881,-109.255 332.881,-109.255\"/>\n",
"<text text-anchor=\"start\" x=\"262.5\" y=\"-127.427\" font-family=\"Lato\" font-size=\"14.00\">!b</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;0 -->\n",
"<g id=\"edge9\" class=\"edge\"><title>2&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M252.579,-26.7885C235.049,-18.4033 205.316,-5.75244 178,-1.6271 143.605,3.56728 103.982,-6.75979 79.7161,-14.9564\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"72.9986,-17.3045 78.5671,-12.021 76.3026,-16.1495 79.6065,-14.9946 79.6065,-14.9946 79.6065,-14.9946 76.3026,-16.1495 80.646,-17.9682 72.9986,-17.3045 72.9986,-17.3045\"/>\n",
"<text text-anchor=\"start\" x=\"153.5\" y=\"-5.4271\" font-family=\"Lato\" font-size=\"14.00\">!b</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;1 -->\n",
"<g id=\"edge10\" class=\"edge\"><title>2&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M256.965,-48.5704C250.631,-55.7566 242.134,-64.1397 233,-69.6271 218.307,-78.4541 199.773,-84.0107 185.19,-87.3312\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"177.965,-88.8693 184.155,-84.3307 181.388,-88.1405 184.811,-87.4117 184.811,-87.4117 184.811,-87.4117 181.388,-88.1405 185.467,-90.4926 177.965,-88.8693 177.965,-88.8693\"/>\n",
"<text text-anchor=\"start\" x=\"196\" y=\"-102.427\" font-family=\"Lato\" font-size=\"14.00\">a &amp; !b</text>\n",
"<text text-anchor=\"start\" x=\"206.5\" y=\"-87.4271\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#5da5da\">\u24ff</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;2 -->\n",
"<g id=\"edge11\" class=\"edge\"><title>2&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M261.969,-51.2912C260.406,-61.2521 262.75,-70.6271 269,-70.6271 273.688,-70.6271 276.178,-65.3537 276.471,-58.5147\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"276.031,-51.2912 279.601,-58.0869 276.244,-54.7847 276.456,-58.2782 276.456,-58.2782 276.456,-58.2782 276.244,-54.7847 273.312,-58.4696 276.031,-51.2912 276.031,-51.2912\"/>\n",
"<text text-anchor=\"start\" x=\"248.5\" y=\"-89.4271\" font-family=\"Lato\" font-size=\"14.00\">!a &amp; !b</text>\n",
"<text text-anchor=\"start\" x=\"261\" y=\"-74.4271\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#5da5da\">\u24ff</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;3 -->\n",
"<g id=\"edge12\" class=\"edge\"><title>2&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M283.045,-46.021C295.967,-57.3074 315.88,-74.6997 330.446,-87.4219\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"335.935,-92.2162 328.591,-89.9839 333.299,-89.9138 330.663,-87.6114 330.663,-87.6114 330.663,-87.6114 333.299,-89.9138 332.735,-85.2389 335.935,-92.2162 335.935,-92.2162\"/>\n",
"<text text-anchor=\"start\" x=\"305\" y=\"-74.4271\" font-family=\"Lato\" font-size=\"14.00\">b</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;3 -->\n",
"<g id=\"edge13\" class=\"edge\"><title>3&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M342.969,-120.291C341.406,-130.252 343.75,-139.627 350,-139.627 354.688,-139.627 357.178,-134.354 357.471,-127.515\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"357.031,-120.291 360.601,-127.087 357.244,-123.785 357.456,-127.278 357.456,-127.278 357.456,-127.278 357.244,-123.785 354.312,-127.47 357.031,-120.291 357.031,-120.291\"/>\n",
"<text text-anchor=\"middle\" x=\"350\" y=\"-143.427\" font-family=\"Lato\" font-size=\"14.00\">1</text>\n",
"</g>\n",
"</g>\n",
"</svg>\n"
],
"text": [
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7f2998a8bea0> >"
]
}
],
"prompt_number": 21
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"spot.complete(spot.translate('Ga'))"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 22,
"svg": [
"<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"no\"?>\n",
"<!DOCTYPE svg PUBLIC \"-//W3C//DTD SVG 1.1//EN\"\n",
" \"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd\">\n",
"<!-- Generated by graphviz version 2.38.0 (20140413.2041)\n",
" -->\n",
"<!-- Title: G Pages: 1 -->\n",
"<svg width=\"173pt\" height=\"85pt\"\n",
" viewBox=\"0.00 0.00 173.00 85.00\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
"<g id=\"graph0\" class=\"graph\" transform=\"scale(1 1) rotate(0) translate(4 81)\">\n",
"<title>G</title>\n",
"<polygon fill=\"white\" stroke=\"none\" points=\"-4,4 -4,-81 169,-81 169,4 -4,4\"/>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g id=\"node2\" class=\"node\"><title>0</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"black\" cx=\"60\" cy=\"-22\" rx=\"18\" ry=\"18\"/>\n",
"<ellipse fill=\"none\" stroke=\"black\" cx=\"60\" cy=\"-22\" rx=\"22\" ry=\"22\"/>\n",
"<text text-anchor=\"middle\" x=\"60\" y=\"-18.3\" font-family=\"Lato\" font-size=\"14.00\">0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g id=\"edge1\" class=\"edge\"><title>I&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M1.16638,-22C2.84121,-22 16.884,-22 30.7112,-22\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"37.8555,-22 30.8556,-25.1501 34.3555,-22 30.8555,-22.0001 30.8555,-22.0001 30.8555,-22.0001 34.3555,-22 30.8555,-18.8501 37.8555,-22 37.8555,-22\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge2\" class=\"edge\"><title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M52.6831,-42.9908C51.7798,-53.0872 54.2188,-62 60,-62 64.3359,-62 66.7918,-56.9866 67.3677,-50.2204\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"67.3169,-42.9908 70.5161,-49.9684 67.3415,-46.4907 67.3662,-49.9906 67.3662,-49.9906 67.3662,-49.9906 67.3415,-46.4907 64.2163,-50.0128 67.3169,-42.9908 67.3169,-42.9908\"/>\n",
"<text text-anchor=\"start\" x=\"56.5\" y=\"-65.8\" font-family=\"Lato\" font-size=\"14.00\">a</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g id=\"node3\" class=\"node\"><title>1</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"black\" cx=\"147\" cy=\"-22\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"147\" y=\"-18.3\" font-family=\"Lato\" font-size=\"14.00\">1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g id=\"edge3\" class=\"edge\"><title>0&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M82.0112,-22C94.0936,-22 109.32,-22 121.889,-22\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"128.938,-22 121.938,-25.1501 125.438,-22 121.938,-22.0001 121.938,-22.0001 121.938,-22.0001 125.438,-22 121.938,-18.8501 128.938,-22 128.938,-22\"/>\n",
"<text text-anchor=\"start\" x=\"100\" y=\"-25.8\" font-family=\"Lato\" font-size=\"14.00\">!a</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge4\" class=\"edge\"><title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"black\" d=\"M139.969,-38.6641C138.406,-48.625 140.75,-58 147,-58 151.688,-58 154.178,-52.7266 154.471,-45.8876\"/>\n",
"<polygon fill=\"black\" stroke=\"black\" points=\"154.031,-38.6641 157.601,-45.4598 154.244,-42.1576 154.456,-45.6511 154.456,-45.6511 154.456,-45.6511 154.244,-42.1576 151.312,-45.8425 154.031,-38.6641 154.031,-38.6641\"/>\n",
"<text text-anchor=\"middle\" x=\"147\" y=\"-61.8\" font-family=\"Lato\" font-size=\"14.00\">1</text>\n",
"</g>\n",
"</g>\n",
"</svg>\n"
],
"text": [
"<spot_impl.twa_graph; proxy of <Swig Object of type 'std::shared_ptr< spot::twa_graph > *' at 0x7f2998a281e0> >"
]
}
],
"prompt_number": 22
}
],
"metadata": {}