treewidth #48
Replies: 12 comments 5 replies
-
There is this early work on SAT which one might want to revisit: Guiding SAT Diagnosis with Tree Decompositions and related successful work in model counting by Johannes K. Fichte DBLP papers as well this hybrid version |
Beta Was this translation helpful? Give feedback.
-
thanks. I see, with so much work done on SAT such ideas can't be new. |
Beta Was this translation helpful? Give feedback.
-
Interesting problem indeed. Fixing the variable order only initially should not have a large impact on solving time but it is also clear that certain benchmarks (particularly pigeon holes) benefit from always using a fixed static variable order. Kissat is very precise in following the given order in the file (initially). So you could achieve this effect with giving the variable indices in the order you want your decisions to occur. Actually it would allocate internal variable indices based on first occurence of a variable (as the 'tumble' option enforces that and is turned on by default). So to achieve a static order you can use '--no-tumble', '--no-bump' and then give the indices in the desired order. If you only want it initially drop the '--no-bump'. |
Beta Was this translation helpful? Give feedback.
-
Yep, and it does make a difference. BTW, MiniSAT packs the variables as they appear on the EVSIDS binary heap and then picks as first decision the one on the top of the heap (the first one unless score randomization is enabled which is off by default). Thus usually first decision is '-1'. Then when pulling off the next decision from the binary EVSIDS heap it will pop '1' from it by the usual replacement of the last variable in the heap (and popping that one from the heap). Therefore the next variable is the one with the highest index in the file. This continues until the first conflict and variables are bumped. So for 99 variables the first decisions will be -1,-99,-98,...,-3,-2. Now check out these benchmarks I generated for showing that the propagation in MiniSAT is quadratic and on these benchmarks all the time is spent in propagation without reaching a single conflict: Quadratic Propagation Benchmarks. The organizers of the SAT Competition 2017 did not use them though (neither the other MiniSAT adverserial benchmarks I submitted). I also have looked into various ways to reorder the decision queue/heap, i.e., 'shuffle' in CaDiCaL, but without much success though. |
Beta Was this translation helpful? Give feedback.
-
We know that a linear static order decision scheme is not good as it kind of gives you OBDD power, while FreeBDDs are exponentially more succinct. Already for OBDDs it is hard problem to find the best order and there are some papers (for FreeBDDs I do not remember any work). So finding a good "initial" order is another then more practical problem. |
Beta Was this translation helpful? Give feedback.
-
Yes exactly, reviving all the old 1990ies work on branching heuristics is a good idea. |
Beta Was this translation helpful? Give feedback.
-
I do think it is a good in case might comment looked like irony. |
Beta Was this translation helpful? Give feedback.
-
From the treewidth/pathwidth consideration,
I would try to sort the variables so to minimize the average
interaction between the already used variables and the rest.
----------------------------------
first occurrence of a variable , tumble
--no-tumble
-- no bump
.
you can use '--no-tumble', '--no-bump' and then give the indices in
the desired order.
you mean, kissat doesn't sort the variables and already performs
differently
on equivalent , variable-permuted or clause-permuted instances ?
I find 101 lines in the code with keyword "sort", 2 with sort variables
LOG ("quick sorting %zu analyzed variables", size);
I'm using kissat sc2020 , I found the Ubuntu executable somewhere online
with keyword search.
sudo apt install kissat
would be nice
I have not yet experimented with varible reordering and no-tumble
maybe later today
…-------------------------------------------
VMTF =
EVSIDS =
VSIDS [31,2004] maps each variable to a score and bumping a variable
consists
in increasing the score of the variable
We actually intended to go to EVSIDS
this year’s competition (EVSIDS
For the new version 3.1.0 (sc2023) of Kissat
...
We also incorporated the ESA idea proposed in the compe-
tition last year [4] and schedule bounded variable elimination
attempts based on variables scores (EVSIDS and VMTF
stamps [3]) and refined it further by taking the difference and
not as previously the sum when falling back to the number of
positive and negative occurrences of a variable. We also went
over SAT sweeping again which improved it slightly.
Am 18.12.2023 13:32 schrieb Armin Biere:
Interesting problem indeed. Fixing the variable order only initially
should not have a large impact on solving time but it is also clear
that certain benchmarks (particularly pigeon holes) benefit from
always using a fixed static variable order. Kissat is very precise in
following the given order in the file (initially). So you could
achieve this effect with giving the variable indices in the order you
want your decisions to occur. Actually it would allocate internal
variable indices based on first occurence of a variable (as the
'tumble' option enforces that and is turned on by default). So to
achieve a static order you can use '--no-tumble', '--no-bump' and then
give the indices in the desired order. If you only want it initially
drop the '--no-bump'.
The solver switches from stable to focused mode once in a while. In
focused mode it uses VMTF and the last activated variable comes last
and thus first as decision. Similarly in stable mode the EVSIDS
ordered binary heap is used and there the score is initialized with
'1-1/idx', so also increasing with larger variable index. Therefore
the last activated variable is also picked first as decision. Now the
catch is that this initialization of the scores resp. VMTF queue
position is done during activation of a variable and thus really as
the variables occur in the file.
--
Reply to this email directly, view it on GitHub [1], or unsubscribe
[2].
You are receiving this because you authored the thread.Message ID:
***@***.***>
Links:
------
[1]
#48 (comment)
[2]
https://github.com/notifications/unsubscribe-auth/BCAREI4PLPWZOWMSZMU6FI3YKAZXXAVCNFSM6AAAAABAYT7HCGVHI2DSMVQWIX3LMV43SRDJONRXK43TNFXW4Q3PNVWWK3TUHM3TQOBVHE4DA
|
Beta Was this translation helpful? Give feedback.
-
I. CADICAL VIVINST [2] G. Andersson, P. Bjesse, B. Cook, and Z. Hanna, “A proof engine https://www.cambridge.org/core/journals/theory-and-practice-of-logic-programming/article/on-the-foundations-of-grounding-in-answer-set-programming/573D6EDC447B516CF2A5D90B1A262332 systematically replacing all variables by the importance of grounding has somehow been eclipsed by now, in my "railway graphs" I may have "clause-grounding" ? "Suitability" is somehow estimated by the balace of the |
Beta Was this translation helpful? Give feedback.
-
sorry, that recursion in my railway-graphs doesn't work, it's more complicated. |
Beta Was this translation helpful? Give feedback.
-
This is instantiation as used in CaDiCaL (in two forms - stand alone and in combination with vivification) is just a preprocessing algorithm and allows to remove variables in clauses. So is (mostly) independent of encoding. |
Beta Was this translation helpful? Give feedback.
-
I downloaded kissat3.1.0 with the --no-bump feature from
|
Beta Was this translation helpful? Give feedback.
-
is there a concept similar to "treewidth" for SAT-problems ?
That gave improvements in "parameterized programming"
We can just make the graph whose vertices are the variables
and there is an edge, iff 2 vertices appear in the same clause.
Then reorder the vertices with a treewidth program
and feed the reordered instance into kissat
(skipping kissat's initial reordering)
Beta Was this translation helpful? Give feedback.
All reactions