The Problem of Compatible Representatives

Donald E. Knuth와 Arvind Raghunathan이 작성 한論문에서는 다양한 조합 문제를 하나의 자연스러운 클래스로 묶고 그 이름을 Compatible Representatives라고 명명한다. 이 논문에서 다루는 대표적인 특수 사례 중에는 다음과 같은 것이 있다.

1. 일련의 상호 배제 관계가 있는 집합 A1, A2, ..., An에 대한 순서열 (x1, x2, ..., xn)이 존재하는지 여부를 결정한다.
2. 이 문제는 NP-완전이며, 예를 들어 모든 집합 Ai가 동일하고 상호 배제 관계가 대칭적이고 반사적인 경우, Compatible Representatives 문제는 인접하지 않은 노드의 클리크 찾기와 유사하다.

특수 사례 중에는 다음과 같은 것들이 있다.

1. 상호 배제 관계가 등가 관련일 때, Compatible Representatives 문제는 2색 문제와 동일하며 NP-완전이다.
2. 각 집합 Ai가 크기가 k인 경우, Compatible Representatives 문제는 kSAT 문제로 재구성 가능하다.
3. 일련의 순서열 (x1, x2, ..., xn)이 존재하는지 여부를 결정할 수 있는 인접하지 않은 노드의 최대 independet set 찾기에서, Compatibility problem은 NP-완전이다.

또한, Compatible Representatives 문제는 cartographer에 의해 사용되는 labeling task와 관련이 있다. Labeling task에서는 city name을 map 위에 표시하기 위해 가능한 위치를 찾고 각 위치가 다른 위치와 충돌하지 않는지 확인하는 문제이다.

논문에서 추가로 다루는 예시 중에는 scheduling problem, permutation의 증가 subsequence, planar 3SAT 등이 포함된다.

The Problem of Compatible Representatives

arXiv:cs/9301116v1 [cs.DS] 1 Jul 1992The Problem of Compatible Representativesby Donald E. Knuth* and Arvind Raghunathan**Abstract. The purpose of this note is to attach a name to a natural class ofcombinatorial problems and to point out that this class includes many importantspecial cases.We also show that a simple problem of placing nonoverlappinglabels on a rectangular map is NP-complete.Keywords backtracking, coloring, compatibility, independent sets, mapmaking, match-ing, NP-complete, preclusion, radio communicationAMS (MOS) subject classifications 68R99 (Discrete mathematics in relation to com-puter science); 90C27 (Combinatorial programming)Abbreviated title Compatible Representatives* Computer Science Department, Stanford University; research supported in part byNational Science Foundation grant CCR–8610181.

** University of California, Davis, Division of Computer Science; research supported inpart by Semiconductor Research Corporation grant SRC–82–11–008.1

The Problem of Compatible Representativesby Donald E. Knuth and Arvind RaghunathanMany combinatorial tasks can be formulated in the following way: Is there a sequence(x1, x2, . .

., xn) such that xj ∈Aj for all j, and xj is compatible with xk for all j < k? HereA1, A2, .

. ., An are given sets, and “compatibility” is a given relation on A1 ∪A2 ∪.

. .∪An.This problem is NP-hard in general.

For example, if all sets Aj are the same, and ifcompatibility is a symmetric, irreflexive relation, a sequence of compatible representativesis nothing but an n-clique in the compatibility graph.The problem of coloring a graph G with c colors is another NP-hard special case ofthe general compatibility question. Let Aj be the the set of pairs {(j, 1), .

. ., (j, c)}, andsay that (j, a) is compatible with (k, b) if either a ̸= b or vj is not adjacent to vk in G,where the vertices of G are {v1, .

. ., vn}.

Then a sequence of compatible representatives isessentially a c-coloring of G. Therefore the problem is NP-hard for all c ≥3.On the other hand, the compatibility problem also has important special cases that areefficiently solvable. If the compatibility relation is ‘̸=’, then a solution sequence (x1, .

. ., xn)is traditionally called a system of distinct representatives [4] [3, Chapter 5], and the problemof finding such systems is well known to be equivalent to bipartite matching.Indeed,if the compatibility relation is the complement of any equivalence relation, a sequence(x1, x2, .

. ., xn) of compatible representatives exists if and only if there is a matching ofcardinality n in a bipartite graph on the vertices {v1, .

. ., vn, c1, .

. ., cm}, where {c1, .

. ., cm}are the equivalence classes and we have vj −−ck if and only if Aj contains an element ofclass ck.Another nice special case is equivalent to identifying increasing subsequences of apermutation.Let π1 .

. .

πm be a permutation of {1, . .

., m}, and let Aj be the set ofpairs {(j, 1), . .

., (j, m)}. Say that (j, a) is compatible with (k, b) if and only if j < k andπa < πb.

Then a compatible sequence(1, a1), . .

., (n, an)is equivalent to an increasingsubsequence (πa1, . .

., πan) of π1 . .

. πm.The example in the prevous paragraph illustrates that compatibility need not be asymmetric relation.

But when the sets Aj are pairwise disjoint, as in that case, we couldjust as well assume that compatibility is symmetric and reflexive, since our definition ofcompatible representatives makes it immaterial whether elements xj of Aj and xk of Akare compatible unless we have j < k.There are, however, important special cases in which compatibility is asymmetric.Consider, for example, a scheduling problem in which Aj is a set of tasks that can be doneat time j, and where xj is compatible with xk only when task xj does not require the priorcompletion of xk.Cartographers face an interesting case of the general compatibility problem when theyattach alphabetic labels to dots on a map. Let Aj represent the possible ways to place thename of city j, and let xj be compatible with xk when positions xj and xk do not overlapeach other or otherwise mislead a potential reader.

Then a good map should be a solutionto the problem of compatible representatives.Notice that the cartographic problem makes sense even if the sets Aj are infinite. The2

task of placing disjoint labels is a fairly natural question of combinatorial geometry thatdoes not appear to be a special case of any other well known problem.In light of this discussion, it seems worthwhile to add the problem of compatiblerepresentatives to the class of “combinatorial problems that deserve a name,” and toinvestigate heuristics and additional special cases that turn out to have efficient solutions.Simple special cases. We have noted that the compatibility problem is equivalent tobipartite matching when incompatibility is an equivalence relation.

The problem also hasa polynomial-time solution when compatibility is transitive. Let B1 = A1, and for j > 1letBj = { y ∈Aj | ∃x ∈Bj−1 (x compatible with y) } .Then the compatibility problem has a solution if and only if Bn is nonempty.

We candecide this in at most Pnj=2 ∥Aj−1∥∥Aj∥steps.Another noteworthy special case occurs when each set Aj contains at most two el-ements. Then the compatibility problem is equivalent to an instance of 2SAT: We canassume that Aj = {vj, vj}; the clauses are (σj ∨σk) for every pair of literals such thatj < k and σj is incompatible with σk.In general, if each ∥Aj∥≤k and k ≥2, the problem reduces directly to an instanceof kSAT in which each literal occurs positively just once.

The literals are (j, a) for a ∈Aj,and the clauses are_n∈Aj(j, a) ,for 1 ≤j ≤n ;(j, a) ∨(k, b) ,for 1 ≤j < k ≤n and a incompatible with b.Conversely, any instance of kSAT with m clauses reduces to the compatibility problemof finding representatives (x1, . .

. , xm), with xj a member of the jth clause and with twoliterals compatible iffthey aren’t negatives of each other.The general compatibility problem with finite sets Aj can also be reduced to anindependent set problem in a natural way.

Consider the graph G with vertices (j, a) fora ∈Aj, having edges(j, a) −−(j, b) ,if a ̸= b;(j, a) −−(k, b) ,if j < k and a is incompatible with b.Then G has an independent set of size n if and only if the compatibility problem has asolution.Therefore we obtain simple solutions of the compatibility problem when there is asimple solution to the corresponding independent set problem. One such case occurs whencompatibility is a symmetric relation and we have the following condition: If i < j < k andthe elements ai, aj, ak are mutually compatible, then (1) every element of Ai is compatiblewith either aj or ak; (2) every element of Aj is compatible with either ai or ak; (3) everyelement of Ak is compatible with either ai or a−j; and (4) every element not in Ai∪Aj∪Ak3

is compatible with either xi, xj, or xk. In such a case the graph G is claw-free, and wecan use Minty’s algorithm [7] to find a maximum independent set.Gr¨otschel, Lov´asz, and Schrijver [2, Chapter 9] have compiled a survey of cases wherethe independent set problem is known to have a simple solution.Another hard case.

A very special case of the general mapmaker’s problem, alluded toin the introduction, turns out to be NP-complete.Consider a set of integer points p1, . .

. , pn on the plane.

We wish to find integer pointsx1, . .

., xn with the following properties for all j ̸= k:|xj −pj| = 1 ;|xj −pk| > 1 ;|xj −xk| ≥2 . (Motivation: Each xj is the center of a 2 × 2 square in which a “label” for point pj canbe placed.

The label at xj should be closer to pj than to any other point; distinct labelsshould not overlap.) We will call this the MFL problem, for “METAFONT labeling,” becauseit arises in connection with the task of attaching labels to points in diagrams drawn byMETAFONT [5, page 328].Solutions to the MFL problem can conveniently be represented by showing each point pjas a heavy dot and drawing an arrow from pj to xj for each j; at most four possibilitiesexist from each of the given points.

For example, it is easy to see that a cluster of fouradjacent points can be labeled in only two ways:r✛r✻r✲r❄r✛r✻r✲r❄There is no way to attach a label to the middle point in a configuration likerrrbecause each of the four positions adjacent to that point is too close to one of the othergiven points. The MFL problem provides an amusing pastime for people who are sitting ina boring meeting and who happen to have a tablet of graph paper to doodle on.The general MFL problem is clearly in NP.

In order to show that it is NP-complete,we observe first that there are only two solutions to the problemrrrrrrrrnamely the two solutions for four-point clusters given earlier, using the same orientationin each cluster. Thus we can construct large chainlike tree networks of four-point clusters,4

for example,r rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrr rrrin which there are only two solutions, “positive” and “negative.” This construction pro-vides a way to represent the values of boolean variables in a satisfiability problem.We can now use Lichtenstein’s theorem that planar 3SAT is NP-complete [6].Aninstance of planar 3SAT is a set of variables v1, . .

., vn arranged in a straight line, togetherwith a set of three-legged clauses above and below them, where the clauses are properlynested so that none of the legs between clauses and variables cross each other. We canalways put the clauses into a rectilinear configuration such asv1v2v3v4v5v9v8v7v6which corresponds to Lichtenstein’s “crossover box” [6, Figure 5].We construct an instance of MFL from a given instance of planar 3SAT by representingthe vertical legs for each variable as chains of four-point clusters; this guarantees that eachvariable will have one of two values, corresponding to the common orientation of all its5

clusters. We can easily stretch out the diagram so that there is no interference betweenthe variables except at places where three legs of a clause come together in a horizontalsegment.It remains to specify the representation of the clauses.

By symmetry we need onlydescribe the representation that appears above the variables. Each horizontal section of acomb-like clause in the upper portion will be represented by a configuration of the formr r rr r rr r rrrrrrrrrr r rrrr r r rrr r r r r r r r r rrleft armz}|{right armz}|{with 6l + 4 dots in the left arm and 6m + 4 dots in the right arm, for some l and m. (Thethree triples at the bottom will connect to clusters that represent variables, as explainedbelow.

Those clusters will occur at positions that are congruent mod 6; the arms of a combstretch out so that they reach the variables appropriate to the clause. )In each group of three dots at the bottom of this construction, the arrow for the middledot must go either up or down.

All three middle arrows cannot go up, because that forcesr✛r❄r✻r❄r✲r✛r❄r✻r❄r✲r✛r❄r✻r❄r✲r✛r✲r✛r✲r✲r✛r✲r✛r✛r✻r✲rr✛r✻r✻r❄r✻r❄r✻r❄r✻r❄r✻r❄r✻r❄r✻r❄r✻r✻r✲and there is no way to attach an arrow to the middle dot in the second row.However, there are solutions in which any one of the middle arrows goes down. Forexample, we can chooser✛r❄r✲r✛r✻r✲r✛r✻r✲r✲r✛r✲r✛r✲r✛r✲r✛r✛r✻r✲r✛r✛r❄r✻r❄r✻r✻r❄r✻r❄r✻r❄r✻r❄r✻r❄r✻r✲6

orr✛r✻r✲r✛r❄r✲r✛r✻r✲r✛r✲r✛r✲r✲r✛r✲r✛r✛r❄r✲r❄r✛r✻r❄r✻r❄r✻r❄r✻r❄r✻r❄r✻r❄r✻r❄r✻r✲and there is a third solution that is essentially a mirror image of the first.We can place four-point clusters below a row of three dots in such a way that adownward arrow on the top middle dot forces an orientation on the clusters, but an upwardarrow on the top middle dot forces nothing:r✛r❄r✲r✛r✻r✲r❄r✛r✻r✲r❄r✛r❄r✲r✛r❄r✲r✛r✻r✲r❄By choosing one of these junction configurations for each variable in the clause, dependingon whether the variable is negated or not, we obtain an instance of MFL that has a solutionif and only if the given planar clauses are satisfiable.Backtracking. We have now proved that MFL is NP-hard.

However, in practice a solutionor proof of nonexistence can often be found quickly by backtracking, using the idea of“preclusion” introduced by Golomb and Baumert [1]. When a trial value xj is selectedfrom Aj, it precludes all selections of other xk that are incompatible with it; precludedvalues can be (temporarily) removed from Ak.

The problem of compatible representativesis precisely the abstract general setting that supports this notion of preclusion.Golomb and Baumert suggest choosing xj at each stage from a currently smallestset Aj whose representative has not yet been chosen. If we are simply looking for a solution,instead of enumerating all solutions, it would also be worthwhile to select elements thatpreclude as few others as possible.For example, if an element of Aj doesn’t preclude any others, we can set xj equal tothat element without loss of generality.

If x ∈Aj precludes only one element y ∈Ak andno others, and if we find no solution when xj = x, then we can set xk = y without loss ofgenerality.Further work. A recent paper by Simon [8] considers the assignment of channels to trans-mitters in a radio communication system.

This is another case of a compatibility problem,7

rather like the mapmaker’s problem because nearby transmitters must not broadcast onthe same channel. Simon presents a polynomial-time approximation scheme that is guar-anteed to find at least a fixed fraction of the optimum number of compatible channels.This suggests that many useful approximation schemes for other instances of the generalcompatibility problem might remain to be found.References[1] Solomon Golomb and Leonard D. Baumert, Backtrack programming, Journalof the ACM, 12 (1965), pp.

516–524. [2] Martin Gr¨otschel, L´aszl´o Lov´asz, and Alexander Schrijver, GeometricAlgorithms and Combinatorial Optimization, Springer-Verlag, New York, 1987.

[3] Marshall Hall, Jr, Combinatorial Theory, Blaisdell, 1967. Second edition, Wiley-Interscience, 1986.

[4] P. Hall, On representatives of subsets, Journal of the London Mathematical Society,10 (1935), pp. 26–30.

[5] Donald E. Knuth, The METAFONTbook, Addison-Wesley, Reading, Mass., 1986. [6] David Lichtenstein, Planar formulæ and their uses, SIAM Journal on Computing,11 (1982), pp.

329–343. [7] G. Minty, On maximal independent sets of vertices in claw-free graphs, Journal ofCombinatorial Theory (B), 28 (1980), pp.

284–304. [8] Hans Ulrich Simon, Approximation algorithms for channel assignment in cellularradio networks, in Fundamentals of Computation Theory, Proceedings of FCT’89,edited by J. Csirik, J. Demetrovics, and F. G´ecseg, Lecture Notes in Computer Science380 (1989), pp.

405–415.8


출처: arXiv:9301.116원문 보기

Subscribe to koineu.com

Don’t miss out on the latest issues. Sign up now to get access to the library of members-only issues.
jamie@example.com
Subscribe