Fast algorithms for vertex subset and vertex partitioning
problems on graphs of low boolean-width⋆
B.-M. Bui-Xuan, J. A. Telle, and M. Vatshelle
Department of Informatics, University of Bergen, Norway.
[buixuan,telle,vatshelle]@ii.uib.no
Abstract. We consider the graph parameter boolean-width, related to the number of different unions of neighborhoods across a cut of a graph. Boolean-width is similar to rankwidth, which is related to the number of GF [2] -sums (1+1=0) of neighborhoods instead
of the Boolean-sums (1+1=1) used for boolean-width. It compares well to the other four
well-known width parameters tree-width, branch-width, clique-width, and rank-width: for
many graph classes boolean-width is bounded whereas tree-width and branch-width are unbounded; for some graph classes boolean-width has been shown to be exponentially smaller
than any of the other four; for arbitrary graphs, boolean-width is never larger than branchwidth (except for extreme values of zero and one), nor tree-width plus one, nor clique-width,
and has been shown to be at least smaller than the square of rank-width. Boolean-width has
been shown to be a very natural parameter to consider when solving Maximum Independent
Set and Minimum Dominating Set using a divide-and-conquer approach. In this paper we
investigate which are the graph problems having the same behaviour, and extend them to a
large class of NP-hard vertex subset and vertex partitioning problems by giving algorithms
that are FPT when parameterized by either boolean-width, rank-width or clique-width, with
runtime single exponential in either parameter if given the pertinent optimal decomposition.
1
Introduction
There are several strategies for coping with NP-hard problems, including the use of heuristics,
SAT solvers, constraint satisfaction resolution, exact algorithms, approximation algorithms, fixed
parameter tractable (FPT) algorithms etc. In this paper we concentrate on the latter paradigm
(see, e.g., [12, 13] for details), and aim for FPT algorithms with low exponential dependency on
the parameter. We focus on a class of vertex subset and vertex partitioning problems that includes a large number of well-known NP-hard graph problems related to domination, independence
or homomorphism, such as Max Independent Set, Min Dominating Set, Max Strong Stable Set,
Max or Min Perfect Code, Min Total Dominating Set, Max or Min Independent Dominating Set,
Min Perfect Dominating Set, Min k -Dominating Set, Max Induced k -Regular Subgraph, Max Induced k -Bounded Degree Subgraph, H -Coloring (or H -Homomorphism, with Kq -Coloring being
q -Coloring), H -Covering, H -Partial Covering, etc (see next section for their formal definition). Algorithms parameterized by either the tree-width [22] of the input graph, or by its clique-width [15],
have already been given for this class of problems.
The parameter that we address in this paper is a recently introduced notion, the so-called
boolean-width [6]. Width parameters of graphs, like tree-width, branch-width, clique-width and
rank-width, are important in the theory of graph algorithms. Many NP-hard graph optimization
problems have FPT algorithms when parameterized by these graph width parameters (see, e.g.,
[18] for an overview). Such algorithms usually have two stages, a first stage computing the right
decomposition of the input graph (e.g., [3, 5, 17, 21]) and a second stage solving the problem by
a divide-and-conquer approach, or dynamic programming, along the decomposition (e.g., [2, 11,
14, 15, 20]). For practical applications we must look carefully at the runtimes as a function of
the parameter. We may then have to concentrate on heuristic algorithms for the first stage, for
example in the way done for tree-width as part of the TreewidthLIB project at University of Utrecht
⋆
Supported by the Norwegian Research Council, project PARALGO.
2
B.-M. Bui-Xuan, J. A. Telle, and M. Vatshelle
tw
k
2
k+1
1.5k
bw
oo
k
k
cw
k
2
k
k
2
rw
0.25 k
boolw
k
2
k
2
Fig. 1. Upper bounds tying parameters tw=tree-width, bw=branch-width, cw=clique-width, rw=rankwidth and boolw=boolean-width. An arrow from P to Q labelled f (k) means that any class of graphs
having parameter P bounded by k will have parameter Q bounded by O(f (k)) , and ∞ means that no
such upper bound can be shown. Except for the labels in a box the bounds are known to be tight, meaning
that there is a class of graphs for which the bound is Ω(f (k)) . For the box containing label 2k a Ω(2k/2 )
bound is known [10].
(e.g., [4]). For the second stage we should carefully design algorithms for each separate problem.
When comparing the usefulness of these width parameters, we first need to compare the values of
the parameters on various graph classes, we secondly need good algorithms or fast heuristics for
the first stage, and we thirdly need to compare the best runtimes for the second stage. From this
perspective, the motivation of focusing on boolean-width can be seen as follows.
Firstly, boolean-width compares well to the four parameters tree-width, branch-width, cliquewidth and rank-width. For many graph classes boolean-width is bounded whereas tree-width and
branch-width are unbounded, because this is the case for clique-width (see, e.g., [18]), and because
boolean-width is bounded if and only if clique-width is bounded [6]. For some graph classes (of
unbounded clique/rank/boolean-width) boolean-width has been shown to be exponentially smaller
than any of the other four, e.g., the so-called Hsu-grid graphs [6]. For arbitrary graphs, booleanwidth is never larger than branch-width (except for extreme values of zero and one), nor tree-width
plus one, nor clique-width, and has been shown to be at least smaller than the square of rankwidth [1, 6]. See Figure 1 for a sketch of how the various parameters compare. Note that for any
class of graphs we have only three possibilities: either all five parameters are bounded (e.g., trees)
or none of them are bounded (e.g., grids) or only clique-width, rank-width and boolean-width are
bounded (e.g., cliques).
Secondly, regarding first stage algorithms, since boolean-width is tied to rank-width, when
parameterizing by the boolean-width of an input graph we get an FPT algorithm that computes
an approximation of an optimal boolean-width decomposition, by applying either the algorithm of
Hliněný and Oum [17] computing an optimal rank-decomposition or the approximation algorithm
of Oum and Seymour [21]. We have also initiated research into heuristic algorithms for the first
stage.
Finally, for the second stage, a typical question would be: for which problems the value of the
boolean-width constitutes the crucial runtime bottleneck, and more specifically for which problems
there are FPT algorithms with low exponential dependency on the boolean-width. This kind of
question has been studied before, for instance with tree-width and branch-width (intensively), and
more recently also for rank-width [8, 14]. For boolean-width, given a decomposition of booleanwidth k of an n-vertex graph, we know that the Maximum Independent Set and Minimum Dominating Set problems can be solved in time O(n(n+23k k)) [6]. In this paper, we broaden the number
of such problems by solving a large class of vertex subset and vertex partitioning problems with
runtime single exponential in the boolean-width (for a polynomial function poly we call 2poly(k)
poly(k)
single exponential in k , 22
double exponential in k , and so on).
More precisely, the runtime of our algorithms as a function of boolean-width for vertex subset
2
problems is O∗ (2dO(boolw ) ), where d is a problem-specific small constant (e.g. d = 1 for Minimum Dominating Set). In Section 4 we argue that as a function of rank-width (rw ) the runtime
Fast algorithms for vertex subset and vertex partitioning problems
2
3
2
is O∗ (2dO(rw ) ). As a function of cliquewidth (cw ) it is O∗ (2dO(cw ) ), but we argue that by applying ideas from [6] this can be improved to O∗ (2dO(cw) ). Any of these runtimes constitute an
improvement of previously known algorithms by significant orders of magnitude, in particular compared to the algorithms parameterized by clique-width given in [15]. The paper [15] addresses a
general class of vertex subset and vertex partitioning problems almost identical to the class of
problems addressed in this paper. For the identical problems the algorithms in [15] have runtimes
containing a factor double exponential in the clique-width, i.e. triple exponential in rank-width or
boolean-width.
2
Framework
Let G be a graph with vertex set V (G) and edge set E(G). We are interested in the following
problems as defined in [22].
Definition 1. Let σ and ρ be finite or co-finite subsets of natural numbers. A subset X of vertices
of a graph G is a sigma-rho set, or simply (σ, ρ)-set, of G if
σ if v ∈ X,
∀v ∈ V (G) : |N (v) ∩ X| ∈
ρ if v ∈ V (G) \ X.
The vertex subset problems consist of finding the size of a minimum or maximum (σ ,ρ)-set in
G. Several NP-hard problems are expressible in this framework, e.g., Max Independent Set({0} ,
N), Min Dominating Set(N, N \ {0} ), Max Strong Stable Set({0} , {0, 1} ), Max or Min Perfect
Code({0} , {1} ), Min Total Dominating Set(N\{0} , N\{0} ), Max or Min Independent Dominating
Set({0} , N \ {0} ) and Min Perfect Dominating Set(N, {1} ). Also if we let Mk = {1, 2, . . . k} then
Min k -Dominating Set(N, N \ Mk ), Max Induced k -Regular Subgraph({k} , N) and Max Induced
k -Bounded Degree Subgraph(Mk , N), (refer to [22] for further details and a more complete list).
This framework is extendible to problems asking for a partition of V (G) into q classes, with each
class satisfying a certain (σ, ρ)-property, as follows.
Definition 2. A degree constraint matrix Dq is a q by q matrix with entries being finite or
co-finite subsets of natural numbers. A Dq -partition in a graph G is a partition {V1 , V2 , ..., Vq } of
V (G) such that for 1 ≤ i, j ≤ q we have ∀v ∈ Vi : |N (v) ∩ Vj | ∈ Dq [i, j].
The vertex partitioning problems for which we give algorithms in this paper consist of deciding
if G has a Dq partition, the so-called ∃Dq problem. NP-hard problems fitting into this framework
include e.g. for any fixed graph H the problems known as H -Coloring or H -Homomorphism (with
q -Coloring being Kq -Coloring), H -Covering, H -Partial Covering, and in general the question of
deciding if an input graph has a partition into q (σ, ρ)-sets, which is in most cases NP-hard
already for either q = 2 or q = 3 [16] (refer to [22] for further details and a more complete list
of problems expressible as ∃Dq problems). Let us mention that extending the algorithms we give
here to handle also the case of finding an extremal value (maximum or minimum) of the cardinality
of a vertex partition class over all Dq -partitions is quite straightforward. An efficient technique to
solve these problems makes use of dynamic programming on graph decompositions, done e.g. in [22]
based on tree decompositions and parameterized by tree-width, and in [15] based on clique-width
expressions and parameterized by clique-width. With some abuse in terminology, let a subcubic
tree be an unrooted tree where all internal nodes have degree three.
Definition 3 (Decomposition tree). A decomposition tree of a graph G is a pair (T, δ) where
T is a subcubic tree having n = |V (G)| leaves and δ is a bijection between the vertices of G and
the leaves of T .
Roughly, trees with their leaves in a bijection with the vertices of G are important for techniques like divide-and-conquer or dynamic programming since they show how to “divide” the graph
instance into several sub-instances and recurse. An alternative is to use rooted binary trees instead
4
B.-M. Bui-Xuan, J. A. Telle, and M. Vatshelle
of subcubic trees, like in clique-width expressions or modular decomposition. In this paper, we only
address unrooted trees, and the question of performing dynamic programming along them. Clearly,
any tree with the right number of leaves and a bijection can be considered as a decomposition tree.
Then, a common technique to select those that are more suited for some task is to use an evaluating
function. A set function f : 2V → R is symmetric if f (A) = f (V \ A) for all A ⊆ V (G). A cut
function of a graph G is a symmetric function over the vertex subsets of G and will also be seen
as a function over all cuts {A, V (G) \ A} of G.
Definition 4 (Decomposition and width parameters). Let f be a cut function of a graph
G, and (T, δ) a decomposition tree of G. For every edge uv in T , {Xu , Xv } denotes the 2partitions of V (G) induced by the leaf sets of the two subtrees we get by removing uv from T .
The f -width of (T, δ) is the maximum value of f (Xu ), taken over every edge uv of T . An optimal
f -decomposition of G is a decomposition tree of G having minimum f -width. The f -width of G
is the f -width of an optimal f -decomposition of G.
When a decomposition tree of G is given, we provide in Section 3 dynamic programming
algorithms to solve on G all vertex subset and vertex partitioning problems as defined above. The
ideas generalize the ideas of [6], a consequence is that the complexity depends on the boolean-width
of the decomposition tree used. Accordingly, we are interested in decomposition trees optimal w.r.t.
boolean-width. Boolean-width is formally defined as follows.
Definition 5 (Boolean-width). The boolean-cut function cut-bool : 2V (G) → R of a graph G
is defined as
cut-bool(A) = log2 |{X ⊆ A : ∃Y ⊆ B ∧ N (Y ) \ B = X}|, where B = V (G) \ A.
It is known from Boolean matrix theory that cut-bool is symmetric [19, Theorem 1.2.3]. The
boolean-width decompositions and parameters of G refer to those of Definition 4 when f =
cut-bool . The cut-bool -width of G will be called the boolean-width of G and denoted by boolw(G).
Notice for any graph G on n vertices that 0 ≤ boolw(G) ≤ n. For a vertex subset A, the value
of cut-bool(A) can also be seen as the logarithm in base 2 of the number of pairwise different
vectors that are spanned – via Boolean sums – by the rows (resp. columns) of the A × V (G) \ A
submatrix of the adjacency matrix of G.
3
Algorithms
Let a graph G and a decomposition tree (T, δ) of G be given as input. We consider in the upcoming
section the problem of computing the size of a minimum or maximum (σ ,ρ)-set in G, the so-called
vertex subset problems (see Definition 1). The subsequent section is devoted to vertex partitioning
problems (see Definition 2). All solutions we give will follow the dynamic programming algorithmic
framework (refer to, e.g., [9] for details).
To this aim, we subdivide an arbitrary edge of T to get a new root node r , and denote by Tr
the resulting rooted tree. The algorithms will follow a bottom-up traversal of Tr . With each node
w of Tr we associate a table data structure Tab w , that will store optimal solutions to subproblems
related to Vw , the set of vertices of G mapped to the leaves of the subtree of Tr rooted at w . From
the perspective of an efficient runtime, each index of the table will be associated with a certain
class of equivalent subproblems that we need to define depending on the problem on which we are
focusing.
3.1
Dynamic programming for vertex subset problems
Let d(N) = 0 . For every finite or co-finite set µ ⊆ N, let d(µ) = 1 + min(maxx∈N x : x ∈
µ, maxx∈N x : x ∈
/ µ). We denote by d(σ, ρ), or simply by d when it appears clearly in the context
Fast algorithms for vertex subset and vertex partitioning problems
5
that σ and ρ are involved, the value d = d(σ, ρ) = max(d(σ), d(ρ)). Note that when checking if a
subset A of vertices is a (σ, ρ)-set, as in Definition 1, it suffices to count the number of neighbors
up to d that a vertex has in A. This is the key to getting fast algorithms and motivates by the
following equivalence relation.
Definition 6 (d-neighbor equivalence). Let G be a graph and A ⊆ V (G) a vertex subset of
G. Denote by A the vertex set V (G) \ A. Two vertex subsets X ⊆ A and X ′ ⊆ A are d-neighbor
equivalent w.r.t. A, denoted by X ≡dA X ′ , if ∀v ∈ A : |N (v) ∩ X| = |N (v) ∩ X ′ | ∨ |N (v) ∩ X| ≥ d ∧ |N (v) ∩ X ′ | ≥ d .
Definition 7. Let G be a graph, A ⊆ V (G), and µ ⊆ N. For X ⊆ V (G), set X µ-dominates A
if ∀v ∈ A : |N (v) ∩ X| ∈ µ. For X ⊆ A, Y ⊆ A , the pair (X, Y ) σ, ρ-dominates A if (X ∪ Y )
σ -dominates X and (X ∪ Y ) ρ-dominates A \ X .
For simplicity, consider first the effect of simply using any X ⊆ A and Y ⊆ A and defining
def
T abw [X][Y ] = optS⊆Vw {|S| : S ≡dVw X and (S, Y ) σ, ρ-dominates Vw } , where opt stands for
function min or max, accordingly. Then, at the root r of Tr the value of T abr [X][∅] (for all
X ⊆ V (G)) would be exactly equal to the size of a maximum, resp. minimum, (σ, ρ)-set of G (c.f.
≡dVr has only one equivalence class). Accordingly, a bottom-up computation of Tab r would be
sufficient to solve the vertex subset problem. However, the sizes of the tables would then depend
on |V (G)|. We first show that using d-neighbor equivalence classes we lower the size of the tables
to a function not depending on |V (G)|. Clearly, if X ≡dVw X ′ , then the values of T abw [X][Y ] and
T abw [X ′ ][Y ] are the same (for all Y ). Hence, for each equivalence class of ≡dVw , we only need to
keep one representative entry in T abw for all the members of that class, thus reducing the number
of entries in T abw to the number of equivalence classes of ≡dVw times the number of equivalence
classes of ≡dV . Recall that Vw denotes V (G) \ Vw .
w
Lemma 1. Let G be a graph and A ⊆ V (G). Then, for every X ⊆ A, there is R ⊆ A such that
R ≡dA X and |R| ≤ d × cut-bool(A). Moreover, the number of equivalence classes of ≡dA is bounded
2
by 2d×cut-bool(A) .
Proof We start with the first part namely bounding the size of the minimal members. Let R = X ,
go through all vertices x ∈ X and delete x from R if R \ {x} ≡dA X . Notice that R ⊆ X and
R ≡dA X and hence fulfill two of the requirements.
We then know that ∀x ∈ R ∃y ∈ N (x) \ A : |N (y) ∩ X| ≤ d, this since otherwise R \ {x} ≡dA X .
We build a set S as follows:
Let S = ∅ , R′ = R . While you can find a pair x ∈ R′ , y ∈ A such that |N (y) ∩ R′ | ≤ d and
x ∈ N (y). Remove N (y) from R′ , add x to S .
Note that all the x’s and y ’s chosen are different since you remove the neighborhood of y from
R′ and that you can always find such a set unless R′ = ∅ . Therefore we know |S| ≥ |R|/d since
we remove at most d nodes in each step. Any of the 2|S| combinations of elements from S will
form a unique neighborhood. Therefore, from the definition of the boolean-cut function we get
cut-bool(A) = cut-bool(A) ≥ |S|. Since |S| ≥ |R|/d, R fulfill the last requirement.
To bound the number of equivalence classes we know from the previous arguments that we only
need to find the equivalence classes among the subsets of A of size at most d × cut-bool(A). Let H
be obtained from the bipartite subgraph of G with color classes A, A after doing twin contraction
of all twins and adding an isolated vertex to each color class unless there already is one. We know
that every node of V (H) ∩ A has a unique neighborhood, hence |V (H) ∩ A| ≤ 2cut-bool(A) . Any
subset of A is a multiset of |V (H) ∩ A|, and a trivial bound on number of multisets of |V (H) ∩ A|
2
with size d×cut-bool(A) gives us: number of equivalence classes less than or equal to 2d×cut-bool(A) .
We now define the canonical representative candVw (X) of every subset X ⊆ Vw , and the canonical representative candV (Y ) of every subset Y ⊆ Vw . For simplicity we define this using Vw instead
w
6
B.-M. Bui-Xuan, J. A. Telle, and M. Vatshelle
of a generic subset A, but note that everything we say about X ⊆ Vw , candVw (X) and ≡dVw will
hold also for candV (Y ), Y ⊆ Vw and ≡Vd . Canonical representatives are to be used for indexing
w
w
the table T abw at node w of the tree Tr . Three properties will be required. Firstly, if X ≡dVw X ′ ,
then we must obviously have candVw (X) = candVw (X ′ ). Secondly, given (X, Y ), we should have a
fast routine that outputs a pointer to the entry T abw [candVw (X)][canVd (Y )]. Thirdly, we should
w
have a list whose elements can be used as indices of the table, i.e. a list containing all canonical
representatives w.r.t. ≡dVw . The following definition trivially fulfills the first requirement.
Definition 8. Let a total ordering of the vertices of V (G) be given, used to define a lexicographical
ordering on subsets of vertices. For every X ⊆ Vw , the canonical representative candVw (X) is
defined as the lexicographically smallest set R ⊆ Vw such that: |R| is minimized and R ≡dVw X .
Definition 9. Let opt stand for either function max or function min, depending on whether
we are looking for a maximum or minimum (σ, ρ)-set, respectively. For every node w of Tr , for
X ⊆ Vw and Y ⊆ Vw , let RX = candVw (X) and RY = candV (Y ). We define the contents of
w
Tab w [RX ][RY ] as:
optS⊆Vw {|S| : S ≡dVw X and (S, Y ) σ, ρ-dominates Vw },
def
T abw [RX ][RY ] = −∞ if no such set S exists and opt = max,
+∞ if no such set S exists and opt = min.
Lemma 2. For every node w of Tr , a list containing all canonical representatives w.r.t. ≡dVw
2
can be output in O(m + d ∗ cut-bool(Vw ) × 22d∗cut-bool(Vw ) +cut-bool(Vw ) ) time. And for every subset
X ⊆ Vw , a pointer to candVw (X) in that list can be computed in O(|X| × 2cut-bool(Vw ) ) time.
Proof Let H be obtained from the bipartite subgraph of G with color classes A, A after doing
twin contraction of all twins and and adding an isolated vertex to each color class unless there
already is one. This we obtain from an external module partition which can be computed in
O(|E(G)|) time [8]. We know from the proof of Lemma 1 that |V (H) ∩ Vw | ≤ 2cut-bool(Vw ) .
Combining Lemma 1 with the fact that a canonical representative is chosen among the sets of
minimal size belonging to that equivalence class, we know that the size of any representative is no
more than d ∗ cut-bool(Vw ). Knowing this we see that it is possible to loop through all sets of size
less than or equal to the largest representative.
A list C will be used in order to store the canonical representatives. We will later want to
access T abw [candVw (X)], so in the list C we will store pairs, one being the set of vertices that
actually appear in candVw (X), and the other being a certain index. And we make one big table
M indexed by all subsets of size at most d ∗ cut-bool(Vw ). For each entry in M we will store a
pointer its representative in C . So given a set X : |X| ≤ d ∗ cut-bool(Vw ), M [X] will return both
the canonical representative and its index.
To check if two sets X and Y are equivalent we find their neighborhoods and see if they are
equal up to d neighbors. Hence it can be done in O((|X| + |Y |)2cut-bool(Vw ) ) time.
Algorithm for computing the list C :
Set index = 0 . We first loop over all sets X of size at most d ∗ cut-bool(Vw ). To make sure we
find the representatives as described in the definition of canonical representatives, we loop over
smaller sets first, and in lexicographically order among those with same size. Then we loop over
all sets R ∈ C and check if X ≡dA R , if so M [X] points to R . If no R ∈ C is equivalent to X ,
add X, index to C , increase index and M [X] points to X .
2
2
In total this becomes O(m + 2d∗cut-bool(Vw ) 2d∗cut-bool(Vw ) 2d ∗ cut-bool(Vw ))2cut-bool(Vw ) ) =
2
O(m + 22d∗cut-bool(Vw ) +cut-bool(Vw ) d ∗ cut-bool(Vw )) time.
To compute candVw (X): Let X ′ = X first go through all vertices x ∈ X and delete x from X ′
if X ′ \ {x} ≡dVw X . As we showed in proof of Lemma 1 we can now assume |X ′ | ≤ d ∗ cut-bool(Vw ).
Now we look up in M and find a pointer to both the canonical representative and the index. This
means candVw (X) can be computed in O(|X|2cut-bool(Vw ) ) time.
Fast algorithms for vertex subset and vertex partitioning problems
7
For every node w (either an internal node or a leaf), our algorithm first computes the list of
canonical representatives w.r.t. ≡dVw , as well as that w.r.t. ≡dV . Then, the two-dimensional table
w
T abw is defined using these two lists. For initialization, the value of every entry of T abw will be
set to +∞ or −∞ depending on whether we are solving a minimization or maximization problem,
respectively.
Updating the leaves: for a leaf l of Tr , for simplicity denote the vertex of G mapped to l by
l . For A = {l} , note that ≡dA has only two equivalence classes: one containing ∅ and the other
containing A. For B = A, we have that two members of an equivalence class of ≡dB must contain
the same the number (from 0 , 1 , . . . , d− 1 , ≥ d) of vertices that are neighbors of l (and thus Tab l
has at most 2 × (d + 1) entries). Accordingly, the following update is correct: for every canonical
representative R w.r.t. ≡dB , do
– If |N (l) ∩ R| ∈ σ then T abl [A][R] = 1 .
– If |N (l) ∩ R| ∈ ρ then T abl [∅][R] = 0 .
Updating the internal nodes: for a node w of Tr with children a and b , the algorithm
performs the following steps. For every canonical representative Rw w.r.t. ≡Vd , for every canonical
w
representative Ra w.r.t. ≡dVa , and for every canonical representative Rb w.r.t. ≡dVb , do:
– Compute Rw = candVw (Ra ∪ Rb ), Ra = candV (Rb ∪ Rw ) and Rb = candV (Ra ∪ Rw )
a
b
– Update Tab w [Rw ][Rw ] = opt(Tab w [Rw ][Rw ], Tab a [Ra ][Ra ] + Tab b [Rb ][Rb ]).
Lemma 3. The table at node w is updated correctly, namely for any canonical representatives Rw
and Rw w.r.t. ≡dVw and ≡dV , if T abw [Rw ][Rw ] is not ±∞ then
w
Tab w [Rw ][Rw ] = optS⊆Vw {|S| : S ≡dVw Rw ∧ (S, Rw ) σ, ρ-dominates Vw }.
If the value of the table is ±∞ then there is no such above set S .
Proof Let a, b be the children of w in Tr , assume Tab a and Tab b are correct. We first show
that if Tab w [Rw ][Rw ] = s and hence not ±∞, then there exists a set Sw satisfying all the
conditions. For a value of Tab w to be set to s, it means that an update happened in the algorithm,
hence there exist Ra and Rb such that: Ra = candV (Rb ∪ Rw ) ,Rb = canVd (Ra ∪ Rw ) and
a
b
Tab a [Ra ][Ra ] + Tab b [Rb ][Rb ] = s. Then we know that there exist Sa and Sb such that (Sa , Ra )
σ, ρ-dominates Va and (Sb , Rb ) σ, ρ-dominates Vb and that |Sa ∪ Sb | = s. Let Sw = Sa ∪ Sb , then
Sw fulfills the two conditions |S| = s and Rw ≡dVw Sw , now we need to show that (Sw , Rw ) σ, ρdominates Vw . Since (Sb ∪ Rw ) ≡dVa Ra and (Sa , Ra ) σ, ρ-dominates Va it follows from Definition
6 and 7 that (Sa , Sb ∪ Rw ) σ, ρ-dominates Va , this is left as an exercise for the reader. Similarly we
conclude that (Sb , Sa ∪ Rw ) σ, ρ-dominates Vb Let S = Sw ∪ Rw = Sa ∪ Sb ∪ Rw then we get S σ dominates Va and S σ -dominates Vb , hence it follows from Definition 7 that S σ -dominates Vw .
Similarly we get S ρ-dominates Va and S ρ-dominates Vb , hence S ρ-dominates Vw . Combining
the two last facts it follows from definition 7 that (Sw , Rw )σ, ρ-dominates Vw .
Next we will ∀Rw , Rw show that if there exist an optimal set Sw ≡dVw Rw such that (Sw , Rw )
σ, ρ-dominates Vw , then Tab w [candVw (Sw )][Rw ] = |Sw |. Let Sa = Sw ∩ Va and Sb = Sw ∩ Vb .
Since the algorithm goes through all triples of representatives, it will at some point go through
(Ra , Rb , Rw ), where Ra = candVa (Sa ) and Rb = candVb (Sb ). Since (Sw , Rw ) σ, ρ-dominates Vw ,
(Sa ∪ Sb ∪ Rw ) σ -dominates Vw and (Sa ∪ Sb ∪ Rw )ρ-dominates Vw . Then (Sa , Sb ∪ Rw ) σ, ρdominates Va and (Sb , Sa ∪ Rw ) σ, ρ-dominates Vb . Since in the algorithm Ra = candVa (Sb ∪ Rw ),
(Sa , Ra ) σ, ρ-dominates Va . Similarly we get that (Sb , Rb ) σ, ρ-dominates Vb . Since Sw is the
optimal Sa , Sa and Sb , Sb must be optimal too, this means that Tab a [Ra ][Ra ] + Tab b [Rb ][Rb ] =
|Sa ∪ Sb | = |Sw |, hence Tab w [Rw ][Rw ] = |Sw |.
By induction all tables will be correct.
Theorem 1. For every n-vertex, m-edge graph G given along with a decomposition tree (T, δ),
any vertex subset problem on G can be solved in
2
O(n(m + d ∗ boolw(T, δ)23d∗boolw(T,δ) +boolw(T,δ) )) time, where d stands for d(σ, ρ).
8
B.-M. Bui-Xuan, J. A. Telle, and M. Vatshelle
Proof The correctness proof follows directly from all what has been said in this section. As for
complexity analysis, for every node w of Tr , we basically: call the first computation of Lemma 2
one time; then loop through every triplet of equivalence classes and call the second computation
of Lemma 2 three times.
Remark 1. For most of the vertex subset problems, including all problems mentioned after Definition 1 (except for those having a parameter k ), we have that either d = 1 or d = 2 . More precisely,
d = 1 for Max Independent Set, Min Dominating Set, Min Total Dominating Set and Max or Min
Independent Dominating Set, and d = 2 for Max Strong Stable Set, Max or Min Perfect Code and
Min Perfect Dominating Set.
3.2
Dynamic programming for vertex partitioning problems
This section addresses ∃Dq problems (see Definition 2). We use similar techniques as those for
vertex subset problems. Recall that d(N) = 0 , and for every finite or co-finite set µ ⊆ N, d(µ) =
1 + min(maxx∈N x : x ∈ µ, maxx∈N x : x ∈
/ µ). Let d = d(Dq ) = maxi,j d(Dq [i, j]).
Definition 10. Let G be a graph and let A ⊆ V (G) be a vertex subset of G. Two q -tuples
(X1 , X2 , ..., Xq ) and (Y1 , Y2 , ..., Yq ) of subsets of A are equivalent, denoted by (X1 , X2 , ..., Xq ) ≡q,d
A
(Y1 , Y2 , ..., Yq ), if
∀i∀v ∈ A : (|N (v) ∩ Xi | = |N (v) ∩ Yi |) ∨ (|N (v) ∩ Xi | > d ∧ |N (v) ∩ Yi | > d).
d
Lemma 4. (X1 , X2 , ..., Xq ) ≡q,d
A (Y1 , Y2 , ..., Yq ) if and only if ∀iXi ≡A Yi . A consequence is that
q,d
d
the number of equivalence classes of ≡A is at most that of ≡A to the power q .
The lemma follows directly from Definitions 6 and 10. In the sequel we will define the values
of T abw directly indexed by the equivalence classes. For this we need to first define canonical
representatives. For a node w of Tr , and X = (X1 , X2 , ..., Xq ) : Xi ⊆ Vw , we define canq,d
Vw (X ) =
d
d
d
(canVw (X1 ), canVw (X2 ), ..., canVw (Xq )).
Definition 11. Let G be a graph and A ⊆ V (G). Let X = (X1 , X2 , ..., Xq ) ∈ Aq and Y =
q
(Y1 , Y2 , ..., Yq ) ∈ A . We say that (X , Y) Dq -dominates A if for all i, j we have that (Xj ∪
Yj ) Dq [i, j]-dominates Xi (c.f. Definition 7).
Definition 12. For every node w of Tr , for every X = (X1 , X2 , ..., Xq ) ∈ Aq and every Y =
q
q,d
(Y1 , Y2 , ..., Yq ) ∈ A , let RX = canq,d
Vw (X ) and RY = canVw (Y). We define the contents of
Tab w [RX ][RY ] as
if ∃ partition S = (S1 , S2 , ..., Sq ) of Vw such that:
T RU E
def
T abw [RX ][RY ] =
S ≡q,d
Vw RX and (S, RY ) Dq -dominates Vw
F ALSE otherwise.
The solution to the ∃Dq -problem is given by checking if some entry in the table at the root has
value T RU E . The computation of the list of all canonical representatives w.r.t. ≡q,d
Vw is basically
q times the one given in the previous section. The same situation holds for the computation of a
canonical representative from the input of a q -uplet. Firstly, initialize all values in all tables to
F ALSE .
Updating the leaves: for a leaf l of Tr , like before, we abusively denote the vertex of G mapped
to l by l , and denote A = {l} . Firstly, there are q possible classes l could belong to in a q -partition
of A (recall that empty sets are allowed). We call their canonical representatives respectively RX1 ,
RX2 , . . . , RXq . Secondly, for vertices in B = V (G) \ {l} note that they are either neighbors of
l or not. Hence we have at most d + 1 choices (namely 0, 1, ..., d − 1 , ≥ d) for each of the q
Fast algorithms for vertex subset and vertex partitioning problems
9
partition classes. (A consequence is that Tab l has at most q(d + 1)q entries.) For every canonical
representative RY = (Y1 , Y2 , . . . , Yq ) w.r.t. ≡q,d
B , we have that (RXi , RY ) Dq -dominates {l} if
and only if ∀j|N (l) ∩ Yj | ∈ Dq [i, j]. Accordingly, we perform the following update for every i and
for every RY :
Tab l [RXi ][RY ] is set to be T RU E if and only if ∀j |N (l) ∩ Yj | ∈ Dq [i, j].
S
Updating the internal node: in the following, q denotes the componentwise union of two
q -tuples. For a node w with children a and b , the algorithm performs the following steps. For
every canonical representative Rw w.r.t. ≡Vq,d , for every canonical representative Ra w.r.t. ≡q,d
Va ,
w
and for every canonical representative Rb w.r.t. ≡q,d
Vb , do:
S
S
S
q,d
q,d
– Compute Rw = canq,d
Vw (Ra
q Rb ), Ra = canVa (Rb
q Rw ), Rb = canVb (Ra
q Rw )
– If Tab w [Rw ][Rw ] = F ALSE then Tab w [Rw ][Rw ] = Tab a [Ra ][Ra ] ∧ Tab b [Rb ][Rb ]
Theorem 2. For every n-vertex, m-edge graph G given along with a decomposition tree (T, δ),
2
any Dq -problem on G can be solved in O(n(m + qd ∗ boolw(T, δ)23qd∗boolw(T,δ) +boolw(T,δ) )) time,
where d stands for d(Dq ).
Proof The complexity analysis is very similar to the one given in Theorem 1. The correctness
proof follows the same style as the proof of Lemma 3, Some steps are not explained here because
they were explained in Lemma 3.
For the correctness, let a, b be the children of w in Tr , assume Tab a and Tab b are correct.
(⇒) For this direction of the proof we have that Tab w [Rw ][Rw ] = T RU E . Then there must
exist someSRa , Rb such that Tab a [Ra ][R
Sa ] = T RU E and Tab b [Rb ][Rb ] = T RU E , where Ra =
candVa (Rb q Rw ) and Rb = candVb (Ra q Rw ). Hence there exists Sa partition of Va and Sb
partition of Vb such that (Sa , Ra ) Dq -dominates Va (Sb , Rb ) Dq -dominates Vb . This means that
∀i, j : (Saj ∪ Raj ) Dq [i, j]-dominates Sai and ∀i, j : (Sbj ∪ Rbj ) Dq [i, j]-dominates Sbi . It then
follows that: ∀i, j : (Saj ∪ Sbj ∪ Rwj ) Dq [i, j]-dominates Sai and ∀i, j : (Saj ∪ Sbj ∪ Rwj ) Dq [i, j]dominates Sbi . It then follows that: ∀i, j : (Swj ∪ Rwj ) Dq [i, j]-dominates Swi . Which means
(S, Rw ) Dq -dominates Vw .
(⇐) For this direction of the proof we have that there exists a partition S = (S1 , ...Sq ) of Vw
such that: (S, Rw ) Dq -dominates Vw . This means that ∀i, j : (Swj ∪ Rwj ) Dq [i, j]-dominates Swi .
Let Sa , Sb be the componentwise intersection of Sw with Va and Vb respectively. We then have:
∀i, j : (Swj ∪ Rwj ) Dq [i, j]-dominates Sai and ∀i, j : (Swj ∪ Rwj ) Dq [i, j]-dominates Sbi . Hence
∀i, j : (Saj ∪ Sbj ∪ RwSj ) Dq [i, j]-dominates Sai and
S ∀i, j : (Saj ∪ Sbj ∪ Rwj ) Dq [i, j]-dominates Sai .
Let Ra = canVd (Sb q Rw ) and Rb = candV (Sa q Rw ) then ∀i, j : (Saj ∪ Raj ) Dq [i, j]-dominates
a
b
Sai and ∀i, j : (Sbj ∪ Rbj ) Dq [i, j]-dominates Sbi . Let Ra = candVa (Sa ) and Rb = candVb (Sb ) then
Tab a [Ra ][Ra ] = T RU E and Tab b [Rb ][Rb ] = T RU E . Since the algorithm goes through all triples,
it will at some point go through (Ra , Rb , Rw ). And it will set Tab w [Rw ][Rw ] to true, once it is
true it will never change.
By induction all tables will be correct.
Remark 2. For most of the vertex partitioning problems, including all problems mentioned after
Definition 2, we have that either d = 1 or d = 2 . More precisely, d = 1 for H -Homomorphism,
and d = 2 for H -Covering and H -Partial Covering.
4
Extensions
2
The runtime of our algorithms for vertex subset problems is O∗ (2dO(boolw ) ). We know that
the boolean-width of a graph is at most its rank-width squared (rw2 )[6] and never more than
its cliquewidth (cw ). By plugging in those bounds we get that our algorithms have runtime
10
B.-M. Bui-Xuan, J. A. Telle, and M. Vatshelle
4
2
O∗ (2dO(rw ) ) and O∗ (2dO(cw ) ). However, a careful analysis shows that our algorithms actually
2
have runtime O∗ (2dO(rw ) ). Moreover, using a careful analysis combined with an extension of ideas
from [6] we also get runtime O∗ (2dO(cw) ).
Let us first argue for rank-width. The main runtime bottleneck is bounding the number of dneighbor equivalence classes, which we bound by the number of twin-classes raised to the size of the
largest representative. Clearly, there are at most min(2rw , 2boolw ) twin classes, and we bounded
the size of the representatives by d × boolw in Lemma 1, but it is straightforward to adapt the
proof of that Lemma to obtain also a d × rw bound. This has been done in [7] but for simplicity
of exposition we did not include it in this extended abstract.
For cliquewidth (cw ) we can do something similar. Firstly, the number of twin classes is bounded
by cw . Secondly, since a d-neighborhood equivalence class can be seen as a vector, of length the
number of twin classes, having d+1 possible values for every element of the vector (cf. Definition 6)
we get that the number of equivalence classes is bounded by (d+ 1)cw . Thirdly, we can improve the
runtime in Lemma 2 to O∗ (2dO(cw) ) by extending the faster algorithm computing representatives
from [6].
5
Conclusion and Perspectives
For problems where d = 1 we can in fact improve the runtime of our algorithms for vertex subset
problems to O∗ (2O(boolw) ) [6], but that requires a special focus on those cases. In this paper
we have instead focused on a much more general class of vertex subset and vertex partitioning
problems. Maybe a tighter analysis can actually show that the algorithms given here have runtime
O∗ (2dO(boolw) ) (alternatively O∗ (2dO(boolw log boolw) )) for all vertex subset problems. However, one
must then show that the number of d-neighbor equivalence classes is no more than the number of
1 -neighbor equivalence classes raised to some function of d (alternatively raised to some function
of d times log log boolw ). This question can be formulated as a purely algebraic one as follows:
First generalize the concept of Boolean sums (1+1=1) to d-Boolean-sums (i + j = min(i + j, d)).
For a Boolean matrix A let Rd (A) be the set of vectors over {0, 1, ..., d} that arise from all possible
d-Boolean sums of rows of A. Is there a function f such that |Rd (A)| ≤ |R1 (A)|f (d) (alternatively
such that |Rd (A)| ≤ |R1 (A)|f (d) log log |R1 (A)| )?
In general, it would be interesting to investigate which are the graph problems that can be
solved efficiently in function of boolean-width, like what has be done in this paper. About the
relationship between boolean-width and other parameters, it would be interesting to investigate
the graphs where boolean-width is exponentially smaller than rank-width (hence also exponentially
smaller than clique-width, tree-width and branch-width), like what has been done for the so-called
Hsu-grid graphs [6]. It would also be nice to know whether there is a better upper bound in term
of rankwidth (is it true that boolean-width is never larger than rankwidth), or a counter-example
to any bound of this type.
References
1. I. Adler, B.-M. Bui-Xuan, G. Renault, and M. Vatshelle. Boolean-width is less than or equal to
branch-width. in preparation.
2. H. Bodlaender. Dynamic programming on graphs with bounded treewidth. In 15th International
Colloquium on Automata, Languages and Programming (ICALP’88), volume 317 of LNCS, pages 105–
118, 1988.
3. H. Bodlaender. A linear-time algorithm for finding tree-decompositions of small treewidth. SIAM
Journal on Computing, 25(6):1305–1317, 1996. Abstract at STOC’93.
4. H. Bodlaender and A. Koster. Treewidth Computations I Upper Bounds. Technical Report UU-CS2008-032, Department of Information and Computing Sciences, Utrecht University, 2008.
5. H. Bodlaender and D. Thilikos. Constructive linear time algorithms for branchwidth. In 24th International Colloquium on Automata, Languages and Programming (ICALP’97), volume 1256 of LNCS,
pages 627–637, 1997.
Fast algorithms for vertex subset and vertex partitioning problems
11
6. B.-M. Bui-Xuan, J. A. Telle, and M. Vatshelle. Boolean-width of graphs. to appear in Proceedings
IWPEC 2009. http://www.ii.uib.no/~telle/bib/BTV09I.pdf.
7. B.-M. Bui-Xuan, J. A. Telle, and M. Vatshelle. Fast FPT algorithms for vertex subset and vertex
partitioning problems using neighborhood unions. http://arxiv.org/abs/0903.4796.
8. B.-M. Bui-Xuan, J. A. Telle, and M. Vatshelle. H -join decomposable graphs and algorithms with
runtime single exponential in rankwidth. to appear in DAM: special issue of GROW.
http://www.ii.uib.no/~telle/bib/BTV.pdf.
9. T. Cormen, C. Leiserson, R. Rivest, and C. Stein. Introduction to algorithms. MIT Press, Cambridge,
MA, second edition, 2001.
10. D. Corneil and U. Rotics. On the relationship between clique-width and treewidth. SIAM Journal on
Computing, 34(4):825–847, 2005.
11. F. Dorn, F. Fomin, and D. Thilikos. Subexponential parameterized algorithms. In 34th International
Colloquium on Automata, Languages and Programming (ICALP’07), pages 15–27, 2007.
12. R. Downey and M. Fellows. Parameterized Complexity. Springer Verlag, 1999.
13. J. Flum and M. Grohe. Parameterized Complexity Theory. Springer Verlag, 2006.
14. R. Ganian and P. Hliněný. On Parse Trees and Myhill-Nerode-type Tools for handling Graphs of
Bounded Rank-width. submitted manuscript.
http://www.fi.muni.cz/~hlineny/Research/papers/MNtools-2.pdf.
15. M. Gerber and D. Kobler. Algorithms for vertex-partitioning problems on graphs with fixed cliquewidth. Theoretical Computer Science, 299(1-3):719–734, 2003.
16. P. Heggernes and J. A. Telle. Partitioning graphs into generalized dominating sets. Nordic Journal of
Computing, 5(2):128–142, 1998.
17. P. Hliněný and S. Oum. Finding branch-decompositions and rank-decompositions. SIAM Journal on
Computing, 38(3):1012–1032, 2008. Abstract at ESA’07.
18. P. Hliněný, S. Oum, D. Seese, and G. Gottlob. Width parameters beyond tree-width and their applications. The Computer Journal, 51(3):326–362, 2008.
19. K. H. Kim. Boolean matrix theory and its applications. Marcel Dekker, 1982.
20. D. Kobler and U. Rotics. Edge dominating set and colorings on graphs with fixed clique-width. Discrete
Applied Mathematics, 126(2-3):197–221, 2003. Abstract at SODA’01.
21. S. Oum and P. Seymour. Approximating clique-width and branch-width. Journal of Combinatorial
Theory, Series B, 96(4):514–528, 2006.
22. J. A. Telle and A. Proskurowski. Algorithms for vertex partitioning problems on partial k -trees. SIAM
Journal on Discrete Mathematics, 10(4):529–550, 1997.
© Copyright 2026 Paperzz