Semi-dynamic Algorithms for Strongly Chordal Graphs

01/31/2020 ∙ by Md. Zamilur Rahman, et al. ∙ 0

There is an extensive literature on dynamic algorithms for a large number of graph theoretic problems, particularly for all varieties of shortest path problems. Germane to this paper are a number fully dynamic algorithms that are known for chordal graphs. However, to the best of our knowledge no study has been done for the problem of dynamic algorithms for strongly chordal graphs. To address this gap, in this paper, we propose a semi-dynamic algorithm for edge-deletions and a semi-dynamic algorithm for edge-insertions in a strongly chordal graph, G = (V, E), on n vertices and m edges. The query complexity of an edge-deletion is O(d_u^2d_v^2 (n + m)), where d_u and d_v are the degrees of the vertices u and v of the candidate edge {u, v}, while the query-complexity of an edge-insertion is O(n^2).

READ FULL TEXT VIEW PDF
POST COMMENT

Comments

There are no comments yet.

Authors

This week in AI

Get the week's most popular data science and artificial intelligence research sent straight to your inbox every Saturday.

1 Introduction

Let be a connected graph on vertices with edges. is chordal if it has no induced chordless cycle of size greater than three. An alternate characterization that is more apposite for this paper is there exists a perfect elimination ordering of its vertices. We will represent a chordal graph by a clique tree (see [1]).

Strongly chordal graphs which are a subclass of chordal graphs was introduced into the graph theory literature by Farber in [3]. is strongly chordal if there exists a strong elimination ordering of its vertices, a generalization of the notion of perfect elimination ordering for chordal graphs.

While the problems of finding a minimum weight dominating set and an independent dominating set in vertex-weighted chordal graphs are NP-hard, Farber again [5] showed that these can be solved in linear time for strongly chordal graphs, provided a strong elimination ordering of the vertices of the graph is known.

There is an extensive literature on dynamic algorithms for a large number of graph theoretic problems, particularly for all varieties of shortest path problems. Germane to this paper are a number fully dynamic algorithms that are known for chordal graphs  [6][8]. However, to the best of our knowledge no study has been done for the problem of dynamic algorithms for strongly chordal graphs.

To address this gap, in this paper, we propose a semi-dynamic algorithm for edge-deletions and a semi-dynamic algorithm for edge-insertions in a strongly chordal graph.

The rest of the paper is structured as follows. In the next section, we explain the design of semi-dynamic algorithm for deletions. In the following section 3, we discuss the complexity of the proposed semi-dynamic algorithms. Finally, section 4 contains concluding remarks and open problems.

2 Semi-dynamic Algorithm for Deletions

Let be a strongly chordal graph and an even cycle of size six or greater in . A chord of is a strong chord if a shortest distance between and along ,

, is odd. The deletion algorithm is based on the following characterization of a strongly chordal graph.

Theorem 1

[4] A graph is strongly chordal if and only if it is chordal and every even cycle of length at least 6 in has a strong chord.

Let be an arbitrary edge of . Then can be deleted from provided remains chordal and it is not the only strong chord of a six-cycle. The check for chordality exploits the following theorem.

Theorem 2

[6] Let be an edge of a chordal graph . Then remains chordal if and only if has exactly one maximal clique containing .

Since strongly chordal graphs are a subclass of chordal graphs, a clique tree data structure, , representing is used to check for the chordality condition.

Consider the chordal graph shown in Figure 1(a) that has three maximal cliques , , and . Each maximal clique is represented by a node in the clique tree and the weight of each edge is the size of the overlap of the two maximal cliques that it joins. To obtain a clique tree from , we use an expanded version of the Maximum Cardinality Search (MCS) algorithm by Blair and Peyton [2].

(a) A chordal graph ()
(b) A clique tree ()
Figure 1: An example

If an edge is present in two or more clique tree nodes, then we cannot delete as its deletion will violate the chordality property of . For instance, we cannot delete the edge or the edge from (see Figure 3) because with the deletion of either of these two edges will cease to be chordal. Thus by maintaining the clique tree data structure , we can determine if an edge can be deleted without violating chordality. This is done as follows. For each node in , we compute the intersection of the node (a maximal clique contains two or more vertices of ) with the edge . If we find has exactly one node containing the end-points of , then we continue and check if the deletion preserves strong chordality.

As explained earlier, an edge can be deleted if and only it is not the only strong chord of a six-cycle. For instance, consider the strongly chordal graph shown in Figure 2. The edge (shown as a dashed line segment) splits the 8-cycle, , into a 4-cycle, , and a 6-cycle, . The addition of a strong chord (shown as a dashed line segment) splits the 6-cycle, , into two 4-cycles, and . Alternately, we could interpret as a strong chord of the 6-cycle , post the introduction of as a strong chord of the initial 8-cycle.

Figure 2: A strongly chordal graph

Since the addition of a strong chord splits an even cycle of size 6 or greater into two odd-length paths, it is sufficient to check for the presence of a strong chord in every even cycle of length 6. We give a formal proof of this in an Appendix.

A potential 6-cycle of which is a strong chord is formed by disjoint pairs of chordless paths (each spanning four vertices) that go from to . Thus we determine all such paths and for every disjoint pair of these we check whether is the only strong chord or not. If there is a strong chord other than in every disjoint pair of paths, then the edge can be deleted. On the other hand, if is the only strong chord for any disjoint pair of paths, then the edge cannot be deleted.

Now, instead of searching for paths in the entire graph, we do a local search in an induced graph, called AuxGraph. This graph is induced by a set of vertices AuxNodes that includes the closed neighbors of both the end-points of the edge to be deleted. Formally, we define .

Setting as the source vertex, we now perform breadth-first search in to find all paths from to .

1:A strongly chordal graph and an edge to be deleted
2:A strongly chordal graph
3:if  returns “True” then
4:     Call UpdateCliqueTreeAfterDeletion
5:     Delete the edge from
6:end if
Algorithm 1 Delete
1:A strongly chordal graph , a clique tree of , and an edge to be deleted
2:Return True or False
3: False
4:if the edge does not exist then
5:      False
6:     return
7:else
8:     if the edge belongs to exactly one node () in  then
9:         if  is not a strong chord then
10:               True
11:              return
12:         else
13:               False
14:              return
15:         end if
16:     else
17:          False
18:         return
19:     end if
20:end if
Algorithm 2 Delete-Query

Algorithm 2 returns “True”, if can be deleted from . When the algorithm returns “True”, we perform the delete operation (see Algorithm 1). After performing the delete operation, we update both the clique tree and the graph. The clique tree node that contains the edge can be replaced with 0, 1, or 2 nodes. The algorithm due to Ibarra [6] deletes the edge and updates .

1:A clique tree and an edge to be deleted
2:An updated clique tree
3:For every , test whether or and whether
4: and are maximal cliques and
5:Replace node with new nodes and respectively representing and and add edge with .
6: and
7:if  then
8:     replace with
9:end if
10:if  then
11:     replace with
12:end if
13:if  then
14:     replace with or (chosen arbitrarily)
15:end if
16:if  and are both maximal in  then
17:     stop
18:end if
19:if  is not maximal because for some  then
20:     choose one such arbitrarily, contract , and replace with
21:end if
22:if  is not maximal then
23:     perform similar operations as step 19 to 21
24:end if
25:return the clique tree
Algorithm 3 UpdateCliqueTreeAfterDeletion [6]
(a) A strongly chordal graph ()
(b) A clique tree () of
(c)
(d)
Figure 3: An example

Consider the strongly chordal graph shown in Figure 1(a). Can we delete the edge ? At first, we check the chordality property. From the clique tree (see Figure 1(b)), we observe there is a single node containing the edge only. This satisfies the chordality condition and now we check the strong chordality condition. To do that, we compute the closed neighborhood of and and then compute the AuxNodes set, where . There are two paths ( and ) between and in the AuxGraph created from the AuxNodes set. We notice that is the only strong chord in the AuxGraph. Hence the deletion of is not allowed. But in the presence of any of the other two strong chords ( or ) in the AuxGraph we will be able to delete .

Consider another example graph, shown in Figure 3(a) where the chordality is preserved if we delete , but the edge is the only strong chord for the 6-cycle (). So, the edge cannot be deleted. But the edge can be deleted from the graph. After checking the clique tree, we see that only a single node contains the edge . So we can proceed to check for the strong chordality condition. We observe that is not a strong chord and thus we can delete the edge and update both and (as shown in Figure 3(c) and 3(d), respectively.)

2.1 Complexity of Deletions

For the semi-dynamic deletion, we create a clique tree in time, using the expanded version of the MCS algorithm. To check if the edge belongs to exactly one maximal clique in , we perform the intersection operation between a maximal clique and the edge . This operation takes linear time. To bound the query complexity of deleting an edge from the strongly chordal graph, we note that this is dominated by the case of finding multiple paths between and and we have to consider these in pairs and run the breadth-first search. An upper bound on the number of pairs of paths between and is , where and are the degrees of and respectively. For consider such a path from to (Fig. 4): is one of the at most vertices adjacent to and is one of the at most vertices adjacent to , so that we have at most paths from to and thus disjoint pairs of paths from to .

Figure 4: A path from to

If is the number of edges currently, in the strongly chordal graph, the complexity of running a breadth-first-search is . Since is the number of edges in the final strongly chordal graph, an upper bound on the query complexity is .

The deletion of an edge take constant time since we maintain an adjacency matrix data structure to represent . This is in addition to the clique tree that we maintain. It is however possible to dispense with the adjacency matrix. In that case, there is additional work required to construct the graph from the clique tree. This can be done using a certain Running Intersection Property of chordal graphs (see [2] for details).

3 Semi-dynamic Algorithm for Insertions

Let be a strong elimination ordering of the vertices of a strongly chordal graph . The neighborhood matrix of , based on , is an matrix whose -th entry is if and is otherwise. Let be the submatrix:

Our dynamic insertion algorithm is based on the following observation.

Observation 1

[4] The row (and column) labels of correspond to a strong elimination ordering if and only if the matrix does not contain as a submtraix.

The absence of in implies that is totally balanced and the theorem below allows us to claim that is strongly chordal.

Theorem 3

[4] A graph is strongly chordal if and only if is totally balanced.

Thus if is strongly chordal, then remains so if inserting the edge into does not create any submatrix in .

To insert an edge into , we first check if it is already present in . If not, we insert it if no submatrix is created.

The initialization process consists of computing a strong elimination ordering of an input strongly chordal graph , using a recognition algorithm for strongly chordal graphs due to Farber [4].

1:A strongly chordal graph and an edge to be inserted
2:Neighborhood Matrix of
3:if  returns “True” then
4:     insert edge into
5:     return updated is the neighborhoood matrix
6:end if
Algorithm 4 Insert

After creating a strong elimination ordering , we create the neighborhood matrix of . We also find the order of and in the ordering . Now we check if the insertion of an edge creates any submatrix or not. The searching strategy is explained with the Figure 5. Assume there is a 0 in the row and column. Now we want to change the entry from 0 to 1 (which corresponds to the insertion of an edge in the graph). Before changing the entry from 0 to 1, we need to check if that creates any submatrix in the or not. To check the presence of submatrix in , we need to check in three different directions from the -th position. We need to check in the upward direction from to , in the downward direction from to , and on the left direction from to position. If there is no submatrix created in for changing the entry from 0 to 1, then we change the -th entry from 0 to 1. Since is a symmetric matrix, we also change the -th entry from 0 to 1.

Figure 5: Algorithm to find submatrix
1:A strongly chordal graph and an edge to be inserted
2:Return True or False
3: True
4:if  is an edge of  then
5:      False
6:     return
7:else
8:     for  to  do downward
9:         for  to  do
10:              if  and and  then
11:                   False
12:                  return
13:              end if
14:         end for
15:     end for
16:     for  to  do upward
17:         for  to  do
18:              if  and and  then
19:                   False
20:                  return
21:              end if
22:         end for
23:     end for
24:     for  to  do leftward
25:         for  to  do
26:              if  and and  then
27:                   False
28:                  return
29:              end if
30:         end for
31:     end for
32:     return
33:end if
Algorithm 5 Insert-Query

Algorithm 5 returns “True” if can be inserted into . In that case, we perform the insert operation (see algorithm 4). Consider the strongly chordal graph shown in Figure 6(a). After finding a strong elimination ordering of , we create the neighborhood matrix . Now, suppose we want to insert an edge, say , into . However, since the insertion of creates a submatrix in , this cannot be done. Next, we might want to insert, say edge , into . This is possible as its insertion does not create any submatrix in . Since is a symmetric matrix, we changed 0 to 1 in both symmetric positions (which corresponds to the insertion of into ).

(a) A strongly chordal graph
(b)

(c) A neighborhood matrix of the strongly chordal graph shown in Figure (a)

(d) A neighborhood matrix of the strongly chordal graph shown in Figure (b)
Figure 6: An example of insertion

3.1 Complexity of Insertions

Computing a strong elimination ordering using Farber’s algorithm takes time, and it takes time to initialize the neighborhood matrix . Thus the preprocessing time-complexity is . The upper bound on searching for a submatrix in is . Thus the time-complexity of an - is .

The insertion of an edge take constant time since we maintain a neighborhood matrix data structure to represent .

4 Discussion

In this paper, we have presented semi-dynamic algorithms for deletions and insertions of edges into a strongly chordal graph. The proposed semi-dynamic algorithms are based on two different characterizations of strongly chordal graphs. The deletion algorithm is based on a strong chord characterization, while the insertion algorithm is based on a totally balanced matrix characterization. An interesting and challenging open problem is to come up with an efficient fully dynamic algorithm for this class of graphs.

References

  • [1] Blair, J. R. S., and Peyton, B. An introduction to chordal graphs and clique trees. In Graph Theory and Sparse Matrix Computation (New York, NY, 1993), A. George, J. R. Gilbert, and J. W. H. Liu, Eds., Springer New York, pp. 1–29.
  • [2] Blair, J. R. S., and Peyton, B. An introduction to chordal graphs and clique trees. In Graph Theory and Sparse Matrix Computation (New York, NY, 1993), A. George, J. R. Gilbert, and J. W. H. Liu, Eds., Springer New York, pp. 1–29.
  • [3] Farber, M. Applications of 1.p. duality to problems involving independence and domination. PhD thesis, Rutgers University, 1982.
  • [4] Farber, M. Characterizations of strongly chordal graphs. Discrete Mathematics 43, 2-3 (1983), 173–189.
  • [5] Farber, M. Domination, independent domination, and duality in strongly chordal graphs. Discrete Applied Mathematics 7, 2 (1984), 115–130.
  • [6] Ibarra, L. Fully dynamic algorithms for chordal graphs and split graphs. ACM Trans. Algorithms 4, 4 (2008), 40:1–40:20.
  • [7] Markenzon, L., Vernet, O., and Araujo, L. H. Two methods for the generation of chordal graphs. Annals OR 157, 1 (2008), 47–60.
  • [8] Mezzini, M. Fully dynamic algorithm for chordal graphs with O(1) query-time and o(n) update-time. Theor. Comput. Sci. 445 (2012), 82–92.

Appendix A Strong chords of even cycles of size 6 or greater

In this appendix, we justify why it is enough to check if an edge that is a candidate for deletion is a strong chord of a 6-cycle.

Definition: Let denote a cycle with edges.

Defintion: An ensemble of strong chords of an even cycle with edges, , is a set of strong chords that are pairwise disjoint, except for common end-points.

Two different ensembles of strong chords are shown in Fig. 7 for an 8-cycle, .

Figure 7: Two different ensembles of strong chords of an 8-cycle

Lemma: A strong chord of a cycle belongs to an ensemble of strong chords, .

Proof: Let , for and even, be a strong chord of an even cycle of length , where . The proof is by induction on . Clearly as a single strong chord splits a 6-cycle into two cycles of length 4, the claim is true for . Assume that the claim is true for a cycle of length . Since splits into two cycles and of even lengths and , by the inductive hypothesis, there exists a disjoint ensemble of strong chords that partition and a disjoint ensemble of strong chords that partition . Since the strong chord is not counted, the total number of strong chords that partition is: . This proves the assertion.

Theorem: Each of the strong chords in an ensemble of strong chords of is a strong chord of a 6-cycle.

Proof: Once again the proof is by induction on . Clearly this is true for , as the ensemble has only one strong chord. Assume the claim holds for an even cycle of smaller length. Among the ensemble of strong chords of there is one, say , that forms a with three boundary edges (see Fig. 8). By the inductive hypothesis, in the even cycle formed by the rest of the edges and each of the strong chords of the residual ensemble is a strong chord of a 6-cycle, . To show that is also a strong chord of a 6-cycle, we observe from Fig. 8, that is a strong chord of the 6-cycle, , or of the 6-cycle or of the 6-cycle and or or is a strong chord in . This completes the proof.

Figure 8: Every strong chord is a strong chord of a 6-cycle