Cartesian product of graphs
In graph theory, the Cartesian product G H of graphs G and H is a graph such that
 the vertex set of G H is the Cartesian product V(G) × V(H); and
 two vertices (u,u' ) and (v,v' ) are adjacent in G H if and only if either
 u = v and u' is adjacent to v' in H, or
 u' = v' and u is adjacent to v in G.
The operation is associative, as the graphs (F G) H and F (G H) are naturally isomorphic. The operation is commutative as an operation on isomorphism classes of graphs, and more strongly the graphs G H and H G are naturally isomorphic, but it is not commutative as an operation on labeled graphs.
The notation G × H has often been used for Cartesian products of graphs, but is now more commonly used for another construction known as the tensor product of graphs. The square symbol is an intuitive and unambiguous notation for the Cartesian product, since it shows visually the four edges resulting from the Cartesian product of two edges.^{[1]}
Examples
 The Cartesian product of two edges is a cycle on four vertices: K_{2} K_{2} = C_{4}.
 The Cartesian product of K_{2} and a path graph is a ladder graph.
 The Cartesian product of two path graphs is a grid graph.
 The Cartesian product of n edges is a hypercube:

 Thus, the Cartesian product of two hypercube graphs is another hypercube: Q _{i} Q _{j} = Q _{i+j}.
 The Cartesian product of two median graphs is another median graph.
 The graph of vertices and edges of an nprism is the Cartesian product graph K_{2} C_{n}.
 The rook's graph is the Cartesian product of two complete graphs.
Properties
If a connected graph is a Cartesian product, it can be factorized uniquely as a product of prime factors, graphs that cannot themselves be decomposed as products of graphs.^{[2]} However, Imrich & Klavžar (2000) describe a disconnected graph that can be expressed in two different ways as a Cartesian product of prime graphs:
 (K _{1} + K _{2} + K _{2} ^{2}) (K _{1} + K _{2} ^{3}) = (K _{1} + K _{2} ^{2} + K _{2} ^{4}) (K _{1} + K _{2}),
where the plus sign denotes disjoint union and the superscripts denote exponentiation over Cartesian products.
A Cartesian product is vertex transitive if and only if each of its factors is.^{[3]}
A Cartesian product is bipartite if and only if each of its factors is. More generally, the chromatic number of the Cartesian product satisfies the equation
 χ(G H) = max {χ(G), χ(H)}. ^{[4]}
The Hedetniemi conjecture states a related equality for the tensor product of graphs. The independence number of a Cartesian product is not so easily calculated, but as Vizing (1963) showed it satisfies the inequalities
 α( G)α( H) + min{V( G)α( G),V( H)α( H)} ≤ α( G H) ≤ min{α( G) V( H), α( H) V( G)}.
The Vizing conjecture states that the domination number of a Cartesian product satisfies the inequality
 γ( G H) ≥ γ( G)γ( H).
The Cartesian product of unit distance graphs is another unit distance graph.^{[5]}
Cartesian product graphs can be recognized efficiently, in linear time.^{[6]}
Algebraic graph theory
Algebraic graph theory can be used to analyse the Cartesian graph product. If the graph has vertices and the adjacency matrix , and the graph has vertices and the adjacency matrix , then the adjacency matrix of the Cartesian product of both graphs is given by
 ,
where denotes the Kronecker product of matrices and denotes the identity matrix.^{[7]} The adjacency matrix of the Cartesian graph product is therefore the Kronecker sum of the adjacency matrices of the factors.
History
According to Imrich & Klavžar (2000), Cartesian products of graphs were defined in 1912 by Whitehead and Russell. They were repeatedly rediscovered later, notably by Gert Sabidussi (1960).