
STATISTICS, OPTIMIZATION AND INFORMATION COMPUTING Stat., Optim. Inf. Comput., Vol. 5, March 2017, pp 35–44. Published online in International Academic Press (www.IAPress.org) Dynamic Programming Algorithms on Directed Cographs Frank Gurski∗ Institute of Computer Science, University of Dusseldorf,¨ Germany. (Received: 20 November 2016; Accepted: 19 December 2016) Abstract In this paper we consider directed cographs, which are defined by Bechet et al. in [3] using the disjoint union, series, and order composition, from an algorithmic point of view. Applying their recursive structure we give dynamic programming algorithms to show that for every directed cograph the size of a largest edgeless subdigraph, the size of a largest subdigraph which is a tournament, the size of a largest semicomplete subdigraph, and the size of a largest complete subdigraph can be computed in linear time. Our main results show that the hamiltonian path, hamiltonian cycle, regular subdigraph, and directed cut problem are polynomial on directed cographs. Keywords directed cograph, digraph, dynamic programming AMS 2010 subject classifications 05C20, 90C39, 05C85 DOI: 10.19139/soic.v5i1.260 1. Introduction Undirected cographs have been introduced in the 1970s by a number of authors under different notations, such as hereditary Dacey graphs (HD graphs) in [16], D∗-graphs in [12], 2-parity graphs in [5], and complement reducible graphs (cographs) in [13]. Cographs can be characterized as the set of graphs without an induced path with four vertices [6]. From an algorithmic point of view the following definition is very useful. (a) Every single vertex is a cograph. (b) If G1;:::;Gk are cographs, then the disjoint union of the graphs G1;:::;Gk is a cograph. (c) If G1;:::;Gk are cographs, then the join of the graphs G1;:::;Gk is a cograph. By this definition every cograph can be represented by a tree structure, denoted as cotree. The leaves of the cotree represent the vertices of the graph and the inner nodes of the cotree correspond to the operations applied on the subexpressions defined by the subtrees. For every graph G one can decide in linear time, whether G is a cograph and in the case of a positive answer construct a cotree for G, see [7] or [11]. Using the cotree a lot of hard problems have been shown to be solvable in polynomial time when restricted to cographs. Such problems are clique, independent set, partition into independent sets (chromatic number), partition into cliques, hamiltonian cycle, isomorphism [6], and vertex disjoint paths [10]. On the other hand, the achromatic number problem is NP-complete for cographs [4]. Directed cographs were introduced in 1997 by Bechet et al. in [3] as follows. (a) Every single vertex is a directed cograph. (b) If G1;:::;Gk are directed cographs, then the disjoint union of the graphs G1;:::;Gk is a directed cograph. (c) If G1;:::;Gk are directed cographs, then the series composition of the graphs G1;:::;Gk is a directed cograph. (d) If G1;:::;Gk are directed cographs, then the order composition of the graphs G1;:::;Gk is a directed cograph. Also every directed cograph can be defined by a tree structure, denoted as di-cotree. The leaves of the di-cotree represent the vertices of the graph and the inner nodes of the di-cotree correspond to the ∗Correspondence to: Frank Gurski (Email: [email protected]). Institute of Computer Science, Algorithmics for Hard Problems Group, University of Dusseldorf,¨ 40225 Dusseldorf,¨ Germany ISSN 2310-5070 (online) ISSN 2311-004X (print) Copyright ⃝c 2017 International Academic Press 36 DYNAMIC PROGRAMMING ALGORITHMS ON DIRECTED COGRAPHS operations applied on the subexpressions defined by the subtrees. Also for every directed graph G one can decide in linear time, whether G is a directed cograph and in the case of a positive answer construct a di-cotree for G, see [8]. Directed cographs can be characterized by eight forbidden induced digraphs [8]. Calculus of directed cographs were also considered in connection with pomset logic in [14]. The algorithmic use of directed cographs has been shown in [2] using their decomposability into acyclic digraphs and semicomplete graphs and also by flow techniques (cf. Section 4.11.3 in [1]). In this paper we use the recursive structure of directed cographs to give new dynamic programming solutions for the following problems. We show that for every directed cograph a largest edgeless subdigraph, a largest subdigraph which is a tournament, a largest semicomplete subdigraph, and a largest complete subdigraph can be computed in linear time. Further we show that the hamiltonian path, hamiltonian cycle, regular subdigraph, and directed cut problem are polynomial on directed cographs. For general digraphs all these problems are NP-hard. Our approach can be applied to a lot of further digraph problems. The aim of this paper is not to complete the list of digraph problems which can be solved by dynamic programming on directed cographs, but to show that all these problems can be handled by dynamic programming solutions using the same scheme. We are also not interested in bounding the running time which is sometimes given by a polynomial of higher degree. Such considerations are only interesting if anybody really has to implement the solutions. 2. Preliminaries 2.1. Digraphs A directed graph or digraph is a pair G = (V; A), where V is a finite set of vertices and A ⊆ f(u; v) j u; v 2 V; u =6 vg is a finite set of ordered pairs of distincty vertices called directed edges or arcs. For a vertex v 2 V , + f 2 j 2 g − f 2 j 2 g the sets NG (v) = u V (v; u) A and NG (v) = u V (u; v) A are called the set of all out-neighbours and the set of all in-neighbours of v. The outdegree of v, out-degG(v) for short, is the number of out-neighbours of 0 0 0 v and the indegree of v, in-degG(v) for short, is the number of in-neighbours of v in G. A digraph G = (V ;A ) is a subdigraph of digraph G = (V; A) if V 0 ⊆ V and A0 ⊆ A. If every arc of A with both end vertices in V 0 is in A0, we say that G0 is an induced subdigraph of digraph G and we write G0 = G[V 0]. For some directed graph G = (V; E) its complement digraph is defined by co-G = (V; f(u; v) j (u; v) 62 E; u; v 2 V; u =6 vg). For some given digraph G = (V; E), we define its underlying undirected graph by ignoring the directions of the edges, i.e. u(G) = (V; ffu; vg j (u; v) 2 E; u; v 2 V g). 2.2. Directed Cographs Let G1 = (V1;E1);:::;Gk = (Vk;Ek) be k vertex-disjoint directed graphs. • The disjoint union of G1;:::;Gk, denoted by G1 ⊕ ::: ⊕ G2, is the graph with vertex set V1 [ ::: [ Vk and arc set E1 [ ::: [ Ek. • The series composition of G1;:::;Gk, denoted by G1 ⊗ ::: ⊗ Gk, is defined by their disjoint union plus all possible arcs between vertices of Gi and Gj for all 1 ≤ i; j ≤ k, i =6 j. • The order composition of G1;:::;Gk, denoted by G1 ⊘ ::: ⊘ Gk, is defined by their disjoint union plus all possible arcs between vertices of Gi and Gj for all 1 ≤ i < j ≤ k. The class of directed cographs has been defined recursively in [3]. (i) Every digraph on a single vertex (fvg; ;), denoted by •, is a directed cograph. (ii) If G1;:::;Gk are directed cographs, then the disjoint union G1 ⊕ ::: ⊕ Gk is a directed cograph. yThus we do not consider directed graphs with loops. Stat., Optim. Inf. Comput. Vol. 5, March 2017 F. GURSKI 37 (iii) If G1;:::;Gk are directed cographs, then the series composition G1 ⊗ ::: ⊗ Gk is a directed cograph. (iv) If G1;:::;Gk are directed cographs, then the order composition G1 ⊘ ::: ⊘ Gk is a directed cograph. Obviously for every directed cograph we can define a tree structure, denoted as di-cotree. The leaves of the di- cotree represent the vertices of the graph and the inner nodes of the di-cotree correspond to the operations applied on the subexpressions defined by the subtrees. For every directed cograph one can construct a di-cotree in linear time, see [8]. Since the disjoint union ⊕, the series composition ⊗, and the order composition ⊘ are associative, we can recursively transform every di-cotree T into a binary di-cotree T 0 for G. Lemma 1 Every cotree T can be transformed into an equivalent binary di-cotree T 0, such that every inner vertex in T 0 has exactly two sons. Example 1 (Directed cograph) Table I shows the definition of a directed cograph and its di-cotree. cograph expression Xi digraph defined by Xi X1 = • X2 = X1 ⊘ X1 X3 = X2 ⊕ X1 X4 = X1 ⊗ X1 X5 = X3 ⊘ X4 Table I. Directed cograph expressions X1;:::;X5, the defined digraphs, and a di-cotree for the directed cograph defined by expression X5. Lemma 2 For every directed cograph its complement digraph is a directed cograph. Proof Let G be a directed cograph and X be a cograph expression for G. An expression c(X) for the complement graph co-G can recursively be defined as follows. If X = •, then c(X) = •. If X = X1 ⊕ X2, then c(X) = c(X1) ⊗ c(X2). If X = X1 ⊗ X2, then c(X) = c(X1) ⊕ c(X2). If X = X1 ⊘ X2, then c(X) = c(X2) ⊘ c(X1). An obvious but important property of directed cographs is that they are hereditary, that is, every induced subdigraph of a directed cograph is a directed cograph.
Details
-
File Typepdf
-
Upload Time-
-
Content LanguagesEnglish
-
Upload UserAnonymous/Not logged-in
-
File Pages10 Page
-
File Size-