Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Diagonalized Cartesian Products of S-prime graphs are S-prime Marc Hellmuth∗,a,b , Lydia Gringmanna , Peter F. Stadlera,b,c,d,e a Bioinformatics Group, Department of Computer Science, and Interdisciplinary Center for Bioinformatics, University of Leipzig, Härtelstraße 16-18, D-04107 Leipzig, Germany b Max Planck Institute for Mathematics in the Sciences, Inselstrasse 22, D-04103 Leipzig, Germany c Fraunhofer Institut für Zelltherapie und Immunologie – IZI Perlickstraße 1, D-04103 Leipzig, Germany d Department of Theoretical Chemistry University of Vienna, Währingerstraße 17, A-1090 Wien, Austria e Santa Fe Institute, 1399 Hyde Park Rd., Santa Fe, NM 87501, USA Abstract A graph is said to be S-prime if, whenever it is a subgraph of a nontrivial Cartesian product graph, it is a subgraph of one of the factors. A diagonalized Cartesian product is obtained from a Cartesian product graph by connecting two vertices of maximal distance by an additional edge. We show there that a diagonalized product of S-prime graphs is again S-prime. Klavžar et al. [Discr. Math. 244: 223-230 (2002)] proved that a graph is S-prime if and only if it admits a nontrivial path-k-coloring. We derive here a characterization of all path-k-colorings of Cartesian products of S-prime graphs. Key words: S-prime, diagonalized Cartesian product, path-k-coloring 1. Introduction and Preliminaries A graph S is said to be S-prime (S stands for “subgraph”) w.r.t. to operation ⋆ if for all graphs G and H with S ⊆ G ⋆ H holds: S ⊆ H or S ⊆ G, where ⋆ denotes an arbitrary graph product. A graph is S-composite if it is not S-prime. The class of S-prime graphs was introduced and characterized for the direct product by Gert Sabidussi in 1975 [10]. He showed that the only S-prime graphs with respect to the direct product are complete graphs or complete graphs minus an edge. Analogous notions of S-prime graphs with respect to other products are due to Lamprey and Barnes [8, 9]. They showed that the only S-prime graphs w.r.t. the strong product and the lexicographic product are the single vertex graph K1 , the disjoint union K1 ∪ K1 and the complete graph on two vertices K2 . Moreover, they characterized S-prime graphs w.r.t. the Cartesian product. We consider finite, simple, connected and undirected graphs G = (V, E). A graph H is a subgraph of a graph G, in symbols H ⊆ G, if V(H) ⊆ V(G) and E(H) ⊆ E(G). We will be concerned here with the Cartesian product GH. It has vertex set V(GH) = V(G) × V(H); two vertices (g1 , h1 ), (g2 , h2 ) are adjacent in GH if (g1 , g2 ) ∈ E(G) and h1 = h2 , or (h1 , h2 ) ∈ E(G2 ) and g1 = g2 . A Cartesian product GH is called trivial if G ≃ K1 or H ≃ K1 . A graph G is prime with respect to the Cartesian product if it has only a trivial Cartesian product representation. For detailed information about product graphs we refer the interested reader to [4] and [5]. In the following we will consider the Cartesian product only. Therefore, the terms S-prime and S-composite refer to this product from here on. S-prime graphs can be characterized in terms of basic S-prime graphs [8, 9]. Following [8, 9], we define basic S-prime graphs recursively: An S-prime graph is basic if it has at least three vertices and contains no proper basic S-prime subgraphs. Moreover, these same authors showed that every S-prime graph is either a basic S-prime graph or can be obtained from basic S-prime graphs using two special operations. The only basic S-prime graphs with less than 7 vertices are K3 and K2,3 . Other examples of S-prime graphs include the complete graphs Kn with n ≥ 1 vertices ∗ Corresponding author Email addresses: marc@bioinf.uni-leipzig.de (Marc Hellmuth), glydia@bioinf.uni-leipzig.de (Lydia Gringmann), studla@bioinf.uni-leipzig.de (Peter F. Stadler) Preprint submitted to Preprint February 8, 2011 and the complete bipartite graphs Km,n with m ≥ 2, n ≥ 3. Not much is known, however, about the structure of (basic) S-prime graphs, although Klavžar et al. [6, 7] and Brešar [1] proved several characterizations of (basic) S-prime graphs. For our purposes, the characterization of S-composite graphs in terms of particular colorings [6] is of most direct interest. Before we proceed, we introduce some notation. Given G = (V, E), we will write G ‡ (uv) for the graph with vertex set V and E ‡ (u, v) for each of the set operations ‡ ∈ {\, ∪, ∩}. The Cartesian product is associative. Therefore, a vertex x of a Cartesian product ni=1Gi is properly “coordinatized” by the vector c(x) := (c1 (x), . . . , cn (x)) whose entries are the vertices ci (x) of its factor graphs Gi . Two adjacent vertices in a Cartesian product graph therefore differ in exactly one coordinate. In a Cartesian product ni=1Gi , the induced subgraph G xj with vertex set {(c1 (x), . . . c j−1 (x), v, c j+1 (x), . . . , cn (x)) ∈ V(G) | v ∈ V(G j )} is isomorphic to the factor G j for every x ∈ V(G). We call this subgraph a G j -layer. Throughout this contribution we will use In = {1, . . . , n} to index the factors. A k-coloring of G is a surjective mapping F : V(G) → {1, . . . , k}. This coloring need not be proper, i.e., adjacent vertices may receive the same color. A path P in G is well-colored by F if for any two consecutive vertices u and v of P we have F(u) , F(v). Following [6], we say that F is a path-k-coloring of G if F(u) , F(v) holds for the endpoints of every well-colored u, v-path P in G. For k = 1 and k = |V| there are trivial path-k-colorings: For k = 1 the coloring is constant and hence there are no well-colored paths. On the other hand if a different color is used for every vertex, then every path, of course, has distinctly colored endpoints. A path-k-coloring is nontrivial if 2 ≤ k ≤ |V(G)| − 1. Theorem 1 ([6]). A connected graph G is S-composite if and only if there exists a nontrivial path-k-coloring. The next corollary, which follows directly from Theorem 1, will be useful in the subsequent discussion. Corollary 1. Consider an S-prime graph S and let F be a path-k-coloring of S . If there are two distinct vertices u, v ∈ V(S ) with F(u) = F(v) then F is constant, i.e., k = 1. Now consider a product graph iGi . We say that all vertices within the Gi -layer Gix have the same color if F(a) = F(b) holds for all vertices a, b ∈ V(Gix ). Note that this does not imply that vertices of different Gi -layer receive the same color. The main topic of this contribution are diagonalized Cartesian product graphs. Definition 1. A graph G is called a diagonalized Cartesian product, if there is an edge (u, v) ∈ E(G) such that H = G \ (uv) is a nontrivial Cartesian product and u and v have maximal distance in H. For an example of a diagonalized Cartesian product see Figure 1. Clearly, diagonalized Cartesian products need u v Figure 1: A diagonalized Cartesian Product of the graph K2 K2 K3 . not be basic S-prime graphs because Cartesian products of basic S-prime graphs contain basic S-prime graphs as their layers. Likewise, diagonalized Cartesian products of K2 ’s, i.e., diagonalized hypercubes, are not basic S-prime graphs in general, even though the graph K2 is not itself a basic S-prime graph. As an example consider the diagonalized hypercube Q2 and Q3 that contain K3 and K2,3 as subgraphs, respectively, see Figure 2. Furthermore, there are families 2 Figure 2: Diagonalized Hypercubes Q2 and Q3 are not basic S-prime, since they contain basic S-prime graphs K3 , resp. K2,3 , highlighted by dashed edges. of (basic) S-prime graphs that are not diagonalized Cartesian products, e.g., K3 , K2,3 and the construction of the graph An in [6]. Nevertheless, in this contribution we will show that diagonalized Cartesian products of S-prime graphs are Sprime. Diagonalized Cartesian products of S-prime graphs play a crucial role in the local prime factor decomposition algorithm for strong product graphs, see [3, 2]. Furthermore, we will give a necessary and sufficient condition for k-colorings of S-prime graphs to be path-k-colorings of Cartesian products of S-prime graphs. 2. Path-k-colorings of Cartesian Products of S-prime graphs Let us start with a brief preview of this section. We first establish that every nontrivial Cartesian product G1 G2 has a nontrivial path-k-coloring. For instance, choose k = |V(G1 )| and assign to every vertex x with coordinates (x1 , x2 ) the color x1 . Given a Cartesian product G = ni=1 S i of S-prime graphs with a nontrivial path-k-coloring F, first we will show that there is an S i -layer on which F is constant. Next, we prove that is true for all S i -layers. We then proceed to show that F is constant even on any H-layer with H =  j∈J S j , provided that certain conditions are satisfied. This eventually leads us to necessary and sufficient conditions for path-k-colorings. This result, in turn, will be demonstrated to imply that diagonalized Cartesian products of S-prime graphs are S-prime. We start our exposition with a simple necessary condition: Lemma 2. Let H ⊆ G and suppose F is a path-k-coloring of G. Then the restriction F|V(H) of F on V(H) is a pathk-coloring of H. Moreover, if V(H) = V(G) and F is a nontrivial path-k-coloring of G, then it is also a nontrivial path-k-coloring of H. Proof. Suppose H is not path-k-colored. Then there is a u, v-path Pu,v in H that is well-colored, but u and v have the same color. This path Pu,v is also contained in G, contradicting the assumption that F is a path-k-coloring of G. The second statement now follows directly from |V(G)| = |V(H)|. Lemma 3. Let F be a nontrivial path-k-coloring of G. Then there are adjacent vertices u, v ∈ V(G) with F(u) = F(v). Proof. Since k ≤ |V(G)| − 1 it follows that there are at least two vertices of the same color, say x and y. Assume now there is a path P x,y from x to y, such that all consecutive vertices have different colors. Then P x,y would be well-colored. But the endpoints of P xy satisfy F(x) = F(y) so that F cannot be a path-k-coloring, a contradiction. Thus there are consecutive, and hence adjacent, vertices with the same color. For later reference, we state the following observation that can be verified by explicitly enumerating all colorings, see Figure 3 for a subset of cases. Lemma 4. The hypercube Q2 = K2 K2 has no path-3-coloring. In particular, every path-2-coloring of Q2 has adjacent vertices with the same color. We next show that F is constant on each S j -layer whenever there is one S j -layer that contains two distinct vertices with the same color. More precisely: 3 4 3 2 2 1 1 1 3 2 1 1 1 1 1 2 1 Figure 3: Possible path-k-coloring of a square Q2 for k = 1, 2, 4. A possible well coloring that is not a path 3-coloring is shown on the right-hand side graph Lemma 5. Let G = ni=1 S i be a given Cartesian product of S-prime graphs and let F be a nontrivial path-k-coloring of G. Furthermore let u, w ∈ V(S uj ) be two distinct vertices satisfying F(u) = F(w). Then F(x) = F(y) holds for all vertices x, y ∈ V(S bj ) in each S j -layer S bj . Proof. Corollary 1 and Lemma 2 imply that all vertices of the layer S uj have the same color. For b ∈ V(S uj ) there is nothing to show. Thus, assume b < V(S uj ), i.e., S uj , S bj , and an arbitrary edge e = (u, v) ∈ E(S uj ). Let ũ ∈ V(S bj ) be the vertex with coordinates c j (ũ) = c j (u). Moreover, let Pu,ũ := (u = u1 , u2 , .., ul = ũ) be a path from u to ũ such that c j (uk ) = c j (u) for all k = 1, . . . , l. None of the edges (uk , uk+1 ) is contained in an S j -layer. By definition of the Cartesian product there is a unique square (u, u2 , v2 , v) where v2 has coordinates ci (v2 ) = ci (u2 ) for i , j and c j (v2 ) = c j (v). Lemma 4 now implies that the only F on the square is either constant or a path-2-coloring, i.e., the assumption F(u) = F(v) implies F(u2 ) = F(v2 ). u Sju2 Sj l−1 v v2 vl−1 vl u u2 ul−1 ũ Sju Sjb b Pu,ũ Figure 4: Idea of the proof of Lemma 5. The path Pu,ũ connects vertices u and uk (k = 2, . . . , l) of distinct S j -layers. If F(uk−1 ) = F(vk−1 ) then the squares (uk−1 , uk , vk , vk−1 ) located in adjacent S j -layers must admit a path-1-coloring or a path-2-coloring, enforcing that uk and vk must have the u same color. This, in turn, is used to show that F is constant on the entire layer S j k . By induction on the length of the path Pu,ũ we see that F(uk ) = F(vk ), whenever ci (vk ) = ci (uk ) for all i , j and c j (vk ) = c j (v). The assumption ũ ∈ V(S bj ) and our choice of the coordinates implies (ul , vl ) = (ũ, vl ) ∈ E(S bj ). We apply Lemma 4 to the square (ul−1 , ũ, vl , vl−1 ) with F(ul−1 ) = F(vl−1 ) to infer F(ũ) = F(vl ). Corollary 1 and Lemma 2 imply that for all vertices x, y ∈ V(S bj ) holds F(x) = F(y). It is important to notice that Lemma 5 only implies that F is constant on S j -layers, but it does not imply that all S j -layers receive the same color. Corollary 2. Let G = ni=1 S i be a given product of S-prime graphs and let F be a nontrivial path-k-coloring of G. Then there is a j ∈ In such that, for every v ∈ V(G), F is constant on S vj . Proof. The assertion follows directly from Lemma 3, Lemma 5, and the definition of the Cartesian product. Lemma 6. Let F be a nontrivial path-k-coloring of the Cartesian product G = ni=1 S i of S-prime graphs S i . Let H =  j∈J S j be the product of a subset of factors of G, where J ⊆ In denotes an arbitrary subset of indices. Moreover, let H a be an H-layer such that F is constant on V(H a ). Then F is constant within each H-layer. 4 Proof. Let H a be an H-layer defined as above and assume H a , H b . By assumption, F is constant on V(H a ). Thus F is also constant on each S j -layer S j ⊆ H a , j ∈ J, and Lemma 5 then implies that F is also constant within every S j -layer with j ∈ J. Now choose two arbitrary vertices x, y ∈ V(H b ). By connectedness of H b there is a path P x,y from x to y consisting only of vertices of this H-layer H b . Notice that any two consecutive vertices xk , xk+1 ∈ P x,y are contained in some S j -layer such that j ∈ J and therefore F(xk ) = F(xk+1 ). Therefore, the coloring F must be constant along P, hence F(x) = F(y). Thus F is constant on V(H b ). Next we consider two (not necessarily prime) factors H1 , H2 of a Cartesian product of S-prime graphs and ask under which conditions a path-k-coloring on (H1 H2 )-layers must be constant. Lemma 7. Let F be a nontrivial path-k-coloring on the Cartesian product G = ni=1 S i of S-prime graphs S i . Let H1 =  j∈J S j and H2 = k∈K S k be two distinct Cartesian products of factors S i of G, where J, K ⊆ In and J ∩ K = ∅. Then F is constant on each (H1 H2 )-layer whenever F is constant on some H1 -layer H1a and on some H2 -layer H2b . Proof. Let H1a and H2b as constructed above. Lemma 6 implies that all vertices within each H1 layer and within each H2 -layer, resp., have the same color. For all vertices z ∈ V(H1a ) there is an H2 -layer H2z , Thus for all vertices x, y ∈ V(H2z ) holds F(x) = F(y) = F(z) = F(a). By definition of the Cartesian product, this implies in particular that all vertices within the layer (H1 H2 )a have the same color F(a). Hence we can apply Lemma 6 and conclude that all vertices within each (H1 H2 )-layer have the same color. Now we are in the position to characterize nontrivial path-k-colorings. Lemma 8. Let F be a nontrivial path-k-coloring of the Cartesian product G = ni=1 S i of S-prime graphs S i , and consider two distinct vertices u, v ∈ V(G) satisfying F(u) = F(v). Let J = { j | c j (u) , c j (v)} ⊆ In denote the index set of the coordinates in which u and v differ, and let H =  j∈J S j be the Cartesian product of the corresponding factors S j of G. Then F is constant within each H-layer H b . Proof. First assume that v ∈ V(S lu ) for some l, which implies that J = {l} by definition of the Cartesian product. In this case, the statement follows directly from Lemma 5. Now assume that there is no l such that v ∈ V(S lu ). Lemma 5 and Corollary 2 together imply that there is an index i such that all vertices within each S i -layer have the same color. In particular, this is true for S iu and S iv . Together with Lemma 5, this observation implies that, since F(u) = F(v), F is constant on V(S iu ) ∪ V(S iv ). Now let ũ ∈ V(S iv ) be the vertex with coordinates ci (u) = ci (ũ) and denote by J1 = { j | c j (u) , c j (ũ)} = J \ {i} the set of indices in which the coordinates of u and ũ differ. Notice that J \ {i} = J, if v = ũ. Let Pu,ũ := (u = u1 , u2 , .., uk = ũ) be a path from u to ũ such that for all vertices x ∈ Pu,ũ holds cr (x) = cr (u) for all r ∈ In \ J1 . In other words, no edge of an S r -layer, r < J1 is contained in the path Pu,ũ , and hence in particular no edge of an S i -layer. From F(u) = F(ũ) and the fact that G is path-k-colored, we can conclude that there is an edge (ul , ul+1 ) ∈ Pu,ũ of some layer different from S i such that F(ul ) = F(ul+1 ). These consecutive vertices ul and ul+1 differ in exactly one coordinate c j1 for some j1 ∈ J1 , hence ul and ul+1 are contained in some S j1 -layer. Lemma 5 implies that all vertices of this layer S uj1l and therefore all vertices within each S j1 -layer have the same color. Lemma 7 now implies that F is constant on each H1 -layer with H1 = S i S j1 , and in particular, all vertices x, y ∈ V(H1u ) ∪ V(H1v ) have the same color, we have again two different layers that have the same color. Just as before we will construct a path between these layers, which implies that the endpoints of this path have the same color. Since G is path-k-colored, this path must contain an edge (ut , ut+1 ) with F(ut ) = F(ut+1 ). More precisely, let ũ be a vertex of this new H1 -layer H1v such that ci (ũ) = ci (u) and c j1 (ũ) = c j1 (u). Again we choose a Path Pu,ũ constructed as above, where J1 is replaced by J2 = J1 \ { j1 }. In other words for all vertices x ∈ Pu,ũ holds cr (x) = cr (u) for all r ∈ In \ J2 , i.e. in particular no edge of Pu,ũ is contained in any H1 -layer. Notice that |J2 | = |J1 | − 1. Again we can conclude that there are consecutive vertices ut , ut+1 ∈ Pu,ũ such that F(ut ) = F(ut+1 ), since F(ũ) = F(u) and G is path-k-colored. Let these consecutive vertices ut and ut+1 differ in coordinate c j2 for some j2 ∈ J2 . Using the same arguments as before we can infer that all vertices in between each H2 = (S i S j1 S j2 )-layer must have the same color. Repeating this procedure generates, in each step, a newindex set J s with |J s | = |J s−1 | − 1 for s = 2, . . . , |J1 |, and all vertices within each H s -layer with H s = S i   j∈J1 \Js S j S js for some j s ∈ J s are shown to have the same color. For s∗ = |J1 | we have |J s∗ | = 1. Moreover the path Pu,ũ with cr (ũ) = cr (u) for all r ∈ In \ { j∗ } with j∗ ∈ J s∗ consists only 5 H1ul H1u Siu Siul Sju1 H1v Sju1l Siv v Sjũ1 ul+1 u Pu,ũ ul ũ Figure 5: Idea of the proof of Lemma 8. The path Pu,ũ connects a pair of vertices with the same color in S iu to S iv . It therefore must contain two u u consecutive vertices ul and ul+1 with the same color. It follows that all vertices within the layer S i l and S j l have the same color F(ul ) and finally 1 one shows that all vertices within each H1 -layer with H1 = S i S j1 have the same color. of vertices that are included in this S j∗ -layer S uj∗ . Since F(u) = F(ũ) and u, ũ ∈ S uj∗ we can conclude that all vertices x ∈ S uj∗ have the same color F(u). From Lemma 6 and Lemma 7 it follows that F is constant on each H s∗ -layer, where   H s∗ = S i ( j∈J1 \Js∗ S j )S j∗ . Since {i} ∪ (J1 \ J s∗ ) ∪ { j∗ } = {i} ∪ ((J \ {i}) \ { j∗ }) ∪ { j∗ } = J, we conclude that all   vertices within each  j∈J S j -layer have the same color, completing the proof of the lemma. Since two vertices with maximal distance contained in a Cartesian product of nontrivial factors differ in all coordinates we can conclude the following corollary. Corollary 3. Let F be a path-k-coloring of the Cartesian product G = ni=1 S i of S-prime graphs S i and suppose u, v ∈ V(G) are two vertices with maximal G-distance that have the same color. Then F is constant on G, i.e., k = 1. 3. Main Results We are now in the position to give a complete characterization of path-k-colorings of Cartesian products of S-prime graphs. Theorem 9 (Path-k-coloring of Cartesian products of S-prime Graphs). Let G = nj=1 S j be a Cartesian product of S-prime graphs, and let F be a k-coloring of G. Then F is a path-k-coloring of G if and only if there exists an index set I ⊆ In such that the following two conditions hold for the graph H defined as H = i∈I S i for I , ∅ and H = K1 for I = ∅. 1. F(a) = F(b) for all a, b ∈ V(H x ) for all x ∈ V(G) and 2. F(a) , F(b) for all a ∈ V(H x ) and b ∈ V(H y ) with H x , H y . The coloring F consists of k = |V(G)|/|V(H)| distinct colors. F is nontrivial if and only if I , In and I , ∅. Proof. Let F be an arbitrary path-k-coloring of G. If F is trivial, then it follows that k = 1 or k = |V(G)| and thus we can conclude that I = In or I = ∅, respectively. In both cases, conditions (1) and (2) are satisfied. If F is nontrivial, then k ≤ |V(G)| − 1 and there are two vertices with the same color. Conditions (1) and (2) now follow directly from Lemma 7 and Lemma 8. We will prove the converse by contraposition. Thus assume that F satisfied properties (1) and (2) for some I ⊆ In and F is not a path-k-coloring of G. Thus, there must be a well colored path Pu,v between two vertices u and v with F(u) = F(v). If there is an edge (a, b) ∈ Pu,v such that (a, b) is contained in an H-layer H x for some x ∈ V(G) we would contradict Condition (1). Thus assume there is no edge (a, b) ∈ Pu,v that lies in any H-layer. Notice that this 6 implies that u and v are not contained in the same H-layer, otherwise some edge (a, b) ∈ Pu,v must be an edge of an H-layer, by definition of the Cartesian product. Since Pu,v is a well colored path between u and v with F(u) = F(v) and H u , H v , we contradict Condition (2). It remains to show that F consists of k = |V(G)|/|V(H)| different colors. For I = In and I = ∅ this assertion is trivially true. Therefore assume I , In and I , ∅. Condition (2) implies that all pairwise different H-layer are colored differently and from Condition (1) we can conclude that all vertices in between each H-layer have the same color. Thus we have just as many colors as H-layers exists. In a Cartesian product G = HH ′ the number of different H-layers is |V(H ′ )| = |V(G)|/|V(H)| and thus k = |V(G)|/|V(H)|. Finally, we have to show that F is nontrivial if and only if I , In and I , ∅. If F is nontrivial the assumption is already shown at the beginning of this proof. Thus assume now that I = In , i.e., H = i∈I S i = G. Condition (1) implies that all vertices v ∈ V(G) have the same color and hence k = 1, contradicting that F is nontrivial. Now let I = ∅, i.e. H = K1 . As for all vertices v, x ∈ V(G) holds v ∈ V(K1x ) if and only if v = x, we can conclude that F(a) , F(b) for all a, b ∈ V(G). Hence k = |V(G)|, again contradicting that F is nontrivial. In the following, let F I denote a path-k-coloring F of a Cartesian product G of S-prime graphs S i that satisfies the conditions of Theorem 9 with index set I. We can now proceed proving the main result of this contribution. Theorem 10. The diagonalized Cartesian Product of S-prime graphs is S-prime. Proof. Let G = H ∪ (uv) be a diagonalized Cartesian product of graphs S i , i.e., H = ni=1 S i is a Cartesian product of S-prime graphs and the vertices u and v have maximal distance in H. Lemma 2 shows that any nontrivial pathk-coloring of G gives rise to a nontrivial path-k-coloring of H, which in turn implies that there is a nontrivial subset I ⊂ In and an according nontrivial path-k-coloring F I such that the conditions of Theorem 9 are satisfied for H. We can conclude that F I (u) , F I (v), since otherwise the coloring of H is trivial with k = 1 according to Corollary 3 and F I would be constant. Let HI denote the Cartesian product i∈I S i of prime factors of G and let HIu and HIv be the HI − layer containing u and v, respectively. Clearly, HIu , HIv , since I , {1, . . . , n}, by definition of the Cartesian product and since u and v have maximal distance in H. Let ũ ∈ V(S iv ) be the vertex with coordinates ci (ũ) = ci (u) for all i ∈ I. Note that v , ũ, because ci (ũ) = ci (u) , ci (v) for all i ∈ I, otherwise u and v would not have maximal distance. Let Pu,ũ be a path between u and ũ such that for all vertices x ∈ Pu,ũ holds ci (x) = ci (u) for all i ∈ I. Thus no edge of any HI -layer is contained in this path Pu,ũ . From Theorem 9 and the fact that F I is nontrivial, it follows that F I (a) , F I (b) for all a ∈ V(HIx ) and b ∈ V(HIy ) with HIx , HIy . This is true in particular also for any two distinct vertices a and b in the path Pu,ũ , since HIa , HIb by choice of the coordinates. Thus Pu,ũ is well colored. Moreover it holds F I (u) , F I (ũ). HIv HIu v u Pu,ũ ũ Figure 6: Sketch of the proof of Theorem 10. The HI -layers HIu and HIv are connected by a well-colored path Pu,ũ with distinct colors at the endpoints, F I (u) , F I (ũ). The path P∗ = Pu,ũ ∪ (u, v) is well colored, but F I (u) = F I (v), i.e., F I is not a path-k-coloring. Now consider the path P∗ = Pu,ũ ∪ (u, v) in G, which is by construction a well colored path from v to ũ. However, F I (v) = F I (ũ). Thus F I is not a path-k-coloring of G for any nontrivial I ⊂ In . Theorem 1 and Lemma 2 imply that G = H ∪ (uv) is S-prime, from what the assumption follows. 7 4 1 2 2 1 3 4 3 1 2 4 3 3 4 4 1 2 1 3 2 Figure 7: Shown are two diagonalized Cartesian products that have a nontrivial path-4-coloring. Therefore these graphs are S-composite. Corollary 4. Diagonalized Hamming graphs, and thus diagonalized Hypercubes, are S-prime. We conclude our presentation with an example that shows that not every diagonalized Cartesian product is Sprime, see Figure 7, and open problems: Problem 1. Are there other classes of diagonalized Cartesian products that are S-prime? Problem 2. Which of the (known) families of S-prime graphs that are not diagonalized Cartesian products can be nontrivially isometrically embedded into diagonalized Cartesian products of S-prime graphs, i.e., they are not contained in single layers? References [1] B. Brešar. On subgraphs of Cartesian product graphs and S-primeness. Discr. Math., 282:43–52, 2004. [2] M Hellmuth. Local Prime Factor Decomposition of Approximate Strong Product Graphs. PhD thesis, University Leipzig, Department of Mathematics and Computer Science, 2010. [3] M. Hellmuth. A local prime factor decomposition algorithm. Discr. Math., 2011. accepted. [4] W. Imrich and S Klavžar. Product graphs. Wiley-Interscience Series in Discrete Mathematics and Optimization. Wiley-Interscience, New York, 2000. [5] W. Imrich, S. Klavžar, and F. D. Rall. Topics in Graph Theory: Graphs and Their Cartesian Product. AK Peters, Ltd., Wellesley, MA, 2008. [6] S. Klavžar, A. Lipovec, and M. Petkovšek. On subgraphs of Cartesian product graphs. Discr. Math., 244:223–230, 2002. [7] S. Klavžar and I. Peterin. Characterizing subgraphs of Hamming graphs. J. Graph Theory, 49(4):302–312, 2005. [8] R. H. Lamprey and B. H. Barnes. A new concept of primeness in graphs. Networks, 11:279–284, 1981. [9] R. H. Lamprey and B. H. Barnes. A characterization of Cartesian-quasiprime graphs. Congressus Numerantium, 109:117–121, 1995. [10] G. Sabidussi. Subdirect representations of graphs in infinite and finite sets. Colloq. Math. Soc. Janos Bolyai, 10:1199–1226, 1975. 8