Algorithms for finding maximum transitive subtournaments

Transcription

Algorithms for finding maximum transitive subtournaments
Journal of Combinatorial Optimization manuscript No.
(will be inserted by the editor)
Algorithms for finding maximum transitive
subtournaments
¨
Lasse Kiviluoto · Patric R. J. Osterg˚
ard ·
Vesa P. Vaskelainen
Received: date / Accepted: date
Abstract The problem of finding a maximum clique is a fundamental problem for undirected graphs, and it is natural to ask whether there are analogous
computational problems for directed graphs. Such a problem is that of finding
a maximum transitive subtournament in a directed graph. A tournament is an
orientation of a complete graph; it is transitive if the occurrence of the arcs xy
and yz implies the occurrence of xz. Searching for a maximum transitive subtournament in a directed graph D is equivalent to searching for a maximum
induced acyclic subgraph in the complement of D, which in turn is computationally equivalent to searching for a minimum feedback vertex set in the
complement of D. This paper discusses two backtrack algorithms and a Russian doll search algorithm for finding a maximum transitive subtournament,
and reports experimental results of their performance.
Keywords backtrack search · clique · directed acyclic graph · feedback
vertex set · Russian doll search · transitive tournament
1 Introduction
The maximum clique problem has attracted a lot of attention along the years;
see (Bomze et al., 1999) for an extensive survey. A clique in a graph is a set of
mutually adjacent vertices, and a maximum clique is a clique with the largest
number of vertices. The following decision problem is NP-complete: Given an
¨
L. Kiviluoto was supported by the Academy of Finland, Grant No. 100500. P.R.J. Osterg˚
ard
was supported in part by the Academy of Finland, Grants No. 107493, 110196, 130142, and
132122. V.P. Vaskelainen was supported by the Academy of Finland, Grant No. 107493
L. Kiviluoto
Celtius Ltd, Pieni Roobertinkatu 11, 00130 Helsinki, Finland
¨
P. R. J. Osterg˚
ard · V. P. Vaskelainen
Department of Communications and Networking, Aalto University School of Electrical Engineering, P.O. Box 13000, 00076 Aalto, Finland
2
¨
L. Kiviluoto, P.R.J. Osterg˚
ard, V.P. Vaskelainen
undirected graph G and an integer k as the input, determine whether there
is a clique of size k in G. In any case, much effort has been put on developing algorithms for the maximum clique problem, which has many important
applications in different fields such as bioinformatics (Butenko and Wilhelm,
2006), chemistry (Rhodes et al., 2003), and electrical engineering (Cong and
Smith, 1993), just to mention a few examples. More applications can be found
in (Bomze et al., 1999, Section 7) and (Pardalos and Xue, 1994).
The maximum clique problem concerns undirected graphs; it is therefore
natural to ask whether there are corresponding problems for directed graphs.
For a directed graph, one may obviously look at the maximum clique problem
for the underlying undirected graph or the undirected graph with an edge
{u, w} if and only if both uw and wu are arcs in the original graph. Cliques
of the latter type are called symmetric cliques. However, both of these cases
reduce to the undirected case.
In Section 2 we will use the problem of determining the capacity of communication channels to demonstrate one possible correspondence between certain
computational problems in undirected and directed graphs. This leads to the
problem of finding a maximum transitive subtournament in a directed graph,
which is computationally equivalent to the problems of finding a maximum
induced acyclic subgraph and a minimum feedback vertex set. Analogously, in
the undirected case we have the maximum clique problem, which is computationally equivalent to the problems of finding a maximum independent set
and a minimum vertex cover. Two backtrack search algorithms and a Russian
doll search algorithm for the maximum transitive subtournament problem are
discussed in Section 3. The performance of these algorithms is compared in
computational experiments in Section 4.
2 Clique-Type Problems for Directed Graphs
In this section, we consider the information-theoretic problem of determining
the capacity of certain communication channels. The purpose of discussing this
theory, which is well known (Alon, 1998; Gargano et al., 1992; K¨
orner et al.,
2005; Sali and Simonyi, 1999), is threefold. First, it provides a way of deriving
an analogue of cliques in directed graphs. Second, it provides evidence of the
importance of algorithms for such clique-type problems in directed graphs. Finally, it shows that also other types of instances of these clique-type problems
than those considered earlier are of practical interest. Moreover, for best possible practical performance, these instances require different algorithms than
previous ones; the study of such algorithms is the main topic of this work.
Consider an undirected graph G with one vertex for each input symbol of a
discrete communication channel and an edge between two vertices if and only
if the two symbols cannot lead to the same output symbol (due to channel
errors). The graph G is known as the characteristic graph of the channel.
¯ the confusion graph of
Alternatively, one may study the complement of G, G,
the channel.
Algorithms for finding maximum transitive subtournaments
3
The clique number of G = (V, E), denoted by ω(G), gives the largest set
of symbols that can be used for error-free transmission of one symbol over
the channel, and the corresponding amount of information is log2 ω(G). If
information is transmitted in blocks of size n, then the information rate is
log2 ω(Gn )
= log2 ω(Gn )1/n
n
bits per transmission, where the (co-normal) power graph Gn has the vertex
set V n = {(u1 , u2 , . . . , un ) : ui ∈ V }, and (u1 , u2 , . . . , un ) and (v1 , v2 , . . . , vn )
are connected by an edge if and only if there is an i such that {ui , vi } ∈ E.
The zero-error capacity (Shannon, 1956) of the channel is
sup log2 ω(Gn )1/n
n≥1
bits per transmission. When this problem is studied purely in the context of
graphs, one ignores the logarithm and defines the zero-error capacity of G as
sup ω(Gn )1/n .
n≥1
Gargano et al. (1992) studied directed graphs in an analogous way. With
D = (V, A) a directed graph, the (co-normal) power graph Dn has the vertex
set V n = {(u1 , u2 , . . . , un ) : ui ∈ V }, and there is an arc from (u1 , u2 , . . . , un )
to (v1 , v2 , . . . , vn ) if and only if there is an i such that ui vi ∈ A. The (nonlogarithmic) Sperner capacity of D is then
σ(D) := sup ωs (Dn )1/n ,
n≥1
where ωs (D) is the size of the maximum symmetric clique.
A transitive tournament is a directed graph (V, A) with vertex set V =
{v1 , v2 , . . . , vm } and arc set A = {vi vj : 1 ≤ i < j ≤ m}. Given a directed
graph D, a transitive subtournament, also known as a transitive clique, is a
subgraph that is a transitive tournament. As with undirected graph, it is
important to notice the difference between subgraphs and induced subgraphs.
Indeed, for any arc in a transitive subtournament, the reverse arc could exist
in D.
The size of a maximum transitive subtournament in D is denoted by ωt (D).
The importance of ωt (D) in the study of Sperner capacity is that (Gargano et
al., 1992; Sali and Simonyi, 1999)
σ(D) = sup ωt (Dn )1/n
n≥1
and as obviously ωs (D) ≤ ωt (D), determination of the size of a maximum
transitive subtournament rather than that of a maximum symmetric clique
for small powers of D may—and often does—lead to better lower bounds on
σ(D). Concrete instances for the problem of determining the size of a maximum
transitive subtournament can be found, for example, in (K¨orner et al., 2005).
4
¨
L. Kiviluoto, P.R.J. Osterg˚
ard, V.P. Vaskelainen
We shall now briefly look at some analogies with the undirected case. The
following decision problem is NP-complete (Karp, 1972; Garey and Johnson,
1979): Given a directed graph D and an integer k as the input, determine
whether there is a transitive subtournament of size k in D.
A clique in an undirected graph G corresponds to an independent set in
¯ but can something similar be said in the directed case? An answer to this
G,
question is provided by the following known graph-theoretic result.
Proposition 1 The vertex set of a transitive subtournament in D is the vertex
¯ and vice versa.
set of an acyclic induced subgraph in D,
Proof In D = (V, A), consider a vertex set V ′ ⊆ V of a transitive subtournament, justified by the ordering v1 , v2 , . . . , vm of the vertices in V ′ . In the
¯ = (V, A),
¯ there are then no arcs vi vj with 1 ≤ i < j ≤ m, so
complement D
vm , vm−1 , . . . , v1 forms a topological ordering with this particular order (from
the smallest to the largest element). Finally, we use the well-known fact that
a directed graph has a topological ordering if and only if it is acyclic (Bang¯ induced
Jensen and Gutin, 2001, Section 1.4) to see that the subgraph of D
′
by V is acyclic. This completes the proof as we have equivalences in all steps.
If S is an independent set in an undirected graph G = (V, E), then S ′ =
V \S is a vertex cover of G. For directed graphs we have the following analogy:
If S induces an acyclic graph, then S ′ = V \S covers—that is, contains a vertex
of—every cycle of G and is called a feedback vertex set.
Finally, we would like to point out that various aspects of clique-type problems, for example, considering weighted graphs, carries over naturally to the
problems for directed graphs discussed here. A final example: The chromatic
number of an undirected graph is the smallest number of independent sets
that partition the vertex set, whereas the dichromatic number (NeumannLara, 1982) of a directed graph is the smallest number of acyclic induced
subgraphs that partition the vertex set.
3 Algorithms
Bearing in mind the analogy between the discussed problems for undirected
and directed graphs, there is an interesting contrast in the established research
directions for algorithms for these types of graphs. Namely, for undirected
graphs a majority of the computational studies have focused on cliques and
independent sets—rather than on vertex covers—whereas for directed graphs
most studies have been on feedback vertex sets—rather than on transitive
subtournaments and induced acyclic subgraphs. We shall now argue that the
main reason for this can be traced to the types of instances for which the
research community have needed the algorithms.
Many algorithms for solving these problems are based on some kind of
backtrack search, whereby the size of a solution essentially gives the depth of
Algorithms for finding maximum transitive subtournaments
5
the search tree. Although the size of the search tree is crucial for the time
consumption rather than the depth of the tree, there is an obvious correlation
between these. Consequently, whenever there is a choice between searching
for a certain type of set or its complement—like with the two versions of
the problems here—the approximate sizes of the sets give a hint for a proper
choice.
For directed graphs, it appears that the work on algorithms has been motivated by instances whose feedback vertex sets are relatively small, that is,
the graphs are almost acyclic. For the instances considered later and those
motivated by the discussion in Section 2, on the other hand, the feedback
vertex sets (in the complement) are very big (for example, for the instances
in Section 4 the largest size of a solution would be close to 190). The current
work opens up the study of practical algorithms for such instances, and will
hopefully inspire further work in the area. Due to the lack of old algorithms to
compare the results with, several algorithms will be presented starting from
basic ones similar to the seminal algorithm by Carraghan and Pardalos (1990)
for finding a maximum clique in an undirected graph.
Only a handful of papers have been published on algorithms for the aforementioned problems for directed graphs. (Note that algorithms can be studied
and compared in two ways: via theoretical bounds and via their practical
performance. We consider algorithm within the latter framework.) The literature is indeed biased toward the case of feedback vertex sets (Berghammer
and Fronk, 2006; Chakradhar et al., 1995; Lin and Jou, 2000; Lloyd and Soffa,
1988; Orenstein et al., 1995; Smith, Jr., and Walford, 1975). Funke and Reinelt
(1996) consider induced acyclic subgraphs, but they concentrate on a variant
of the problem where arcs have weights and the aim is to maximize the total
arc weight of the induced graph.
We shall here present three algorithms for finding a maximum transitive
subtournament: two backtrack algorithms and a Russian doll search algorithm.
The similarities between these and the algorithms published in (Carraghan
¨
and Pardalos, 1990) and (Osterg˚
ard, 2002) are not incidental. The order of
the vertices of the input graph has a (sometimes even significant) impact on
the computation times of these algorithms; this issue is discussed further in
the Section 4.
We start with a basic backtrack algorithm, Algorithm 1, that builds up
a transitive subtournament so that if vertex v is added on level i—this information is saved in the variable ai —then there must be an arc vw to add
vertex w on level j whenever j > i. The set of vertices w such that there is
an arc vw is denoted by Γ + (v). The parameters U and s of the procedure
basic1(U, s) stand for the set of remaining vertex candidates and the size of
the current transitive subtournament, respectively. The algorithm is invoked
with basic1(V, 0), where V is the set of all vertices, and the initial value of
the global variable record is 0.
Algorithm 1 builds up a transitive subtournament in the order of its vertices, starting from the vertex that has all other vertices of the subtournament
as successors. Obviously, one could instead proceed in the opposite direction,
6
¨
L. Kiviluoto, P.R.J. Osterg˚
ard, V.P. Vaskelainen
Algorithm 1 First Backtrack Algorithm
procedure basic1(U : set, s: integer)
1: if |U | = 0 then
2:
if s > record then
3:
record ← s
4:
Save the current solution a1 , a2 , . . . , as
5:
end if
6:
return
7: end if
8: for i ← 1, 2, . . . , |U | do
9:
U ′ ← U ∩ Γ + (ui ); The elements of U are denoted by u1 , u2 , . . ..
10:
if s + 1 + |U ′ | > record then
11:
as+1 ← ui
12:
basic1(U ′ , s + 1)
13:
end if
14: end for
end procedure
starting from the vertex that has all other vertices of the subtournament as
predecessors; it is easily seen that in the case of random directed graphs, these
two approaches lead the same estimated performance.
Although updating the set of vertex candidates in line 9 of Algorithm 1 is
a rather straightforward operation, careful implementation of this step does
have some impact on the overall performance as it lies in the core of the
algorithm. A thorough consideration of such core steps of backtrack algorithms
was carried out by Thiel et al. (1987); Lam et al. (1988) in their work on
proving nonexistence of projective planes of order 10; in fact, they gave reasons
for algorithms to act differently on different levels of the search tree (the levels
being split into three regions).
One drawback of Algorithm 1 is that having considered a certain vertex,
chosen in line 8, we cannot remove it from U since it can also be considered at
later stages when building up the transitive tournament. The next two algorithms to be considered do not have this drawback; on the other hand, in these
algorithms we do need a test that determines whether an induced subgraph
contains a transitive tournament. Actually, because of this test, we consider
the complementary graph instead and build up induced acyclic subgraphs
(Proposition 1); throughout the rest of this section, the maximum induced
acyclic subgraph setting is therefore assumed.
The next algorithms to be considered build up an induced acyclic subgraph, adding the vertices in the order they occur in the directed graph D.
Maintaining a set of vertices that do not introduce cycles when added to a
solution set is a much more complicated operation than the update operation
for Algorithm 1. Consequently, as there is not one obvious way of carrying out
this operation, care has to be taken in the evaluation of algorithms to distinguish between the impact of this core part of the algorithm from the impact
of the overall algorithm.
For each vertex to be added to a partial solution—which induces an acyclic
subgraph—one may simply test whether the vertices in the extended partial
Algorithms for finding maximum transitive subtournaments
7
solution also would induce an acyclic subgraph; this can be done by breadthfirst search (BFS) or depth-first search (DFS) in time O(|V |+|A|). However, it
is computationally less expensive to maintain a set U of vertices that, together
with the partial solution, do not form induced cycles. Updating U after adding
a vertex to the solution set is a nontrivial operation. We shall now elaborate
briefly on this operation.
When a vertex v is added to the solution set B, we can delete a vertex
u ∈ U whenever there exist vertices v ′ , v ′′ ∈ B such that there is a path
from v ′ through v to v ′′ in B, and arcs v ′′ u and uv ′ in the original graph D.
The latter information can be precalculated into a table that for each triple
u, v ′ , v ′′ of vertices tells whether there are arcs v ′′ u and uv ′ . With Θ(|V |3 )
bits for this table, Θ(|V |2 ) bits for each u, the question can be answered in
constant time. On the other hand, by finding—with BFS or DFS—all vertices
V ′ in B from which there is a directed path to v (v itself is in this set) as
well as all vertices V ′′ to which there is a directed path from v (v is also in
this set), we get the desired pairs (v ′ , v ′′ ) ∈ (V ′ , V ′′ ). The auxiliary table fits
into the available memory for the instances considered in Section 4. Anyway,
other data structures can be utilized should the space requirement be an issue,
trading speed for memory.
To test (v ′ , v ′′ ) ∈ (V ′ , V ′′ ) against the information about paths v ′′ uv ′ , there
are two possibilities. If the number of pairs (v ′ , v ′′ ) ∈ (V ′ , V ′′ ) is large, then
one may form a string with Θ(|V |2 ) bits and 1s for each pair occurring; this
string can be immediately tested against the precalculated strings of the same
length. On the other hand, with very few pairs, it is faster to test each pair
separately. In the current work we used only the latter approach. Note also
that when a certain pair has been tested, then it need not be tested among
descendants in the search tree; this information is maintained in the search
tree.
With the above described method, we consider Algorithm 2, which is a
backtrack algorithm, and Algorithm 3, which a Russian doll search algorithm.
In Algorithm 3, we handle the easy case of cycles of length 2 in a direct way
through T (v), v ∈ V , which denotes the set of vertices w ∈ V for which not
both vw and wv are arcs.
Algorithm 2 is invoked with basic2(V, 0). The global variable record has
initial value 0. The function reduce takes care of reducing the set of candidate
vertices in U after a new vertex is added to the solution. The other variables
and parameters are as in Algorithm 1.
A major difference between Algorithm 1 and Algorithm 2 (as well as Algorithm 3) is that we search for (ordered) tuples of vertices in the former and
sets of vertices in the latter. When we search for sets, we may remove a vertex
from further consideration after the inclusion of the vertex in a solution has
been examined (line 14 in Algorithm 2).
Algorithm 3 is a Russian doll search algorithm. A Russian doll search
algorithm (Verfaillie et al., 1996) can in general terms be described as an
algorithm for solving a problem with n variables through n subproblems, where
the first subproblem includes just the nth variable, the ith subproblem the last
8
¨
L. Kiviluoto, P.R.J. Osterg˚
ard, V.P. Vaskelainen
i variables, and where the solutions of the subproblems are used for pruning
in later subproblems. A general treatment of Russian doll search algorithms
can be found in (Dechter, 2003, Section 13.2.2). Russian doll search has been
¨
applied to the maximum clique problem in (Osterg˚
ard, 2002).
In Algorithm 3, which is invoked with russiandoll, the definition Si =
{vi , vi+1 , . . . , vn } gives the vertex sets of the subproblems. The size of a maximum induced acyclic subgraph in the subgraph induced by Si is saved in the
array c[i]. Note that c[i − 1] = c[i] or c[i − 1] = c[i] + 1. If a solution corresponding to the latter equality is found then a subproblem has obviously
been solved; the variable found makes immediate interruption possible. The
feature of Russian doll search to use solutions of subproblems for later pruning
is implemented in line 14 of Algorithm 3. The other variables and parameters
are as in Algorithms 1 and 2.
Algorithm 2 Second Backtrack Algorithm
procedure basic2(U : set, s: integer)
1: if |U | = 0 then
2:
if s > record then
3:
record ← s
4:
Save the current solution a1 , a2 , . . . , as
5:
end if
6:
return
7: end if
8: while U 6= ∅ do
9:
if s + |U | ≤ record then
10:
return
11:
end if
12:
i ← min{j : vj ∈ U }
13:
as+1 ← vi
14:
U ← U \ {vi }
15:
U ′ ← reduce(U, a1 , . . . , as+1 )
16:
basic2(U ′ , s + 1)
17: end while
end procedure
4 Computational Results
In this section we use computational experiments to compare Algorithms 1,
2, and 3. Indeed, these algorithms were designed with the aim of optimizing
practical performance, and belong to a class of algorithms less amenable to
a formal performance analysis (McGeoch, 2007). Recall that we are dealing
with an optimization version of an NP-complete problem.
The algorithms were implemented in C++ and evaluated using random
graphs. Random graphs were chosen for two reasons. First, random graphs
are easily generated, which simplifies the process of comparing future results
to that of the current study. Second, random graphs can be generated with
Algorithms for finding maximum transitive subtournaments
9
Algorithm 3 Russian Doll Search Algorithm
procedure rds(U : set, s: integer)
1: if |U | = 0 then
2:
if s > record then
3:
record ← s
4:
Save the current solution a1 , a2 , . . . , as
5:
found ← true
6:
end if
7:
return
8: end if
9: while U 6= ∅ do
10:
if s + |U | ≤ record then
11:
return
12:
end if
13:
i ← min{j : vj ∈ U }
14:
if s + c[i] ≤ record then
15:
return
16:
end if
17:
as+1 ← vi
18:
U ← U \ {vi }
19:
U ′ ← reduce(U, a1 , . . . , as+1 )
20:
rds(U ′ , s + 1)
21:
if found = true then
22:
return
23:
end if
24: end while
end procedure
procedure russiandoll
25: record ← 0
26: for i = n, n − 1, . . . , 1 do
27:
found ← false
28:
rds(Si ∩ T (vi ), 1)
29:
c[i] = record
30: end for
end procedure
different arc probabilities. The arc probability is the probability that there is
an arc for any given ordered pair of vertices of the graph. For example, if the
arc probability is p, then the probability that there is no arc in either direction
between two given vertices is (1−p)(1−p). Random graphs are also commonly
used for testing clique algorithms.
Here, graphs with 40 to 200 vertices were generated with different arc
probabilities. It is important to note that for Algorithm 1 we consider such
a random graph D, but for Algorithms 2 and 3 we consider its complement
¯ Algorithms for finding minimum feedback vertex sets have generally been
D.
evaluated using the ISCAS’89 benchmark graphs (Chakradhar et al., 1995;
Lin and Jou, 2000; Orenstein et al., 1995). Similar graphs, with respect to the
number of arcs, are obtained by the current model with 0.98 ≤ p ≤ 0.999 and
thereby form a specific type of graphs as for arc density.
One detail that has been omitted so far is the impact of vertex orderings
on the performance of the algorithms. For clique algorithms, the importance
of this detail was recognized in the work by Carraghan and Pardalos (1990). It
10
¨
L. Kiviluoto, P.R.J. Osterg˚
ard, V.P. Vaskelainen
is therefore no surprise that the choice of ordering turns out to have a crucial
impact also for the type of algorithms considered in the current study.
Vertex orderings for clique-type problems are heuristics, many of which
tend to order the vertices (in increasing or decreasing order) according to how
likely they are to occur in a maximum solution. The best orders are not always
intuitive and some experimentation is generally needed to find a good heuristic
(for the graphs considered). Basic orderings considered here are those based on
the vertex degrees in the underlying undirected graph (U), the outdegrees of
the vertices in the directed graph (O), and the indegrees of the vertices in the
directed graph (I). The vertices can be ordered ascending (ր ) or descending
(ց ). Also the case with no reordering is considered (NONE).
¯ it seems reasonable that a large number of
Thinking in the terms of D,
pairs v ′ , v ′′ such that there are arcs v ′′ u and uv ′ make it less likely for u to
be in a maximum induced acyclic subgraph (recall that this is related to the
number of elements in the table used in Algorithms 2 and 3). Therefore we
also consider the ordering (P) given by the product of the indegree and the
outdegree of the vertices in the complementary graph.
Russian doll search algorithms tend to perform well when the elements
of an optimal solution are spread out evenly over the set of all elements.
For undirected graphs and the maximum clique problem, this is achieved by
coloring the vertices and grouping the vertices that belong to each color class.
¯ we may get a similar
Also in the case of induced acyclic subgraphs of D,
ordering (C) by grouping the vertices into symmetric cliques; in other words,
these groups are independent sets of the underlying graph of D. Since the
heuristic is only relevant for Russian doll search algorithms and not for basic
backtrack search, it was only carried out for Algorithm 3.
To compare the different orderings, we utilized the average ranks ranking method (Brazdil and Soares, 2000). For each parameter pair (n, p) in
{(50, 0.5), (50, 0.6), (50, 0.7), (50, 0.8), (50, 0.9), (100, 0.5), (100, 0.6), (100, 0.7),
(200, 0.3), (200, 0.4), (200, 0.5), (500, 0.2), (500, 0.3), (1000, 0.1), (1000, 0.2)}, five
instances were generated and tested with each ordering. Orderings were given
a rank number, starting from 1, with respect to their performance, and the
average of all runs was calculated for each ordering. The results are shown
in Table 1. The best ordering for each algorithm is in bold and used in the
computations leading to Table 2.
In Table 2, we show the average time for 10 random graphs of each parameter set, except for the instances when Algorithm 1 took longer than 500000
seconds, where the results are based on a single run. Empty entries indicate
that the algorithm did not finish in 850000 seconds. The last two columns
A1/A3 and A2/A3 give the ratio of the average computational times. Once
again, recall that for Algorithms 2 and 3 the computations are carried out on
the complementary graph. These times are in CPU seconds for a 2.93-GHz
PC with Linux operating system. Also the average size of a solution is given.
Figure 1 illustrates the performance of Algorithm 1 relative to Algorithm 3
based on the values from Table 2. Some additional entries have been added
for small instances, where the running times are a fraction of a second.
Algorithms for finding maximum transitive subtournaments
11
Table 1 Ranking of permutations
Ordering
Uր
Uց
Oր
Oց
Iր
Iց
Pր
Pց
Cր
Cց
NONE
A1
A2
A3
5.73
4.20
6.41
3.67
4.69
4.91
6.06
4.29
1.56
7.97
3.25
6.52
3.27
6.48
2.27
8.65
5.04
5.03
2.89
8.15
4.28
7.37
4.13
8.36
3.95
8.93
4.85
5.97
7.11
Table 2 Evaluation of the algorithms
|V |
p
A1/A3
A2/A3
40
40
40
40
0.7
0.8
0.9
0.95
15.6
20.2
28.0
35.0
0.16
22.8
843000
0.05
0.25
0.18
0.01
0.03
0.16
0.09
0.02
6.5
145
9400000
2.1
1.6
2.0
0.7
80
80
80
80
80
80
0.5
0.6
0.7
0.8
0.85
0.9
11.6
15.0
19.8
27.0
33.0
43.0
0.12
1.65
106
233000
0.47
2.89
52.7
3270
12400
62900
0.25
1.87
25.9
2020
5610
9920
0.5
0.9
4.1
116
1.8
1.5
2.0
1.6
2.2
6.3
120
120
120
120
120
120
0.4
0.5
0.6
0.7
0.75
0.8
10.1
13.0
16.7
22.3
26.0
31.0
0.10
1.51
58.8
9160
527000
0.60
5.61
112
3680
47400
847000
0.40
3.46
66.3
2080
24000
587000
0.2
0.4
0.9
4.4
22.0
1.5
1.6
1.7
1.8
2.0
1.4
160
160
160
160
160
0.4
0.5
0.6
0.65
0.7
11.0
14.0
18.0
20.6
24.0
0.55
10.4
688
17600
640000
3.44
35.5
995
16600
149000
2.04
22.2
626
9940
103000
0.3
0.5
1.1
1.8
6.2
1.7
1.6
1.6
1.6
1.5
200
200
200
200
200
0.3
0.4
0.5
0.6
0.65
9.0
11.6
14.6
19.0
21.9
0.15
2.14
75.6
8480
209000
1.22
13.7
276
13600
150000
0.79
7.70
189
8470
74300
0.2
0.3
0.4
1.0
2.8
1.5
1.8
1.5
1.6
2.0
max size
A1
A2
A3
Table 2 and Figure 1 show that the algorithm for finding maximum transitive subtournaments (Algorithm 1) is faster than the ones for finding maximum
induced acyclic subgraphs in the complement (Algorithms 2 and 3) for solutions of size smaller than 15–20. The Russian doll search approach for finding
maximum induced acyclic subgraphs (Algorithm 3) is faster than Algorithm 2,
except for instances whose running times are a fraction of a second. Moreover,
12
¨
L. Kiviluoto, P.R.J. Osterg˚
ard, V.P. Vaskelainen
Fig. 1 Performance of A1 relative to A3
Algorithm 3 is the overall fastest for the densest graphs considered in this
work. The range for which Algorithm 1 is applicable is smaller than that for
Algorithm 3, which in practice can handle instances with solution size greater
than 30.
Although the density of the ISCAS’89 benchmark graphs is the worst possible for the current algorithms—and no additional graph reduction techniques
were employed—each ISCAS’89 graph with fewer than 100 vertices could be
processed within a few milliseconds.
As Algorithm 3 resembles the maximum clique algorithm presented in
¨
(Osterg˚
ard, 2002), it is natural to ask whether ideas from other maximum
clique algorithms could be implemented in algorithms for finding maximum
transitive subtournaments. However, most clique algorithms utilize various
types of colorings, and it is not clear how to carry over this concept (as for
efficient computing) to directed graphs.
Notice that in a related work on algorithms for finding maximum independent sets in hypergraphs, Russian doll search turned out to be orders of
magnitude faster than integer linear programming with a state-of-the-art op¨
timization tool (Osterg˚
ard and Vaskelainen, 2011).
We conclude this paper with the remark that the considered algorithms
have been applied to instances of the applications discussed in Section 2; an
exhaustive determination of the Sperner capacity of small directed graphs has
been carried out in (Kiviluoto et al., 2009).
Acknowledgements The authors thank Brendan McKay for useful discussions and the
referees for valuable comments.
Algorithms for finding maximum transitive subtournaments
13
References
Alon N (1998) On the capacity of digraphs. European J. Combin. 19:1–5
Bang-Jensen J, Gutin G (2001) Digraphs: Theory, Algorithms and Applications, Springer-Verlag, London, 2001
Berghammer R, Fronk A (2006) Exact computation of minimum feedback
vertex sets with relational algebra. Fund. Inform. 70:301–316
Bomze IM, Budinich M, Pardalos PM, Pelillo M (1999) The maximum clique
problem. In: Du D-Z, Pardalos PM (eds), Handbook of Combinatorial Optimization, Supplement Vol. A, Kluwer, Dordrecht, pp 1–74
Brazdil PB, Soares C (2000) A comparison of ranking methods for classification algorithm selection. In: L´opez de M´antanas R, Plaza E. (eds) Machine
Learning: ECML 2000, LNCS 1810, Springer, Berlin, pp 63–74
Butenko S, Wilhelm WE (2006) Clique-detection models in computational
biochemistry and genomics. European J. Oper. Res. 173:1–17
Carraghan R, Pardalos PM (1990) An exact algorithm for the maximum clique
problem. Oper. Res. Lett. 9:375–382
Chakradhar ST, Balakrishnan A, Agrawal VD (1995) An exact algorithm for
selecting partial scan flip-flops. J. Electron. Test. Theory Appl. 7:83–93
Cong J, Smith M (1993) A parallel bottom-up clustering algorithm with applications to circuit partitioning in VLSI design. In: Proc. 30th International
Design Automation Conference, ACM, New York, pp 755–760
Dechter R (2003) Constraint Processing, Morgan Kaufmann, San Francisco,
2003
Funke M, Reinelt G (1996) A polyhedral approach to the feedback vertex set
problem. In: Cunningham WH, McCormick ST, Queyranne M (eds) Integer Programming and Combinatorial Optimization, LNCS 1084, Springer,
Berlin, pp 445–459
Garey MR, Johnson DS (1979) Computers and Intractability: A Guide to the
Theory of NP-Completeness. W. H. Freeman, San Francisco
Gargano L, K¨
orner J, Vaccaro U (1992) Qualitative independence and Sperner
problems for directed graphs. J. Combin. Theory Ser. A 61:173–192
Karp RM, Reducibility among combinatorial problems. In: Miller RE,
Thatcher JW (eds) Complexity of Computer Computations, Plenum, New
York, pp 85–103
¨
Kiviluoto L, Osterg˚
ard PRJ, Vaskelainen VP (2009) Sperner capacity of small
digraphs. Adv. Math. Commun. 3:125–133
K¨
orner J, Pilotto C, Simonyi G (2005) Local chromatic number and Sperner
capacity. J. Combin. Theory Ser. B 95:101–117
Lam CWH, Thiel LH, Swiercz S (1988) A computer search for a projective
plane of order 10. In: Deza MM, Frankl P, Rosenberg IG (eds) Algebraic, Extremal and Metric Combinatorics, Cambridge University Press, Cambridge,
pp 155–165
Lin H-M, Jou J-Y (2000) On computing the minimum feedback vertex set of
a directed graph by contraction operations. IEEE Trans. Comput.-Aided
Design Integr Circuits Syst. 19:295–307.
14
¨
L. Kiviluoto, P.R.J. Osterg˚
ard, V.P. Vaskelainen
Lloyd EL, Soffa ML (1988) On locating minimum feedback vertex sets. J.
Comput. System Sci. 37:292–311
McGeoch CC (2007) Experimental algorithmics. Communications of the ACM
50(11):27–31
Neumann-Lara V (1982) The dichromatic number of a digraph. J. Combin.
Theory Ser. B 33:265–270
Orenstein T, Kohavi Z, Pomeranz I (1995) An optimal algorithm for cycle
breaking in directed graphs. J. Electron. Test. Theory Appl. 7:71–81
¨
Osterg˚
ard PRJ (2002) A fast algorithm for the maximum clique problem.
Discrete Appl. Math. 120:197–207
¨
Osterg˚
ard PRJ, Vaskelainen VP (2011) Russian doll search for the Steiner
triple covering problem. Optim. Lett. 5:631–638
Pardalos PM, Xue J (1994) The maximum clique problem. J. Global Optim.
4:301–328
Rhodes N, Willett P, Calvet A, Dunbar JB, Humblet C (2003) CLIP: similarity
searching of 3D databases using clique detection, J. Chem. Inform. Comput.
Sci. 43:443–448
Sali A, Simonyi G (1999) Orientations of self-complementary graphs and the
relation of Sperner and Shannon capacities. Europ. J. Combin. 20:93–99
Shannon CE (1956) The zero-error capacity of a noisy channel. IRE Trans.
Inform. Theory 2:8–19
Smith, Jr., GW, Walford RB (1975) The identification of a minimal feedback
vertex set of a directed graph. IEEE Trans. Circuits and Systems 22:9–14
Thiel LH, Lam CWH, Swiercz S (1987) Using a CRAY-1 to perform backtrack search. In: Kartashev LP, Kartashev SI (eds) Supercomputing ’87:
Supercomputer Design, Performance Evaluation and Performance Education, Vol. 3, International Supercomputing Institute, St. Petersburg, Fla.,
pp 92–99
Verfaillie G, Lemaˆıtre M, Schiex T (1996) Russian doll search for solving constraint optimization problems. In: Proc. 13th National Conference on Artificial Intelligence (AAAI-96), AAAI Press, Menlo Park, pp 181–187