# Orientations without forbidden patterns on three vertices

Given a set of oriented graphs F, a graph G is an F-graph if it admits an F-free orientation. Building on previous work by Bang-Jensen and Urrutia, we propose a master algorithm that determines if a graph admits an F-free orientation when F is a subset of the orientations of P_3 and the transitive triangle. We extend previous results of Skrien by studying the class of F-graphs, when F is any set of oriented graphs of order three; structural characterizations for all such sets are provided, except for the so-called perfectly-orientable graphs and one of its subclasses, which remain as open problems.

## Authors

• 3 publications
• 9 publications
07/15/2019

### Proper Orientation Number of Triangle-free Bridgeless Outerplanar Graphs

An orientation of G is a digraph obtained from G by replacing each edge ...
09/28/2020

### Extension of Gyarfas-Sumner conjecture to digraphs

The dichromatic number of a digraph D is the minimum number of colors ne...
03/12/2020

### Duality pairs and homomorphisms to oriented and un-oriented cycles

In the homomorphism order of digraphs, a duality pair is an ordered pair...
03/12/2020

### Duality pairs and homomorphisms to oriented and unoriented cycles

In the homomorphism order of digraphs, a duality pair is an ordered pair...
06/20/2020

### AOT: Pushing the Efficiency Boundary of Main-memory Triangle Listing

Triangle listing is an important topic significant in many practical app...
09/25/2020

### On the signed chromatic number of some classes of graphs

A signed graph (G, σ) is a graph G along with a function σ: E(G) →{+,-}....
04/07/2020

### egg: Easy, Efficient, and Extensible E-graphs

An E-graph is a data structure that can efficiently encode the congruenc...
##### 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

For a set of oriented graphs , a graph is an -graph if it admits an -free orientation. The concept of -graph was introduced by Skrien in skrienJGT6 , where he studied -graphs when consists of a subset of the orientations of . Following Skrien, we will use , , and to denote the orientations of , see Figure 1. Also in skrienJGT6 , Skrien proved structural characterizations of -graphs for every , except for and ; notice that - and -graphs are actually the same class, known as perfectly-orientable graphs.

Studying the structure of -free orientable graphs has caught the interest of several authors. In particular, Hartinger and Milanic, and the same authors with Brešar and Kos, have thoroughly studied this family in a series of papers bresarDAM248 ; hartingerJGT2016 ; hartingerDM2017 . We will follow their terminology and call the class of -graphs, -perfectly-orientable graphs (-p.o. graphs for short). They have nice results when the problem is restricted to some families, e.g., they showed that a cograph is -p.o. if and only if it is -free. Nonetheless, characterizing the class of -p.o. graphs through forbidden induced subgraphs remains an open problem in the general case.

From the algorithmic point of view, Urrutia and Gavril found a polynomial time algorithm to recognize -perfectly orientable graphs (urrutiaIPL41 ). Furthermore, in bangjensenJCTB59 , the authors show that for any subset of , there is a polynomial time algorithm to determine if a graph admits an -free orientation. They do so by reducing each of these problems to -SAT. Recall that in the classic article aspvallIPL8 , -SAT is solved by proceeding over an auxiliary digraph constructed from the -SAT instance. By using these two techiques, we extend the aforementioned result from bangjensenJCTB59 to any subset of , where is the transitive tournament of order . Instead of reducing our problem to -SAT, we give an explicit construction of an auxiliary digraph . Then, we follow the same procedure used in aspvallIPL8 over . Thus, we show a certifying polynomial time algorithm to determine if a graph belongs to the class of -graphs, for any set .

In addition to the algorithm mentioned above, in this paper we extend Skrien’s work by proposing characterizations of -graphs when is any set of oriented graphs on three vertices, except for and , where denotes the directed

-cycle. Probably the most interesting case is the family of

-graphs, for which we provide a characterization in terms of forbidden homomorphic images of a family of graphs. The characterization of -graphs results suprisingly natural, and the obstructions are obtained by “reverse-engineering” the no-certificates provided by the recognition algorithm.

We refer the reader to bangjensenDigraphs for undefined basic terms. We denote the oriented graphs on three vertices as in Figure 1. Given a set , we define and . For a statment , we denote by the truth value of . In other words, if is true, and otherwise.

We say that any set is a simple set. For a graph and a simple set . We construct the constraint digraph associated to and as follows. The vertex set, , of is the set ; notice that for every edge , both and belong to . We define the following sets of arcs:

• ,

• ,

• , and

• .

Finally, we define the arc set, , of as

In the following section we will use the constraint digraph for our algorithm. We will also use it at the end of this paper to find a structural characterization of -graphs.

The rest of the paper is organized as follows. In Section 2, the algorithm to recognize -graphs, where is any subset of , is presented. In Section 3, we characterize -graphs for most of the cases not covered in skrienJGT6 . Section 4 is devoted to characterize -free matrices. Conclusions and some open problems are presented in Section 5.

## 2 Algorithm

In this section we propose a master algorithm that finds an -free orientation of a graph , or outputs that it is not possible to find one. We say that it is a master algorithm since it works for any set .

We begin by observing some properties of the constraint digraph, .

###### Proposition 1.

Let be a graph and . Then, in , if and only if .

###### Proof.

Proving one implication is enough to prove the whole statement. Observe that if and only if for some . We will prove the statement for the case when , the other cases follow the same line of argumentation. If then , , and . Thus , and , therefore . Hence, if and only if . ∎

From here, the following two propositions are easy to obtain.

###### Proposition 2.

Let be a graph and . There is a directed path from to in if and only if there is a directed path from to in .

###### Proof.

Proceed by induction over the length of the directed path. Notice that Proposition 1 is the base case. Use again Proposition 1 in the inductive step. ∎

Let be a digraph and let be the digraph obtained from by reversing every arc. A digraph is skew-symmetric if it is isomorphic to .

###### Proposition 3.

Let be a graph and . The constraint digraph of and is skew-symmetric.

###### Proof.

Let be a digraph. Let be the constraint digraph of and . Consider the function defined by . By Proposition 1, it is clear to see that is a digraph isomorphism between and . ∎

By the isomorphism shown in the previous proof, every strong component in has a dual component, (which might be equal to ), induced by the vertices of the form where . By Proposition 2, a strong component reaches another one , if and only if reaches . A well-known algorithm of Tarjan tarjanSIAMJC1972 generates the strong components of a digraph in reverse topological order (i.e. if reaches then is generated before ).

Let us go back to the construction of the constraint digraph. Suppose that we want to find an -free orientation of . An arc in tells us that, in order to achieve such an orientation, if we orient the edge from to , then we must orient the edge from to . Inductively, if there is a path from to and we orient the edge from to then we must orient the edge from to . Thus, if and belong to the same strong component, does not admit an -free orientation. In fact the reverse implication is also true. To see this, we will consider the famous -satisfiability algorithm due to Tarjan aspvallIPL8 .

###### Algorithm 4 (2-satisfiability algorithm aspvallIPL8 ).

Process the strong components, , of in reverse topological order as follows:

General Step. If is marked, do nothing. Otherwise if then stop: does not admit an -free orientation. Otherwise mark true and false.

Clearly, the algorithm finishes inside a loop of the general step only if there is a vertex in the same strong component as . Otherwise, the -colouring of induces an -free orientation of . We prove the later fact in the following proposition.

###### Proposition 5.

Let be a graph and a simple set. If Algorithm 4 outputs a -colouring of the vertices in then vertices with colour true induce an -free orientation of .

###### Proof.

Clearly, if is marked with true, then is marked with false. Also, every vertex receives one and only one truth colour. Hence the true-coloured vertices of induce an orientation of ; this is, if is marked true, then is oriented as . We now prove that it is an -free orientation of . To do so, we must prove that for any two oriented edges that induce an oriented graph in , then at least one is marked with false. By construction of , it must happen that if and induce an oriented graph in then and . Hence it is adequate to show that if is marked with true and , then is also marked with true. Since the algorithm marks all the vertices in the same strong component at once, it suffices to show that for any two strong components and of , if is true-coloured and reaches , then is also true-coloured. Suppose that is marked with true and it reaches , but is false-coloured. Since reaches , , where is the reverse topological order of the strong components of . Since is marked with false it means that was processed before (i.e. ). Analogously . Transitivity of , implies that . Since reaches , by Proposition 2, reaches , then . Previous inequalities yield the following chain, . From which we conclude that ; equivalently . This contradicts that the algorithm does not assign two different truth values to the same component. Therefore if reaches and is marked with true, is marked with true as well. ∎

Now it is easy to prove the following result.

###### Theorem 6.

Let be a graph and a simple set. The following are equivalent:

• there are no vertices contained in the same strong connected component of ,

• for any strong component , (i.e. ).

###### Proof.

The equivalence between the second and third item is trivial. On the paragraph preceding Algorithm 4 it was shown that the second statement implies the first one. The remaining implication is proved by Algorithm 4 and Proposition 5. ∎

The order of is , where is the size of . Also note that . Thus . Since both the -satisfiabiltiy algorithm and Tarjan’s algorithm for generating the strong components of a digraph run in time, our algorithm runs in time once is constructed.

## 3 Graph properties and small forbidden orientations.

In this section we study the family of -graphs when consists of oriented graphs on three vertices. In skrienJGT6 Skrien studied the cases when is a set of orientations of . For this reason, we study -graphs when either or contains at least one orientation of . Cleary, any orientation of a ()-free graph is ()-free. Moreover, it is not hard to verify that if a graph admits a ()-free orientation, then it is ()-free. Since the class of ()-free graphs coincides with the class of complete multipartite graphs, if , then the family of -graphs is the intersection of -graphs and complete multipartite graphs. Therefore, we only consider families of -graphs when and contains an orientation of .

It is direct to verify that if the set of forbidden orientations consists of connected graphs, then the associated hereditary property is closed under disjoint unions. Thus, it suffices to study connected graphs.

Skrien’s results from skrienJGT6 are included in Table 3. Recall that he found an alternative characterization for all sets containing orientations of , except for -p.o. graphs. Bang-Jensen, Huang and Prisner also studied -perfectly orientable graphs, in particular, they proved the following result in bangjensenJCTB59 .

###### Proposition 7.

bangjensenJCTB59 Every graph with exactly one induced cycle of length greater than is -perfectly orientable.

This result can be equivalently restated as follows: every triangle-free graph is -perfectly orientable if it has only one induced cycle. With a simpler proof than the one found in bangjensenJCTB59 , we prove the biconditional version of this result, which is a corollary to the following proposition.

###### Proposition 8.

The following statements are equivalent for a connected graph ,

2. admits an orientation such that for every vertex ,

3. there is function such that ,

4. is unicyclic,

5. has no more edges than vertices.

###### Proof.

It is not hard to notice that the first two items are equivalent, and so are the second and third one. It is also straightforward to show that if has no more edges than vertices, then is unicyclic (recall that is connected), so is an implication of . Now we prove that the second item implies the fifth one. Let be an orientation of such that for every vertex of . Consider the function where . Since , is an injective function. Thus . To conclude the proof we show that if is unicyclic, it admits an -free orientation. If is a tree, root in any vertex and orient the edges from descendent to ancestor. If is a cycle, orient in a cyclic way. In any other case, let by the only cycle in . Orient in a cyclic way. Notice that is a tree. Root in the vertex corresponding to . Orient the edges in from descendent to ancestor. We have oriented all edges in now, and it it not hard to notice that this orientation is -free. ∎

###### Corollary 9.

A graph admits a -free orientation if and only if is unicyclic and triangle free.

###### Proof.

Suppose admits a -free orientation. Clearly, is triangle-free and by Proposition 8, is also a unicyclic graph. On the other hand, consider a triangle-free unicyclic graph . By Proposition 8, it admits a -free orientation . Since is triangle-free, is -free. ∎

The family of -graphs when , has already been characterized, and it is a particular case of the Gallai-Hasse-Roy-Vitaver Theorem.

###### Proposition 10.

A graph is bipartite if and only if it admits an -free orientation.

In skrienJGT6 , Skrien shows that a graph is a proper circular arc graph if and only if it is a -graph. A proper cicular-arc graph is a graph that admits an intersection model where no arc is contained in another. A family of sets is said to have the Helly property, if for any subfamily such that any two sets , , then the intersection of all sets in is non-empty. A (proper) Helly cicular-arc graph is a graph that admits an intersection model that satisfies the Helly property (and no arc is contained in another). We extend Skrien’s result to proper Helly circular-arc graphs.

###### Proposition 11.

A graph admits a -free orientation if and only if is a proper Helly circular-arc graph.

###### Proof.

Let be a graph that admits a -free orientation. By line two of Table 3, we know that must be a proper circular-arc graph. Corollary 5 in linDAM2013 shows that a proper circular-arc graph is a proper Helly circular-arc graph if it contains neither the Hajos graph nor a -wheel as an induced subgraph. It is not hard to notice that neither of those graphs admit a -free orientation. Thus, since is a proper circular-arc graph, must be a proper Helly circular-arc graph.

In mckeeDM2003 it is proved that a model of a proper circular-arc graph is the model of a proper Helly circular-arc graph if and only if no two nor three arcs cover its circle. Consider a proper Helly circular-arc graph . Let be a model of where no three arcs cover the circle. Moreover, we can assume that no end points of the arcs in coincide. Let us denote by the anti-clockwise end point of , and by the clockwise end point. We denote by the following orientation of . Consider an edge . By moving in a clockwise motion around the circle, we see the endpoints of and form the sequence or . We orient form to when we see , in the other case we orient it from to . Bearing in mind that there are no three arcs that cover the circle, it is easy to see is -free. ∎

Since every graph admits an acyclic orientation, every graph admits a -orientation. Which is not the case for -free orientable graphs. Recall that a graph is locally bipartite if the open neighbourhood of every vertex induces a bipartite graph.

###### Proposition 12.

For any graph the following statements hold:

• if is -colourable, then it admits a -free orientation,

• if admits a -free orientation, then it is -free,

• if admits a -free orientation, then it is locally bipartite.

###### Proof.

Let be graph with a proper colouring . By orienting the edges of from to , with subindices taken modulo 3, we obtain a -free orientation of . In order to prove the second item, it suffices to notice that does not admit a -free orientation. Let be a -free orientation of a graph . For any vertex , the sets and are a partition of . Since is -free, and are independent sets. ∎

As we will see later, the statements in the previous proposition are far from being necessary and sufficient conditions for a graph to admit a

-free orientation. For the moment, recall the well known result of Mycielski stating that the chromatic number on triangle-free graphs is unbounded

mycielskiCM1995 . Thus, there are graphs with arbitrary large chromatic number that admit a -free orientation. Nonetheless, for perfect graph, the first condition of the previous proposition actually characterizes graphs admitting a -free orientation.

###### Proposition 13.

A perfect graph admits a -free orientation if and only if it is -colourable.

###### Proof.

Consider a perfect graph . By Proposition 12, if is -colourable it admits a -free orientation. On the other hand, suppose that admits a -free orientation. By Proposition 12, is -free. Since is perfect, is -colourable. ∎

Since comparability graphs are perfect graphs, the following proposition stems from Proposition 13.

###### Proposition 14.

A graph admits a -free orientation if and only if it is a -colourable comparability graph.

###### Proof.

If a graph admits a -free orientation, then it is a comparability graph. Thus, is a perfect graph that admits a -free orientation. By Proposition 13, is a -colourable comparability graph. Now suppose that is a -colourable comparability graph. Since is perfect, it is -free. Consider the partial order of the vertices, , induced by the edges of . Let is -minimal, is -maximal and . It follows from the construction of , , and the fact that is -free, that the sets is an independent set for . Orient the edges from to , from to and from to ; name this orientation . Clearly, is -free. In order to show that is also -free, consider three vertices , that induce a path on . Since does not induce a triangle, it may not happen that . Thus and , or and . Then induces either a or in . Concluding that is a -free orientation of . ∎

Before proceeding to study the non perfect graphs that admit a -free orientation, allow us to study two very simple subclasses.

###### Proposition 15.

A graph admits a -free orientation if and only if . Equivalently, admits a -free orientation if and only is a dijsoint union of paths and cycles.

###### Proof.

Recall that if and only if is a disjoint union of paths and cycles. Suppose that there is a vertex with at least three distinct neighbours, . Let be an orientation of . Without loss of generality, and will be in-neighbours of in . If then will induce a in . On the other hand, if , will induce a in . Thus if , does not admit a -free orientation. To conclude the proof, consider a disjoint union of paths and cycles . By orienting every cycle and path of in a directed way, we obtain a -free orientation of . ∎

###### Proposition 16.

A connected graph admits a -free orientation if and only if is a star or a triangle.

###### Proof.

It is trivial to find a -free orientation of a star or a triangle. Recall that a connected graph is a star if and only if is -free. Notice that neither nor admit a -free orientation. Thus if does not contain a triangle and admits a -free orientation, is a star. On the contrary, if contains a triangle, observe that neither of the three connected supergraphs of on four vertices, admit a -free orientation. Thus, if contains a triangle , then . ∎

## 4 {T3}-graphs

The following results build up to characterize the family of graphs that admit a -free orientation.

###### Proposition 17.

Consider a set of tournaments and an -graph . If a graph admits a homomorphism , then admits an -free orientation.

###### Proof.

Consider an -free orientation of . We obtain an orientation of in the following way, there is an arc in if and only if is an arc in . Since is a graph homomorphism, by the way we chose to orient the edges of , induces a digraph homomorphism . Thus, every tournament in , can be embedded in . Since consists of tournaments and is an -free orientation of , is also an -free orientation of . ∎

If a graph admits a homomorphism to another graph , we write ; and otherwise. If is a set of graphs, we write , if for every graph .

###### Corollary 18.

For every set of tournaments , there is a set of graphs such that for any graph , admits an -free orientation if and only if .

###### Proof.

By Proposition 17 an example of such a set, is the set of graphs that do not admit an -free orientation. ∎

Corollary 18 motivates the characterization we propose of -graphs; i.e. we find a set of graphs, , such that a graph admits a -free orientation if and only if . First we introduce some definitions. Consider two paths and such that . If we embed and in two distinct parallel lines on the plane, add the edges , and triangulate the inside region of the resulting cycle in such a way that each of the new edges has one end in and the other in , we say that the resulting embedded graph is a t-embedding of and . Any graph that admits an isomorphic embedding to a t-embedding of and will be called a t-join of and . A graph obtained from a t-join, , of two paths, and , by identifying with and with is called a donut. If we identify with and with it is called a Möbius donut. In both cases we say that is the spanning t-join of the t-(Möbius) donut; and will be the underlying paths. Note that if one of the underlying paths only has one vertex, then the donut is a wheel. In order to avoid loops, we will not consider donuts when both of the underlying paths are on two vertices, nor Möbius donuts when either of the initial or final vertices of () is adjacent to all vertices of (). As a final definition, if the number of triangles in the t-join is even will say that the resulting donut (Möbius donut) is an even donut (even Möbius donut); otherwise we say it a is an odd donut (odd Möbius donut).

It is not hard to prove the following statement with an inductive argument.

###### Remark 19.

The number of triangles in a t-join is the sum of the vertices in and minus two.

Donuts and Möbius donuts are defined as quotient graphs. The following remark might reside in the land of trivial results, but will be used in the main proof.

###### Remark 20.

Consider a homomorphism and a relation over such that if then . Then induces a homomorphism .

Recall that denotes the constraint digraph defined in Section 2. From the definition of , it follows that if , for any graph , every arc in is symmetric. Thus, we may think of as a graph. For any graph , we denote by the constraint graph of with the set . Recall that admits a -free orientation if and only if and are in different connected components in for any edge .

###### Lemma 21.

Let be a graph that does not admit a -free orientation, then there is an odd donut or an even Möbius donut, , such that .

###### Proof.

Let be an -path in ; i.e. , and for . Recall that each vertex in is an orientation of an edge in , thus, denote by the tail of the arc and by the head of . For instance, and . Since for , induces a triangle in . So , and by definition of one of the following must hold, or . We define the function by if or, if , and for , if or, if . In other words, for , maps the arc to the vertex such that .

Let us observe that for and every vertex , for some . For it follows from the definition of . If and , by definition of , we know that , thus we conclude by induction on . Now, we define the function as if or if , and for , if and if . Notice that for , and . The following claim includes these and additional observations.

###### Claim 0.

For the functions and , and for the following hold,

1. or but not both for ,

2. for every ,

3. if , for every vertex , for some ,

4. for and,

5. and or and .

Since , by Claim 1.3, for every , the set is not an empty set, so we may define . Note that if then , so by Claim 1.5, , hence . With a backward induction argument, if then . We define the function recursively: , and . For an intiger , we define its -predecessor, as , analogously we define its -predecessor, . The following claim follows from the definitions of and ,

###### Claim 0.

For , if () then the following statements hold,

• (),

• if , then the -predecessor of , , is (if , then the -predecessor of , , is ),

• on the other hand, if then (if then ) and,

• , and for , .

We proceed to construct a graph with vertex set . We define recursively. In Figure 2 we show an example of the construction of . First, set and ; . By construction of it is clear that induces a path where and is the -predecessor of , and induce a path where and is the -predecessor of . Since every vertex is adjacent to its and predecessor, proceeding by induction we can notice that is a t-join of and .