Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
2-satisfiability
Solves the 2-sat problem, which assigns boolean values to variables (a, b, c...) such that it satisfies a boolean expression which is a conjunction of clauses, where each clause is a disjunction of two variables. For example, (a || b) && (a || not c) && (not b || not c). The solution is obtained from the strongly connected components of the implication graph constructed from the clauses.
Sources: