fram-lang / fram-lang/dbl

Detecting equivalent propositional variables in SAT-solver

Open
#202 0 comments 0 reactions 0 assignees View on GitHub
2.2. sat
Dominant language
OCaml
Stars
45
Forks
28
PR merge metrics
No merged PRs in 30d

Description

Clauses added to SAT-solver commonly contains cycles, like [¬p ∨ q, ¬q ∨ p] or [¬p ∨ q, ¬q ∨ r, ¬r ∨ s, ¬s ∨ p]. Such cycles correspond to effect equivalence constraints, and all variables on such a cycle must have the same value. The SAT-solver could detect such situations and collapse all variables on a cycle. Currently, there is some infrastructure for collapsing variables (there is `SameAs` constructor in the type representing values of propositional variables) that can be used.

It seems that cycles with different polarity of variables like [p ∨ q, ¬p ∨ ¬q] don't appear in the wild (I didn't find any), so we don't have to care about them.

Contributor guide

No contributing guide indexed for this repository

Research direction

Begin at the SAT-solver entry point and inspect the existing SameAs constructor in the value representation. Trace how implication clauses are processed, then determine how equivalent-variable cycles should be collapsed and how completion can be verified for both direct and multi-step cycles.

Written by the indexing model from the issue text.

Assessment

Tech stack
ocaml
Domain
compilers
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.