Difference between revisions of "2-satisfiability"
Karl Jones (Talk | contribs) (Created page with "In computer science, '''2-satisfiability''' (abbreviated as '''2-SAT''' or just '''2SAT''') is the problem of determining whether a collection of two-valued (Boolean or bi...") |
(No difference)
|
Revision as of 13:47, 25 May 2016
In computer science, 2-satisfiability (abbreviated as 2-SAT or just 2SAT) is the problem of determining whether a collection of two-valued (Boolean or binary) variables with constraints on pairs of variables can be assigned values satisfying all the constraints.
Description
2-satisfiability is a special case of the general Boolean satisfiability problem, which can involve constraints on more than two variables, and of constraint satisfaction problems, which can allow more than two choices for the value of each variable. But in contrast to those more general problems, which are NP-complete, 2-satisfiability can be solved in polynomial time.
Instances of the 2-satisfiability problem are typically expressed as 2-CNF, also known as Krom formulas.
An alternative representation is the implication graph, which expresses the variables of an instance and their negations as vertices in a graph, and constraints on pairs of variables as directed edges.
An instance may be solved in polynomial time by resolution.
Linear time solutions include a method based on backtracking and another method based on the strongly connected components of the implication graph.
2-satisfiability may be applied to geometry and data visualization problems in which a collection of objects each have two potential locations and the goal is to find a placement for each object that avoids overlaps with other objects.
Other applications include clustering data to minimize the sum of the diameters of the clusters, classroom and sports scheduling, and recovering shapes from information about their cross-sections.
Computational complexity theory
In computational complexity theory, 2-satisfiability provides an example of an NL-complete problem, one that can be solved non-deterministically using a logarithmic amount of storage and that is among the hardest of the problems solvable in this resource bound.
The set of all solutions to a 2-satisfiability instance can be given the structure of a median graph, but counting these solutions is #P-complete and therefore not expected to have a polynomial-time solution.
Random instances undergo a sharp phase transition from solvable to unsolvable instances as the ratio of constraints to variables increases past 1, a phenomenon conjectured but unproven for more complicated forms of the satisfiability problem.
A computationally difficult variation of 2-satisfiability, finding a truth assignment that maximizes the number of satisfied constraints, has an approximation algorithm whose optimality depends on the unique games conjecture, and another difficult variation, finding a satisfying assignment minimizing the number of true variables, is an important test case for parameterized complexity.
See also
- Computational complexity theory
- Computer science
- Constraint (mathematics)
- Horn-satisfiability
- Implication graph
- Median graph
- Satisfiability problem
External links
- 2-satisfiability @ Wikipedia