spot/tests/python/product.ipynb
Alexandre Duret-Lutz 60296317c7 python: more conventional __repr__ for several types
* NEWS: Mention the change.
* python/spot/__init__.py: Add _repr_latex_ for twa_word, and
remove __repr__ and __str__ for atomic_prop_set.
* python/spot/impl.i: Implement __repr__ and __str__ for
atomic_prop_set.  Fix __repr__ for trival, acc_code, acc_cond,
mark_t.  Remove __repr__ for twa_run and twa_word.
* tests/python/acc_cond.ipynb, tests/python/accparse.ipynb,
tests/python/atva16-fig2a.ipynb, tests/python/automata.ipynb,
tests/python/bdditer.py, tests/python/contains.ipynb,
tests/python/gen.ipynb, tests/python/highlighting.ipynb,
tests/python/ltlsimple.py, tests/python/ltsmin-dve.ipynb,
tests/python/product.ipynb, tests/python/relabel.py,
tests/python/satmin.ipynb tests/python/stutter-inv.ipynb,
tests/python/word.ipynb: Adjust test cases.
* tests/python/formulas.ipynb: Add test for atomic_prop_set.
2018-11-03 07:53:26 +01:00

2494 lines
198 KiB
Text

{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"metadata": {},
"outputs": [],
"source": [
"from IPython.display import display, HTML\n",
"import spot\n",
"from spot.jupyter import display_inline # display multiple arguments side-by-side\n",
"import buddy\n",
"spot.setup(show_default='.tvb')"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# Anatomy of a product\n",
"\n",
"In this notebook, we write a Python function that constructs the product of two automata.\n",
"\n",
"This is obviously not a new feature: Spot can already make a product of two automata using its `product()` function. \n",
"For instance:"
]
},
{
"cell_type": "code",
"execution_count": 2,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"<div style='vertical-align:text-top;display:inline-block;'><?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.40.1 (20161225.0304)\n",
" -->\n",
"<!-- Pages: 1 -->\n",
"<svg width=\"151pt\" height=\"205pt\"\n",
" viewBox=\"0.00 0.00 151.00 205.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 201)\">\n",
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-201 147,-201 147,4 -4,4\"/>\n",
"<text text-anchor=\"start\" x=\"50.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">Inf(</text>\n",
"<text text-anchor=\"start\" x=\"72.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"88.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)</text>\n",
"<text text-anchor=\"start\" x=\"48.5\" y=\"-168.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">[Büchi]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g id=\"node2\" class=\"node\">\n",
"<title>0</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"18\" cy=\"-105\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"18\" y=\"-101.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g id=\"edge1\" class=\"edge\">\n",
"<title>I&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M18,-159.8767C18,-156.822 18,-143.0552 18,-130.0759\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"18,-123.0193 21.1501,-130.0192 18,-126.5193 18.0001,-130.0193 18.0001,-130.0193 18.0001,-130.0193 18,-126.5193 14.8501,-130.0193 18,-123.0193 18,-123.0193\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge2\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.0373,-111.3792C44.8579,-112.6811 54,-110.5547 54,-105 54,-100.834 48.8576,-98.5964 42.1433,-98.2872\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.0373,-98.6208 41.8818,-95.1459 38.5335,-98.4566 42.0296,-98.2924 42.0296,-98.2924 42.0296,-98.2924 38.5335,-98.4566 42.1774,-101.439 35.0373,-98.6208 35.0373,-98.6208\"/>\n",
"<text text-anchor=\"start\" x=\"54\" y=\"-101.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g id=\"node3\" class=\"node\">\n",
"<title>1</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"18\" cy=\"-18\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"13.5\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g id=\"edge3\" class=\"edge\">\n",
"<title>0&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M18,-86.9735C18,-74.2586 18,-57.0603 18,-43.0183\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"18,-36.0034 21.1501,-43.0033 18,-39.5034 18.0001,-43.0034 18.0001,-43.0034 18.0001,-43.0034 18,-39.5034 14.8501,-43.0034 18,-36.0034 18,-36.0034\"/>\n",
"<text text-anchor=\"start\" x=\"18\" y=\"-57.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge4\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.7817,-21.775C45.3149,-22.4165 54,-21.1582 54,-18 54,-15.6807 49.3161,-14.386 43.0521,-14.1159\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.7817,-14.225 42.7337,-10.9702 39.2813,-14.1724 42.7809,-14.1199 42.7809,-14.1199 42.7809,-14.1199 39.2813,-14.1724 42.8282,-17.2695 35.7817,-14.225 35.7817,-14.225\"/>\n",
"<text text-anchor=\"start\" x=\"54\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge5\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.2149,-23.5866C58.4302,-27.9423 91,-26.0801 91,-18 91,-10.709 64.4809,-8.4807 42.2449,-11.3152\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.2149,-12.4134 41.6449,-8.2206 38.673,-11.8731 42.1311,-11.3329 42.1311,-11.3329 42.1311,-11.3329 38.673,-11.8731 42.6173,-14.4452 35.2149,-12.4134 35.2149,-12.4134\"/>\n",
"<text text-anchor=\"start\" x=\"91\" y=\"-21.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"100\" y=\"-6.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"</g>\n",
"</g>\n",
"</svg>\n",
"</div><div style='vertical-align:text-top;display:inline-block;'><?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.40.1 (20161225.0304)\n",
" -->\n",
"<!-- Pages: 1 -->\n",
"<svg width=\"208pt\" height=\"220pt\"\n",
" viewBox=\"0.00 0.00 208.02 220.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 216)\">\n",
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-216 204.0193,-216 204.0193,4 -4,4\"/>\n",
"<text text-anchor=\"start\" x=\"53.0096\" y=\"-197.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">Inf(</text>\n",
"<text text-anchor=\"start\" x=\"75.0096\" y=\"-197.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"91.0096\" y=\"-197.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)&amp;Inf(</text>\n",
"<text text-anchor=\"start\" x=\"127.0096\" y=\"-197.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"143.0096\" y=\"-197.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)</text>\n",
"<text text-anchor=\"start\" x=\"56.0096\" y=\"-183.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">[gen. Büchi 2]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g id=\"node2\" class=\"node\">\n",
"<title>0</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"68.0193\" cy=\"-120\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"68.0193\" y=\"-116.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g id=\"edge1\" class=\"edge\">\n",
"<title>I&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M68.0193,-174.8767C68.0193,-171.822 68.0193,-158.0552 68.0193,-145.0759\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"68.0193,-138.0193 71.1694,-145.0192 68.0193,-141.5193 68.0194,-145.0193 68.0194,-145.0193 68.0194,-145.0193 68.0193,-141.5193 64.8694,-145.0193 68.0193,-138.0193 68.0193,-138.0193\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge2\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M85.801,-123.2357C95.3342,-123.7856 104.0193,-122.707 104.0193,-120 104.0193,-118.012 99.3354,-116.9023 93.0714,-116.6708\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"85.801,-116.7643 92.7599,-113.5244 89.3007,-116.7192 92.8004,-116.6742 92.8004,-116.6742 92.8004,-116.6742 89.3007,-116.7192 92.841,-119.8239 85.801,-116.7643 85.801,-116.7643\"/>\n",
"<text text-anchor=\"start\" x=\"104.0193\" y=\"-123.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"114.5193\" y=\"-108.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge3\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M85.5885,-124.845C108.7793,-128.5056 141.0193,-126.8906 141.0193,-120 141.0193,-113.7823 114.7687,-111.8601 92.6031,-114.2335\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"85.5885,-115.155 92.1185,-111.12 89.0587,-114.6991 92.5288,-114.2432 92.5288,-114.2432 92.5288,-114.2432 89.0587,-114.6991 92.9392,-117.3663 85.5885,-115.155 85.5885,-115.155\"/>\n",
"<text text-anchor=\"start\" x=\"152.5193\" y=\"-123.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b</text>\n",
"<text text-anchor=\"start\" x=\"141.0193\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"157.0193\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g id=\"node3\" class=\"node\">\n",
"<title>1</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"68.0193\" cy=\"-18\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"68.0193\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g id=\"edge4\" class=\"edge\">\n",
"<title>0&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M50.3286,-115.3021C35.307,-110.2732 14.6933,-100.6701 5.0193,-84 -1.6731,-72.4679 -1.6731,-65.5321 5.0193,-54 13.3329,-39.6741 29.7258,-30.5674 43.7056,-25.0978\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"50.3286,-22.6979 44.8205,-28.0443 47.0379,-23.8903 43.7473,-25.0827 43.7473,-25.0827 43.7473,-25.0827 47.0379,-23.8903 42.6741,-22.1211 50.3286,-22.6979 50.3286,-22.6979\"/>\n",
"<text text-anchor=\"start\" x=\"5.0193\" y=\"-65.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g id=\"edge5\" class=\"edge\">\n",
"<title>1&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M68.0193,-36.0777C68.0193,-52.2729 68.0193,-76.2033 68.0193,-94.3707\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"68.0193,-101.7644 64.8694,-94.7644 68.0193,-98.2644 68.0194,-94.7644 68.0194,-94.7644 68.0194,-94.7644 68.0193,-98.2644 71.1694,-94.7645 68.0193,-101.7644 68.0193,-101.7644\"/>\n",
"<text text-anchor=\"start\" x=\"68.0193\" y=\"-72.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"78.5193\" y=\"-57.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g id=\"edge6\" class=\"edge\">\n",
"<title>1&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M83.5721,-27.9858C91.923,-34.3143 101.423,-43.3143 106.0193,-54 111.2877,-66.2483 111.2877,-71.7517 106.0193,-84 102.4285,-92.3482 95.8446,-99.6675 89.154,-105.4879\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"83.5721,-110.0142 87.0252,-103.1586 86.2906,-107.8098 89.0092,-105.6053 89.0092,-105.6053 89.0092,-105.6053 86.2906,-107.8098 90.9932,-108.052 83.5721,-110.0142 83.5721,-110.0142\"/>\n",
"<text text-anchor=\"start\" x=\"109.0193\" y=\"-72.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"110.0193\" y=\"-58.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"126.0193\" y=\"-58.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge7\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M85.801,-22.4941C95.3342,-23.2578 104.0193,-21.7598 104.0193,-18 104.0193,-15.2389 99.3354,-13.6976 93.0714,-13.3761\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"85.801,-13.5059 92.7436,-10.2313 89.3004,-13.4434 92.7999,-13.3808 92.7999,-13.3808 92.7999,-13.3808 89.3004,-13.4434 92.8562,-16.5303 85.801,-13.5059 85.801,-13.5059\"/>\n",
"<text text-anchor=\"start\" x=\"104.0193\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge8\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M85.0367,-24.4905C109.3677,-29.8803 145.0193,-27.7168 145.0193,-18 145.0193,-9.1942 115.7391,-6.5917 92.1396,-10.1928\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"85.0367,-11.5095 91.3452,-7.1363 88.4781,-10.8715 91.9194,-10.2335 91.9194,-10.2335 91.9194,-10.2335 88.4781,-10.8715 92.4936,-13.3307 85.0367,-11.5095 85.0367,-11.5095\"/>\n",
"<text text-anchor=\"start\" x=\"145.0193\" y=\"-21.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b &amp; !c</text>\n",
"<text text-anchor=\"start\" x=\"155.5193\" y=\"-6.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"</g>\n",
"</svg>\n",
"</div><div style='vertical-align:text-top;display:inline-block;'><?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.40.1 (20161225.0304)\n",
" -->\n",
"<!-- Pages: 1 -->\n",
"<svg width=\"298pt\" height=\"360pt\"\n",
" viewBox=\"0.00 0.00 298.26 360.00\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
"<g id=\"graph0\" class=\"graph\" transform=\"scale(.8491 .8491) rotate(0) translate(4 420)\">\n",
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-420 347.2812,-420 347.2812,4 -4,4\"/>\n",
"<text text-anchor=\"start\" x=\"98.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">Inf(</text>\n",
"<text text-anchor=\"start\" x=\"120.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"136.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)&amp;Inf(</text>\n",
"<text text-anchor=\"start\" x=\"172.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"188.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)&amp;Inf(</text>\n",
"<text text-anchor=\"start\" x=\"224.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"<text text-anchor=\"start\" x=\"240.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)</text>\n",
"<text text-anchor=\"start\" x=\"127.6406\" y=\"-387.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">[gen. Büchi 3]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g id=\"node2\" class=\"node\">\n",
"<title>0</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"160.2812\" cy=\"-324\" rx=\"27\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"150.2812\" y=\"-320.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">0,0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g id=\"edge1\" class=\"edge\">\n",
"<title>I&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M160.2812,-378.8767C160.2812,-375.822 160.2812,-362.0552 160.2812,-349.0759\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"160.2812,-342.0193 163.4313,-349.0192 160.2813,-345.5193 160.2813,-349.0193 160.2813,-349.0193 160.2813,-349.0193 160.2813,-345.5193 157.1313,-349.0193 160.2812,-342.0193 160.2812,-342.0193\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge2\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M187.0761,-327.3676C197.0616,-327.478 205.2812,-326.3555 205.2812,-324 205.2812,-322.2334 200.6577,-321.1603 194.1333,-320.7808\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"187.0761,-320.6324 194.1408,-317.6303 190.5753,-320.706 194.0745,-320.7796 194.0745,-320.7796 194.0745,-320.7796 190.5753,-320.706 194.0083,-323.9289 187.0761,-320.6324 187.0761,-320.6324\"/>\n",
"<text text-anchor=\"start\" x=\"205.2812\" y=\"-327.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"215.7812\" y=\"-312.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge3\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M186.0796,-329.5486C211.4499,-332.248 242.2812,-330.3984 242.2812,-324 242.2812,-318.2014 216.9598,-316.1388 193.329,-317.8121\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"186.0796,-318.4514 192.7758,-314.6986 189.566,-318.1439 193.0525,-317.8364 193.0525,-317.8364 193.0525,-317.8364 189.566,-318.1439 193.3292,-320.9742 186.0796,-318.4514 186.0796,-318.4514\"/>\n",
"<text text-anchor=\"start\" x=\"253.7812\" y=\"-327.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b</text>\n",
"<text text-anchor=\"start\" x=\"242.2812\" y=\"-313.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"258.2812\" y=\"-313.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g id=\"node3\" class=\"node\">\n",
"<title>1</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"98.2812\" cy=\"-222\" rx=\"27\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"88.2812\" y=\"-218.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">0,1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g id=\"edge4\" class=\"edge\">\n",
"<title>0&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M134.6199,-317.5565C109.9118,-310.7718 75.1592,-299.4971 67.2812,-288 59.7446,-277.001 62.641,-270.4998 67.2812,-258 69.4269,-252.2201 72.9625,-246.7462 76.8935,-241.8925\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"81.6302,-236.4982 79.3784,-243.8367 79.3208,-239.1282 77.0114,-241.7582 77.0114,-241.7582 77.0114,-241.7582 79.3208,-239.1282 74.6444,-239.6798 81.6302,-236.4982 81.6302,-236.4982\"/>\n",
"<text text-anchor=\"start\" x=\"67.2812\" y=\"-269.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 2 -->\n",
"<g id=\"node4\" class=\"node\">\n",
"<title>2</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"109.2812\" cy=\"-18\" rx=\"27\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"99.2812\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1,0</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;2 -->\n",
"<g id=\"edge5\" class=\"edge\">\n",
"<title>0&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M180.7162,-311.6108C190.4934,-305.191 202.0502,-296.8509 211.2812,-288 277.1558,-224.8381 335.2804,-185.4263 298.2812,-102 285.3971,-72.9487 273.2111,-69.1623 245.2812,-54 212.9274,-36.4361 171.5265,-27.0749 142.9477,-22.346\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"135.9714,-21.2414 143.378,-19.225 139.4283,-21.7888 142.8853,-22.3362 142.8853,-22.3362 142.8853,-22.3362 139.4283,-21.7888 142.3926,-25.4475 135.9714,-21.2414 135.9714,-21.2414\"/>\n",
"<text text-anchor=\"start\" x=\"309.2812\" y=\"-174.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"310.2812\" y=\"-160.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"326.2812\" y=\"-160.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g id=\"edge6\" class=\"edge\">\n",
"<title>1&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M105.7255,-239.3679C111.862,-253.0084 121.1742,-272.2622 131.2812,-288 134.4526,-292.9381 138.1783,-297.9925 141.8831,-302.6938\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"146.5211,-308.4246 139.6688,-304.965 144.3192,-305.7039 142.1174,-302.9833 142.1174,-302.9833 142.1174,-302.9833 144.3192,-305.7039 144.5659,-301.0016 146.5211,-308.4246 146.5211,-308.4246\"/>\n",
"<text text-anchor=\"start\" x=\"131.2812\" y=\"-276.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"141.7812\" y=\"-261.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g id=\"edge7\" class=\"edge\">\n",
"<title>1&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M123.9724,-227.9702C139.7306,-233.1016 158.6715,-242.2517 168.2812,-258 175.8397,-270.3867 174.0451,-286.5246 170.2609,-299.742\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"168.0006,-306.7422 167.1539,-299.1129 169.0761,-303.4115 170.1515,-300.0808 170.1515,-300.0808 170.1515,-300.0808 169.0761,-303.4115 173.1492,-301.0487 168.0006,-306.7422 168.0006,-306.7422\"/>\n",
"<text text-anchor=\"start\" x=\"173.2812\" y=\"-276.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"174.2812\" y=\"-262.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"190.2812\" y=\"-262.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge8\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M124.6278,-226.6692C134.8144,-226.8767 143.2812,-225.3203 143.2812,-222 143.2812,-219.5098 138.5187,-218.0117 131.8399,-217.5059\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"124.6278,-217.3308 131.7023,-214.3517 128.1268,-217.4158 131.6258,-217.5008 131.6258,-217.5008 131.6258,-217.5008 128.1268,-217.4158 131.5493,-220.6499 124.6278,-217.3308 124.6278,-217.3308\"/>\n",
"<text text-anchor=\"start\" x=\"143.2812\" y=\"-218.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge9\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M123.1487,-229.4501C149.9682,-233.5654 184.2812,-231.082 184.2812,-222 184.2812,-213.6985 155.6123,-210.9102 130.2026,-213.6351\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"123.1487,-214.5499 129.6855,-210.5257 126.6197,-214.0997 130.0906,-213.6496 130.0906,-213.6496 130.0906,-213.6496 126.6197,-214.0997 130.4958,-216.7734 123.1487,-214.5499 123.1487,-214.5499\"/>\n",
"<text text-anchor=\"start\" x=\"184.2812\" y=\"-225.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b &amp; !c</text>\n",
"<text text-anchor=\"start\" x=\"194.7812\" y=\"-210.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;2 -->\n",
"<g id=\"edge10\" class=\"edge\">\n",
"<title>1&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M77.0983,-210.4497C54.2395,-196.6366 19.1207,-171.162 4.2812,-138 -2.254,-123.3955 .2268,-117.4778 4.2812,-102 10.4837,-78.3221 13.2954,-70.6019 31.2812,-54 44.3014,-41.9817 62.0356,-33.365 77.3044,-27.581\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"84.1205,-25.1208 78.6058,-30.4603 80.8284,-26.3091 77.5363,-27.4974 77.5363,-27.4974 77.5363,-27.4974 80.8284,-26.3091 76.4668,-24.5345 84.1205,-25.1208 84.1205,-25.1208\"/>\n",
"<text text-anchor=\"start\" x=\"4.2812\" y=\"-123.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"17.2812\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"33.2812\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 3 -->\n",
"<g id=\"node5\" class=\"node\">\n",
"<title>3</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"98.2812\" cy=\"-120\" rx=\"27\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"88.2812\" y=\"-116.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1,1</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;3 -->\n",
"<g id=\"edge11\" class=\"edge\">\n",
"<title>1&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M98.2812,-203.7644C98.2812,-187.5192 98.2812,-163.5825 98.2812,-145.4527\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"98.2812,-138.0777 101.4313,-145.0776 98.2813,-141.5777 98.2813,-145.0777 98.2813,-145.0777 98.2813,-145.0777 98.2813,-141.5777 95.1313,-145.0777 98.2812,-138.0777 98.2812,-138.0777\"/>\n",
"<text text-anchor=\"start\" x=\"98.2812\" y=\"-174.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; !c</text>\n",
"<text text-anchor=\"start\" x=\"121.2812\" y=\"-159.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;2 -->\n",
"<g id=\"edge12\" class=\"edge\">\n",
"<title>2&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M135.6278,-22.6692C145.8144,-22.8767 154.2812,-21.3203 154.2812,-18 154.2812,-15.5098 149.5187,-14.0117 142.8399,-13.5059\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"135.6278,-13.3308 142.7023,-10.3517 139.1268,-13.4158 142.6258,-13.5008 142.6258,-13.5008 142.6258,-13.5008 139.1268,-13.4158 142.5493,-16.6499 135.6278,-13.3308 135.6278,-13.3308\"/>\n",
"<text text-anchor=\"start\" x=\"154.2812\" y=\"-21.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"177.2812\" y=\"-6.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;2 -->\n",
"<g id=\"edge14\" class=\"edge\">\n",
"<title>2&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M134.3443,-24.9574C167.401,-29.743 216.2812,-27.4238 216.2812,-18 216.2812,-9.2388 174.0331,-6.6183 141.5294,-10.1385\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"134.3443,-11.0426 140.8962,-7.0432 137.8169,-10.6056 141.2895,-10.1686 141.2895,-10.1686 141.2895,-10.1686 137.8169,-10.6056 141.6828,-13.2939 134.3443,-11.0426 134.3443,-11.0426\"/>\n",
"<text text-anchor=\"start\" x=\"223.2812\" y=\"-21.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"216.2812\" y=\"-7.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"232.2812\" y=\"-7.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"248.2812\" y=\"-7.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;3 -->\n",
"<g id=\"edge13\" class=\"edge\">\n",
"<title>2&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M107.3317,-36.0777C105.5851,-52.2729 103.0044,-76.2033 101.0452,-94.3707\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"100.2478,-101.7644 97.8666,-94.467 100.6231,-98.2846 100.9984,-94.8048 100.9984,-94.8048 100.9984,-94.8048 100.6231,-98.2846 104.1303,-95.1426 100.2478,-101.7644 100.2478,-101.7644\"/>\n",
"<text text-anchor=\"start\" x=\"104.2812\" y=\"-65.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; !c</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;2 -->\n",
"<g id=\"edge15\" class=\"edge\">\n",
"<title>3&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M124.5946,-115.0604C141.9558,-110.2881 163.4291,-101.1485 174.2812,-84 181.4112,-72.7332 181.0504,-65.4872 174.2812,-54 166.9753,-41.6021 153.694,-33.1733 141.0323,-27.6086\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"134.5024,-24.9539 142.1734,-24.6722 137.7447,-26.2721 140.987,-27.5902 140.987,-27.5902 140.987,-27.5902 137.7447,-26.2721 139.8006,-30.5083 134.5024,-24.9539 134.5024,-24.9539\"/>\n",
"<text text-anchor=\"start\" x=\"179.2812\" y=\"-72.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"202.2812\" y=\"-57.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;2 -->\n",
"<g id=\"edge17\" class=\"edge\">\n",
"<title>3&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M76.4536,-109.3159C61.7697,-101.6255 44.3717,-91.3533 40.2812,-84 33.7996,-72.3482 33.3695,-65.402 40.2812,-54 48.3469,-40.6943 63.1181,-32.0748 76.9301,-26.6177\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"83.5999,-24.1862 78.1022,-29.5433 80.3116,-25.385 77.0233,-26.5838 77.0233,-26.5838 77.0233,-26.5838 80.3116,-25.385 75.9444,-23.6244 83.5999,-24.1862 83.5999,-24.1862\"/>\n",
"<text text-anchor=\"start\" x=\"40.2812\" y=\"-72.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"45.2812\" y=\"-58.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"61.2812\" y=\"-58.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"77.2812\" y=\"-58.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;3 -->\n",
"<g id=\"edge16\" class=\"edge\">\n",
"<title>3&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M124.6278,-124.6692C134.8144,-124.8767 143.2812,-123.3203 143.2812,-120 143.2812,-117.5098 138.5187,-116.0117 131.8399,-115.5059\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"124.6278,-115.3308 131.7023,-112.3517 128.1268,-115.4158 131.6258,-115.5008 131.6258,-115.5008 131.6258,-115.5008 128.1268,-115.4158 131.5493,-118.6499 124.6278,-115.3308 124.6278,-115.3308\"/>\n",
"<text text-anchor=\"start\" x=\"143.2812\" y=\"-116.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; !c</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;3 -->\n",
"<g id=\"edge18\" class=\"edge\">\n",
"<title>3&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M123.4219,-126.8825C157.5961,-131.7668 209.2812,-129.4727 209.2812,-120 209.2812,-111.1564 164.2326,-108.5695 130.4414,-112.2394\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"123.4219,-113.1175 129.9768,-109.1229 126.8949,-112.683 130.3678,-112.2486 130.3678,-112.2486 130.3678,-112.2486 126.8949,-112.683 130.7588,-115.3742 123.4219,-113.1175 123.4219,-113.1175\"/>\n",
"<text text-anchor=\"start\" x=\"209.2812\" y=\"-123.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; !c</text>\n",
"<text text-anchor=\"start\" x=\"224.2812\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"240.2812\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"</g>\n",
"</svg>\n",
"</div>"
],
"text/plain": [
"<IPython.core.display.HTML object>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"a1 = spot.translate('FGa & GFb')\n",
"a2 = spot.translate('G(Fc U b)')\n",
"prod = spot.product(a1, a2)\n",
"display_inline(a1, a2, prod)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"The builtin `spot.product()` function produces an automaton whose language is the intersection of the two input languages. It does so by building an automaton that keeps track of the runs in the two input automata. The states are labeled by pairs of input states so that we can more easily follow what is going on, but those labels are purely cosmetic. The acceptance condition is the conjunction of the two acceptance condition, but the acceptance sets of one input automaton have been shifted to not conflict with the other automaton.\n",
"\n",
"In fact, that automaton printer has an option to shift those sets in its output, and this is perfect for illustrating products. For instance `a.show('+3')` will display `a1` with all its acceptance sets shifted by 3. \n",
"\n",
"Let's define a function for displaying the three automata involved in a product, using this shift option so we can follow what is going on with the acceptance sets."
]
},
{
"cell_type": "code",
"execution_count": 3,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"<div style='vertical-align:text-top;display:inline-block;'><?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.40.1 (20161225.0304)\n",
" -->\n",
"<!-- Pages: 1 -->\n",
"<svg width=\"151pt\" height=\"205pt\"\n",
" viewBox=\"0.00 0.00 151.00 205.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 201)\">\n",
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-201 147,-201 147,4 -4,4\"/>\n",
"<text text-anchor=\"start\" x=\"50.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">Inf(</text>\n",
"<text text-anchor=\"start\" x=\"72.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"88.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)</text>\n",
"<text text-anchor=\"start\" x=\"48.5\" y=\"-168.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">[Büchi]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g id=\"node2\" class=\"node\">\n",
"<title>0</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"18\" cy=\"-105\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"18\" y=\"-101.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g id=\"edge1\" class=\"edge\">\n",
"<title>I&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M18,-159.8767C18,-156.822 18,-143.0552 18,-130.0759\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"18,-123.0193 21.1501,-130.0192 18,-126.5193 18.0001,-130.0193 18.0001,-130.0193 18.0001,-130.0193 18,-126.5193 14.8501,-130.0193 18,-123.0193 18,-123.0193\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge2\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.0373,-111.3792C44.8579,-112.6811 54,-110.5547 54,-105 54,-100.834 48.8576,-98.5964 42.1433,-98.2872\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.0373,-98.6208 41.8818,-95.1459 38.5335,-98.4566 42.0296,-98.2924 42.0296,-98.2924 42.0296,-98.2924 38.5335,-98.4566 42.1774,-101.439 35.0373,-98.6208 35.0373,-98.6208\"/>\n",
"<text text-anchor=\"start\" x=\"54\" y=\"-101.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g id=\"node3\" class=\"node\">\n",
"<title>1</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"18\" cy=\"-18\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"13.5\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g id=\"edge3\" class=\"edge\">\n",
"<title>0&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M18,-86.9735C18,-74.2586 18,-57.0603 18,-43.0183\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"18,-36.0034 21.1501,-43.0033 18,-39.5034 18.0001,-43.0034 18.0001,-43.0034 18.0001,-43.0034 18,-39.5034 14.8501,-43.0034 18,-36.0034 18,-36.0034\"/>\n",
"<text text-anchor=\"start\" x=\"18\" y=\"-57.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge4\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.7817,-21.775C45.3149,-22.4165 54,-21.1582 54,-18 54,-15.6807 49.3161,-14.386 43.0521,-14.1159\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.7817,-14.225 42.7337,-10.9702 39.2813,-14.1724 42.7809,-14.1199 42.7809,-14.1199 42.7809,-14.1199 39.2813,-14.1724 42.8282,-17.2695 35.7817,-14.225 35.7817,-14.225\"/>\n",
"<text text-anchor=\"start\" x=\"54\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge5\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.2149,-23.5866C58.4302,-27.9423 91,-26.0801 91,-18 91,-10.709 64.4809,-8.4807 42.2449,-11.3152\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.2149,-12.4134 41.6449,-8.2206 38.673,-11.8731 42.1311,-11.3329 42.1311,-11.3329 42.1311,-11.3329 38.673,-11.8731 42.6173,-14.4452 35.2149,-12.4134 35.2149,-12.4134\"/>\n",
"<text text-anchor=\"start\" x=\"91\" y=\"-21.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"100\" y=\"-6.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"</g>\n",
"</g>\n",
"</svg>\n",
"</div><div style='vertical-align:text-top;display:inline-block;'><svg height=\"220pt\" viewBox=\"0.00 0.00 208.02 220.00\" width=\"208pt\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
"<g class=\"graph\" id=\"graph0\" transform=\"scale(1 1) rotate(0) translate(4 216)\">\n",
"<polygon fill=\"#ffffff\" points=\"-4,4 -4,-216 204.0193,-216 204.0193,4 -4,4\" stroke=\"transparent\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"53.0096\" y=\"-197.8\">Inf(</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"75.0096\" y=\"-197.8\">❶</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"91.0096\" y=\"-197.8\">)&amp;Inf(</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"127.0096\" y=\"-197.8\">❷</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"143.0096\" y=\"-197.8\">)</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"56.0096\" y=\"-183.8\">[gen. Büchi 2]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g class=\"node\" id=\"node2\">\n",
"<title>0</title>\n",
"<ellipse cx=\"68.0193\" cy=\"-120\" fill=\"#ffffaa\" rx=\"18\" ry=\"18\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"middle\" x=\"68.0193\" y=\"-116.3\">0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge1\">\n",
"<title>I-&gt;0</title>\n",
"<path d=\"M68.0193,-174.8767C68.0193,-171.822 68.0193,-158.0552 68.0193,-145.0759\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"68.0193,-138.0193 71.1694,-145.0192 68.0193,-141.5193 68.0194,-145.0193 68.0194,-145.0193 68.0194,-145.0193 68.0193,-141.5193 64.8694,-145.0193 68.0193,-138.0193 68.0193,-138.0193\" stroke=\"#000000\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge2\">\n",
"<title>0-&gt;0</title>\n",
"<path d=\"M85.801,-123.2357C95.3342,-123.7856 104.0193,-122.707 104.0193,-120 104.0193,-118.012 99.3354,-116.9023 93.0714,-116.6708\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.801,-116.7643 92.7599,-113.5244 89.3007,-116.7192 92.8004,-116.6742 92.8004,-116.6742 92.8004,-116.6742 89.3007,-116.7192 92.841,-119.8239 85.801,-116.7643 85.801,-116.7643\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"104.0193\" y=\"-123.8\">!b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"114.5193\" y=\"-108.8\">❶</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge3\">\n",
"<title>0-&gt;0</title>\n",
"<path d=\"M85.5885,-124.845C108.7793,-128.5056 141.0193,-126.8906 141.0193,-120 141.0193,-113.7823 114.7687,-111.8601 92.6031,-114.2335\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.5885,-115.155 92.1185,-111.12 89.0587,-114.6991 92.5288,-114.2432 92.5288,-114.2432 92.5288,-114.2432 89.0587,-114.6991 92.9392,-117.3663 85.5885,-115.155 85.5885,-115.155\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"152.5193\" y=\"-123.8\">b</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"141.0193\" y=\"-109.8\">❶</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"157.0193\" y=\"-109.8\">❷</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g class=\"node\" id=\"node3\">\n",
"<title>1</title>\n",
"<ellipse cx=\"68.0193\" cy=\"-18\" fill=\"#ffffaa\" rx=\"18\" ry=\"18\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"middle\" x=\"68.0193\" y=\"-14.3\">1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge4\">\n",
"<title>0-&gt;1</title>\n",
"<path d=\"M50.3286,-115.3021C35.307,-110.2732 14.6933,-100.6701 5.0193,-84 -1.6731,-72.4679 -1.6731,-65.5321 5.0193,-54 13.3329,-39.6741 29.7258,-30.5674 43.7056,-25.0978\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"50.3286,-22.6979 44.8205,-28.0443 47.0379,-23.8903 43.7473,-25.0827 43.7473,-25.0827 43.7473,-25.0827 47.0379,-23.8903 42.6741,-22.1211 50.3286,-22.6979 50.3286,-22.6979\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"5.0193\" y=\"-65.3\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge5\">\n",
"<title>1-&gt;0</title>\n",
"<path d=\"M68.0193,-36.0777C68.0193,-52.2729 68.0193,-76.2033 68.0193,-94.3707\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"68.0193,-101.7644 64.8694,-94.7644 68.0193,-98.2644 68.0194,-94.7644 68.0194,-94.7644 68.0194,-94.7644 68.0193,-98.2644 71.1694,-94.7645 68.0193,-101.7644 68.0193,-101.7644\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"68.0193\" y=\"-72.8\">!b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"78.5193\" y=\"-57.8\">❶</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge6\">\n",
"<title>1-&gt;0</title>\n",
"<path d=\"M83.5721,-27.9858C91.923,-34.3143 101.423,-43.3143 106.0193,-54 111.2877,-66.2483 111.2877,-71.7517 106.0193,-84 102.4285,-92.3482 95.8446,-99.6675 89.154,-105.4879\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"83.5721,-110.0142 87.0252,-103.1586 86.2906,-107.8098 89.0092,-105.6053 89.0092,-105.6053 89.0092,-105.6053 86.2906,-107.8098 90.9932,-108.052 83.5721,-110.0142 83.5721,-110.0142\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"109.0193\" y=\"-72.8\">b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"110.0193\" y=\"-58.8\">❶</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"126.0193\" y=\"-58.8\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge7\">\n",
"<title>1-&gt;1</title>\n",
"<path d=\"M85.801,-22.4941C95.3342,-23.2578 104.0193,-21.7598 104.0193,-18 104.0193,-15.2389 99.3354,-13.6976 93.0714,-13.3761\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.801,-13.5059 92.7436,-10.2313 89.3004,-13.4434 92.7999,-13.3808 92.7999,-13.3808 92.7999,-13.3808 89.3004,-13.4434 92.8562,-16.5303 85.801,-13.5059 85.801,-13.5059\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"104.0193\" y=\"-14.3\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge8\">\n",
"<title>1-&gt;1</title>\n",
"<path d=\"M85.0367,-24.4905C109.3677,-29.8803 145.0193,-27.7168 145.0193,-18 145.0193,-9.1942 115.7391,-6.5917 92.1396,-10.1928\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.0367,-11.5095 91.3452,-7.1363 88.4781,-10.8715 91.9194,-10.2335 91.9194,-10.2335 91.9194,-10.2335 88.4781,-10.8715 92.4936,-13.3307 85.0367,-11.5095 85.0367,-11.5095\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"145.0193\" y=\"-21.8\">b &amp; !c</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"155.5193\" y=\"-6.8\">❷</text>\n",
"</g>\n",
"</g>\n",
"</svg></div><div style='vertical-align:text-top;display:inline-block;'><?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.40.1 (20161225.0304)\n",
" -->\n",
"<!-- Pages: 1 -->\n",
"<svg width=\"298pt\" height=\"360pt\"\n",
" viewBox=\"0.00 0.00 298.26 360.00\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
"<g id=\"graph0\" class=\"graph\" transform=\"scale(.8491 .8491) rotate(0) translate(4 420)\">\n",
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-420 347.2812,-420 347.2812,4 -4,4\"/>\n",
"<text text-anchor=\"start\" x=\"98.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">Inf(</text>\n",
"<text text-anchor=\"start\" x=\"120.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"136.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)&amp;Inf(</text>\n",
"<text text-anchor=\"start\" x=\"172.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"188.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)&amp;Inf(</text>\n",
"<text text-anchor=\"start\" x=\"224.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"<text text-anchor=\"start\" x=\"240.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)</text>\n",
"<text text-anchor=\"start\" x=\"127.6406\" y=\"-387.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">[gen. Büchi 3]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g id=\"node2\" class=\"node\">\n",
"<title>0</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"160.2812\" cy=\"-324\" rx=\"27\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"150.2812\" y=\"-320.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">0,0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g id=\"edge1\" class=\"edge\">\n",
"<title>I&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M160.2812,-378.8767C160.2812,-375.822 160.2812,-362.0552 160.2812,-349.0759\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"160.2812,-342.0193 163.4313,-349.0192 160.2813,-345.5193 160.2813,-349.0193 160.2813,-349.0193 160.2813,-349.0193 160.2813,-345.5193 157.1313,-349.0193 160.2812,-342.0193 160.2812,-342.0193\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge2\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M187.0761,-327.3676C197.0616,-327.478 205.2812,-326.3555 205.2812,-324 205.2812,-322.2334 200.6577,-321.1603 194.1333,-320.7808\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"187.0761,-320.6324 194.1408,-317.6303 190.5753,-320.706 194.0745,-320.7796 194.0745,-320.7796 194.0745,-320.7796 190.5753,-320.706 194.0083,-323.9289 187.0761,-320.6324 187.0761,-320.6324\"/>\n",
"<text text-anchor=\"start\" x=\"205.2812\" y=\"-327.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"215.7812\" y=\"-312.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge3\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M186.0796,-329.5486C211.4499,-332.248 242.2812,-330.3984 242.2812,-324 242.2812,-318.2014 216.9598,-316.1388 193.329,-317.8121\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"186.0796,-318.4514 192.7758,-314.6986 189.566,-318.1439 193.0525,-317.8364 193.0525,-317.8364 193.0525,-317.8364 189.566,-318.1439 193.3292,-320.9742 186.0796,-318.4514 186.0796,-318.4514\"/>\n",
"<text text-anchor=\"start\" x=\"253.7812\" y=\"-327.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b</text>\n",
"<text text-anchor=\"start\" x=\"242.2812\" y=\"-313.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"258.2812\" y=\"-313.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g id=\"node3\" class=\"node\">\n",
"<title>1</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"98.2812\" cy=\"-222\" rx=\"27\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"88.2812\" y=\"-218.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">0,1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g id=\"edge4\" class=\"edge\">\n",
"<title>0&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M134.6199,-317.5565C109.9118,-310.7718 75.1592,-299.4971 67.2812,-288 59.7446,-277.001 62.641,-270.4998 67.2812,-258 69.4269,-252.2201 72.9625,-246.7462 76.8935,-241.8925\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"81.6302,-236.4982 79.3784,-243.8367 79.3208,-239.1282 77.0114,-241.7582 77.0114,-241.7582 77.0114,-241.7582 79.3208,-239.1282 74.6444,-239.6798 81.6302,-236.4982 81.6302,-236.4982\"/>\n",
"<text text-anchor=\"start\" x=\"67.2812\" y=\"-269.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 2 -->\n",
"<g id=\"node4\" class=\"node\">\n",
"<title>2</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"109.2812\" cy=\"-18\" rx=\"27\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"99.2812\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1,0</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;2 -->\n",
"<g id=\"edge5\" class=\"edge\">\n",
"<title>0&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M180.7162,-311.6108C190.4934,-305.191 202.0502,-296.8509 211.2812,-288 277.1558,-224.8381 335.2804,-185.4263 298.2812,-102 285.3971,-72.9487 273.2111,-69.1623 245.2812,-54 212.9274,-36.4361 171.5265,-27.0749 142.9477,-22.346\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"135.9714,-21.2414 143.378,-19.225 139.4283,-21.7888 142.8853,-22.3362 142.8853,-22.3362 142.8853,-22.3362 139.4283,-21.7888 142.3926,-25.4475 135.9714,-21.2414 135.9714,-21.2414\"/>\n",
"<text text-anchor=\"start\" x=\"309.2812\" y=\"-174.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"310.2812\" y=\"-160.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"326.2812\" y=\"-160.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g id=\"edge6\" class=\"edge\">\n",
"<title>1&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M105.7255,-239.3679C111.862,-253.0084 121.1742,-272.2622 131.2812,-288 134.4526,-292.9381 138.1783,-297.9925 141.8831,-302.6938\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"146.5211,-308.4246 139.6688,-304.965 144.3192,-305.7039 142.1174,-302.9833 142.1174,-302.9833 142.1174,-302.9833 144.3192,-305.7039 144.5659,-301.0016 146.5211,-308.4246 146.5211,-308.4246\"/>\n",
"<text text-anchor=\"start\" x=\"131.2812\" y=\"-276.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"141.7812\" y=\"-261.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g id=\"edge7\" class=\"edge\">\n",
"<title>1&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M123.9724,-227.9702C139.7306,-233.1016 158.6715,-242.2517 168.2812,-258 175.8397,-270.3867 174.0451,-286.5246 170.2609,-299.742\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"168.0006,-306.7422 167.1539,-299.1129 169.0761,-303.4115 170.1515,-300.0808 170.1515,-300.0808 170.1515,-300.0808 169.0761,-303.4115 173.1492,-301.0487 168.0006,-306.7422 168.0006,-306.7422\"/>\n",
"<text text-anchor=\"start\" x=\"173.2812\" y=\"-276.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"174.2812\" y=\"-262.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"190.2812\" y=\"-262.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge8\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M124.6278,-226.6692C134.8144,-226.8767 143.2812,-225.3203 143.2812,-222 143.2812,-219.5098 138.5187,-218.0117 131.8399,-217.5059\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"124.6278,-217.3308 131.7023,-214.3517 128.1268,-217.4158 131.6258,-217.5008 131.6258,-217.5008 131.6258,-217.5008 128.1268,-217.4158 131.5493,-220.6499 124.6278,-217.3308 124.6278,-217.3308\"/>\n",
"<text text-anchor=\"start\" x=\"143.2812\" y=\"-218.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge9\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M123.1487,-229.4501C149.9682,-233.5654 184.2812,-231.082 184.2812,-222 184.2812,-213.6985 155.6123,-210.9102 130.2026,-213.6351\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"123.1487,-214.5499 129.6855,-210.5257 126.6197,-214.0997 130.0906,-213.6496 130.0906,-213.6496 130.0906,-213.6496 126.6197,-214.0997 130.4958,-216.7734 123.1487,-214.5499 123.1487,-214.5499\"/>\n",
"<text text-anchor=\"start\" x=\"184.2812\" y=\"-225.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b &amp; !c</text>\n",
"<text text-anchor=\"start\" x=\"194.7812\" y=\"-210.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;2 -->\n",
"<g id=\"edge10\" class=\"edge\">\n",
"<title>1&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M77.0983,-210.4497C54.2395,-196.6366 19.1207,-171.162 4.2812,-138 -2.254,-123.3955 .2268,-117.4778 4.2812,-102 10.4837,-78.3221 13.2954,-70.6019 31.2812,-54 44.3014,-41.9817 62.0356,-33.365 77.3044,-27.581\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"84.1205,-25.1208 78.6058,-30.4603 80.8284,-26.3091 77.5363,-27.4974 77.5363,-27.4974 77.5363,-27.4974 80.8284,-26.3091 76.4668,-24.5345 84.1205,-25.1208 84.1205,-25.1208\"/>\n",
"<text text-anchor=\"start\" x=\"4.2812\" y=\"-123.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"17.2812\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"33.2812\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 3 -->\n",
"<g id=\"node5\" class=\"node\">\n",
"<title>3</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"98.2812\" cy=\"-120\" rx=\"27\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"88.2812\" y=\"-116.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1,1</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;3 -->\n",
"<g id=\"edge11\" class=\"edge\">\n",
"<title>1&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M98.2812,-203.7644C98.2812,-187.5192 98.2812,-163.5825 98.2812,-145.4527\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"98.2812,-138.0777 101.4313,-145.0776 98.2813,-141.5777 98.2813,-145.0777 98.2813,-145.0777 98.2813,-145.0777 98.2813,-141.5777 95.1313,-145.0777 98.2812,-138.0777 98.2812,-138.0777\"/>\n",
"<text text-anchor=\"start\" x=\"98.2812\" y=\"-174.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; !c</text>\n",
"<text text-anchor=\"start\" x=\"121.2812\" y=\"-159.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;2 -->\n",
"<g id=\"edge12\" class=\"edge\">\n",
"<title>2&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M135.6278,-22.6692C145.8144,-22.8767 154.2812,-21.3203 154.2812,-18 154.2812,-15.5098 149.5187,-14.0117 142.8399,-13.5059\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"135.6278,-13.3308 142.7023,-10.3517 139.1268,-13.4158 142.6258,-13.5008 142.6258,-13.5008 142.6258,-13.5008 139.1268,-13.4158 142.5493,-16.6499 135.6278,-13.3308 135.6278,-13.3308\"/>\n",
"<text text-anchor=\"start\" x=\"154.2812\" y=\"-21.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"177.2812\" y=\"-6.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;2 -->\n",
"<g id=\"edge14\" class=\"edge\">\n",
"<title>2&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M134.3443,-24.9574C167.401,-29.743 216.2812,-27.4238 216.2812,-18 216.2812,-9.2388 174.0331,-6.6183 141.5294,-10.1385\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"134.3443,-11.0426 140.8962,-7.0432 137.8169,-10.6056 141.2895,-10.1686 141.2895,-10.1686 141.2895,-10.1686 137.8169,-10.6056 141.6828,-13.2939 134.3443,-11.0426 134.3443,-11.0426\"/>\n",
"<text text-anchor=\"start\" x=\"223.2812\" y=\"-21.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"216.2812\" y=\"-7.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"232.2812\" y=\"-7.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"248.2812\" y=\"-7.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;3 -->\n",
"<g id=\"edge13\" class=\"edge\">\n",
"<title>2&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M107.3317,-36.0777C105.5851,-52.2729 103.0044,-76.2033 101.0452,-94.3707\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"100.2478,-101.7644 97.8666,-94.467 100.6231,-98.2846 100.9984,-94.8048 100.9984,-94.8048 100.9984,-94.8048 100.6231,-98.2846 104.1303,-95.1426 100.2478,-101.7644 100.2478,-101.7644\"/>\n",
"<text text-anchor=\"start\" x=\"104.2812\" y=\"-65.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; !c</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;2 -->\n",
"<g id=\"edge15\" class=\"edge\">\n",
"<title>3&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M124.5946,-115.0604C141.9558,-110.2881 163.4291,-101.1485 174.2812,-84 181.4112,-72.7332 181.0504,-65.4872 174.2812,-54 166.9753,-41.6021 153.694,-33.1733 141.0323,-27.6086\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"134.5024,-24.9539 142.1734,-24.6722 137.7447,-26.2721 140.987,-27.5902 140.987,-27.5902 140.987,-27.5902 137.7447,-26.2721 139.8006,-30.5083 134.5024,-24.9539 134.5024,-24.9539\"/>\n",
"<text text-anchor=\"start\" x=\"179.2812\" y=\"-72.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"202.2812\" y=\"-57.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;2 -->\n",
"<g id=\"edge17\" class=\"edge\">\n",
"<title>3&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M76.4536,-109.3159C61.7697,-101.6255 44.3717,-91.3533 40.2812,-84 33.7996,-72.3482 33.3695,-65.402 40.2812,-54 48.3469,-40.6943 63.1181,-32.0748 76.9301,-26.6177\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"83.5999,-24.1862 78.1022,-29.5433 80.3116,-25.385 77.0233,-26.5838 77.0233,-26.5838 77.0233,-26.5838 80.3116,-25.385 75.9444,-23.6244 83.5999,-24.1862 83.5999,-24.1862\"/>\n",
"<text text-anchor=\"start\" x=\"40.2812\" y=\"-72.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"45.2812\" y=\"-58.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"61.2812\" y=\"-58.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"77.2812\" y=\"-58.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;3 -->\n",
"<g id=\"edge16\" class=\"edge\">\n",
"<title>3&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M124.6278,-124.6692C134.8144,-124.8767 143.2812,-123.3203 143.2812,-120 143.2812,-117.5098 138.5187,-116.0117 131.8399,-115.5059\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"124.6278,-115.3308 131.7023,-112.3517 128.1268,-115.4158 131.6258,-115.5008 131.6258,-115.5008 131.6258,-115.5008 128.1268,-115.4158 131.5493,-118.6499 124.6278,-115.3308 124.6278,-115.3308\"/>\n",
"<text text-anchor=\"start\" x=\"143.2812\" y=\"-116.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; !c</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;3 -->\n",
"<g id=\"edge18\" class=\"edge\">\n",
"<title>3&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M123.4219,-126.8825C157.5961,-131.7668 209.2812,-129.4727 209.2812,-120 209.2812,-111.1564 164.2326,-108.5695 130.4414,-112.2394\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"123.4219,-113.1175 129.9768,-109.1229 126.8949,-112.683 130.3678,-112.2486 130.3678,-112.2486 130.3678,-112.2486 126.8949,-112.683 130.7588,-115.3742 123.4219,-113.1175 123.4219,-113.1175\"/>\n",
"<text text-anchor=\"start\" x=\"209.2812\" y=\"-123.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; !c</text>\n",
"<text text-anchor=\"start\" x=\"224.2812\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"240.2812\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"</g>\n",
"</svg>\n",
"</div>"
],
"text/plain": [
"<IPython.core.display.HTML object>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"def show_prod(a1, a2, res):\n",
" s1 = a1.num_sets()\n",
" display_inline(a1, a2.show('.tvb+{}'.format(s1)), res)\n",
"\n",
"show_prod(a1, a2, prod)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# Building a product\n",
"\n",
"Let's now rewrite `product()` in Python. We will do that in three steps.\n",
"\n",
"\n",
"## First attempt\n",
"\n",
"First, we build a product without taking care of the acceptance sets. We just want to get the general shape of the algorithm.\n",
"\n",
"We will build an automaton of type `twa_graph`, i.e., an automaton represented explicitely using a graph. In those automata, states are numbered by integers, starting from `0`. (Those states can also be given a different name, which is why the the `product()` shows us something that appears to be labeled by pairs, but the real identifier of each state is an integer.)\n",
"\n",
"We will use a dictionary to keep track of the association between a pair `(ls,rs)` of input states, and its number in the output."
]
},
{
"cell_type": "code",
"execution_count": 4,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"<div style='vertical-align:text-top;display:inline-block;'><?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.40.1 (20161225.0304)\n",
" -->\n",
"<!-- Pages: 1 -->\n",
"<svg width=\"151pt\" height=\"205pt\"\n",
" viewBox=\"0.00 0.00 151.00 205.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 201)\">\n",
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-201 147,-201 147,4 -4,4\"/>\n",
"<text text-anchor=\"start\" x=\"50.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">Inf(</text>\n",
"<text text-anchor=\"start\" x=\"72.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"88.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)</text>\n",
"<text text-anchor=\"start\" x=\"48.5\" y=\"-168.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">[Büchi]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g id=\"node2\" class=\"node\">\n",
"<title>0</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"18\" cy=\"-105\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"18\" y=\"-101.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g id=\"edge1\" class=\"edge\">\n",
"<title>I&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M18,-159.8767C18,-156.822 18,-143.0552 18,-130.0759\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"18,-123.0193 21.1501,-130.0192 18,-126.5193 18.0001,-130.0193 18.0001,-130.0193 18.0001,-130.0193 18,-126.5193 14.8501,-130.0193 18,-123.0193 18,-123.0193\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge2\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.0373,-111.3792C44.8579,-112.6811 54,-110.5547 54,-105 54,-100.834 48.8576,-98.5964 42.1433,-98.2872\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.0373,-98.6208 41.8818,-95.1459 38.5335,-98.4566 42.0296,-98.2924 42.0296,-98.2924 42.0296,-98.2924 38.5335,-98.4566 42.1774,-101.439 35.0373,-98.6208 35.0373,-98.6208\"/>\n",
"<text text-anchor=\"start\" x=\"54\" y=\"-101.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g id=\"node3\" class=\"node\">\n",
"<title>1</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"18\" cy=\"-18\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"13.5\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g id=\"edge3\" class=\"edge\">\n",
"<title>0&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M18,-86.9735C18,-74.2586 18,-57.0603 18,-43.0183\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"18,-36.0034 21.1501,-43.0033 18,-39.5034 18.0001,-43.0034 18.0001,-43.0034 18.0001,-43.0034 18,-39.5034 14.8501,-43.0034 18,-36.0034 18,-36.0034\"/>\n",
"<text text-anchor=\"start\" x=\"18\" y=\"-57.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge4\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.7817,-21.775C45.3149,-22.4165 54,-21.1582 54,-18 54,-15.6807 49.3161,-14.386 43.0521,-14.1159\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.7817,-14.225 42.7337,-10.9702 39.2813,-14.1724 42.7809,-14.1199 42.7809,-14.1199 42.7809,-14.1199 39.2813,-14.1724 42.8282,-17.2695 35.7817,-14.225 35.7817,-14.225\"/>\n",
"<text text-anchor=\"start\" x=\"54\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge5\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.2149,-23.5866C58.4302,-27.9423 91,-26.0801 91,-18 91,-10.709 64.4809,-8.4807 42.2449,-11.3152\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.2149,-12.4134 41.6449,-8.2206 38.673,-11.8731 42.1311,-11.3329 42.1311,-11.3329 42.1311,-11.3329 38.673,-11.8731 42.6173,-14.4452 35.2149,-12.4134 35.2149,-12.4134\"/>\n",
"<text text-anchor=\"start\" x=\"91\" y=\"-21.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"100\" y=\"-6.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"</g>\n",
"</g>\n",
"</svg>\n",
"</div><div style='vertical-align:text-top;display:inline-block;'><svg height=\"220pt\" viewBox=\"0.00 0.00 208.02 220.00\" width=\"208pt\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
"<g class=\"graph\" id=\"graph0\" transform=\"scale(1 1) rotate(0) translate(4 216)\">\n",
"<polygon fill=\"#ffffff\" points=\"-4,4 -4,-216 204.0193,-216 204.0193,4 -4,4\" stroke=\"transparent\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"53.0096\" y=\"-197.8\">Inf(</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"75.0096\" y=\"-197.8\">❶</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"91.0096\" y=\"-197.8\">)&amp;Inf(</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"127.0096\" y=\"-197.8\">❷</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"143.0096\" y=\"-197.8\">)</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"56.0096\" y=\"-183.8\">[gen. Büchi 2]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g class=\"node\" id=\"node2\">\n",
"<title>0</title>\n",
"<ellipse cx=\"68.0193\" cy=\"-120\" fill=\"#ffffaa\" rx=\"18\" ry=\"18\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"middle\" x=\"68.0193\" y=\"-116.3\">0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge1\">\n",
"<title>I-&gt;0</title>\n",
"<path d=\"M68.0193,-174.8767C68.0193,-171.822 68.0193,-158.0552 68.0193,-145.0759\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"68.0193,-138.0193 71.1694,-145.0192 68.0193,-141.5193 68.0194,-145.0193 68.0194,-145.0193 68.0194,-145.0193 68.0193,-141.5193 64.8694,-145.0193 68.0193,-138.0193 68.0193,-138.0193\" stroke=\"#000000\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge2\">\n",
"<title>0-&gt;0</title>\n",
"<path d=\"M85.801,-123.2357C95.3342,-123.7856 104.0193,-122.707 104.0193,-120 104.0193,-118.012 99.3354,-116.9023 93.0714,-116.6708\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.801,-116.7643 92.7599,-113.5244 89.3007,-116.7192 92.8004,-116.6742 92.8004,-116.6742 92.8004,-116.6742 89.3007,-116.7192 92.841,-119.8239 85.801,-116.7643 85.801,-116.7643\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"104.0193\" y=\"-123.8\">!b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"114.5193\" y=\"-108.8\">❶</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge3\">\n",
"<title>0-&gt;0</title>\n",
"<path d=\"M85.5885,-124.845C108.7793,-128.5056 141.0193,-126.8906 141.0193,-120 141.0193,-113.7823 114.7687,-111.8601 92.6031,-114.2335\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.5885,-115.155 92.1185,-111.12 89.0587,-114.6991 92.5288,-114.2432 92.5288,-114.2432 92.5288,-114.2432 89.0587,-114.6991 92.9392,-117.3663 85.5885,-115.155 85.5885,-115.155\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"152.5193\" y=\"-123.8\">b</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"141.0193\" y=\"-109.8\">❶</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"157.0193\" y=\"-109.8\">❷</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g class=\"node\" id=\"node3\">\n",
"<title>1</title>\n",
"<ellipse cx=\"68.0193\" cy=\"-18\" fill=\"#ffffaa\" rx=\"18\" ry=\"18\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"middle\" x=\"68.0193\" y=\"-14.3\">1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge4\">\n",
"<title>0-&gt;1</title>\n",
"<path d=\"M50.3286,-115.3021C35.307,-110.2732 14.6933,-100.6701 5.0193,-84 -1.6731,-72.4679 -1.6731,-65.5321 5.0193,-54 13.3329,-39.6741 29.7258,-30.5674 43.7056,-25.0978\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"50.3286,-22.6979 44.8205,-28.0443 47.0379,-23.8903 43.7473,-25.0827 43.7473,-25.0827 43.7473,-25.0827 47.0379,-23.8903 42.6741,-22.1211 50.3286,-22.6979 50.3286,-22.6979\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"5.0193\" y=\"-65.3\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge5\">\n",
"<title>1-&gt;0</title>\n",
"<path d=\"M68.0193,-36.0777C68.0193,-52.2729 68.0193,-76.2033 68.0193,-94.3707\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"68.0193,-101.7644 64.8694,-94.7644 68.0193,-98.2644 68.0194,-94.7644 68.0194,-94.7644 68.0194,-94.7644 68.0193,-98.2644 71.1694,-94.7645 68.0193,-101.7644 68.0193,-101.7644\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"68.0193\" y=\"-72.8\">!b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"78.5193\" y=\"-57.8\">❶</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge6\">\n",
"<title>1-&gt;0</title>\n",
"<path d=\"M83.5721,-27.9858C91.923,-34.3143 101.423,-43.3143 106.0193,-54 111.2877,-66.2483 111.2877,-71.7517 106.0193,-84 102.4285,-92.3482 95.8446,-99.6675 89.154,-105.4879\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"83.5721,-110.0142 87.0252,-103.1586 86.2906,-107.8098 89.0092,-105.6053 89.0092,-105.6053 89.0092,-105.6053 86.2906,-107.8098 90.9932,-108.052 83.5721,-110.0142 83.5721,-110.0142\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"109.0193\" y=\"-72.8\">b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"110.0193\" y=\"-58.8\">❶</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"126.0193\" y=\"-58.8\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge7\">\n",
"<title>1-&gt;1</title>\n",
"<path d=\"M85.801,-22.4941C95.3342,-23.2578 104.0193,-21.7598 104.0193,-18 104.0193,-15.2389 99.3354,-13.6976 93.0714,-13.3761\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.801,-13.5059 92.7436,-10.2313 89.3004,-13.4434 92.7999,-13.3808 92.7999,-13.3808 92.7999,-13.3808 89.3004,-13.4434 92.8562,-16.5303 85.801,-13.5059 85.801,-13.5059\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"104.0193\" y=\"-14.3\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge8\">\n",
"<title>1-&gt;1</title>\n",
"<path d=\"M85.0367,-24.4905C109.3677,-29.8803 145.0193,-27.7168 145.0193,-18 145.0193,-9.1942 115.7391,-6.5917 92.1396,-10.1928\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.0367,-11.5095 91.3452,-7.1363 88.4781,-10.8715 91.9194,-10.2335 91.9194,-10.2335 91.9194,-10.2335 88.4781,-10.8715 92.4936,-13.3307 85.0367,-11.5095 85.0367,-11.5095\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"145.0193\" y=\"-21.8\">b &amp; !c</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"155.5193\" y=\"-6.8\">❷</text>\n",
"</g>\n",
"</g>\n",
"</svg></div><div style='vertical-align:text-top;display:inline-block;'><?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.40.1 (20161225.0304)\n",
" -->\n",
"<!-- Pages: 1 -->\n",
"<svg width=\"308pt\" height=\"360pt\"\n",
" viewBox=\"0.00 0.00 307.76 360.00\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
"<g id=\"graph0\" class=\"graph\" transform=\"scale(.9449 .9449) rotate(0) translate(4 377)\">\n",
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-377 321.7138,-377 321.7138,4 -4,4\"/>\n",
"<text text-anchor=\"start\" x=\"155.8569\" y=\"-357.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">t</text>\n",
"<text text-anchor=\"start\" x=\"147.8569\" y=\"-342.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">[all]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g id=\"node2\" class=\"node\">\n",
"<title>0</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"151.7138\" cy=\"-279\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"151.7138\" y=\"-275.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g id=\"edge1\" class=\"edge\">\n",
"<title>I&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M151.7138,-333.8767C151.7138,-330.822 151.7138,-317.0552 151.7138,-304.0759\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"151.7138,-297.0193 154.8639,-304.0192 151.7139,-300.5193 151.7139,-304.0193 151.7139,-304.0193 151.7139,-304.0193 151.7139,-300.5193 148.5639,-304.0193 151.7138,-297.0193 151.7138,-297.0193\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge2\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M169.4956,-282.2357C179.0288,-282.7856 187.7138,-281.707 187.7138,-279 187.7138,-277.012 183.0299,-275.9023 176.766,-275.6708\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"169.4956,-275.7643 176.4545,-272.5244 172.9953,-275.7192 176.495,-275.6742 176.495,-275.6742 176.495,-275.6742 172.9953,-275.7192 176.5355,-278.8239 169.4956,-275.7643 169.4956,-275.7643\"/>\n",
"<text text-anchor=\"start\" x=\"187.7138\" y=\"-275.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; c</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge3\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M169.283,-283.845C192.4739,-287.5056 224.7138,-285.8906 224.7138,-279 224.7138,-272.7823 198.4633,-270.8601 176.2977,-273.2335\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"169.283,-274.155 175.8131,-270.12 172.7532,-273.6991 176.2234,-273.2432 176.2234,-273.2432 176.2234,-273.2432 172.7532,-273.6991 176.6337,-276.3663 169.283,-274.155 169.283,-274.155\"/>\n",
"<text text-anchor=\"start\" x=\"224.7138\" y=\"-275.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g id=\"node3\" class=\"node\">\n",
"<title>1</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"89.7138\" cy=\"-192\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"89.7138\" y=\"-188.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g id=\"edge4\" class=\"edge\">\n",
"<title>0&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M133.9114,-274.6578C109.4511,-268.2901 67.4726,-255.7825 58.7138,-243 50.9334,-231.6452 59.5755,-218.3417 69.6912,-208.1695\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"75.0362,-203.1624 72.0811,-210.247 72.4819,-205.5552 69.9276,-207.9481 69.9276,-207.9481 69.9276,-207.9481 72.4819,-205.5552 67.7741,-205.6492 75.0362,-203.1624 75.0362,-203.1624\"/>\n",
"<text text-anchor=\"start\" x=\"58.7138\" y=\"-231.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 2 -->\n",
"<g id=\"node4\" class=\"node\">\n",
"<title>2</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"109.7138\" cy=\"-18\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"109.7138\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">2</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;2 -->\n",
"<g id=\"edge5\" class=\"edge\">\n",
"<title>0&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M167.1696,-269.4005C208.7264,-242.3058 317.3153,-162.3063 280.7138,-87 270.3365,-65.649 259.8892,-64.7313 238.7138,-54 204.7792,-36.8026 161.527,-26.8824 134.7294,-21.9622\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"127.6289,-20.7051 135.0709,-18.8237 131.0753,-21.3153 134.5217,-21.9255 134.5217,-21.9255 134.5217,-21.9255 131.0753,-21.3153 133.9725,-25.0272 127.6289,-20.7051 127.6289,-20.7051\"/>\n",
"<text text-anchor=\"start\" x=\"283.7138\" y=\"-144.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g id=\"edge6\" class=\"edge\">\n",
"<title>1&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M99.128,-207.452C105.5198,-217.7116 114.3079,-231.3788 122.7138,-243 126.7208,-248.5396 131.2722,-254.3788 135.5621,-259.7047\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"140.0762,-265.2441 133.2122,-261.8076 137.8652,-262.5309 135.6541,-259.8177 135.6541,-259.8177 135.6541,-259.8177 137.8652,-262.5309 138.096,-257.8278 140.0762,-265.2441 140.0762,-265.2441\"/>\n",
"<text text-anchor=\"start\" x=\"122.7138\" y=\"-231.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g id=\"edge7\" class=\"edge\">\n",
"<title>1&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M107.3728,-195.6C124.1338,-200.0568 148.3957,-209.452 159.7138,-228 164.7733,-236.2913 164.1152,-246.7026 161.6739,-255.9529\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"159.5245,-262.7461 158.633,-255.1219 160.5804,-259.4092 161.6362,-256.0722 161.6362,-256.0722 161.6362,-256.0722 160.5804,-259.4092 164.6395,-257.0225 159.5245,-262.7461 159.5245,-262.7461\"/>\n",
"<text text-anchor=\"start\" x=\"162.7138\" y=\"-231.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b &amp; c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge8\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M107.4956,-195.775C117.0288,-196.4165 125.7138,-195.1582 125.7138,-192 125.7138,-189.6807 121.0299,-188.386 114.766,-188.1159\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"107.4956,-188.225 114.4475,-184.9702 110.9952,-188.1724 114.4948,-188.1199 114.4948,-188.1199 114.4948,-188.1199 110.9952,-188.1724 114.5421,-191.2695 107.4956,-188.225 107.4956,-188.225\"/>\n",
"<text text-anchor=\"start\" x=\"125.7138\" y=\"-188.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge9\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M107.0989,-197.5198C131.4197,-201.961 166.7138,-200.1211 166.7138,-192 166.7138,-184.6403 137.7272,-182.4392 114.1904,-185.3967\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"107.0989,-186.4802 113.5428,-182.309 110.5588,-185.9515 114.0186,-185.4229 114.0186,-185.4229 114.0186,-185.4229 110.5588,-185.9515 114.4944,-188.5367 107.0989,-186.4802 107.0989,-186.4802\"/>\n",
"<text text-anchor=\"start\" x=\"166.7138\" y=\"-188.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;2 -->\n",
"<g id=\"edge10\" class=\"edge\">\n",
"<title>1&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M73.1612,-184.3058C52.6995,-173.7614 18.8523,-152.6874 4.7138,-123 -2.1657,-108.5545 -.3824,-102.1667 4.7138,-87 16.3854,-52.2654 57.9525,-33.4051 85.1542,-24.5424\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"92.0708,-22.4018 86.3151,-27.4806 88.7273,-23.4366 85.3838,-24.4714 85.3838,-24.4714 85.3838,-24.4714 88.7273,-23.4366 84.4524,-21.4622 92.0708,-22.4018 92.0708,-22.4018\"/>\n",
"<text text-anchor=\"start\" x=\"4.7138\" y=\"-101.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; c</text>\n",
"</g>\n",
"<!-- 3 -->\n",
"<g id=\"node5\" class=\"node\">\n",
"<title>3</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"89.7138\" cy=\"-105\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"89.7138\" y=\"-101.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">3</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;3 -->\n",
"<g id=\"edge11\" class=\"edge\">\n",
"<title>1&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M89.7138,-173.9735C89.7138,-161.2586 89.7138,-144.0603 89.7138,-130.0183\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"89.7138,-123.0034 92.8639,-130.0033 89.7139,-126.5034 89.7139,-130.0034 89.7139,-130.0034 89.7139,-130.0034 89.7139,-126.5034 86.5639,-130.0034 89.7138,-123.0034 89.7138,-123.0034\"/>\n",
"<text text-anchor=\"start\" x=\"89.7138\" y=\"-144.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; !c</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;2 -->\n",
"<g id=\"edge12\" class=\"edge\">\n",
"<title>2&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M127.4956,-21.775C137.0288,-22.4165 145.7138,-21.1582 145.7138,-18 145.7138,-15.6807 141.0299,-14.386 134.766,-14.1159\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"127.4956,-14.225 134.4475,-10.9702 130.9952,-14.1724 134.4948,-14.1199 134.4948,-14.1199 134.4948,-14.1199 130.9952,-14.1724 134.5421,-17.2695 127.4956,-14.225 127.4956,-14.225\"/>\n",
"<text text-anchor=\"start\" x=\"145.7138\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; c</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;2 -->\n",
"<g id=\"edge14\" class=\"edge\">\n",
"<title>2&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M127.1668,-23.0988C156.9131,-28.0668 207.7138,-26.3672 207.7138,-18 207.7138,-10.2538 164.174,-8.2222 134.1086,-11.9053\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"127.1668,-12.9012 133.6485,-8.7889 130.6313,-12.4041 134.0959,-11.907 134.0959,-11.907 134.0959,-11.907 130.6313,-12.4041 134.5433,-15.0251 127.1668,-12.9012 127.1668,-12.9012\"/>\n",
"<text text-anchor=\"start\" x=\"207.7138\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;3 -->\n",
"<g id=\"edge13\" class=\"edge\">\n",
"<title>2&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M105.6726,-35.5796C102.7192,-48.4267 98.6744,-66.0218 95.3959,-80.2832\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"93.7611,-87.3943 92.2596,-79.8664 94.5453,-83.9832 95.3295,-80.5722 95.3295,-80.5722 95.3295,-80.5722 94.5453,-83.9832 98.3994,-81.278 93.7611,-87.3943 93.7611,-87.3943\"/>\n",
"<text text-anchor=\"start\" x=\"100.7138\" y=\"-57.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; !c</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;2 -->\n",
"<g id=\"edge15\" class=\"edge\">\n",
"<title>3&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M107.8975,-102.658C127.2281,-99.0915 156.8776,-90.2906 170.7138,-69 182.8477,-50.3288 155.4692,-34.938 133.556,-26.107\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"126.9806,-23.5806 134.6447,-23.1509 130.2478,-24.836 133.5149,-26.0913 133.5149,-26.0913 133.5149,-26.0913 130.2478,-24.836 132.3851,-29.0317 126.9806,-23.5806 126.9806,-23.5806\"/>\n",
"<text text-anchor=\"start\" x=\"172.7138\" y=\"-57.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; c</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;2 -->\n",
"<g id=\"edge17\" class=\"edge\">\n",
"<title>3&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M74.0896,-95.6306C58.9195,-86.3709 37.8671,-73.0233 35.7138,-69 32.5681,-63.1222 32.1782,-59.6519 35.7138,-54 46.3879,-36.9371 67.7231,-27.7518 84.7536,-22.9411\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"91.7452,-21.137 85.7543,-25.9361 88.3562,-22.0115 84.9672,-22.8861 84.9672,-22.8861 84.9672,-22.8861 88.3562,-22.0115 84.1801,-19.836 91.7452,-21.137 91.7452,-21.137\"/>\n",
"<text text-anchor=\"start\" x=\"35.7138\" y=\"-57.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; c</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;3 -->\n",
"<g id=\"edge16\" class=\"edge\">\n",
"<title>3&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M107.4956,-108.775C117.0288,-109.4165 125.7138,-108.1582 125.7138,-105 125.7138,-102.6807 121.0299,-101.386 114.766,-101.1159\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"107.4956,-101.225 114.4475,-97.9702 110.9952,-101.1724 114.4948,-101.1199 114.4948,-101.1199 114.4948,-101.1199 110.9952,-101.1724 114.5421,-104.2695 107.4956,-101.225 107.4956,-101.225\"/>\n",
"<text text-anchor=\"start\" x=\"125.7138\" y=\"-101.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; !c</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;3 -->\n",
"<g id=\"edge18\" class=\"edge\">\n",
"<title>3&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M107.1439,-110.0252C137.8488,-115.0833 191.7138,-113.4082 191.7138,-105 191.7138,-97.2158 145.5477,-95.2025 114.3318,-98.9598\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"107.1439,-99.9748 113.6347,-95.8769 110.6095,-99.4854 114.0752,-98.996 114.0752,-98.996 114.0752,-98.996 110.6095,-99.4854 114.5156,-102.1151 107.1439,-99.9748 107.1439,-99.9748\"/>\n",
"<text text-anchor=\"start\" x=\"191.7138\" y=\"-101.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; !c</text>\n",
"</g>\n",
"</g>\n",
"</svg>\n",
"</div>"
],
"text/plain": [
"<IPython.core.display.HTML object>"
]
},
"metadata": {},
"output_type": "display_data"
}
],
"source": [
"def product1(left, right):\n",
" # A bdd_dict object associates BDD variables (that are \n",
" # used in BDDs labeleing the edges) to atomic propositions.\n",
" bdict = left.get_dict()\n",
" # If the two automata do not have the same BDD dict, then\n",
" # we cannot easily detect compatible transitions.\n",
" if right.get_dict() != bdict:\n",
" raise RuntimeError(\"automata should share their dictionary\")\n",
" \n",
" result = spot.make_twa_graph(bdict)\n",
" # This will be our state dictionary\n",
" sdict = {}\n",
" # The list of output states for which we have not yet\n",
" # computed the successors. Items on this list are triplets\n",
" # of the form (ls, rs, p) where ls,rs are the state number in\n",
" # the left and right automata, and p is the state number if\n",
" # the output automaton.\n",
" todo = []\n",
" # Transform a pair of state number (ls, rs) into a state number in\n",
" # the output automaton, creating a new state if needed. Whenever\n",
" # a new state is created, we can add it to todo.\n",
" def dst(ls, rs):\n",
" pair = (ls, rs)\n",
" p = sdict.get(pair)\n",
" if p is None:\n",
" p = result.new_state()\n",
" sdict[pair] = p\n",
" todo.append((ls, rs, p))\n",
" return p\n",
" \n",
" # Setup the initial state. It always exists.\n",
" result.set_init_state(dst(left.get_init_state_number(), \n",
" right.get_init_state_number()))\n",
"\n",
" # Build all states and edges in the product\n",
" while todo:\n",
" lsrc, rsrc, osrc = todo.pop()\n",
" for lt in left.out(lsrc):\n",
" for rt in right.out(rsrc):\n",
" cond = lt.cond & rt.cond\n",
" if cond != buddy.bddfalse:\n",
" result.new_edge(osrc, dst(lt.dst, rt.dst), cond)\n",
" return result\n",
"\n",
"p1 = product1(a1, a2)\n",
"show_prod(a1, a2, p1)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Besides the obvious lack of acceptance condition (which defaults to `t`) and acceptance sets, there is a less obvious problem: we never declared the set of atomic propositions used by the result automaton. This as two consequences:\n",
"- calling `p1.ap()` will return an empty set of atomic propositions"
]
},
{
"cell_type": "code",
"execution_count": 5,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"(spot.formula(\"a\"), spot.formula(\"b\"))\n",
"(spot.formula(\"c\"), spot.formula(\"b\"))\n",
"()\n"
]
}
],
"source": [
"print(a1.ap())\n",
"print(a2.ap())\n",
"print(p1.ap())"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"- the `bdd_dict` instance that is shared by the three automata knows that the atomic propositions `a` and `b` are used by automata `a1` and that `b` and `c` are used by `a2`. But it is unaware of `p1`. That means that if we delete automata `a1` and `a2`, then the `bdd_dict` will release the associated BDD variables, and attempting to print automaton `p1` will either crash (because it uses bdd variables that are not associated to any atomic proposition) or display different atomic propositions (in case the BDD variables have been associated to different propositions in the meantime).\n",
"\n",
"These two issues are fixed by either calling `p1.register_ap(...)` for each atomic proposition, or in our case `p1.copy_ap_of(...)` to copy the atomic propositions of each input automaton. "
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Second attempt: a working product\n",
"\n",
"This fixes the list of atomtic propositions, as discussed above, and also sets the correct acceptance condition.\n",
"The `set_acceptance` method takes two arguments: a number of sets, and an acceptance function. In our case, both of these arguments are readily computed from the number of states and acceptance functions of the input automata."
]
},
{
"cell_type": "code",
"execution_count": 6,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"<div style='vertical-align:text-top;display:inline-block;'><?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.40.1 (20161225.0304)\n",
" -->\n",
"<!-- Pages: 1 -->\n",
"<svg width=\"151pt\" height=\"205pt\"\n",
" viewBox=\"0.00 0.00 151.00 205.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 201)\">\n",
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-201 147,-201 147,4 -4,4\"/>\n",
"<text text-anchor=\"start\" x=\"50.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">Inf(</text>\n",
"<text text-anchor=\"start\" x=\"72.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"88.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)</text>\n",
"<text text-anchor=\"start\" x=\"48.5\" y=\"-168.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">[Büchi]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g id=\"node2\" class=\"node\">\n",
"<title>0</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"18\" cy=\"-105\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"18\" y=\"-101.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g id=\"edge1\" class=\"edge\">\n",
"<title>I&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M18,-159.8767C18,-156.822 18,-143.0552 18,-130.0759\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"18,-123.0193 21.1501,-130.0192 18,-126.5193 18.0001,-130.0193 18.0001,-130.0193 18.0001,-130.0193 18,-126.5193 14.8501,-130.0193 18,-123.0193 18,-123.0193\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge2\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.0373,-111.3792C44.8579,-112.6811 54,-110.5547 54,-105 54,-100.834 48.8576,-98.5964 42.1433,-98.2872\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.0373,-98.6208 41.8818,-95.1459 38.5335,-98.4566 42.0296,-98.2924 42.0296,-98.2924 42.0296,-98.2924 38.5335,-98.4566 42.1774,-101.439 35.0373,-98.6208 35.0373,-98.6208\"/>\n",
"<text text-anchor=\"start\" x=\"54\" y=\"-101.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g id=\"node3\" class=\"node\">\n",
"<title>1</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"18\" cy=\"-18\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"13.5\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g id=\"edge3\" class=\"edge\">\n",
"<title>0&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M18,-86.9735C18,-74.2586 18,-57.0603 18,-43.0183\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"18,-36.0034 21.1501,-43.0033 18,-39.5034 18.0001,-43.0034 18.0001,-43.0034 18.0001,-43.0034 18,-39.5034 14.8501,-43.0034 18,-36.0034 18,-36.0034\"/>\n",
"<text text-anchor=\"start\" x=\"18\" y=\"-57.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge4\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.7817,-21.775C45.3149,-22.4165 54,-21.1582 54,-18 54,-15.6807 49.3161,-14.386 43.0521,-14.1159\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.7817,-14.225 42.7337,-10.9702 39.2813,-14.1724 42.7809,-14.1199 42.7809,-14.1199 42.7809,-14.1199 39.2813,-14.1724 42.8282,-17.2695 35.7817,-14.225 35.7817,-14.225\"/>\n",
"<text text-anchor=\"start\" x=\"54\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge5\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.2149,-23.5866C58.4302,-27.9423 91,-26.0801 91,-18 91,-10.709 64.4809,-8.4807 42.2449,-11.3152\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.2149,-12.4134 41.6449,-8.2206 38.673,-11.8731 42.1311,-11.3329 42.1311,-11.3329 42.1311,-11.3329 38.673,-11.8731 42.6173,-14.4452 35.2149,-12.4134 35.2149,-12.4134\"/>\n",
"<text text-anchor=\"start\" x=\"91\" y=\"-21.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"100\" y=\"-6.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"</g>\n",
"</g>\n",
"</svg>\n",
"</div><div style='vertical-align:text-top;display:inline-block;'><svg height=\"220pt\" viewBox=\"0.00 0.00 208.02 220.00\" width=\"208pt\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
"<g class=\"graph\" id=\"graph0\" transform=\"scale(1 1) rotate(0) translate(4 216)\">\n",
"<polygon fill=\"#ffffff\" points=\"-4,4 -4,-216 204.0193,-216 204.0193,4 -4,4\" stroke=\"transparent\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"53.0096\" y=\"-197.8\">Inf(</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"75.0096\" y=\"-197.8\">❶</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"91.0096\" y=\"-197.8\">)&amp;Inf(</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"127.0096\" y=\"-197.8\">❷</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"143.0096\" y=\"-197.8\">)</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"56.0096\" y=\"-183.8\">[gen. Büchi 2]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g class=\"node\" id=\"node2\">\n",
"<title>0</title>\n",
"<ellipse cx=\"68.0193\" cy=\"-120\" fill=\"#ffffaa\" rx=\"18\" ry=\"18\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"middle\" x=\"68.0193\" y=\"-116.3\">0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge1\">\n",
"<title>I-&gt;0</title>\n",
"<path d=\"M68.0193,-174.8767C68.0193,-171.822 68.0193,-158.0552 68.0193,-145.0759\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"68.0193,-138.0193 71.1694,-145.0192 68.0193,-141.5193 68.0194,-145.0193 68.0194,-145.0193 68.0194,-145.0193 68.0193,-141.5193 64.8694,-145.0193 68.0193,-138.0193 68.0193,-138.0193\" stroke=\"#000000\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge2\">\n",
"<title>0-&gt;0</title>\n",
"<path d=\"M85.801,-123.2357C95.3342,-123.7856 104.0193,-122.707 104.0193,-120 104.0193,-118.012 99.3354,-116.9023 93.0714,-116.6708\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.801,-116.7643 92.7599,-113.5244 89.3007,-116.7192 92.8004,-116.6742 92.8004,-116.6742 92.8004,-116.6742 89.3007,-116.7192 92.841,-119.8239 85.801,-116.7643 85.801,-116.7643\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"104.0193\" y=\"-123.8\">!b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"114.5193\" y=\"-108.8\">❶</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge3\">\n",
"<title>0-&gt;0</title>\n",
"<path d=\"M85.5885,-124.845C108.7793,-128.5056 141.0193,-126.8906 141.0193,-120 141.0193,-113.7823 114.7687,-111.8601 92.6031,-114.2335\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.5885,-115.155 92.1185,-111.12 89.0587,-114.6991 92.5288,-114.2432 92.5288,-114.2432 92.5288,-114.2432 89.0587,-114.6991 92.9392,-117.3663 85.5885,-115.155 85.5885,-115.155\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"152.5193\" y=\"-123.8\">b</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"141.0193\" y=\"-109.8\">❶</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"157.0193\" y=\"-109.8\">❷</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g class=\"node\" id=\"node3\">\n",
"<title>1</title>\n",
"<ellipse cx=\"68.0193\" cy=\"-18\" fill=\"#ffffaa\" rx=\"18\" ry=\"18\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"middle\" x=\"68.0193\" y=\"-14.3\">1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge4\">\n",
"<title>0-&gt;1</title>\n",
"<path d=\"M50.3286,-115.3021C35.307,-110.2732 14.6933,-100.6701 5.0193,-84 -1.6731,-72.4679 -1.6731,-65.5321 5.0193,-54 13.3329,-39.6741 29.7258,-30.5674 43.7056,-25.0978\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"50.3286,-22.6979 44.8205,-28.0443 47.0379,-23.8903 43.7473,-25.0827 43.7473,-25.0827 43.7473,-25.0827 47.0379,-23.8903 42.6741,-22.1211 50.3286,-22.6979 50.3286,-22.6979\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"5.0193\" y=\"-65.3\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge5\">\n",
"<title>1-&gt;0</title>\n",
"<path d=\"M68.0193,-36.0777C68.0193,-52.2729 68.0193,-76.2033 68.0193,-94.3707\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"68.0193,-101.7644 64.8694,-94.7644 68.0193,-98.2644 68.0194,-94.7644 68.0194,-94.7644 68.0194,-94.7644 68.0193,-98.2644 71.1694,-94.7645 68.0193,-101.7644 68.0193,-101.7644\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"68.0193\" y=\"-72.8\">!b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"78.5193\" y=\"-57.8\">❶</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge6\">\n",
"<title>1-&gt;0</title>\n",
"<path d=\"M83.5721,-27.9858C91.923,-34.3143 101.423,-43.3143 106.0193,-54 111.2877,-66.2483 111.2877,-71.7517 106.0193,-84 102.4285,-92.3482 95.8446,-99.6675 89.154,-105.4879\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"83.5721,-110.0142 87.0252,-103.1586 86.2906,-107.8098 89.0092,-105.6053 89.0092,-105.6053 89.0092,-105.6053 86.2906,-107.8098 90.9932,-108.052 83.5721,-110.0142 83.5721,-110.0142\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"109.0193\" y=\"-72.8\">b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"110.0193\" y=\"-58.8\">❶</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"126.0193\" y=\"-58.8\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge7\">\n",
"<title>1-&gt;1</title>\n",
"<path d=\"M85.801,-22.4941C95.3342,-23.2578 104.0193,-21.7598 104.0193,-18 104.0193,-15.2389 99.3354,-13.6976 93.0714,-13.3761\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.801,-13.5059 92.7436,-10.2313 89.3004,-13.4434 92.7999,-13.3808 92.7999,-13.3808 92.7999,-13.3808 89.3004,-13.4434 92.8562,-16.5303 85.801,-13.5059 85.801,-13.5059\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"104.0193\" y=\"-14.3\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge8\">\n",
"<title>1-&gt;1</title>\n",
"<path d=\"M85.0367,-24.4905C109.3677,-29.8803 145.0193,-27.7168 145.0193,-18 145.0193,-9.1942 115.7391,-6.5917 92.1396,-10.1928\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.0367,-11.5095 91.3452,-7.1363 88.4781,-10.8715 91.9194,-10.2335 91.9194,-10.2335 91.9194,-10.2335 88.4781,-10.8715 92.4936,-13.3307 85.0367,-11.5095 85.0367,-11.5095\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"145.0193\" y=\"-21.8\">b &amp; !c</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"155.5193\" y=\"-6.8\">❷</text>\n",
"</g>\n",
"</g>\n",
"</svg></div><div style='vertical-align:text-top;display:inline-block;'><?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.40.1 (20161225.0304)\n",
" -->\n",
"<!-- Pages: 1 -->\n",
"<svg width=\"280pt\" height=\"360pt\"\n",
" viewBox=\"0.00 0.00 280.11 360.00\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
"<g id=\"graph0\" class=\"graph\" transform=\"scale(.8491 .8491) rotate(0) translate(4 420)\">\n",
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-420 325.9023,-420 325.9023,4 -4,4\"/>\n",
"<text text-anchor=\"start\" x=\"87.9512\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">Inf(</text>\n",
"<text text-anchor=\"start\" x=\"109.9512\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"125.9512\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)&amp;Inf(</text>\n",
"<text text-anchor=\"start\" x=\"161.9512\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"177.9512\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)&amp;Inf(</text>\n",
"<text text-anchor=\"start\" x=\"213.9512\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"<text text-anchor=\"start\" x=\"229.9512\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)</text>\n",
"<text text-anchor=\"start\" x=\"116.9512\" y=\"-387.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">[gen. Büchi 3]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g id=\"node2\" class=\"node\">\n",
"<title>0</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"150.9023\" cy=\"-324\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"150.9023\" y=\"-320.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g id=\"edge1\" class=\"edge\">\n",
"<title>I&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M150.9023,-378.8767C150.9023,-375.822 150.9023,-362.0552 150.9023,-349.0759\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"150.9023,-342.0193 154.0524,-349.0192 150.9024,-345.5193 150.9024,-349.0193 150.9024,-349.0193 150.9024,-349.0193 150.9024,-345.5193 147.7524,-349.0193 150.9023,-342.0193 150.9023,-342.0193\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge2\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M168.684,-327.2357C178.2173,-327.7856 186.9023,-326.707 186.9023,-324 186.9023,-322.012 182.2184,-320.9023 175.9544,-320.6708\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"168.684,-320.7643 175.6429,-317.5244 172.1838,-320.7192 175.6835,-320.6742 175.6835,-320.6742 175.6835,-320.6742 172.1838,-320.7192 175.724,-323.8239 168.684,-320.7643 168.684,-320.7643\"/>\n",
"<text text-anchor=\"start\" x=\"186.9023\" y=\"-327.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"197.4023\" y=\"-312.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge3\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M168.4715,-328.845C191.6623,-332.5056 223.9023,-330.8906 223.9023,-324 223.9023,-317.7823 197.6517,-315.8601 175.4861,-318.2335\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"168.4715,-319.155 175.0015,-315.12 171.9417,-318.6991 175.4119,-318.2432 175.4119,-318.2432 175.4119,-318.2432 171.9417,-318.6991 175.8222,-321.3663 168.4715,-319.155 168.4715,-319.155\"/>\n",
"<text text-anchor=\"start\" x=\"235.4023\" y=\"-327.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b</text>\n",
"<text text-anchor=\"start\" x=\"223.9023\" y=\"-313.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"239.9023\" y=\"-313.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g id=\"node3\" class=\"node\">\n",
"<title>1</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"88.9023\" cy=\"-222\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"88.9023\" y=\"-218.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g id=\"edge4\" class=\"edge\">\n",
"<title>0&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M133.0999,-319.6578C108.6396,-313.2901 66.661,-300.7825 57.9023,-288 50.3657,-277.001 53.2621,-270.4998 57.9023,-258 60.4857,-251.0409 65.0841,-244.5255 69.9614,-239.0019\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"74.8675,-233.8292 72.3359,-241.0758 72.4589,-236.3686 70.0503,-238.9081 70.0503,-238.9081 70.0503,-238.9081 72.4589,-236.3686 67.7648,-236.7404 74.8675,-233.8292 74.8675,-233.8292\"/>\n",
"<text text-anchor=\"start\" x=\"57.9023\" y=\"-269.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 2 -->\n",
"<g id=\"node4\" class=\"node\">\n",
"<title>2</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"108.9023\" cy=\"-18\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"108.9023\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">2</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;2 -->\n",
"<g id=\"edge5\" class=\"edge\">\n",
"<title>0&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M166.9774,-315.1313C177.764,-308.6234 191.7943,-299.0235 201.9023,-288 262.4855,-221.9301 309.3583,-186.6634 279.9023,-102 270.9614,-76.3016 264.6208,-68.9739 241.9023,-54 208.7166,-32.1271 162.5827,-23.4819 134.2875,-20.1078\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"127.1513,-19.3238 134.4535,-16.9571 130.6304,-19.7061 134.1095,-20.0883 134.1095,-20.0883 134.1095,-20.0883 130.6304,-19.7061 133.7655,-23.2195 127.1513,-19.3238 127.1513,-19.3238\"/>\n",
"<text text-anchor=\"start\" x=\"287.9023\" y=\"-174.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"288.9023\" y=\"-160.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"304.9023\" y=\"-160.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g id=\"edge6\" class=\"edge\">\n",
"<title>1&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M96.0961,-238.8105C102.2281,-252.4802 111.6568,-272.0466 121.9023,-288 125.5968,-293.7527 130.0437,-299.6631 134.3332,-304.9894\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"138.8829,-310.5045 131.9984,-307.1093 136.6556,-307.8046 134.4283,-305.1047 134.4283,-305.1047 134.4283,-305.1047 136.6556,-307.8046 136.8582,-303.1002 138.8829,-310.5045 138.8829,-310.5045\"/>\n",
"<text text-anchor=\"start\" x=\"121.9023\" y=\"-276.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"132.4023\" y=\"-261.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g id=\"edge7\" class=\"edge\">\n",
"<title>1&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M106.5612,-225.6C123.3222,-230.0568 147.5841,-239.452 158.9023,-258 166.6844,-270.7531 164.5518,-287.4826 160.5411,-300.9071\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"158.3152,-307.5874 157.5396,-299.9506 159.4216,-304.2669 160.5281,-300.9464 160.5281,-300.9464 160.5281,-300.9464 159.4216,-304.2669 163.5165,-301.9422 158.3152,-307.5874 158.3152,-307.5874\"/>\n",
"<text text-anchor=\"start\" x=\"163.9023\" y=\"-276.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"164.9023\" y=\"-262.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"180.9023\" y=\"-262.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge8\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M106.684,-226.4941C116.2173,-227.2578 124.9023,-225.7598 124.9023,-222 124.9023,-219.2389 120.2184,-217.6976 113.9544,-217.3761\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"106.684,-217.5059 113.6266,-214.2313 110.1835,-217.4434 113.6829,-217.3808 113.6829,-217.3808 113.6829,-217.3808 110.1835,-217.4434 113.7392,-220.5303 106.684,-217.5059 106.684,-217.5059\"/>\n",
"<text text-anchor=\"start\" x=\"124.9023\" y=\"-218.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge9\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M105.9197,-228.4905C130.2508,-233.8803 165.9023,-231.7168 165.9023,-222 165.9023,-213.1942 136.6221,-210.5917 113.0226,-214.1928\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"105.9197,-215.5095 112.2283,-211.1363 109.3611,-214.8715 112.8025,-214.2335 112.8025,-214.2335 112.8025,-214.2335 109.3611,-214.8715 113.3767,-217.3307 105.9197,-215.5095 105.9197,-215.5095\"/>\n",
"<text text-anchor=\"start\" x=\"165.9023\" y=\"-225.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b &amp; !c</text>\n",
"<text text-anchor=\"start\" x=\"176.4023\" y=\"-210.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;2 -->\n",
"<g id=\"edge10\" class=\"edge\">\n",
"<title>1&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M73.311,-212.3888C52.8739,-198.7618 17.9757,-171.6938 3.9023,-138 -2.2643,-123.2361 .6264,-117.661 3.9023,-102 8.67,-79.2076 8.3751,-70.4034 24.9023,-54 41.107,-37.9167 65.6349,-28.5398 84.009,-23.4116\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"90.9669,-21.5882 84.9941,-26.4099 87.5813,-22.4755 84.1956,-23.3628 84.1956,-23.3628 84.1956,-23.3628 87.5813,-22.4755 83.397,-20.3156 90.9669,-21.5882 90.9669,-21.5882\"/>\n",
"<text text-anchor=\"start\" x=\"3.9023\" y=\"-123.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"16.9023\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"32.9023\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 3 -->\n",
"<g id=\"node5\" class=\"node\">\n",
"<title>3</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"88.9023\" cy=\"-120\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"88.9023\" y=\"-116.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">3</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;3 -->\n",
"<g id=\"edge11\" class=\"edge\">\n",
"<title>1&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M88.9023,-203.7644C88.9023,-187.5192 88.9023,-163.5825 88.9023,-145.4527\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"88.9023,-138.0777 92.0524,-145.0776 88.9024,-141.5777 88.9024,-145.0777 88.9024,-145.0777 88.9024,-145.0777 88.9024,-141.5777 85.7524,-145.0777 88.9023,-138.0777 88.9023,-138.0777\"/>\n",
"<text text-anchor=\"start\" x=\"88.9023\" y=\"-174.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; !c</text>\n",
"<text text-anchor=\"start\" x=\"111.9023\" y=\"-159.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;2 -->\n",
"<g id=\"edge12\" class=\"edge\">\n",
"<title>2&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M126.684,-22.4941C136.2173,-23.2578 144.9023,-21.7598 144.9023,-18 144.9023,-15.2389 140.2184,-13.6976 133.9544,-13.3761\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"126.684,-13.5059 133.6266,-10.2313 130.1835,-13.4434 133.6829,-13.3808 133.6829,-13.3808 133.6829,-13.3808 130.1835,-13.4434 133.7392,-16.5303 126.684,-13.5059 126.684,-13.5059\"/>\n",
"<text text-anchor=\"start\" x=\"144.9023\" y=\"-21.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"167.9023\" y=\"-6.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;2 -->\n",
"<g id=\"edge14\" class=\"edge\">\n",
"<title>2&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M125.9194,-23.9824C155.6023,-30.0039 206.9023,-28.0098 206.9023,-18 206.9023,-8.7331 162.9345,-6.3363 132.8559,-10.8093\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"125.9194,-12.0176 132.2749,-7.713 129.3675,-11.4169 132.8155,-10.8163 132.8155,-10.8163 132.8155,-10.8163 129.3675,-11.4169 133.3561,-13.9196 125.9194,-12.0176 125.9194,-12.0176\"/>\n",
"<text text-anchor=\"start\" x=\"213.9023\" y=\"-21.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"206.9023\" y=\"-7.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"222.9023\" y=\"-7.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"238.9023\" y=\"-7.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;3 -->\n",
"<g id=\"edge13\" class=\"edge\">\n",
"<title>2&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M105.3914,-35.9057C102.1615,-52.3781 97.342,-76.9574 93.7466,-95.2942\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"92.386,-102.233 90.6419,-94.7576 93.0595,-98.7984 93.733,-95.3638 93.733,-95.3638 93.733,-95.3638 93.0595,-98.7984 96.8242,-95.9699 92.386,-102.233 92.386,-102.233\"/>\n",
"<text text-anchor=\"start\" x=\"100.9023\" y=\"-65.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; !c</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;2 -->\n",
"<g id=\"edge15\" class=\"edge\">\n",
"<title>3&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M106.948,-117.7924C126.5006,-114.3306 156.7895,-105.6088 170.9023,-84 178.1932,-72.8366 177.5547,-65.5552 170.9023,-54 162.8112,-39.9458 146.8966,-30.8723 133.2176,-25.3502\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"126.3215,-22.7786 133.9809,-22.273 129.6009,-24.0015 132.8803,-25.2244 132.8803,-25.2244 132.8803,-25.2244 129.6009,-24.0015 131.7796,-28.1759 126.3215,-22.7786 126.3215,-22.7786\"/>\n",
"<text text-anchor=\"start\" x=\"175.9023\" y=\"-72.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"198.9023\" y=\"-57.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;2 -->\n",
"<g id=\"edge17\" class=\"edge\">\n",
"<title>3&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M73.2761,-110.8185C57.8068,-101.5671 36.114,-88.0909 33.9023,-84 27.5613,-72.271 26.8013,-65.2851 33.9023,-54 44.8058,-36.6718 66.6292,-27.4958 83.9366,-22.7568\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"91.0326,-20.9866 85.0032,-25.7374 87.6366,-21.8338 84.2407,-22.681 84.2407,-22.681 84.2407,-22.681 87.6366,-21.8338 83.4782,-19.6247 91.0326,-20.9866 91.0326,-20.9866\"/>\n",
"<text text-anchor=\"start\" x=\"33.9023\" y=\"-72.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"38.9023\" y=\"-58.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"54.9023\" y=\"-58.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"70.9023\" y=\"-58.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;3 -->\n",
"<g id=\"edge16\" class=\"edge\">\n",
"<title>3&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M106.684,-124.4941C116.2173,-125.2578 124.9023,-123.7598 124.9023,-120 124.9023,-117.2389 120.2184,-115.6976 113.9544,-115.3761\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"106.684,-115.5059 113.6266,-112.2313 110.1835,-115.4434 113.6829,-115.3808 113.6829,-115.3808 113.6829,-115.3808 110.1835,-115.4434 113.7392,-118.5303 106.684,-115.5059 106.684,-115.5059\"/>\n",
"<text text-anchor=\"start\" x=\"124.9023\" y=\"-116.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; !c</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;3 -->\n",
"<g id=\"edge18\" class=\"edge\">\n",
"<title>3&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M106.3324,-125.9824C137.0373,-132.0039 190.9023,-130.0098 190.9023,-120 190.9023,-110.7331 144.7361,-108.3363 113.5202,-112.8093\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"106.3324,-114.0176 112.7133,-109.7507 109.7839,-113.4374 113.2355,-112.8571 113.2355,-112.8571 113.2355,-112.8571 109.7839,-113.4374 113.7577,-115.9635 106.3324,-114.0176 106.3324,-114.0176\"/>\n",
"<text text-anchor=\"start\" x=\"190.9023\" y=\"-123.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; !c</text>\n",
"<text text-anchor=\"start\" x=\"205.9023\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"221.9023\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"</g>\n",
"</svg>\n",
"</div>"
],
"text/plain": [
"<IPython.core.display.HTML object>"
]
},
"metadata": {},
"output_type": "display_data"
},
{
"name": "stdout",
"output_type": "stream",
"text": [
"(spot.formula(\"a\"), spot.formula(\"b\"), spot.formula(\"c\"))\n"
]
}
],
"source": [
"def product2(left, right):\n",
" bdict = left.get_dict()\n",
" if right.get_dict() != bdict:\n",
" raise RuntimeError(\"automata should share their dictionary\")\n",
" \n",
" result = spot.make_twa_graph(bdict)\n",
" # Copy the atomic propositions of the two input automata\n",
" result.copy_ap_of(left)\n",
" result.copy_ap_of(right)\n",
" \n",
" sdict = {}\n",
" todo = []\n",
" def dst(ls, rs):\n",
" pair = (ls, rs)\n",
" p = sdict.get(pair)\n",
" if p is None:\n",
" p = result.new_state()\n",
" sdict[pair] = p\n",
" todo.append((ls, rs, p))\n",
" return p\n",
" \n",
" result.set_init_state(dst(left.get_init_state_number(), \n",
" right.get_init_state_number()))\n",
"\n",
" # The acceptance sets of the right automaton will be shifted by this amount\n",
" shift = left.num_sets()\n",
" result.set_acceptance(shift + right.num_sets(),\n",
" left.get_acceptance() & (right.get_acceptance() << shift))\n",
" \n",
" while todo:\n",
" lsrc, rsrc, osrc = todo.pop()\n",
" for lt in left.out(lsrc):\n",
" for rt in right.out(rsrc):\n",
" cond = lt.cond & rt.cond\n",
" if cond != buddy.bddfalse:\n",
" # membership of this transitions to the new acceptance sets\n",
" acc = lt.acc | (rt.acc << shift)\n",
" result.new_edge(osrc, dst(lt.dst, rt.dst), cond, acc)\n",
" return result\n",
"\n",
"p2 = product2(a1, a2)\n",
"show_prod(a1, a2, p2)\n",
"print(p2.ap())"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Third attempt: a more usable product\n",
"\n",
"We could stop with the previous function: the result is a correct product from a theoretical point of view. However our function is still inferior to `spot.product()` in a couple of points:\n",
"- states are not presented as pairs\n",
"- the properties of the resulting automaton are not set\n",
"\n",
"The former point could be addressed by calling `set_state_names()` and passing an array of strings: if a state number is smaller than the size of that array, then the string at that position will be displayed instead of the state number in the dot output. However we can do even better by using `set_product_states()` and passing an array of pairs of states. Besides the output routines, some algorithms actually retrieve this vector of pair of states to work on the product.\n",
"\n",
"Regarding the latter point, consider for instance the deterministic nature of these automata. In Spot an automaton is deterministic if it is both existential (no universal branching) and universal (no non-deterministic branching). In our case we will restrict the algorithm to existantial input (by asserting `is_existential()` on both operands), so we can consider that the `prop_universal()` property is an indication of determinism:"
]
},
{
"cell_type": "code",
"execution_count": 7,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"maybe\n",
"yes\n",
"maybe\n",
"maybe\n"
]
}
],
"source": [
"print(a1.prop_universal())\n",
"print(a2.prop_universal())\n",
"print(prod.prop_universal())\n",
"print(p1.prop_universal())"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Because `a1` and `a2` are deterministic, their product is necessarily deterministic. This is a property that the `spot.product()` algorithm will preserve, but that our version does not *yet* preserve. We can fix that by adding\n",
"\n",
" if left.prop_universal() and right.prop_universal():\n",
" result.prop_universal(True)\n",
" \n",
"at the end of our function. Note that this is **not** the same as\n",
"\n",
" result.prop_universal(left.prop_universal() and right.prop_universal())\n",
"\n",
"because the results the `prop_*()` family of functions take and return instances of `spot.trival` values. These `spot.trival`, can, as their name implies, take one amongst three values representing `yes`, `no`, and `maybe`. `yes` and `no` should be used when we actually know that the automaton is deterministic or not (not deterministic meaning that there actually exists some non determinitic state in the automaton), and `maybe` when we do not know. \n",
"\n",
"The one-liner above is wrong for two reasons:\n",
"\n",
" - if `left` and `right` are non-deterministic, their product could be deterministic, so calling prop_universal(False) would be wrong. \n",
"\n",
" - the use of the `and` operator on `trival` is misleading in non-Boolean context. The `&` operator would be the correct operator to use if you want to work in threed-valued logic. Compare: "
]
},
{
"cell_type": "code",
"execution_count": 8,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
" no & no = no no and no = no \n",
" no & maybe = no no and maybe = no \n",
" no & yes = no no and yes = no \n",
"maybe & no = no maybe and no = maybe\n",
"maybe & maybe = maybe maybe and maybe = maybe\n",
"maybe & yes = maybe maybe and yes = maybe\n",
" yes & no = no yes and no = no \n",
" yes & maybe = maybe yes and maybe = maybe\n",
" yes & yes = yes yes and yes = yes \n"
]
}
],
"source": [
"yes = spot.trival(True)\n",
"no = spot.trival(False)\n",
"maybe = spot.trival_maybe()\n",
"for u in (no, maybe, yes):\n",
" for v in (no, maybe, yes):\n",
" print(\"{u!s:>5} & {v!s:<5} = {r1!s:<5} {u!s:>5} and {v!s:<5} = {r2!s:<5}\"\n",
" .format(u=u, v=v, r1=(u&v), r2=(u and v)))"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"The reason `maybe and no` is equal to `maybe` is that Python evaluate it like `no if maybe else maybe`, but when a trival is evaluated in a Boolean context (as in `if maybe`) the result is True only if the trival is equal to yes.\n",
"\n",
"So our\n",
"\n",
" if left.prop_universal() and right.prop_universal():\n",
" result.prop_universal(True)\n",
"\n",
"is OK because the `if` body will only be entered of both input automata are known to be deterministic."
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"However the question is in fact more general than just determinism: the product of two weak automata is weak, the product of two stutter-invariant automata is stutter-invariant, etc. So when writing an algorithm one should consider which of the [property bits](https://spot.lrde.epita.fr/hoa.html#property-bits) are naturally preserved by the algorithm, and set the relevant bits: this can save time later if the resulting automaton is used as input for another algorithm."
]
},
{
"cell_type": "code",
"execution_count": 9,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"<div style='vertical-align:text-top;display:inline-block;'><?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.40.1 (20161225.0304)\n",
" -->\n",
"<!-- Pages: 1 -->\n",
"<svg width=\"151pt\" height=\"205pt\"\n",
" viewBox=\"0.00 0.00 151.00 205.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 201)\">\n",
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-201 147,-201 147,4 -4,4\"/>\n",
"<text text-anchor=\"start\" x=\"50.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">Inf(</text>\n",
"<text text-anchor=\"start\" x=\"72.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"88.5\" y=\"-182.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)</text>\n",
"<text text-anchor=\"start\" x=\"48.5\" y=\"-168.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">[Büchi]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g id=\"node2\" class=\"node\">\n",
"<title>0</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"18\" cy=\"-105\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"middle\" x=\"18\" y=\"-101.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g id=\"edge1\" class=\"edge\">\n",
"<title>I&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M18,-159.8767C18,-156.822 18,-143.0552 18,-130.0759\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"18,-123.0193 21.1501,-130.0192 18,-126.5193 18.0001,-130.0193 18.0001,-130.0193 18.0001,-130.0193 18,-126.5193 14.8501,-130.0193 18,-123.0193 18,-123.0193\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge2\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.0373,-111.3792C44.8579,-112.6811 54,-110.5547 54,-105 54,-100.834 48.8576,-98.5964 42.1433,-98.2872\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.0373,-98.6208 41.8818,-95.1459 38.5335,-98.4566 42.0296,-98.2924 42.0296,-98.2924 42.0296,-98.2924 38.5335,-98.4566 42.1774,-101.439 35.0373,-98.6208 35.0373,-98.6208\"/>\n",
"<text text-anchor=\"start\" x=\"54\" y=\"-101.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g id=\"node3\" class=\"node\">\n",
"<title>1</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"18\" cy=\"-18\" rx=\"18\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"13.5\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g id=\"edge3\" class=\"edge\">\n",
"<title>0&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M18,-86.9735C18,-74.2586 18,-57.0603 18,-43.0183\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"18,-36.0034 21.1501,-43.0033 18,-39.5034 18.0001,-43.0034 18.0001,-43.0034 18.0001,-43.0034 18,-39.5034 14.8501,-43.0034 18,-36.0034 18,-36.0034\"/>\n",
"<text text-anchor=\"start\" x=\"18\" y=\"-57.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge4\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.7817,-21.775C45.3149,-22.4165 54,-21.1582 54,-18 54,-15.6807 49.3161,-14.386 43.0521,-14.1159\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.7817,-14.225 42.7337,-10.9702 39.2813,-14.1724 42.7809,-14.1199 42.7809,-14.1199 42.7809,-14.1199 39.2813,-14.1724 42.8282,-17.2695 35.7817,-14.225 35.7817,-14.225\"/>\n",
"<text text-anchor=\"start\" x=\"54\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge5\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M35.2149,-23.5866C58.4302,-27.9423 91,-26.0801 91,-18 91,-10.709 64.4809,-8.4807 42.2449,-11.3152\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"35.2149,-12.4134 41.6449,-8.2206 38.673,-11.8731 42.1311,-11.3329 42.1311,-11.3329 42.1311,-11.3329 38.673,-11.8731 42.6173,-14.4452 35.2149,-12.4134 35.2149,-12.4134\"/>\n",
"<text text-anchor=\"start\" x=\"91\" y=\"-21.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"100\" y=\"-6.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"</g>\n",
"</g>\n",
"</svg>\n",
"</div><div style='vertical-align:text-top;display:inline-block;'><svg height=\"220pt\" viewBox=\"0.00 0.00 208.02 220.00\" width=\"208pt\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
"<g class=\"graph\" id=\"graph0\" transform=\"scale(1 1) rotate(0) translate(4 216)\">\n",
"<polygon fill=\"#ffffff\" points=\"-4,4 -4,-216 204.0193,-216 204.0193,4 -4,4\" stroke=\"transparent\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"53.0096\" y=\"-197.8\">Inf(</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"75.0096\" y=\"-197.8\">❶</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"91.0096\" y=\"-197.8\">)&amp;Inf(</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"127.0096\" y=\"-197.8\">❷</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"143.0096\" y=\"-197.8\">)</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"56.0096\" y=\"-183.8\">[gen. Büchi 2]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g class=\"node\" id=\"node2\">\n",
"<title>0</title>\n",
"<ellipse cx=\"68.0193\" cy=\"-120\" fill=\"#ffffaa\" rx=\"18\" ry=\"18\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"middle\" x=\"68.0193\" y=\"-116.3\">0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge1\">\n",
"<title>I-&gt;0</title>\n",
"<path d=\"M68.0193,-174.8767C68.0193,-171.822 68.0193,-158.0552 68.0193,-145.0759\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"68.0193,-138.0193 71.1694,-145.0192 68.0193,-141.5193 68.0194,-145.0193 68.0194,-145.0193 68.0194,-145.0193 68.0193,-141.5193 64.8694,-145.0193 68.0193,-138.0193 68.0193,-138.0193\" stroke=\"#000000\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge2\">\n",
"<title>0-&gt;0</title>\n",
"<path d=\"M85.801,-123.2357C95.3342,-123.7856 104.0193,-122.707 104.0193,-120 104.0193,-118.012 99.3354,-116.9023 93.0714,-116.6708\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.801,-116.7643 92.7599,-113.5244 89.3007,-116.7192 92.8004,-116.6742 92.8004,-116.6742 92.8004,-116.6742 89.3007,-116.7192 92.841,-119.8239 85.801,-116.7643 85.801,-116.7643\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"104.0193\" y=\"-123.8\">!b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"114.5193\" y=\"-108.8\">❶</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge3\">\n",
"<title>0-&gt;0</title>\n",
"<path d=\"M85.5885,-124.845C108.7793,-128.5056 141.0193,-126.8906 141.0193,-120 141.0193,-113.7823 114.7687,-111.8601 92.6031,-114.2335\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.5885,-115.155 92.1185,-111.12 89.0587,-114.6991 92.5288,-114.2432 92.5288,-114.2432 92.5288,-114.2432 89.0587,-114.6991 92.9392,-117.3663 85.5885,-115.155 85.5885,-115.155\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"152.5193\" y=\"-123.8\">b</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"141.0193\" y=\"-109.8\">❶</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"157.0193\" y=\"-109.8\">❷</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g class=\"node\" id=\"node3\">\n",
"<title>1</title>\n",
"<ellipse cx=\"68.0193\" cy=\"-18\" fill=\"#ffffaa\" rx=\"18\" ry=\"18\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"middle\" x=\"68.0193\" y=\"-14.3\">1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge4\">\n",
"<title>0-&gt;1</title>\n",
"<path d=\"M50.3286,-115.3021C35.307,-110.2732 14.6933,-100.6701 5.0193,-84 -1.6731,-72.4679 -1.6731,-65.5321 5.0193,-54 13.3329,-39.6741 29.7258,-30.5674 43.7056,-25.0978\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"50.3286,-22.6979 44.8205,-28.0443 47.0379,-23.8903 43.7473,-25.0827 43.7473,-25.0827 43.7473,-25.0827 47.0379,-23.8903 42.6741,-22.1211 50.3286,-22.6979 50.3286,-22.6979\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"5.0193\" y=\"-65.3\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge5\">\n",
"<title>1-&gt;0</title>\n",
"<path d=\"M68.0193,-36.0777C68.0193,-52.2729 68.0193,-76.2033 68.0193,-94.3707\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"68.0193,-101.7644 64.8694,-94.7644 68.0193,-98.2644 68.0194,-94.7644 68.0194,-94.7644 68.0194,-94.7644 68.0193,-98.2644 71.1694,-94.7645 68.0193,-101.7644 68.0193,-101.7644\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"68.0193\" y=\"-72.8\">!b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"78.5193\" y=\"-57.8\">❶</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge6\">\n",
"<title>1-&gt;0</title>\n",
"<path d=\"M83.5721,-27.9858C91.923,-34.3143 101.423,-43.3143 106.0193,-54 111.2877,-66.2483 111.2877,-71.7517 106.0193,-84 102.4285,-92.3482 95.8446,-99.6675 89.154,-105.4879\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"83.5721,-110.0142 87.0252,-103.1586 86.2906,-107.8098 89.0092,-105.6053 89.0092,-105.6053 89.0092,-105.6053 86.2906,-107.8098 90.9932,-108.052 83.5721,-110.0142 83.5721,-110.0142\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"109.0193\" y=\"-72.8\">b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"110.0193\" y=\"-58.8\">❶</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"126.0193\" y=\"-58.8\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge7\">\n",
"<title>1-&gt;1</title>\n",
"<path d=\"M85.801,-22.4941C95.3342,-23.2578 104.0193,-21.7598 104.0193,-18 104.0193,-15.2389 99.3354,-13.6976 93.0714,-13.3761\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.801,-13.5059 92.7436,-10.2313 89.3004,-13.4434 92.7999,-13.3808 92.7999,-13.3808 92.7999,-13.3808 89.3004,-13.4434 92.8562,-16.5303 85.801,-13.5059 85.801,-13.5059\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"104.0193\" y=\"-14.3\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge8\">\n",
"<title>1-&gt;1</title>\n",
"<path d=\"M85.0367,-24.4905C109.3677,-29.8803 145.0193,-27.7168 145.0193,-18 145.0193,-9.1942 115.7391,-6.5917 92.1396,-10.1928\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"85.0367,-11.5095 91.3452,-7.1363 88.4781,-10.8715 91.9194,-10.2335 91.9194,-10.2335 91.9194,-10.2335 88.4781,-10.8715 92.4936,-13.3307 85.0367,-11.5095 85.0367,-11.5095\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"145.0193\" y=\"-21.8\">b &amp; !c</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"155.5193\" y=\"-6.8\">❷</text>\n",
"</g>\n",
"</g>\n",
"</svg></div><div style='vertical-align:text-top;display:inline-block;'><?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.40.1 (20161225.0304)\n",
" -->\n",
"<!-- Pages: 1 -->\n",
"<svg width=\"298pt\" height=\"360pt\"\n",
" viewBox=\"0.00 0.00 298.26 360.00\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
"<g id=\"graph0\" class=\"graph\" transform=\"scale(.8491 .8491) rotate(0) translate(4 420)\">\n",
"<polygon fill=\"#ffffff\" stroke=\"transparent\" points=\"-4,4 -4,-420 347.2812,-420 347.2812,4 -4,4\"/>\n",
"<text text-anchor=\"start\" x=\"98.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">Inf(</text>\n",
"<text text-anchor=\"start\" x=\"120.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"136.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)&amp;Inf(</text>\n",
"<text text-anchor=\"start\" x=\"172.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"188.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)&amp;Inf(</text>\n",
"<text text-anchor=\"start\" x=\"224.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"<text text-anchor=\"start\" x=\"240.6406\" y=\"-401.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">)</text>\n",
"<text text-anchor=\"start\" x=\"127.6406\" y=\"-387.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">[gen. Büchi 3]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g id=\"node2\" class=\"node\">\n",
"<title>0</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"160.2812\" cy=\"-324\" rx=\"27\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"150.2812\" y=\"-320.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">0,0</text>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g id=\"edge1\" class=\"edge\">\n",
"<title>I&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M160.2812,-378.8767C160.2812,-375.822 160.2812,-362.0552 160.2812,-349.0759\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"160.2812,-342.0193 163.4313,-349.0192 160.2813,-345.5193 160.2813,-349.0193 160.2813,-349.0193 160.2813,-349.0193 160.2813,-345.5193 157.1313,-349.0193 160.2812,-342.0193 160.2812,-342.0193\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge2\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M187.0761,-327.3676C197.0616,-327.478 205.2812,-326.3555 205.2812,-324 205.2812,-322.2334 200.6577,-321.1603 194.1333,-320.7808\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"187.0761,-320.6324 194.1408,-317.6303 190.5753,-320.706 194.0745,-320.7796 194.0745,-320.7796 194.0745,-320.7796 190.5753,-320.706 194.0083,-323.9289 187.0761,-320.6324 187.0761,-320.6324\"/>\n",
"<text text-anchor=\"start\" x=\"205.2812\" y=\"-327.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"215.7812\" y=\"-312.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g id=\"edge3\" class=\"edge\">\n",
"<title>0&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M186.0796,-329.5486C211.4499,-332.248 242.2812,-330.3984 242.2812,-324 242.2812,-318.2014 216.9598,-316.1388 193.329,-317.8121\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"186.0796,-318.4514 192.7758,-314.6986 189.566,-318.1439 193.0525,-317.8364 193.0525,-317.8364 193.0525,-317.8364 189.566,-318.1439 193.3292,-320.9742 186.0796,-318.4514 186.0796,-318.4514\"/>\n",
"<text text-anchor=\"start\" x=\"253.7812\" y=\"-327.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b</text>\n",
"<text text-anchor=\"start\" x=\"242.2812\" y=\"-313.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"258.2812\" y=\"-313.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g id=\"node3\" class=\"node\">\n",
"<title>1</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"98.2812\" cy=\"-222\" rx=\"27\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"88.2812\" y=\"-218.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">0,1</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g id=\"edge4\" class=\"edge\">\n",
"<title>0&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M134.6199,-317.5565C109.9118,-310.7718 75.1592,-299.4971 67.2812,-288 59.7446,-277.001 62.641,-270.4998 67.2812,-258 69.4269,-252.2201 72.9625,-246.7462 76.8935,-241.8925\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"81.6302,-236.4982 79.3784,-243.8367 79.3208,-239.1282 77.0114,-241.7582 77.0114,-241.7582 77.0114,-241.7582 79.3208,-239.1282 74.6444,-239.6798 81.6302,-236.4982 81.6302,-236.4982\"/>\n",
"<text text-anchor=\"start\" x=\"67.2812\" y=\"-269.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 2 -->\n",
"<g id=\"node4\" class=\"node\">\n",
"<title>2</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"109.2812\" cy=\"-18\" rx=\"27\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"99.2812\" y=\"-14.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1,0</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;2 -->\n",
"<g id=\"edge5\" class=\"edge\">\n",
"<title>0&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M180.7162,-311.6108C190.4934,-305.191 202.0502,-296.8509 211.2812,-288 277.1558,-224.8381 335.2804,-185.4263 298.2812,-102 285.3971,-72.9487 273.2111,-69.1623 245.2812,-54 212.9274,-36.4361 171.5265,-27.0749 142.9477,-22.346\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"135.9714,-21.2414 143.378,-19.225 139.4283,-21.7888 142.8853,-22.3362 142.8853,-22.3362 142.8853,-22.3362 139.4283,-21.7888 142.3926,-25.4475 135.9714,-21.2414 135.9714,-21.2414\"/>\n",
"<text text-anchor=\"start\" x=\"309.2812\" y=\"-174.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"310.2812\" y=\"-160.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"326.2812\" y=\"-160.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g id=\"edge6\" class=\"edge\">\n",
"<title>1&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M105.7255,-239.3679C111.862,-253.0084 121.1742,-272.2622 131.2812,-288 134.4526,-292.9381 138.1783,-297.9925 141.8831,-302.6938\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"146.5211,-308.4246 139.6688,-304.965 144.3192,-305.7039 142.1174,-302.9833 142.1174,-302.9833 142.1174,-302.9833 144.3192,-305.7039 144.5659,-301.0016 146.5211,-308.4246 146.5211,-308.4246\"/>\n",
"<text text-anchor=\"start\" x=\"131.2812\" y=\"-276.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"141.7812\" y=\"-261.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g id=\"edge7\" class=\"edge\">\n",
"<title>1&#45;&gt;0</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M123.9724,-227.9702C139.7306,-233.1016 158.6715,-242.2517 168.2812,-258 175.8397,-270.3867 174.0451,-286.5246 170.2609,-299.742\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"168.0006,-306.7422 167.1539,-299.1129 169.0761,-303.4115 170.1515,-300.0808 170.1515,-300.0808 170.1515,-300.0808 169.0761,-303.4115 173.1492,-301.0487 168.0006,-306.7422 168.0006,-306.7422\"/>\n",
"<text text-anchor=\"start\" x=\"173.2812\" y=\"-276.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"174.2812\" y=\"-262.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"190.2812\" y=\"-262.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge8\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M124.6278,-226.6692C134.8144,-226.8767 143.2812,-225.3203 143.2812,-222 143.2812,-219.5098 138.5187,-218.0117 131.8399,-217.5059\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"124.6278,-217.3308 131.7023,-214.3517 128.1268,-217.4158 131.6258,-217.5008 131.6258,-217.5008 131.6258,-217.5008 128.1268,-217.4158 131.5493,-220.6499 124.6278,-217.3308 124.6278,-217.3308\"/>\n",
"<text text-anchor=\"start\" x=\"143.2812\" y=\"-218.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g id=\"edge9\" class=\"edge\">\n",
"<title>1&#45;&gt;1</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M123.1487,-229.4501C149.9682,-233.5654 184.2812,-231.082 184.2812,-222 184.2812,-213.6985 155.6123,-210.9102 130.2026,-213.6351\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"123.1487,-214.5499 129.6855,-210.5257 126.6197,-214.0997 130.0906,-213.6496 130.0906,-213.6496 130.0906,-213.6496 126.6197,-214.0997 130.4958,-216.7734 123.1487,-214.5499 123.1487,-214.5499\"/>\n",
"<text text-anchor=\"start\" x=\"184.2812\" y=\"-225.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">b &amp; !c</text>\n",
"<text text-anchor=\"start\" x=\"194.7812\" y=\"-210.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;2 -->\n",
"<g id=\"edge10\" class=\"edge\">\n",
"<title>1&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M77.0983,-210.4497C54.2395,-196.6366 19.1207,-171.162 4.2812,-138 -2.254,-123.3955 .2268,-117.4778 4.2812,-102 10.4837,-78.3221 13.2954,-70.6019 31.2812,-54 44.3014,-41.9817 62.0356,-33.365 77.3044,-27.581\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"84.1205,-25.1208 78.6058,-30.4603 80.8284,-26.3091 77.5363,-27.4974 77.5363,-27.4974 77.5363,-27.4974 80.8284,-26.3091 76.4668,-24.5345 84.1205,-25.1208 84.1205,-25.1208\"/>\n",
"<text text-anchor=\"start\" x=\"4.2812\" y=\"-123.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"17.2812\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"33.2812\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 3 -->\n",
"<g id=\"node5\" class=\"node\">\n",
"<title>3</title>\n",
"<ellipse fill=\"#ffffaa\" stroke=\"#000000\" cx=\"98.2812\" cy=\"-120\" rx=\"27\" ry=\"18\"/>\n",
"<text text-anchor=\"start\" x=\"88.2812\" y=\"-116.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">1,1</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;3 -->\n",
"<g id=\"edge11\" class=\"edge\">\n",
"<title>1&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M98.2812,-203.7644C98.2812,-187.5192 98.2812,-163.5825 98.2812,-145.4527\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"98.2812,-138.0777 101.4313,-145.0776 98.2813,-141.5777 98.2813,-145.0777 98.2813,-145.0777 98.2813,-145.0777 98.2813,-141.5777 95.1313,-145.0777 98.2812,-138.0777 98.2812,-138.0777\"/>\n",
"<text text-anchor=\"start\" x=\"98.2812\" y=\"-174.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; !c</text>\n",
"<text text-anchor=\"start\" x=\"121.2812\" y=\"-159.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;2 -->\n",
"<g id=\"edge12\" class=\"edge\">\n",
"<title>2&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M135.6278,-22.6692C145.8144,-22.8767 154.2812,-21.3203 154.2812,-18 154.2812,-15.5098 149.5187,-14.0117 142.8399,-13.5059\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"135.6278,-13.3308 142.7023,-10.3517 139.1268,-13.4158 142.6258,-13.5008 142.6258,-13.5008 142.6258,-13.5008 139.1268,-13.4158 142.5493,-16.6499 135.6278,-13.3308 135.6278,-13.3308\"/>\n",
"<text text-anchor=\"start\" x=\"154.2812\" y=\"-21.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"177.2812\" y=\"-6.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;2 -->\n",
"<g id=\"edge14\" class=\"edge\">\n",
"<title>2&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M134.3443,-24.9574C167.401,-29.743 216.2812,-27.4238 216.2812,-18 216.2812,-9.2388 174.0331,-6.6183 141.5294,-10.1385\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"134.3443,-11.0426 140.8962,-7.0432 137.8169,-10.6056 141.2895,-10.1686 141.2895,-10.1686 141.2895,-10.1686 137.8169,-10.6056 141.6828,-13.2939 134.3443,-11.0426 134.3443,-11.0426\"/>\n",
"<text text-anchor=\"start\" x=\"223.2812\" y=\"-21.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b</text>\n",
"<text text-anchor=\"start\" x=\"216.2812\" y=\"-7.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"232.2812\" y=\"-7.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"248.2812\" y=\"-7.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;3 -->\n",
"<g id=\"edge13\" class=\"edge\">\n",
"<title>2&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M107.3317,-36.0777C105.5851,-52.2729 103.0044,-76.2033 101.0452,-94.3707\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"100.2478,-101.7644 97.8666,-94.467 100.6231,-98.2846 100.9984,-94.8048 100.9984,-94.8048 100.9984,-94.8048 100.6231,-98.2846 104.1303,-95.1426 100.2478,-101.7644 100.2478,-101.7644\"/>\n",
"<text text-anchor=\"start\" x=\"104.2812\" y=\"-65.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; !c</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;2 -->\n",
"<g id=\"edge15\" class=\"edge\">\n",
"<title>3&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M124.5946,-115.0604C141.9558,-110.2881 163.4291,-101.1485 174.2812,-84 181.4112,-72.7332 181.0504,-65.4872 174.2812,-54 166.9753,-41.6021 153.694,-33.1733 141.0323,-27.6086\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"134.5024,-24.9539 142.1734,-24.6722 137.7447,-26.2721 140.987,-27.5902 140.987,-27.5902 140.987,-27.5902 137.7447,-26.2721 139.8006,-30.5083 134.5024,-24.9539 134.5024,-24.9539\"/>\n",
"<text text-anchor=\"start\" x=\"179.2812\" y=\"-72.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"202.2812\" y=\"-57.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;2 -->\n",
"<g id=\"edge17\" class=\"edge\">\n",
"<title>3&#45;&gt;2</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M76.4536,-109.3159C61.7697,-101.6255 44.3717,-91.3533 40.2812,-84 33.7996,-72.3482 33.3695,-65.402 40.2812,-54 48.3469,-40.6943 63.1181,-32.0748 76.9301,-26.6177\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"83.5999,-24.1862 78.1022,-29.5433 80.3116,-25.385 77.0233,-26.5838 77.0233,-26.5838 77.0233,-26.5838 80.3116,-25.385 75.9444,-23.6244 83.5999,-24.1862 83.5999,-24.1862\"/>\n",
"<text text-anchor=\"start\" x=\"40.2812\" y=\"-72.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; c</text>\n",
"<text text-anchor=\"start\" x=\"45.2812\" y=\"-58.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"61.2812\" y=\"-58.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff4da0\">❶</text>\n",
"<text text-anchor=\"start\" x=\"77.2812\" y=\"-58.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;3 -->\n",
"<g id=\"edge16\" class=\"edge\">\n",
"<title>3&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M124.6278,-124.6692C134.8144,-124.8767 143.2812,-123.3203 143.2812,-120 143.2812,-117.5098 138.5187,-116.0117 131.8399,-115.5059\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"124.6278,-115.3308 131.7023,-112.3517 128.1268,-115.4158 131.6258,-115.5008 131.6258,-115.5008 131.6258,-115.5008 128.1268,-115.4158 131.5493,-118.6499 124.6278,-115.3308 124.6278,-115.3308\"/>\n",
"<text text-anchor=\"start\" x=\"143.2812\" y=\"-116.3\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; !b &amp; !c</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;3 -->\n",
"<g id=\"edge18\" class=\"edge\">\n",
"<title>3&#45;&gt;3</title>\n",
"<path fill=\"none\" stroke=\"#000000\" d=\"M123.4219,-126.8825C157.5961,-131.7668 209.2812,-129.4727 209.2812,-120 209.2812,-111.1564 164.2326,-108.5695 130.4414,-112.2394\"/>\n",
"<polygon fill=\"#000000\" stroke=\"#000000\" points=\"123.4219,-113.1175 129.9768,-109.1229 126.8949,-112.683 130.3678,-112.2486 130.3678,-112.2486 130.3678,-112.2486 126.8949,-112.683 130.7588,-115.3742 123.4219,-113.1175 123.4219,-113.1175\"/>\n",
"<text text-anchor=\"start\" x=\"209.2812\" y=\"-123.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#000000\">a &amp; b &amp; !c</text>\n",
"<text text-anchor=\"start\" x=\"224.2812\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#1f78b4\">⓿</text>\n",
"<text text-anchor=\"start\" x=\"240.2812\" y=\"-109.8\" font-family=\"Lato\" font-size=\"14.00\" fill=\"#ff7f00\">❷</text>\n",
"</g>\n",
"</g>\n",
"</svg>\n",
"</div>"
],
"text/plain": [
"<IPython.core.display.HTML object>"
]
},
"metadata": {},
"output_type": "display_data"
},
{
"name": "stdout",
"output_type": "stream",
"text": [
"maybe\n"
]
}
],
"source": [
"def product3(left, right):\n",
" # the twa_graph.is_existential() method returns a Boolean, not a spot.trival\n",
" if not (left.is_existential() and right.is_existential()):\n",
" raise RuntimeError(\"alternating automata are not supported\")\n",
" bdict = left.get_dict()\n",
" if right.get_dict() != bdict:\n",
" raise RuntimeError(\"automata should share their dictionary\")\n",
" \n",
" result = spot.make_twa_graph(bdict)\n",
" result.copy_ap_of(left)\n",
" result.copy_ap_of(right)\n",
" \n",
" pairs = [] # our array of state pairs\n",
" sdict = {}\n",
" todo = []\n",
" def dst(ls, rs):\n",
" pair = (ls, rs)\n",
" p = sdict.get(pair)\n",
" if p is None:\n",
" p = result.new_state()\n",
" sdict[pair] = p\n",
" todo.append((ls, rs, p))\n",
" pairs.append((ls, rs)) # name each state\n",
" return p\n",
" \n",
" result.set_init_state(dst(left.get_init_state_number(), \n",
" right.get_init_state_number()))\n",
"\n",
" shift = left.num_sets()\n",
" result.set_acceptance(shift + right.num_sets(),\n",
" left.get_acceptance() & (right.get_acceptance() << shift))\n",
" \n",
" while todo:\n",
" lsrc, rsrc, osrc = todo.pop()\n",
" for lt in left.out(lsrc):\n",
" for rt in right.out(rsrc):\n",
" cond = lt.cond & rt.cond\n",
" if cond != buddy.bddfalse:\n",
" acc = lt.acc | (rt.acc << shift)\n",
" result.new_edge(osrc, dst(lt.dst, rt.dst), cond, acc)\n",
"\n",
" # Remember the origin of our states\n",
" result.set_product_states(pairs)\n",
" \n",
" # Loop over all the properties we want to preserve if they hold in both automata\n",
" for p in ('prop_universal', 'prop_complete', 'prop_weak', 'prop_inherently_weak', \n",
" 'prop_terminal', 'prop_stutter_invariant', 'prop_state_acc'):\n",
" if getattr(left, p)() and getattr(right, p)():\n",
" getattr(result, p)(True)\n",
" return result\n",
"\n",
"p3 = product3(a1, a2)\n",
"show_prod(a1, a2, p3)\n",
"print(p3.prop_universal())"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"For development, it is useful to know that we can force the automaton printer to show the real state numbers (not the pairs) by passing option `1`, and that we can retrieve the associated pairs ourselves. Note that the pairs also appear as tooltips when we mouse over the states."
]
},
{
"cell_type": "code",
"execution_count": 10,
"metadata": {},
"outputs": [
{
"data": {
"image/svg+xml": [
"<svg height=\"277pt\" viewBox=\"0.00 0.00 502.00 277.09\" width=\"502pt\" xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\">\n",
"<g class=\"graph\" id=\"graph0\" transform=\"scale(1 1) rotate(0) translate(4 273.0871)\">\n",
"<polygon fill=\"#ffffff\" points=\"-4,4 -4,-273.0871 498,-273.0871 498,4 -4,4\" stroke=\"transparent\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"174\" y=\"-254.8871\">Inf(</text>\n",
"<text fill=\"#1f78b4\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"196\" y=\"-254.8871\">⓿</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"212\" y=\"-254.8871\">)&amp;Inf(</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"248\" y=\"-254.8871\">❶</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"264\" y=\"-254.8871\">)&amp;Inf(</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"300\" y=\"-254.8871\">❷</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"316\" y=\"-254.8871\">)</text>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"203\" y=\"-240.8871\">[gen. Büchi 3]</text>\n",
"<!-- I -->\n",
"<!-- 0 -->\n",
"<g class=\"node\" id=\"node2\">\n",
"<title>0</title>\n",
"<g id=\"a_node2\"><a xlink:title=\"0,0\">\n",
"<ellipse cx=\"56\" cy=\"-83.0871\" fill=\"#ffffaa\" rx=\"18\" ry=\"18\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"middle\" x=\"56\" y=\"-79.3871\">0</text>\n",
"</a>\n",
"</g>\n",
"</g>\n",
"<!-- I&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge1\">\n",
"<title>I-&gt;0</title>\n",
"<path d=\"M1.1233,-83.0871C4.178,-83.0871 17.9448,-83.0871 30.9241,-83.0871\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"37.9807,-83.0871 30.9808,-86.2372 34.4807,-83.0871 30.9807,-83.0872 30.9807,-83.0872 30.9807,-83.0872 34.4807,-83.0871 30.9807,-79.9372 37.9807,-83.0871 37.9807,-83.0871\" stroke=\"#000000\"/>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge2\">\n",
"<title>0-&gt;0</title>\n",
"<path d=\"M52.7643,-100.8688C52.2144,-110.402 53.293,-119.0871 56,-119.0871 57.988,-119.0871 59.0977,-114.4032 59.3292,-108.1392\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"59.2357,-100.8688 62.4756,-107.8277 59.2808,-104.3685 59.3258,-107.8682 59.3258,-107.8682 59.3258,-107.8682 59.2808,-104.3685 56.1761,-107.9088 59.2357,-100.8688 59.2357,-100.8688\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"37.5\" y=\"-137.8871\">!b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"48\" y=\"-122.8871\">❶</text>\n",
"</g>\n",
"<!-- 0&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge3\">\n",
"<title>0-&gt;0</title>\n",
"<path d=\"M50.9906,-100.6642C47.5451,-121.8051 49.2148,-149.0871 56,-149.0871 62.043,-149.0871 64.0285,-127.4466 61.9564,-107.7777\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"61.0094,-100.6642 65.0556,-107.1873 61.4713,-104.1336 61.9332,-107.603 61.9332,-107.603 61.9332,-107.603 61.4713,-104.1336 58.8107,-108.0187 61.0094,-100.6642 61.0094,-100.6642\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"51.5\" y=\"-166.8871\">b</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"40\" y=\"-152.8871\">❶</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"56\" y=\"-152.8871\">❷</text>\n",
"</g>\n",
"<!-- 1 -->\n",
"<g class=\"node\" id=\"node3\">\n",
"<title>1</title>\n",
"<g id=\"a_node3\"><a xlink:title=\"0,1\">\n",
"<ellipse cx=\"169\" cy=\"-109.0871\" fill=\"#ffffaa\" rx=\"18\" ry=\"18\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"middle\" x=\"169\" y=\"-105.3871\">1</text>\n",
"</a>\n",
"</g>\n",
"</g>\n",
"<!-- 0&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge4\">\n",
"<title>0-&gt;1</title>\n",
"<path d=\"M61.6055,-100.2245C67.0373,-113.7408 76.7269,-131.669 92,-140.0871 107.9587,-148.883 115.9169,-146.4287 133,-140.0871 139.9591,-137.5037 146.4745,-132.9053 151.9981,-128.0279\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"157.1708,-123.1219 154.2596,-130.2246 154.6314,-125.5305 152.0919,-127.939 152.0919,-127.939 152.0919,-127.939 154.6314,-125.5305 149.9242,-125.6535 157.1708,-123.1219 157.1708,-123.1219\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"92\" y=\"-148.8871\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 2 -->\n",
"<g class=\"node\" id=\"node4\">\n",
"<title>2</title>\n",
"<g id=\"a_node4\"><a xlink:title=\"1,0\">\n",
"<ellipse cx=\"463\" cy=\"-111.0871\" fill=\"#ffffaa\" rx=\"18\" ry=\"18\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"middle\" x=\"463\" y=\"-107.3871\">2</text>\n",
"</a>\n",
"</g>\n",
"</g>\n",
"<!-- 0&#45;&gt;2 -->\n",
"<g class=\"edge\" id=\"edge5\">\n",
"<title>0-&gt;2</title>\n",
"<path d=\"M66.9425,-68.4317C73.3383,-61.1255 82.0941,-53.0254 92,-49.0871 230.3551,5.92 297.9667,25.1982 427,-49.0871 441.0542,-57.1782 450.1277,-73.0928 455.6498,-86.7718\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"458.2214,-93.6679 452.8241,-88.2097 456.9985,-90.3885 455.7756,-87.1091 455.7756,-87.1091 455.7756,-87.1091 456.9985,-90.3885 458.727,-86.0085 458.2214,-93.6679 458.2214,-93.6679\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"219\" y=\"-27.8871\">a &amp; b</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"220\" y=\"-13.8871\">❶</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"236\" y=\"-13.8871\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge6\">\n",
"<title>1-&gt;0</title>\n",
"<path d=\"M151.0948,-104.9673C132.0352,-100.5819 101.7512,-93.6139 80.491,-88.7222\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"73.6563,-87.1496 81.1844,-85.6495 77.0671,-87.9344 80.478,-88.7193 80.478,-88.7193 80.478,-88.7193 77.0671,-87.9344 79.7716,-91.789 73.6563,-87.1496 73.6563,-87.1496\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"94\" y=\"-118.8871\">!b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"104.5\" y=\"-103.8871\">❶</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;0 -->\n",
"<g class=\"edge\" id=\"edge7\">\n",
"<title>1-&gt;0</title>\n",
"<path d=\"M161.9837,-92.2918C156.1165,-80.6383 146.5186,-66.0118 133,-59.0871 116.7817,-50.7795 109.4403,-53.8066 92,-59.0871 86.3385,-60.8012 80.7535,-63.7319 75.7337,-66.9684\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"69.7143,-71.1629 73.6565,-64.5764 72.5859,-69.1619 75.4575,-67.1608 75.4575,-67.1608 75.4575,-67.1608 72.5859,-69.1619 77.2584,-69.7452 69.7143,-71.1629 69.7143,-71.1629\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"95.5\" y=\"-76.8871\">b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"96.5\" y=\"-62.8871\">❶</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"112.5\" y=\"-62.8871\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge8\">\n",
"<title>1-&gt;1</title>\n",
"<path d=\"M164.0012,-126.497C163.0681,-136.175 164.7344,-145.0871 169,-145.0871 172.1326,-145.0871 173.8633,-140.2807 174.1921,-133.8943\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"173.9988,-126.497 177.3307,-133.4122 174.0903,-129.9958 174.1818,-133.4946 174.1818,-133.4946 174.1818,-133.4946 174.0903,-129.9958 171.0329,-133.5769 173.9988,-126.497 173.9988,-126.497\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"148.5\" y=\"-148.8871\">!b &amp; !c</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;1 -->\n",
"<g class=\"edge\" id=\"edge9\">\n",
"<title>1-&gt;1</title>\n",
"<path d=\"M161.0436,-125.3954C155.9026,-143.0475 158.5547,-163.0871 169,-163.0871 178.058,-163.0871 181.2555,-148.017 178.5924,-132.5024\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"176.9564,-125.3954 181.5965,-131.5103 177.7416,-128.8062 178.5267,-132.217 178.5267,-132.217 178.5267,-132.217 177.7416,-128.8062 175.457,-132.9236 176.9564,-125.3954 176.9564,-125.3954\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"150.5\" y=\"-181.8871\">b &amp; !c</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"161\" y=\"-166.8871\">❷</text>\n",
"</g>\n",
"<!-- 1&#45;&gt;2 -->\n",
"<g class=\"edge\" id=\"edge10\">\n",
"<title>1-&gt;2</title>\n",
"<path d=\"M181.2425,-122.7647C200.7658,-143.422 241.2381,-181.6952 285,-196.0871 346.7465,-216.3935 376.0833,-201.4909 427,-161.0871 436.4852,-153.5603 444.6212,-142.9132 450.7464,-133.3771\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"454.4752,-127.315 453.4908,-134.9277 452.6414,-130.2962 450.8077,-133.2774 450.8077,-133.2774 450.8077,-133.2774 452.6414,-130.2962 448.1246,-131.627 454.4752,-127.315 454.4752,-127.315\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"285\" y=\"-222.8871\">a &amp; b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"298\" y=\"-208.8871\">❶</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"314\" y=\"-208.8871\">❷</text>\n",
"</g>\n",
"<!-- 3 -->\n",
"<g class=\"node\" id=\"node5\">\n",
"<title>3</title>\n",
"<g id=\"a_node5\"><a xlink:title=\"1,1\">\n",
"<ellipse cx=\"314\" cy=\"-90.0871\" fill=\"#ffffaa\" rx=\"18\" ry=\"18\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"middle\" x=\"314\" y=\"-86.3871\">3</text>\n",
"</a>\n",
"</g>\n",
"</g>\n",
"<!-- 1&#45;&gt;3 -->\n",
"<g class=\"edge\" id=\"edge11\">\n",
"<title>1-&gt;3</title>\n",
"<path d=\"M187.0712,-106.7191C212.6862,-103.3627 259.663,-97.2071 288.7229,-93.3992\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"295.7011,-92.4849 289.1697,-96.5177 292.2308,-92.9396 288.7604,-93.3944 288.7604,-93.3944 288.7604,-93.3944 292.2308,-92.9396 288.3511,-90.2711 295.7011,-92.4849 295.7011,-92.4849\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"205\" y=\"-121.8871\">a &amp; b &amp; !c</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"228\" y=\"-106.8871\">❷</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;2 -->\n",
"<g class=\"edge\" id=\"edge12\">\n",
"<title>2-&gt;2</title>\n",
"<path d=\"M456.9752,-128.1244C455.7456,-137.945 457.7539,-147.0871 463,-147.0871 466.9346,-147.0871 469.0479,-141.9446 469.3399,-135.2304\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"469.0248,-128.1244 472.4819,-134.9779 469.1799,-131.6209 469.335,-135.1175 469.335,-135.1175 469.335,-135.1175 469.1799,-131.6209 466.1881,-135.2571 469.0248,-128.1244 469.0248,-128.1244\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"432\" y=\"-165.8871\">a &amp; !b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"455\" y=\"-150.8871\">❶</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;2 -->\n",
"<g class=\"edge\" id=\"edge14\">\n",
"<title>2-&gt;2</title>\n",
"<path d=\"M454.0632,-127.0341C446.8726,-148.3732 449.8516,-177.0871 463,-177.0871 474.7617,-177.0871 478.3859,-154.1106 473.8726,-133.9897\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"471.9368,-127.0341 476.8484,-132.9332 472.8753,-130.4059 473.8137,-133.7778 473.8137,-133.7778 473.8137,-133.7778 472.8753,-130.4059 470.779,-134.6224 471.9368,-127.0341 471.9368,-127.0341\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"446\" y=\"-194.8871\">a &amp; b</text>\n",
"<text fill=\"#1f78b4\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"439\" y=\"-180.8871\">⓿</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"455\" y=\"-180.8871\">❶</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"471\" y=\"-180.8871\">❷</text>\n",
"</g>\n",
"<!-- 2&#45;&gt;3 -->\n",
"<g class=\"edge\" id=\"edge13\">\n",
"<title>2-&gt;3</title>\n",
"<path d=\"M444.9634,-108.545C418.5254,-104.8188 369.1456,-97.8593 339.1543,-93.6323\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"331.9729,-92.6202 339.344,-90.478 335.4386,-93.1087 338.9044,-93.5972 338.9044,-93.5972 338.9044,-93.5972 335.4386,-93.1087 338.4647,-96.7163 331.9729,-92.6202 331.9729,-92.6202\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"361\" y=\"-108.8871\">a &amp; !b &amp; !c</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;2 -->\n",
"<g class=\"edge\" id=\"edge15\">\n",
"<title>3-&gt;2</title>\n",
"<path d=\"M328.2977,-78.7969C337.1615,-72.5336 349.0955,-65.3643 361,-62.0871 389.2812,-54.3013 400.8285,-48.8395 427,-62.0871 437.8162,-67.5621 446.173,-77.986 452.1001,-87.8168\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"455.6457,-94.1334 449.4725,-89.5711 453.9325,-91.0814 452.2193,-88.0293 452.2193,-88.0293 452.2193,-88.0293 453.9325,-91.0814 454.9662,-86.4874 455.6457,-94.1334 455.6457,-94.1334\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"363\" y=\"-80.8871\">a &amp; !b &amp; c</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"386\" y=\"-65.8871\">❶</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;2 -->\n",
"<g class=\"edge\" id=\"edge17\">\n",
"<title>3-&gt;2</title>\n",
"<path d=\"M327.1013,-103.0603C335.8856,-110.8094 348.1612,-119.9301 361,-124.0871 388.907,-133.1229 398.1059,-129.1442 427,-124.0871 431.1932,-123.3531 435.5422,-122.1725 439.7064,-120.8146\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"446.4798,-118.4096 440.9372,-123.7203 443.1815,-119.5807 439.8832,-120.7518 439.8832,-120.7518 439.8832,-120.7518 443.1815,-119.5807 438.8292,-117.7834 446.4798,-118.4096 446.4798,-118.4096\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"365\" y=\"-146.8871\">a &amp; b &amp; c</text>\n",
"<text fill=\"#1f78b4\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"370\" y=\"-132.8871\">⓿</text>\n",
"<text fill=\"#ff4da0\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"386\" y=\"-132.8871\">❶</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"402\" y=\"-132.8871\">❷</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;3 -->\n",
"<g class=\"edge\" id=\"edge16\">\n",
"<title>3-&gt;3</title>\n",
"<path d=\"M307.1445,-106.7511C305.6211,-116.7121 307.9063,-126.0871 314,-126.0871 318.5703,-126.0871 320.9983,-120.8136 321.2839,-113.9746\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"320.8555,-106.7511 324.4145,-113.5523 321.0628,-110.245 321.27,-113.7388 321.27,-113.7388 321.27,-113.7388 321.0628,-110.245 318.1256,-113.9254 320.8555,-106.7511 320.8555,-106.7511\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"281\" y=\"-129.8871\">a &amp; !b &amp; !c</text>\n",
"</g>\n",
"<!-- 3&#45;&gt;3 -->\n",
"<g class=\"edge\" id=\"edge18\">\n",
"<title>3-&gt;3</title>\n",
"<path d=\"M303.5026,-105.0144C295.5712,-122.9845 299.0703,-144.0871 314,-144.0871 327.0635,-144.0871 331.3754,-127.9304 326.9359,-111.8527\" fill=\"none\" stroke=\"#000000\"/>\n",
"<polygon fill=\"#000000\" points=\"324.4974,-105.0144 329.8156,-110.5497 325.673,-108.3111 326.8486,-111.6077 326.8486,-111.6077 326.8486,-111.6077 325.673,-108.3111 323.8816,-112.6658 324.4974,-105.0144 324.4974,-105.0144\" stroke=\"#000000\"/>\n",
"<text fill=\"#000000\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"283\" y=\"-161.8871\">a &amp; b &amp; !c</text>\n",
"<text fill=\"#1f78b4\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"298\" y=\"-147.8871\">⓿</text>\n",
"<text fill=\"#ff7f00\" font-family=\"Lato\" font-size=\"14.00\" text-anchor=\"start\" x=\"314\" y=\"-147.8871\">❷</text>\n",
"</g>\n",
"</g>\n",
"</svg>"
],
"text/plain": [
"<IPython.core.display.SVG object>"
]
},
"metadata": {},
"output_type": "display_data"
},
{
"name": "stdout",
"output_type": "stream",
"text": [
"0: (0, 0)\n",
"1: (0, 1)\n",
"2: (1, 0)\n",
"3: (1, 1)\n"
]
}
],
"source": [
"display(p3.show('.1'))\n",
"pairs = p3.get_product_states()\n",
"for s in range(p3.num_states()):\n",
" print(\"{}: {}\".format(s, pairs[s]))"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# Timings\n",
"\n",
"As an indication of how slow it is to implement such an algorithm using the Python bindings of Spot, consider the following comparison:"
]
},
{
"cell_type": "code",
"execution_count": 11,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"200 µs ± 2.74 µs per loop (mean ± std. dev. of 7 runs, 1000 loops each)\n"
]
}
],
"source": [
"%timeit product3(a1, a2)"
]
},
{
"cell_type": "code",
"execution_count": 12,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"3.35 µs ± 52.4 ns per loop (mean ± std. dev. of 7 runs, 100000 loops each)\n"
]
}
],
"source": [
"%timeit spot.product(a1, a2)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Depending on the machine where this notebook has been run, using the C++ version of the product can be 1 to 2 orders of magnitude faster. This is due to all the type conversions (converting Python types to C++ types) that occurs everytime a function/method of Spot is called from Python. When calling high-level C++ functions (such as `spot.product()`) from Python, the overhead is negligible because most of the time is spent on the C++ side, actually executing the function. However when calling low-level functions (such as `new_edge()`, `new_state()`, `out()`) most of the time is spent converting the arguments from Python to C++ and the results from C++ to Python.\n",
"\n",
"Despite that speed difference, Python can be useful to prototype an algorithm before implementing it in C++."
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# The case of weak automata\n",
"\n",
"Finally, note that `spot.product()` actually does a bit more: it has some specializations for when one of the argument of the product is marked as weak (as indicated by `prop_weak()`). In this case, the resulting acceptance condition can be simplified a bit."
]
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.7"
}
},
"nbformat": 4,
"nbformat_minor": 2
}