python-sat 1.9.dev8__tar.gz → 1.9.dev10__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {python_sat-1.9.dev8/python_sat.egg-info → python_sat-1.9.dev10}/PKG-INFO +1 -1
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/pysat/__init__.py +1 -1
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/pysat/formula.py +7 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10/python_sat.egg-info}/PKG-INFO +1 -1
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_clausification.py +2 -1
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/LICENSE.txt +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/MANIFEST.in +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/README.rst +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/allies/__init__.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/allies/approxmc.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/allies/unigen.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/cardenc/bitwise.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/cardenc/card.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/cardenc/clset.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/cardenc/common.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/cardenc/itot.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/cardenc/ladder.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/cardenc/mto.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/cardenc/pairwise.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/cardenc/ptypes.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/cardenc/pycard.cc +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/cardenc/seqcounter.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/cardenc/sortcard.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/cardenc/utils.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/__init__.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/bbscan.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/bica.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/fm.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/genhard.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/hitman.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/lbx.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/lsu.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/mcsls.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/models.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/musx.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/optux.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/primer.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/rc2.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/examples/usage.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/formula/pf_parse.cc +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/formula/pf_plus.cc +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/formula/pf_plus.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/formula/pf_py.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/formula/pf_scan.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/formula/pf_weight.cc +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/formula/pf_weight.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/formula/pyformula.cc +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/formula/pyformula.hh +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/pysat/_fileio.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/pysat/_utils.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/pysat/card.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/pysat/engines.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/pysat/integer.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/pysat/pb.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/pysat/process.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/pysat/solvers.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/python_sat.egg-info/SOURCES.txt +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/python_sat.egg-info/dependency_links.txt +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/python_sat.egg-info/requires.txt +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/python_sat.egg-info/top_level.txt +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/requirements.txt +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/setup.cfg +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/setup.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/cadical103.tar.gz +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/cadical153.tar.gz +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/cadical195.tar.gz +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/cadical300.tar.gz +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/glucose30.tar.gz +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/glucose41.tar.gz +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/glucose421.tar.gz +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/lingeling.tar.gz +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/maplechrono.zip +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/maplecm.zip +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/maplesat.zip +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/mergesat3.tar.gz +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/minicard.tar.gz +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/minisat22.tar.gz +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/minisatgh.zip +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/cadical103.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/cadical153.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/cadical195.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/cadical300.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/glucose30.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/glucose41.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/glucose421.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/gluecard30.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/gluecard41.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/kissat404.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/lingeling.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/maplechrono.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/maplecm.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/maplesat.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/mergesat3.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/minicard.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/minisat22.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/minisatep.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/patches/minisatgh.patch +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/prepare.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/solvers/pysolvers.cc +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_accum_stats.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_atmost.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_atmost1.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_atmostk.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_boolengine.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_cnf.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_empty_extclause.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_encode_pb_conditional.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_equals1.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_formula_parsing.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_formula_unique.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_idpool.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_integer.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_oom.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_process.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_propagate.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_unique_model.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_unique_mus.py +0 -0
- {python_sat-1.9.dev8 → python_sat-1.9.dev10}/tests/test_warmstart.py +0 -0
|
@@ -810,6 +810,13 @@ class Formula(object):
|
|
|
810
810
|
:type type: :class:`FormulaType`
|
|
811
811
|
"""
|
|
812
812
|
|
|
813
|
+
# Formula.__new__ may return an existing structurally identical
|
|
814
|
+
# formula; by default, Python still invokes __init__ in that case,
|
|
815
|
+
# which is harmful; if an identical object exists, we should
|
|
816
|
+
# immediately return
|
|
817
|
+
if hasattr(self, 'type'):
|
|
818
|
+
return
|
|
819
|
+
|
|
813
820
|
assert 'type' in kwargs, 'No \'type\' of the formula is provided'
|
|
814
821
|
self.type = kwargs['type']
|
|
815
822
|
|
|
@@ -33,9 +33,10 @@ def test_clausification():
|
|
|
33
33
|
[1, 5, -6], [6, -1, 5], [6, 1, -5], [6], [7]])
|
|
34
34
|
|
|
35
35
|
# multiple successive inner/outermost clausification
|
|
36
|
+
Formula.cleanup()
|
|
36
37
|
f = And(Atom('1'), Atom('2'))
|
|
37
38
|
compare(list(f), [[1], [2]])
|
|
38
39
|
|
|
39
40
|
# nested conjunctions are inherited directly by the outer conjunction
|
|
40
41
|
g = And(f, Atom('3'))
|
|
41
|
-
compare(list(g), [[1], [2], [
|
|
42
|
+
compare(list(g), [[1], [2], [3]])
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|