contains: fix the semantics
spot::contains(a, b) should test a⊇b. It was testing a⊆b instead. * NEWS: Mention the bug. * spot/twaalgos/contains.cc, spot/twaalgos/contains.hh: Fix the code and documentation. * tests/python/contains.ipynb: Adjust description and expected results. * python/spot/__init__.py: Also swap the argument of language_containment_checker.contains() * bin/autfilt.cc: Adjust usage.
This commit is contained in:
parent
4ce0d92896
commit
23722c031f
6 changed files with 27 additions and 50 deletions
|
|
@ -17,7 +17,7 @@
|
|||
"source": [
|
||||
"# Containement checks\n",
|
||||
"\n",
|
||||
"The `spot.contains()` function checks whether the language of its left argument is included in the language of its right argument. The arguments may mix automata and formulas; the latter can be given as strings."
|
||||
"The `spot.contains()` function checks whether the language of its right argument is included in the language of its left argument. The arguments may mix automata and formulas; the latter can be given as strings."
|
||||
]
|
||||
},
|
||||
{
|
||||
|
|
@ -38,7 +38,7 @@
|
|||
{
|
||||
"data": {
|
||||
"text/plain": [
|
||||
"(False, True)"
|
||||
"(True, False)"
|
||||
]
|
||||
},
|
||||
"execution_count": 3,
|
||||
|
|
@ -58,7 +58,7 @@
|
|||
{
|
||||
"data": {
|
||||
"text/plain": [
|
||||
"(False, True)"
|
||||
"(True, False)"
|
||||
]
|
||||
},
|
||||
"execution_count": 4,
|
||||
|
|
@ -78,7 +78,7 @@
|
|||
{
|
||||
"data": {
|
||||
"text/plain": [
|
||||
"(False, True)"
|
||||
"(True, False)"
|
||||
]
|
||||
},
|
||||
"execution_count": 5,
|
||||
|
|
@ -98,7 +98,7 @@
|
|||
{
|
||||
"data": {
|
||||
"text/plain": [
|
||||
"(False, True)"
|
||||
"(True, False)"
|
||||
]
|
||||
},
|
||||
"execution_count": 6,
|
||||
|
|
@ -118,7 +118,7 @@
|
|||
{
|
||||
"data": {
|
||||
"text/plain": [
|
||||
"(False, True)"
|
||||
"(True, False)"
|
||||
]
|
||||
},
|
||||
"execution_count": 7,
|
||||
|
|
@ -145,7 +145,7 @@
|
|||
{
|
||||
"data": {
|
||||
"text/plain": [
|
||||
"(False, True)"
|
||||
"(True, False)"
|
||||
]
|
||||
},
|
||||
"execution_count": 8,
|
||||
|
|
@ -165,7 +165,7 @@
|
|||
{
|
||||
"data": {
|
||||
"text/plain": [
|
||||
"(False, True)"
|
||||
"(True, False)"
|
||||
]
|
||||
},
|
||||
"execution_count": 9,
|
||||
|
|
@ -272,7 +272,7 @@
|
|||
{
|
||||
"data": {
|
||||
"text/plain": [
|
||||
"(False, True)"
|
||||
"(True, False)"
|
||||
]
|
||||
},
|
||||
"execution_count": 14,
|
||||
|
|
@ -344,7 +344,7 @@
|
|||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 34,
|
||||
"execution_count": 17,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
|
|
@ -360,7 +360,7 @@
|
|||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 35,
|
||||
"execution_count": 18,
|
||||
"metadata": {},
|
||||
"outputs": [
|
||||
{
|
||||
|
|
@ -484,34 +484,6 @@
|
|||
"source": [
|
||||
"show_one_difference(aut_f, aut_g)"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 36,
|
||||
"metadata": {},
|
||||
"outputs": [
|
||||
{
|
||||
"ename": "NameError",
|
||||
"evalue": "name 'run' is not defined",
|
||||
"output_type": "error",
|
||||
"traceback": [
|
||||
"\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
|
||||
"\u001b[0;31mNameError\u001b[0m Traceback (most recent call last)",
|
||||
"\u001b[0;32m<ipython-input-36-d7d1b4bd9ffe>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m()\u001b[0m\n\u001b[0;32m----> 1\u001b[0;31m \u001b[0mrun\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mget_aut\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m",
|
||||
"\u001b[0;31mNameError\u001b[0m: name 'run' is not defined"
|
||||
]
|
||||
}
|
||||
],
|
||||
"source": [
|
||||
"run.get_aut()"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": []
|
||||
}
|
||||
],
|
||||
"metadata": {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue