Edges of a complete graph have one of $2$ colors. Prove that every two vertices can be connected by a path of edges of same color of length at most 3.

coloringgraph theory

All edges of a complete graph are colored: each edge with a red or blue color. I need to prove that there exists a color (one of those two) such that every two vertices can be connected by a path with edges of this color of length at most $3$.

Unfortunately, I don't know how to do that, any help would be appreciated.

Best Answer

Suppose $v_1$ and $v_2$ are vertices with no blue path of length at most $3$ joining them, and note that $v_1$ and $v_2$ are joined by a red edge.

Now consider the sets $V_{RB}=\{$ vertices joined by a red edge to $v_1$ and a blue edge to $v_2\}$, $V_{BR}=\{$ vertices joined by a blue edge to $v_1$ and a red edge to $v_2\}$, $V_{RR}=\{$ vertices joined by a red edge to both $v_1$ and $v_2\}$.

There are no vertices which are joined by blue edges to both $v_1$ and $v_2$, by the hypothesis, so every vertex is joined to both $v_1$ and $v_2$ either directly, by a red edge, or by a red path of length $2$ via the other.

Then any two vertices in the same one of these three sets are joined to each other by a red path of length $2$ (via either $v_1$ or $v_2$).

A vertex in $V_{RR}$ is joined to one in $V_{RB}$ or $V_{BR}$ by a red path of length 2 (via either $v_1$ or $v_2$).

Finally, any vertex in $V_{RB}$ is joined by a red edge to one in $V_{BR}$ - if the edge joining them were blue, there would be a blue path of length $3$ from $v_1$ to $v_2$ via these two vertices.

Hence, from the hypothesis that there is a pair of vertices with no blue path of length $3$ between them, we have shown that every pair of vertices is connected by a red path of length at most $3$.