combinatorics.simple_graph.prodMathlib.Combinatorics.SimpleGraph.Prod

This file has been ported!

Changes since the initial port

The following section lists changes to this file in mathlib3 and mathlib4 that occured after the initial port. Most recent changes are shown first. Hovering over a commit will show all commits associated with the same mathlib3 commit.

Changes in mathlib3

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(last sync)

Changes in mathlib3port

mathlib3
mathlib3port
Diff
@@ -45,7 +45,7 @@ and `(a, b₁)` and `(a, b₂)` if `H` relates `b₁` and `b₂`. -/
 def boxProd (G : SimpleGraph α) (H : SimpleGraph β) : SimpleGraph (α × β)
     where
   Adj x y := G.Adj x.1 y.1 ∧ x.2 = y.2 ∨ H.Adj x.2 y.2 ∧ x.1 = y.1
-  symm x y := by simp [and_comm', or_comm', eq_comm, adj_comm]
+  symm x y := by simp [and_comm, or_comm, eq_comm, adj_comm]
   loopless x := by simp
 #align simple_graph.box_prod SimpleGraph.boxProd
 -/
@@ -81,7 +81,7 @@ theorem boxProd_neighborSet (x : α × β) :
   by
   ext ⟨a', b'⟩
   simp only [mem_neighbor_set, Set.mem_union, box_prod_adj, Set.mem_prod, Set.mem_singleton_iff]
-  simp only [eq_comm, and_comm']
+  simp only [eq_comm, and_comm]
 #align simple_graph.box_prod_neighbor_set SimpleGraph.boxProd_neighborSet
 -/
 
@@ -91,7 +91,7 @@ variable (G H I)
 /-- The box product is commutative up to isomorphism. `equiv.prod_comm` as a graph isomorphism. -/
 @[simps]
 def boxProdComm : G □ H ≃g H □ G :=
-  ⟨Equiv.prodComm _ _, fun x y => or_comm' _ _⟩
+  ⟨Equiv.prodComm _ _, fun x y => or_comm _ _⟩
 #align simple_graph.box_prod_comm SimpleGraph.boxProdComm
 -/
 
@@ -100,8 +100,8 @@ def boxProdComm : G □ H ≃g H □ G :=
 @[simps]
 def boxProdAssoc : G □ H □ I ≃g G □ (H □ I) :=
   ⟨Equiv.prodAssoc _ _ _, fun x y => by
-    simp only [box_prod_adj, Equiv.prodAssoc_apply, or_and_right, or_assoc', Prod.ext_iff,
-      and_assoc', @and_comm (x.1.1 = _)]⟩
+    simp only [box_prod_adj, Equiv.prodAssoc_apply, or_and_right, or_assoc, Prod.ext_iff, and_assoc,
+      @and_comm (x.1.1 = _)]⟩
 #align simple_graph.box_prod_assoc SimpleGraph.boxProdAssoc
 -/
 
@@ -272,7 +272,7 @@ instance boxProdFintypeNeighborSet (x : α × β) [Fintype (G.neighborSet x.1)]
       by
       simp_rw [Finset.mem_disjUnion, Finset.mem_product, Finset.mem_singleton, mem_neighbor_finset,
         mem_neighbor_set, Equiv.refl_apply, box_prod_adj]
-      simp only [eq_comm, and_comm'])
+      simp only [eq_comm, and_comm])
 #align simple_graph.box_prod_fintype_neighbor_set SimpleGraph.boxProdFintypeNeighborSet
 -/
 
Diff
@@ -213,13 +213,21 @@ protected theorem Preconnected.boxProd (hG : G.Preconnected) (hH : H.Preconnecte
 
 #print SimpleGraph.Preconnected.ofBoxProdLeft /-
 protected theorem Preconnected.ofBoxProdLeft [Nonempty β] (h : (G □ H).Preconnected) :
-    G.Preconnected := by classical
+    G.Preconnected := by
+  classical
+  rintro a₁ a₂
+  obtain ⟨w⟩ := h (a₁, Classical.arbitrary _) (a₂, Classical.arbitrary _)
+  exact ⟨w.of_box_prod_left⟩
 #align simple_graph.preconnected.of_box_prod_left SimpleGraph.Preconnected.ofBoxProdLeft
 -/
 
 #print SimpleGraph.Preconnected.ofBoxProdRight /-
 protected theorem Preconnected.ofBoxProdRight [Nonempty α] (h : (G □ H).Preconnected) :
-    H.Preconnected := by classical
+    H.Preconnected := by
+  classical
+  rintro b₁ b₂
+  obtain ⟨w⟩ := h (Classical.arbitrary _, b₁) (Classical.arbitrary _, b₂)
+  exact ⟨w.of_box_prod_right⟩
 #align simple_graph.preconnected.of_box_prod_right SimpleGraph.Preconnected.ofBoxProdRight
 -/
 
Diff
@@ -213,21 +213,13 @@ protected theorem Preconnected.boxProd (hG : G.Preconnected) (hH : H.Preconnecte
 
 #print SimpleGraph.Preconnected.ofBoxProdLeft /-
 protected theorem Preconnected.ofBoxProdLeft [Nonempty β] (h : (G □ H).Preconnected) :
-    G.Preconnected := by
-  classical
-  rintro a₁ a₂
-  obtain ⟨w⟩ := h (a₁, Classical.arbitrary _) (a₂, Classical.arbitrary _)
-  exact ⟨w.of_box_prod_left⟩
+    G.Preconnected := by classical
 #align simple_graph.preconnected.of_box_prod_left SimpleGraph.Preconnected.ofBoxProdLeft
 -/
 
 #print SimpleGraph.Preconnected.ofBoxProdRight /-
 protected theorem Preconnected.ofBoxProdRight [Nonempty α] (h : (G □ H).Preconnected) :
-    H.Preconnected := by
-  classical
-  rintro b₁ b₂
-  obtain ⟨w⟩ := h (Classical.arbitrary _, b₁) (Classical.arbitrary _, b₂)
-  exact ⟨w.of_box_prod_right⟩
+    H.Preconnected := by classical
 #align simple_graph.preconnected.of_box_prod_right SimpleGraph.Preconnected.ofBoxProdRight
 -/
 
Diff
@@ -3,7 +3,7 @@ Copyright (c) 2022 George Peter Banyard, Yaël Dillies, Kyle Miller. All rights
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: George Peter Banyard, Yaël Dillies, Kyle Miller
 -/
-import Mathbin.Combinatorics.SimpleGraph.Connectivity
+import Combinatorics.SimpleGraph.Connectivity
 
 #align_import combinatorics.simple_graph.prod from "leanprover-community/mathlib"@"f47581155c818e6361af4e4fda60d27d020c226b"
 
Diff
@@ -2,14 +2,11 @@
 Copyright (c) 2022 George Peter Banyard, Yaël Dillies, Kyle Miller. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: George Peter Banyard, Yaël Dillies, Kyle Miller
-
-! This file was ported from Lean 3 source module combinatorics.simple_graph.prod
-! leanprover-community/mathlib commit f47581155c818e6361af4e4fda60d27d020c226b
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathbin.Combinatorics.SimpleGraph.Connectivity
 
+#align_import combinatorics.simple_graph.prod from "leanprover-community/mathlib"@"f47581155c818e6361af4e4fda60d27d020c226b"
+
 /-!
 # Graph products
 
Diff
@@ -53,26 +53,32 @@ def boxProd (G : SimpleGraph α) (H : SimpleGraph β) : SimpleGraph (α × β)
 #align simple_graph.box_prod SimpleGraph.boxProd
 -/
 
--- mathport name: «expr □ »
 infixl:70 " □ " => boxProd
 
+#print SimpleGraph.boxProd_adj /-
 @[simp]
 theorem boxProd_adj : (G □ H).Adj x y ↔ G.Adj x.1 y.1 ∧ x.2 = y.2 ∨ H.Adj x.2 y.2 ∧ x.1 = y.1 :=
   Iff.rfl
 #align simple_graph.box_prod_adj SimpleGraph.boxProd_adj
+-/
 
+#print SimpleGraph.boxProd_adj_left /-
 @[simp]
 theorem boxProd_adj_left : (G □ H).Adj (a₁, b) (a₂, b) ↔ G.Adj a₁ a₂ := by
   rw [box_prod_adj, and_iff_left rfl, or_iff_left fun h : H.adj b b ∧ _ => h.1.Ne rfl]
 #align simple_graph.box_prod_adj_left SimpleGraph.boxProd_adj_left
+-/
 
+#print SimpleGraph.boxProd_adj_right /-
 @[simp]
 theorem boxProd_adj_right : (G □ H).Adj (a, b₁) (a, b₂) ↔ H.Adj b₁ b₂ := by
   rw [box_prod_adj, and_iff_left rfl, or_iff_right fun h : G.adj a a ∧ _ => h.1.Ne rfl]
 #align simple_graph.box_prod_adj_right SimpleGraph.boxProd_adj_right
+-/
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+#print SimpleGraph.boxProd_neighborSet /-
 theorem boxProd_neighborSet (x : α × β) :
     (G □ H).neighborSet x = G.neighborSet x.1 ×ˢ {x.2} ∪ {x.1} ×ˢ H.neighborSet x.2 :=
   by
@@ -80,6 +86,7 @@ theorem boxProd_neighborSet (x : α × β) :
   simp only [mem_neighbor_set, Set.mem_union, box_prod_adj, Set.mem_prod, Set.mem_singleton_iff]
   simp only [eq_comm, and_comm']
 #align simple_graph.box_prod_neighbor_set SimpleGraph.boxProd_neighborSet
+-/
 
 variable (G H I)
 
@@ -196,6 +203,7 @@ end Walk
 
 variable {G H}
 
+#print SimpleGraph.Preconnected.boxProd /-
 protected theorem Preconnected.boxProd (hG : G.Preconnected) (hH : H.Preconnected) :
     (G □ H).Preconnected := by
   rintro x y
@@ -204,6 +212,7 @@ protected theorem Preconnected.boxProd (hG : G.Preconnected) (hH : H.Preconnecte
   rw [← @Prod.mk.eta _ _ x, ← @Prod.mk.eta _ _ y]
   exact ⟨(w₁.box_prod_left _ _).append (w₂.box_prod_right _ _)⟩
 #align simple_graph.preconnected.box_prod SimpleGraph.Preconnected.boxProd
+-/
 
 #print SimpleGraph.Preconnected.ofBoxProdLeft /-
 protected theorem Preconnected.ofBoxProdLeft [Nonempty β] (h : (G □ H).Preconnected) :
@@ -215,6 +224,7 @@ protected theorem Preconnected.ofBoxProdLeft [Nonempty β] (h : (G □ H).Precon
 #align simple_graph.preconnected.of_box_prod_left SimpleGraph.Preconnected.ofBoxProdLeft
 -/
 
+#print SimpleGraph.Preconnected.ofBoxProdRight /-
 protected theorem Preconnected.ofBoxProdRight [Nonempty α] (h : (G □ H).Preconnected) :
     H.Preconnected := by
   classical
@@ -222,27 +232,36 @@ protected theorem Preconnected.ofBoxProdRight [Nonempty α] (h : (G □ H).Preco
   obtain ⟨w⟩ := h (Classical.arbitrary _, b₁) (Classical.arbitrary _, b₂)
   exact ⟨w.of_box_prod_right⟩
 #align simple_graph.preconnected.of_box_prod_right SimpleGraph.Preconnected.ofBoxProdRight
+-/
 
+#print SimpleGraph.Connected.boxProd /-
 protected theorem Connected.boxProd (hG : G.Connected) (hH : H.Connected) : (G □ H).Connected := by
   haveI := hG.nonempty; haveI := hH.nonempty; exact ⟨hG.preconnected.box_prod hH.preconnected⟩
 #align simple_graph.connected.box_prod SimpleGraph.Connected.boxProd
+-/
 
+#print SimpleGraph.Connected.ofBoxProdLeft /-
 protected theorem Connected.ofBoxProdLeft (h : (G □ H).Connected) : G.Connected :=
   by
   haveI := (nonempty_prod.1 h.nonempty).1; haveI := (nonempty_prod.1 h.nonempty).2
   exact ⟨h.preconnected.of_box_prod_left⟩
 #align simple_graph.connected.of_box_prod_left SimpleGraph.Connected.ofBoxProdLeft
+-/
 
+#print SimpleGraph.Connected.ofBoxProdRight /-
 protected theorem Connected.ofBoxProdRight (h : (G □ H).Connected) : H.Connected :=
   by
   haveI := (nonempty_prod.1 h.nonempty).1; haveI := (nonempty_prod.1 h.nonempty).2
   exact ⟨h.preconnected.of_box_prod_right⟩
 #align simple_graph.connected.of_box_prod_right SimpleGraph.Connected.ofBoxProdRight
+-/
 
+#print SimpleGraph.boxProd_connected /-
 @[simp]
 theorem boxProd_connected : (G □ H).Connected ↔ G.Connected ∧ H.Connected :=
   ⟨fun h => ⟨h.ofBoxProdLeft, h.ofBoxProdRight⟩, fun h => h.1.boxProd h.2⟩
 #align simple_graph.box_prod_connected SimpleGraph.boxProd_connected
+-/
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
@@ -262,6 +281,7 @@ instance boxProdFintypeNeighborSet (x : α × β) [Fintype (G.neighborSet x.1)]
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+#print SimpleGraph.boxProd_neighborFinset /-
 theorem boxProd_neighborFinset (x : α × β) [Fintype (G.neighborSet x.1)]
     [Fintype (H.neighborSet x.2)] [Fintype ((G □ H).neighborSet x)] :
     (G □ H).neighborFinset x =
@@ -273,13 +293,16 @@ theorem boxProd_neighborFinset (x : α × β) [Fintype (G.neighborSet x.1)]
   refine' Eq.trans _ Finset.attach_map_val
   convert Finset.map_map _ (Function.Embedding.subtype _) Finset.univ
 #align simple_graph.box_prod_neighbor_finset SimpleGraph.boxProd_neighborFinset
+-/
 
+#print SimpleGraph.boxProd_degree /-
 theorem boxProd_degree (x : α × β) [Fintype (G.neighborSet x.1)] [Fintype (H.neighborSet x.2)]
     [Fintype ((G □ H).neighborSet x)] : (G □ H).degree x = G.degree x.1 + H.degree x.2 :=
   by
   rw [degree, degree, degree, box_prod_neighbor_finset, Finset.card_disjUnion]
   simp_rw [Finset.card_product, Finset.card_singleton, mul_one, one_mul]
 #align simple_graph.box_prod_degree SimpleGraph.boxProd_degree
+-/
 
 end SimpleGraph
 
Diff
@@ -209,18 +209,18 @@ protected theorem Preconnected.boxProd (hG : G.Preconnected) (hH : H.Preconnecte
 protected theorem Preconnected.ofBoxProdLeft [Nonempty β] (h : (G □ H).Preconnected) :
     G.Preconnected := by
   classical
-    rintro a₁ a₂
-    obtain ⟨w⟩ := h (a₁, Classical.arbitrary _) (a₂, Classical.arbitrary _)
-    exact ⟨w.of_box_prod_left⟩
+  rintro a₁ a₂
+  obtain ⟨w⟩ := h (a₁, Classical.arbitrary _) (a₂, Classical.arbitrary _)
+  exact ⟨w.of_box_prod_left⟩
 #align simple_graph.preconnected.of_box_prod_left SimpleGraph.Preconnected.ofBoxProdLeft
 -/
 
 protected theorem Preconnected.ofBoxProdRight [Nonempty α] (h : (G □ H).Preconnected) :
     H.Preconnected := by
   classical
-    rintro b₁ b₂
-    obtain ⟨w⟩ := h (Classical.arbitrary _, b₁) (Classical.arbitrary _, b₂)
-    exact ⟨w.of_box_prod_right⟩
+  rintro b₁ b₂
+  obtain ⟨w⟩ := h (Classical.arbitrary _, b₁) (Classical.arbitrary _, b₂)
+  exact ⟨w.of_box_prod_right⟩
 #align simple_graph.preconnected.of_box_prod_right SimpleGraph.Preconnected.ofBoxProdRight
 
 protected theorem Connected.boxProd (hG : G.Connected) (hH : H.Connected) : (G □ H).Connected := by
Diff
@@ -175,7 +175,7 @@ theorem ofBoxProdLeft_boxProdLeft [DecidableEq β] [DecidableRel G.Adj] :
     by
     rw [walk.box_prod_left, map_cons, of_box_prod_left, Or.by_cases, dif_pos, ← walk.box_prod_left,
       of_box_prod_left_box_prod_left]
-    exacts[rfl, ⟨h, rfl⟩]
+    exacts [rfl, ⟨h, rfl⟩]
 #align simple_graph.walk.of_box_prod_left_box_prod_left SimpleGraph.Walk.ofBoxProdLeft_boxProdLeft
 -/
 
@@ -188,7 +188,7 @@ theorem ofBoxProdLeft_boxProdRight [DecidableEq α] [DecidableRel G.Adj] :
     by
     rw [walk.box_prod_right, map_cons, of_box_prod_right, Or.by_cases, dif_pos, ←
       walk.box_prod_right, of_box_prod_left_box_prod_right]
-    exacts[rfl, ⟨h, rfl⟩]
+    exacts [rfl, ⟨h, rfl⟩]
 #align simple_graph.walk.of_box_prod_left_box_prod_right SimpleGraph.Walk.ofBoxProdLeft_boxProdRight
 -/
 
Diff
@@ -56,45 +56,21 @@ def boxProd (G : SimpleGraph α) (H : SimpleGraph β) : SimpleGraph (α × β)
 -- mathport name: «expr □ »
 infixl:70 " □ " => boxProd
 
-/- warning: simple_graph.box_prod_adj -> SimpleGraph.boxProd_adj is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β} {x : Prod.{u1, u2} α β} {y : Prod.{u1, u2} α β}, Iff (SimpleGraph.Adj.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) x y) (Or (And (SimpleGraph.Adj.{u1} α G (Prod.fst.{u1, u2} α β x) (Prod.fst.{u1, u2} α β y)) (Eq.{succ u2} β (Prod.snd.{u1, u2} α β x) (Prod.snd.{u1, u2} α β y))) (And (SimpleGraph.Adj.{u2} β H (Prod.snd.{u1, u2} α β x) (Prod.snd.{u1, u2} α β y)) (Eq.{succ u1} α (Prod.fst.{u1, u2} α β x) (Prod.fst.{u1, u2} α β y))))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β} {x : Prod.{u2, u1} α β} {y : Prod.{u2, u1} α β}, Iff (SimpleGraph.Adj.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) x y) (Or (And (SimpleGraph.Adj.{u2} α G (Prod.fst.{u2, u1} α β x) (Prod.fst.{u2, u1} α β y)) (Eq.{succ u1} β (Prod.snd.{u2, u1} α β x) (Prod.snd.{u2, u1} α β y))) (And (SimpleGraph.Adj.{u1} β H (Prod.snd.{u2, u1} α β x) (Prod.snd.{u2, u1} α β y)) (Eq.{succ u2} α (Prod.fst.{u2, u1} α β x) (Prod.fst.{u2, u1} α β y))))
-Case conversion may be inaccurate. Consider using '#align simple_graph.box_prod_adj SimpleGraph.boxProd_adjₓ'. -/
 @[simp]
 theorem boxProd_adj : (G □ H).Adj x y ↔ G.Adj x.1 y.1 ∧ x.2 = y.2 ∨ H.Adj x.2 y.2 ∧ x.1 = y.1 :=
   Iff.rfl
 #align simple_graph.box_prod_adj SimpleGraph.boxProd_adj
 
-/- warning: simple_graph.box_prod_adj_left -> SimpleGraph.boxProd_adj_left is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β} {a₁ : α} {a₂ : α} {b : β}, Iff (SimpleGraph.Adj.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) (Prod.mk.{u1, u2} α β a₁ b) (Prod.mk.{u1, u2} α β a₂ b)) (SimpleGraph.Adj.{u1} α G a₁ a₂)
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β} {a₁ : α} {a₂ : β} {b : α}, Iff (SimpleGraph.Adj.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) (Prod.mk.{u2, u1} α β a₁ a₂) (Prod.mk.{u2, u1} α β b a₂)) (SimpleGraph.Adj.{u2} α G a₁ b)
-Case conversion may be inaccurate. Consider using '#align simple_graph.box_prod_adj_left SimpleGraph.boxProd_adj_leftₓ'. -/
 @[simp]
 theorem boxProd_adj_left : (G □ H).Adj (a₁, b) (a₂, b) ↔ G.Adj a₁ a₂ := by
   rw [box_prod_adj, and_iff_left rfl, or_iff_left fun h : H.adj b b ∧ _ => h.1.Ne rfl]
 #align simple_graph.box_prod_adj_left SimpleGraph.boxProd_adj_left
 
-/- warning: simple_graph.box_prod_adj_right -> SimpleGraph.boxProd_adj_right is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β} {a : α} {b₁ : β} {b₂ : β}, Iff (SimpleGraph.Adj.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) (Prod.mk.{u1, u2} α β a b₁) (Prod.mk.{u1, u2} α β a b₂)) (SimpleGraph.Adj.{u2} β H b₁ b₂)
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β} {a : α} {b₁ : β} {b₂ : β}, Iff (SimpleGraph.Adj.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) (Prod.mk.{u2, u1} α β a b₁) (Prod.mk.{u2, u1} α β a b₂)) (SimpleGraph.Adj.{u1} β H b₁ b₂)
-Case conversion may be inaccurate. Consider using '#align simple_graph.box_prod_adj_right SimpleGraph.boxProd_adj_rightₓ'. -/
 @[simp]
 theorem boxProd_adj_right : (G □ H).Adj (a, b₁) (a, b₂) ↔ H.Adj b₁ b₂ := by
   rw [box_prod_adj, and_iff_left rfl, or_iff_right fun h : G.adj a a ∧ _ => h.1.Ne rfl]
 #align simple_graph.box_prod_adj_right SimpleGraph.boxProd_adj_right
 
-/- warning: simple_graph.box_prod_neighbor_set -> SimpleGraph.boxProd_neighborSet is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β} (x : Prod.{u1, u2} α β), Eq.{succ (max u1 u2)} (Set.{max u1 u2} (Prod.{u1, u2} α β)) (SimpleGraph.neighborSet.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) x) (Union.union.{max u1 u2} (Set.{max u1 u2} (Prod.{u1, u2} α β)) (Set.hasUnion.{max u1 u2} (Prod.{u1, u2} α β)) (Set.prod.{u1, u2} α β (SimpleGraph.neighborSet.{u1} α G (Prod.fst.{u1, u2} α β x)) (Singleton.singleton.{u2, u2} β (Set.{u2} β) (Set.hasSingleton.{u2} β) (Prod.snd.{u1, u2} α β x))) (Set.prod.{u1, u2} α β (Singleton.singleton.{u1, u1} α (Set.{u1} α) (Set.hasSingleton.{u1} α) (Prod.fst.{u1, u2} α β x)) (SimpleGraph.neighborSet.{u2} β H (Prod.snd.{u1, u2} α β x))))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β} (x : Prod.{u2, u1} α β), Eq.{max (succ u2) (succ u1)} (Set.{max u2 u1} (Prod.{u2, u1} α β)) (SimpleGraph.neighborSet.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) x) (Union.union.{max u1 u2} (Set.{max u1 u2} (Prod.{u2, u1} α β)) (Set.instUnionSet.{max u2 u1} (Prod.{u2, u1} α β)) (Set.prod.{u2, u1} α β (SimpleGraph.neighborSet.{u2} α G (Prod.fst.{u2, u1} α β x)) (Singleton.singleton.{u1, u1} β (Set.{u1} β) (Set.instSingletonSet.{u1} β) (Prod.snd.{u2, u1} α β x))) (Set.prod.{u2, u1} α β (Singleton.singleton.{u2, u2} α (Set.{u2} α) (Set.instSingletonSet.{u2} α) (Prod.fst.{u2, u1} α β x)) (SimpleGraph.neighborSet.{u1} β H (Prod.snd.{u2, u1} α β x))))
-Case conversion may be inaccurate. Consider using '#align simple_graph.box_prod_neighbor_set SimpleGraph.boxProd_neighborSetₓ'. -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 theorem boxProd_neighborSet (x : α × β) :
@@ -220,12 +196,6 @@ end Walk
 
 variable {G H}
 
-/- warning: simple_graph.preconnected.box_prod -> SimpleGraph.Preconnected.boxProd is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β}, (SimpleGraph.Preconnected.{u1} α G) -> (SimpleGraph.Preconnected.{u2} β H) -> (SimpleGraph.Preconnected.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β}, (SimpleGraph.Preconnected.{u2} α G) -> (SimpleGraph.Preconnected.{u1} β H) -> (SimpleGraph.Preconnected.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H))
-Case conversion may be inaccurate. Consider using '#align simple_graph.preconnected.box_prod SimpleGraph.Preconnected.boxProdₓ'. -/
 protected theorem Preconnected.boxProd (hG : G.Preconnected) (hH : H.Preconnected) :
     (G □ H).Preconnected := by
   rintro x y
@@ -245,12 +215,6 @@ protected theorem Preconnected.ofBoxProdLeft [Nonempty β] (h : (G □ H).Precon
 #align simple_graph.preconnected.of_box_prod_left SimpleGraph.Preconnected.ofBoxProdLeft
 -/
 
-/- warning: simple_graph.preconnected.of_box_prod_right -> SimpleGraph.Preconnected.ofBoxProdRight is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β} [_inst_1 : Nonempty.{succ u1} α], (SimpleGraph.Preconnected.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H)) -> (SimpleGraph.Preconnected.{u2} β H)
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β} [_inst_1 : Nonempty.{succ u2} α], (SimpleGraph.Preconnected.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H)) -> (SimpleGraph.Preconnected.{u1} β H)
-Case conversion may be inaccurate. Consider using '#align simple_graph.preconnected.of_box_prod_right SimpleGraph.Preconnected.ofBoxProdRightₓ'. -/
 protected theorem Preconnected.ofBoxProdRight [Nonempty α] (h : (G □ H).Preconnected) :
     H.Preconnected := by
   classical
@@ -259,46 +223,22 @@ protected theorem Preconnected.ofBoxProdRight [Nonempty α] (h : (G □ H).Preco
     exact ⟨w.of_box_prod_right⟩
 #align simple_graph.preconnected.of_box_prod_right SimpleGraph.Preconnected.ofBoxProdRight
 
-/- warning: simple_graph.connected.box_prod -> SimpleGraph.Connected.boxProd is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β}, (SimpleGraph.Connected.{u1} α G) -> (SimpleGraph.Connected.{u2} β H) -> (SimpleGraph.Connected.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β}, (SimpleGraph.Connected.{u2} α G) -> (SimpleGraph.Connected.{u1} β H) -> (SimpleGraph.Connected.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H))
-Case conversion may be inaccurate. Consider using '#align simple_graph.connected.box_prod SimpleGraph.Connected.boxProdₓ'. -/
 protected theorem Connected.boxProd (hG : G.Connected) (hH : H.Connected) : (G □ H).Connected := by
   haveI := hG.nonempty; haveI := hH.nonempty; exact ⟨hG.preconnected.box_prod hH.preconnected⟩
 #align simple_graph.connected.box_prod SimpleGraph.Connected.boxProd
 
-/- warning: simple_graph.connected.of_box_prod_left -> SimpleGraph.Connected.ofBoxProdLeft is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β}, (SimpleGraph.Connected.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H)) -> (SimpleGraph.Connected.{u1} α G)
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β}, (SimpleGraph.Connected.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H)) -> (SimpleGraph.Connected.{u2} α G)
-Case conversion may be inaccurate. Consider using '#align simple_graph.connected.of_box_prod_left SimpleGraph.Connected.ofBoxProdLeftₓ'. -/
 protected theorem Connected.ofBoxProdLeft (h : (G □ H).Connected) : G.Connected :=
   by
   haveI := (nonempty_prod.1 h.nonempty).1; haveI := (nonempty_prod.1 h.nonempty).2
   exact ⟨h.preconnected.of_box_prod_left⟩
 #align simple_graph.connected.of_box_prod_left SimpleGraph.Connected.ofBoxProdLeft
 
-/- warning: simple_graph.connected.of_box_prod_right -> SimpleGraph.Connected.ofBoxProdRight is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β}, (SimpleGraph.Connected.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H)) -> (SimpleGraph.Connected.{u2} β H)
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β}, (SimpleGraph.Connected.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H)) -> (SimpleGraph.Connected.{u1} β H)
-Case conversion may be inaccurate. Consider using '#align simple_graph.connected.of_box_prod_right SimpleGraph.Connected.ofBoxProdRightₓ'. -/
 protected theorem Connected.ofBoxProdRight (h : (G □ H).Connected) : H.Connected :=
   by
   haveI := (nonempty_prod.1 h.nonempty).1; haveI := (nonempty_prod.1 h.nonempty).2
   exact ⟨h.preconnected.of_box_prod_right⟩
 #align simple_graph.connected.of_box_prod_right SimpleGraph.Connected.ofBoxProdRight
 
-/- warning: simple_graph.box_prod_connected -> SimpleGraph.boxProd_connected is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β}, Iff (SimpleGraph.Connected.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H)) (And (SimpleGraph.Connected.{u1} α G) (SimpleGraph.Connected.{u2} β H))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β}, Iff (SimpleGraph.Connected.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H)) (And (SimpleGraph.Connected.{u2} α G) (SimpleGraph.Connected.{u1} β H))
-Case conversion may be inaccurate. Consider using '#align simple_graph.box_prod_connected SimpleGraph.boxProd_connectedₓ'. -/
 @[simp]
 theorem boxProd_connected : (G □ H).Connected ↔ G.Connected ∧ H.Connected :=
   ⟨fun h => ⟨h.ofBoxProdLeft, h.ofBoxProdRight⟩, fun h => h.1.boxProd h.2⟩
@@ -320,12 +260,6 @@ instance boxProdFintypeNeighborSet (x : α × β) [Fintype (G.neighborSet x.1)]
 #align simple_graph.box_prod_fintype_neighbor_set SimpleGraph.boxProdFintypeNeighborSet
 -/
 
-/- warning: simple_graph.box_prod_neighbor_finset -> SimpleGraph.boxProd_neighborFinset is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β} (x : Prod.{u1, u2} α β) [_inst_1 : Fintype.{u1} (coeSort.{succ u1, succ (succ u1)} (Set.{u1} α) Type.{u1} (Set.hasCoeToSort.{u1} α) (SimpleGraph.neighborSet.{u1} α G (Prod.fst.{u1, u2} α β x)))] [_inst_2 : Fintype.{u2} (coeSort.{succ u2, succ (succ u2)} (Set.{u2} β) Type.{u2} (Set.hasCoeToSort.{u2} β) (SimpleGraph.neighborSet.{u2} β H (Prod.snd.{u1, u2} α β x)))] [_inst_3 : Fintype.{max u1 u2} (coeSort.{succ (max u1 u2), succ (succ (max u1 u2))} (Set.{max u1 u2} (Prod.{u1, u2} α β)) Type.{max u1 u2} (Set.hasCoeToSort.{max u1 u2} (Prod.{u1, u2} α β)) (SimpleGraph.neighborSet.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) x))], Eq.{succ (max u1 u2)} (Finset.{max u1 u2} (Prod.{u1, u2} α β)) (SimpleGraph.neighborFinset.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) x _inst_3) (Finset.disjUnion.{max u1 u2} (Prod.{u1, u2} α β) (Finset.product.{u1, u2} α β (SimpleGraph.neighborFinset.{u1} α G (Prod.fst.{u1, u2} α β x) _inst_1) (Singleton.singleton.{u2, u2} β (Finset.{u2} β) (Finset.hasSingleton.{u2} β) (Prod.snd.{u1, u2} α β x))) (Finset.product.{u1, u2} α β (Singleton.singleton.{u1, u1} α (Finset.{u1} α) (Finset.hasSingleton.{u1} α) (Prod.fst.{u1, u2} α β x)) (SimpleGraph.neighborFinset.{u2} β H (Prod.snd.{u1, u2} α β x) _inst_2)) (Iff.mpr (Disjoint.{max u1 u2} (Finset.{max u1 u2} (Prod.{u1, u2} α β)) (Finset.partialOrder.{max u1 u2} (Prod.{u1, u2} α β)) (Finset.orderBot.{max u1 u2} (Prod.{u1, u2} α β)) (Finset.product.{u1, u2} α β (SimpleGraph.neighborFinset.{u1} α G (Prod.fst.{u1, u2} α β x) _inst_1) (Singleton.singleton.{u2, u2} β (Finset.{u2} β) (Finset.hasSingleton.{u2} β) (Prod.snd.{u1, u2} α β x))) (Finset.product.{u1, u2} α β (Singleton.singleton.{u1, u1} α (Finset.{u1} α) (Finset.hasSingleton.{u1} α) (Prod.fst.{u1, u2} α β x)) (SimpleGraph.neighborFinset.{u2} β H (Prod.snd.{u1, u2} α β x) _inst_2))) (Or (Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.orderBot.{u1} α) (SimpleGraph.neighborFinset.{u1} α G (Prod.fst.{u1, u2} α β x) _inst_1) (Singleton.singleton.{u1, u1} α (Finset.{u1} α) (Finset.hasSingleton.{u1} α) (Prod.fst.{u1, u2} α β x))) (Disjoint.{u2} (Finset.{u2} β) (Finset.partialOrder.{u2} β) (Finset.orderBot.{u2} β) (Singleton.singleton.{u2, u2} β (Finset.{u2} β) (Finset.hasSingleton.{u2} β) (Prod.snd.{u1, u2} α β x)) (SimpleGraph.neighborFinset.{u2} β H (Prod.snd.{u1, u2} α β x) _inst_2))) (Finset.disjoint_product.{u1, u2} α β (SimpleGraph.neighborFinset.{u1} α G (Prod.fst.{u1, u2} α β x) _inst_1) (Singleton.singleton.{u1, u1} α (Finset.{u1} α) (Finset.hasSingleton.{u1} α) (Prod.fst.{u1, u2} α β x)) (Singleton.singleton.{u2, u2} β (Finset.{u2} β) (Finset.hasSingleton.{u2} β) (Prod.snd.{u1, u2} α β x)) (SimpleGraph.neighborFinset.{u2} β H (Prod.snd.{u1, u2} α β x) _inst_2)) (Or.inl (Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.orderBot.{u1} α) (SimpleGraph.neighborFinset.{u1} α G (Prod.fst.{u1, u2} α β x) _inst_1) (Singleton.singleton.{u1, u1} α (Finset.{u1} α) (Finset.hasSingleton.{u1} α) (Prod.fst.{u1, u2} α β x))) (Disjoint.{u2} (Finset.{u2} β) (Finset.partialOrder.{u2} β) (Finset.orderBot.{u2} β) (Singleton.singleton.{u2, u2} β (Finset.{u2} β) (Finset.hasSingleton.{u2} β) (Prod.snd.{u1, u2} α β x)) (SimpleGraph.neighborFinset.{u2} β H (Prod.snd.{u1, u2} α β x) _inst_2)) (SimpleGraph.neighborFinset_disjoint_singleton.{u1} α G (Prod.fst.{u1, u2} α β x) _inst_1))))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β} (x : Prod.{u2, u1} α β) [_inst_1 : Fintype.{u2} (Set.Elem.{u2} α (SimpleGraph.neighborSet.{u2} α G (Prod.fst.{u2, u1} α β x)))] [_inst_2 : Fintype.{u1} (Set.Elem.{u1} β (SimpleGraph.neighborSet.{u1} β H (Prod.snd.{u2, u1} α β x)))] [_inst_3 : Fintype.{max u2 u1} (Set.Elem.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.neighborSet.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) x))], Eq.{max (succ u2) (succ u1)} (Finset.{max u2 u1} (Prod.{u2, u1} α β)) (SimpleGraph.neighborFinset.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) x _inst_3) (Finset.disjUnion.{max u2 u1} (Prod.{u2, u1} α β) (Finset.product.{u2, u1} α β (SimpleGraph.neighborFinset.{u2} α G (Prod.fst.{u2, u1} α β x) _inst_1) (Singleton.singleton.{u1, u1} β (Finset.{u1} β) (Finset.instSingletonFinset.{u1} β) (Prod.snd.{u2, u1} α β x))) (Finset.product.{u2, u1} α β (Singleton.singleton.{u2, u2} α (Finset.{u2} α) (Finset.instSingletonFinset.{u2} α) (Prod.fst.{u2, u1} α β x)) (SimpleGraph.neighborFinset.{u1} β H (Prod.snd.{u2, u1} α β x) _inst_2)) (Iff.mpr (Disjoint.{max u1 u2} (Finset.{max u1 u2} (Prod.{u2, u1} α β)) (Finset.partialOrder.{max u2 u1} (Prod.{u2, u1} α β)) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{max u2 u1} (Prod.{u2, u1} α β)) (Finset.product.{u2, u1} α β (SimpleGraph.neighborFinset.{u2} α G (Prod.fst.{u2, u1} α β x) _inst_1) (Singleton.singleton.{u1, u1} β (Finset.{u1} β) (Finset.instSingletonFinset.{u1} β) (Prod.snd.{u2, u1} α β x))) (Finset.product.{u2, u1} α β (Singleton.singleton.{u2, u2} α (Finset.{u2} α) (Finset.instSingletonFinset.{u2} α) (Prod.fst.{u2, u1} α β x)) (SimpleGraph.neighborFinset.{u1} β H (Prod.snd.{u2, u1} α β x) _inst_2))) (Or (Disjoint.{u2} (Finset.{u2} α) (Finset.partialOrder.{u2} α) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u2} α) (SimpleGraph.neighborFinset.{u2} α G (Prod.fst.{u2, u1} α β x) _inst_1) (Singleton.singleton.{u2, u2} α (Finset.{u2} α) (Finset.instSingletonFinset.{u2} α) (Prod.fst.{u2, u1} α β x))) (Disjoint.{u1} (Finset.{u1} β) (Finset.partialOrder.{u1} β) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u1} β) (Singleton.singleton.{u1, u1} β (Finset.{u1} β) (Finset.instSingletonFinset.{u1} β) (Prod.snd.{u2, u1} α β x)) (SimpleGraph.neighborFinset.{u1} β H (Prod.snd.{u2, u1} α β x) _inst_2))) (Finset.disjoint_product.{u2, u1} α β (SimpleGraph.neighborFinset.{u2} α G (Prod.fst.{u2, u1} α β x) _inst_1) (Singleton.singleton.{u2, u2} α (Finset.{u2} α) (Finset.instSingletonFinset.{u2} α) (Prod.fst.{u2, u1} α β x)) (Singleton.singleton.{u1, u1} β (Finset.{u1} β) (Finset.instSingletonFinset.{u1} β) (Prod.snd.{u2, u1} α β x)) (SimpleGraph.neighborFinset.{u1} β H (Prod.snd.{u2, u1} α β x) _inst_2)) (Or.inl (Disjoint.{u2} (Finset.{u2} α) (Finset.partialOrder.{u2} α) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u2} α) (SimpleGraph.neighborFinset.{u2} α G (Prod.fst.{u2, u1} α β x) _inst_1) (Singleton.singleton.{u2, u2} α (Finset.{u2} α) (Finset.instSingletonFinset.{u2} α) (Prod.fst.{u2, u1} α β x))) (Disjoint.{u1} (Finset.{u1} β) (Finset.partialOrder.{u1} β) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u1} β) (Singleton.singleton.{u1, u1} β (Finset.{u1} β) (Finset.instSingletonFinset.{u1} β) (Prod.snd.{u2, u1} α β x)) (SimpleGraph.neighborFinset.{u1} β H (Prod.snd.{u2, u1} α β x) _inst_2)) (SimpleGraph.neighborFinset_disjoint_singleton.{u2} α G (Prod.fst.{u2, u1} α β x) _inst_1))))
-Case conversion may be inaccurate. Consider using '#align simple_graph.box_prod_neighbor_finset SimpleGraph.boxProd_neighborFinsetₓ'. -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 theorem boxProd_neighborFinset (x : α × β) [Fintype (G.neighborSet x.1)]
@@ -340,12 +274,6 @@ theorem boxProd_neighborFinset (x : α × β) [Fintype (G.neighborSet x.1)]
   convert Finset.map_map _ (Function.Embedding.subtype _) Finset.univ
 #align simple_graph.box_prod_neighbor_finset SimpleGraph.boxProd_neighborFinset
 
-/- warning: simple_graph.box_prod_degree -> SimpleGraph.boxProd_degree is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β} (x : Prod.{u1, u2} α β) [_inst_1 : Fintype.{u1} (coeSort.{succ u1, succ (succ u1)} (Set.{u1} α) Type.{u1} (Set.hasCoeToSort.{u1} α) (SimpleGraph.neighborSet.{u1} α G (Prod.fst.{u1, u2} α β x)))] [_inst_2 : Fintype.{u2} (coeSort.{succ u2, succ (succ u2)} (Set.{u2} β) Type.{u2} (Set.hasCoeToSort.{u2} β) (SimpleGraph.neighborSet.{u2} β H (Prod.snd.{u1, u2} α β x)))] [_inst_3 : Fintype.{max u1 u2} (coeSort.{succ (max u1 u2), succ (succ (max u1 u2))} (Set.{max u1 u2} (Prod.{u1, u2} α β)) Type.{max u1 u2} (Set.hasCoeToSort.{max u1 u2} (Prod.{u1, u2} α β)) (SimpleGraph.neighborSet.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) x))], Eq.{1} Nat (SimpleGraph.degree.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) x _inst_3) (HAdd.hAdd.{0, 0, 0} Nat Nat Nat (instHAdd.{0} Nat Nat.hasAdd) (SimpleGraph.degree.{u1} α G (Prod.fst.{u1, u2} α β x) _inst_1) (SimpleGraph.degree.{u2} β H (Prod.snd.{u1, u2} α β x) _inst_2))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β} (x : Prod.{u2, u1} α β) [_inst_1 : Fintype.{u2} (Set.Elem.{u2} α (SimpleGraph.neighborSet.{u2} α G (Prod.fst.{u2, u1} α β x)))] [_inst_2 : Fintype.{u1} (Set.Elem.{u1} β (SimpleGraph.neighborSet.{u1} β H (Prod.snd.{u2, u1} α β x)))] [_inst_3 : Fintype.{max u2 u1} (Set.Elem.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.neighborSet.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) x))], Eq.{1} Nat (SimpleGraph.degree.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) x _inst_3) (HAdd.hAdd.{0, 0, 0} Nat Nat Nat (instHAdd.{0} Nat instAddNat) (SimpleGraph.degree.{u2} α G (Prod.fst.{u2, u1} α β x) _inst_1) (SimpleGraph.degree.{u1} β H (Prod.snd.{u2, u1} α β x) _inst_2))
-Case conversion may be inaccurate. Consider using '#align simple_graph.box_prod_degree SimpleGraph.boxProd_degreeₓ'. -/
 theorem boxProd_degree (x : α × β) [Fintype (G.neighborSet x.1)] [Fintype (H.neighborSet x.2)]
     [Fintype ((G □ H).neighborSet x)] : (G □ H).degree x = G.degree x.1 + H.degree x.2 :=
   by
Diff
@@ -265,11 +265,8 @@ lean 3 declaration is
 but is expected to have type
   forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β}, (SimpleGraph.Connected.{u2} α G) -> (SimpleGraph.Connected.{u1} β H) -> (SimpleGraph.Connected.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H))
 Case conversion may be inaccurate. Consider using '#align simple_graph.connected.box_prod SimpleGraph.Connected.boxProdₓ'. -/
-protected theorem Connected.boxProd (hG : G.Connected) (hH : H.Connected) : (G □ H).Connected :=
-  by
-  haveI := hG.nonempty
-  haveI := hH.nonempty
-  exact ⟨hG.preconnected.box_prod hH.preconnected⟩
+protected theorem Connected.boxProd (hG : G.Connected) (hH : H.Connected) : (G □ H).Connected := by
+  haveI := hG.nonempty; haveI := hH.nonempty; exact ⟨hG.preconnected.box_prod hH.preconnected⟩
 #align simple_graph.connected.box_prod SimpleGraph.Connected.boxProd
 
 /- warning: simple_graph.connected.of_box_prod_left -> SimpleGraph.Connected.ofBoxProdLeft is a dubious translation:
@@ -280,8 +277,7 @@ but is expected to have type
 Case conversion may be inaccurate. Consider using '#align simple_graph.connected.of_box_prod_left SimpleGraph.Connected.ofBoxProdLeftₓ'. -/
 protected theorem Connected.ofBoxProdLeft (h : (G □ H).Connected) : G.Connected :=
   by
-  haveI := (nonempty_prod.1 h.nonempty).1
-  haveI := (nonempty_prod.1 h.nonempty).2
+  haveI := (nonempty_prod.1 h.nonempty).1; haveI := (nonempty_prod.1 h.nonempty).2
   exact ⟨h.preconnected.of_box_prod_left⟩
 #align simple_graph.connected.of_box_prod_left SimpleGraph.Connected.ofBoxProdLeft
 
@@ -293,8 +289,7 @@ but is expected to have type
 Case conversion may be inaccurate. Consider using '#align simple_graph.connected.of_box_prod_right SimpleGraph.Connected.ofBoxProdRightₓ'. -/
 protected theorem Connected.ofBoxProdRight (h : (G □ H).Connected) : H.Connected :=
   by
-  haveI := (nonempty_prod.1 h.nonempty).1
-  haveI := (nonempty_prod.1 h.nonempty).2
+  haveI := (nonempty_prod.1 h.nonempty).1; haveI := (nonempty_prod.1 h.nonempty).2
   exact ⟨h.preconnected.of_box_prod_right⟩
 #align simple_graph.connected.of_box_prod_right SimpleGraph.Connected.ofBoxProdRight
 
Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: George Peter Banyard, Yaël Dillies, Kyle Miller
 
 ! This file was ported from Lean 3 source module combinatorics.simple_graph.prod
-! leanprover-community/mathlib commit 2985fa3c31a27274aed06c433510bc14b73d6488
+! leanprover-community/mathlib commit f47581155c818e6361af4e4fda60d27d020c226b
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
@@ -13,6 +13,9 @@ import Mathbin.Combinatorics.SimpleGraph.Connectivity
 /-!
 # Graph products
 
+> THIS FILE IS SYNCHRONIZED WITH MATHLIB4.
+> Any changes to this file require a corresponding PR to mathlib4.
+
 This file defines the box product of graphs and other product constructions. The box product of `G`
 and `H` is the graph on the product of the vertices such that `x` and `y` are related iff they agree
 on one component and the other one is related via either `G` or `H`. For example, the box product of
Diff
@@ -39,6 +39,7 @@ namespace SimpleGraph
 variable {G : SimpleGraph α} {H : SimpleGraph β} {I : SimpleGraph γ} {a a₁ a₂ : α} {b b₁ b₂ : β}
   {x y : α × β}
 
+#print SimpleGraph.boxProd /-
 /-- Box product of simple graphs. It relates `(a₁, b)` and `(a₂, b)` if `G` relates `a₁` and `a₂`,
 and `(a, b₁)` and `(a, b₂)` if `H` relates `b₁` and `b₂`. -/
 def boxProd (G : SimpleGraph α) (H : SimpleGraph β) : SimpleGraph (α × β)
@@ -47,25 +48,50 @@ def boxProd (G : SimpleGraph α) (H : SimpleGraph β) : SimpleGraph (α × β)
   symm x y := by simp [and_comm', or_comm', eq_comm, adj_comm]
   loopless x := by simp
 #align simple_graph.box_prod SimpleGraph.boxProd
+-/
 
 -- mathport name: «expr □ »
 infixl:70 " □ " => boxProd
 
+/- warning: simple_graph.box_prod_adj -> SimpleGraph.boxProd_adj is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β} {x : Prod.{u1, u2} α β} {y : Prod.{u1, u2} α β}, Iff (SimpleGraph.Adj.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) x y) (Or (And (SimpleGraph.Adj.{u1} α G (Prod.fst.{u1, u2} α β x) (Prod.fst.{u1, u2} α β y)) (Eq.{succ u2} β (Prod.snd.{u1, u2} α β x) (Prod.snd.{u1, u2} α β y))) (And (SimpleGraph.Adj.{u2} β H (Prod.snd.{u1, u2} α β x) (Prod.snd.{u1, u2} α β y)) (Eq.{succ u1} α (Prod.fst.{u1, u2} α β x) (Prod.fst.{u1, u2} α β y))))
+but is expected to have type
+  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β} {x : Prod.{u2, u1} α β} {y : Prod.{u2, u1} α β}, Iff (SimpleGraph.Adj.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) x y) (Or (And (SimpleGraph.Adj.{u2} α G (Prod.fst.{u2, u1} α β x) (Prod.fst.{u2, u1} α β y)) (Eq.{succ u1} β (Prod.snd.{u2, u1} α β x) (Prod.snd.{u2, u1} α β y))) (And (SimpleGraph.Adj.{u1} β H (Prod.snd.{u2, u1} α β x) (Prod.snd.{u2, u1} α β y)) (Eq.{succ u2} α (Prod.fst.{u2, u1} α β x) (Prod.fst.{u2, u1} α β y))))
+Case conversion may be inaccurate. Consider using '#align simple_graph.box_prod_adj SimpleGraph.boxProd_adjₓ'. -/
 @[simp]
 theorem boxProd_adj : (G □ H).Adj x y ↔ G.Adj x.1 y.1 ∧ x.2 = y.2 ∨ H.Adj x.2 y.2 ∧ x.1 = y.1 :=
   Iff.rfl
 #align simple_graph.box_prod_adj SimpleGraph.boxProd_adj
 
+/- warning: simple_graph.box_prod_adj_left -> SimpleGraph.boxProd_adj_left is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β} {a₁ : α} {a₂ : α} {b : β}, Iff (SimpleGraph.Adj.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) (Prod.mk.{u1, u2} α β a₁ b) (Prod.mk.{u1, u2} α β a₂ b)) (SimpleGraph.Adj.{u1} α G a₁ a₂)
+but is expected to have type
+  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β} {a₁ : α} {a₂ : β} {b : α}, Iff (SimpleGraph.Adj.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) (Prod.mk.{u2, u1} α β a₁ a₂) (Prod.mk.{u2, u1} α β b a₂)) (SimpleGraph.Adj.{u2} α G a₁ b)
+Case conversion may be inaccurate. Consider using '#align simple_graph.box_prod_adj_left SimpleGraph.boxProd_adj_leftₓ'. -/
 @[simp]
 theorem boxProd_adj_left : (G □ H).Adj (a₁, b) (a₂, b) ↔ G.Adj a₁ a₂ := by
   rw [box_prod_adj, and_iff_left rfl, or_iff_left fun h : H.adj b b ∧ _ => h.1.Ne rfl]
 #align simple_graph.box_prod_adj_left SimpleGraph.boxProd_adj_left
 
+/- warning: simple_graph.box_prod_adj_right -> SimpleGraph.boxProd_adj_right is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β} {a : α} {b₁ : β} {b₂ : β}, Iff (SimpleGraph.Adj.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) (Prod.mk.{u1, u2} α β a b₁) (Prod.mk.{u1, u2} α β a b₂)) (SimpleGraph.Adj.{u2} β H b₁ b₂)
+but is expected to have type
+  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β} {a : α} {b₁ : β} {b₂ : β}, Iff (SimpleGraph.Adj.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) (Prod.mk.{u2, u1} α β a b₁) (Prod.mk.{u2, u1} α β a b₂)) (SimpleGraph.Adj.{u1} β H b₁ b₂)
+Case conversion may be inaccurate. Consider using '#align simple_graph.box_prod_adj_right SimpleGraph.boxProd_adj_rightₓ'. -/
 @[simp]
 theorem boxProd_adj_right : (G □ H).Adj (a, b₁) (a, b₂) ↔ H.Adj b₁ b₂ := by
   rw [box_prod_adj, and_iff_left rfl, or_iff_right fun h : G.adj a a ∧ _ => h.1.Ne rfl]
 #align simple_graph.box_prod_adj_right SimpleGraph.boxProd_adj_right
 
+/- warning: simple_graph.box_prod_neighbor_set -> SimpleGraph.boxProd_neighborSet is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β} (x : Prod.{u1, u2} α β), Eq.{succ (max u1 u2)} (Set.{max u1 u2} (Prod.{u1, u2} α β)) (SimpleGraph.neighborSet.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) x) (Union.union.{max u1 u2} (Set.{max u1 u2} (Prod.{u1, u2} α β)) (Set.hasUnion.{max u1 u2} (Prod.{u1, u2} α β)) (Set.prod.{u1, u2} α β (SimpleGraph.neighborSet.{u1} α G (Prod.fst.{u1, u2} α β x)) (Singleton.singleton.{u2, u2} β (Set.{u2} β) (Set.hasSingleton.{u2} β) (Prod.snd.{u1, u2} α β x))) (Set.prod.{u1, u2} α β (Singleton.singleton.{u1, u1} α (Set.{u1} α) (Set.hasSingleton.{u1} α) (Prod.fst.{u1, u2} α β x)) (SimpleGraph.neighborSet.{u2} β H (Prod.snd.{u1, u2} α β x))))
+but is expected to have type
+  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β} (x : Prod.{u2, u1} α β), Eq.{max (succ u2) (succ u1)} (Set.{max u2 u1} (Prod.{u2, u1} α β)) (SimpleGraph.neighborSet.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) x) (Union.union.{max u1 u2} (Set.{max u1 u2} (Prod.{u2, u1} α β)) (Set.instUnionSet.{max u2 u1} (Prod.{u2, u1} α β)) (Set.prod.{u2, u1} α β (SimpleGraph.neighborSet.{u2} α G (Prod.fst.{u2, u1} α β x)) (Singleton.singleton.{u1, u1} β (Set.{u1} β) (Set.instSingletonSet.{u1} β) (Prod.snd.{u2, u1} α β x))) (Set.prod.{u2, u1} α β (Singleton.singleton.{u2, u2} α (Set.{u2} α) (Set.instSingletonSet.{u2} α) (Prod.fst.{u2, u1} α β x)) (SimpleGraph.neighborSet.{u1} β H (Prod.snd.{u2, u1} α β x))))
+Case conversion may be inaccurate. Consider using '#align simple_graph.box_prod_neighbor_set SimpleGraph.boxProd_neighborSetₓ'. -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 theorem boxProd_neighborSet (x : α × β) :
@@ -78,12 +104,15 @@ theorem boxProd_neighborSet (x : α × β) :
 
 variable (G H I)
 
+#print SimpleGraph.boxProdComm /-
 /-- The box product is commutative up to isomorphism. `equiv.prod_comm` as a graph isomorphism. -/
 @[simps]
 def boxProdComm : G □ H ≃g H □ G :=
   ⟨Equiv.prodComm _ _, fun x y => or_comm' _ _⟩
 #align simple_graph.box_prod_comm SimpleGraph.boxProdComm
+-/
 
+#print SimpleGraph.boxProdAssoc /-
 /-- The box product is associative up to isomorphism. `equiv.prod_assoc` as a graph isomorphism. -/
 @[simps]
 def boxProdAssoc : G □ H □ I ≃g G □ (H □ I) :=
@@ -91,7 +120,9 @@ def boxProdAssoc : G □ H □ I ≃g G □ (H □ I) :=
     simp only [box_prod_adj, Equiv.prodAssoc_apply, or_and_right, or_assoc', Prod.ext_iff,
       and_assoc', @and_comm (x.1.1 = _)]⟩
 #align simple_graph.box_prod_assoc SimpleGraph.boxProdAssoc
+-/
 
+#print SimpleGraph.boxProdLeft /-
 /-- The embedding of `G` into `G □ H` given by `b`. -/
 @[simps]
 def boxProdLeft (b : β) : G ↪g G □ H where
@@ -99,7 +130,9 @@ def boxProdLeft (b : β) : G ↪g G □ H where
   inj' a₁ a₂ := congr_arg Prod.fst
   map_rel_iff' a₁ a₂ := boxProd_adj_left
 #align simple_graph.box_prod_left SimpleGraph.boxProdLeft
+-/
 
+#print SimpleGraph.boxProdRight /-
 /-- The embedding of `H` into `G □ H` given by `a`. -/
 @[simps]
 def boxProdRight (a : α) : H ↪g G □ H
@@ -108,25 +141,31 @@ def boxProdRight (a : α) : H ↪g G □ H
   inj' b₁ b₂ := congr_arg Prod.snd
   map_rel_iff' b₁ b₂ := boxProd_adj_right
 #align simple_graph.box_prod_right SimpleGraph.boxProdRight
+-/
 
 namespace Walk
 
 variable {G}
 
+#print SimpleGraph.Walk.boxProdLeft /-
 /-- Turn a walk on `G` into a walk on `G □ H`. -/
 protected def boxProdLeft (b : β) : G.Walk a₁ a₂ → (G □ H).Walk (a₁, b) (a₂, b) :=
   Walk.map (G.boxProdLeft H b).toHom
 #align simple_graph.walk.box_prod_left SimpleGraph.Walk.boxProdLeft
+-/
 
 variable (G) {H}
 
+#print SimpleGraph.Walk.boxProdRight /-
 /-- Turn a walk on `H` into a walk on `G □ H`. -/
 protected def boxProdRight (a : α) : H.Walk b₁ b₂ → (G □ H).Walk (a, b₁) (a, b₂) :=
   Walk.map (G.boxProdRight H a).toHom
 #align simple_graph.walk.box_prod_right SimpleGraph.Walk.boxProdRight
+-/
 
 variable {G}
 
+#print SimpleGraph.Walk.ofBoxProdLeft /-
 /-- Project a walk on `G □ H` to a walk on `G` by discarding the moves in the direction of `H`. -/
 def ofBoxProdLeft [DecidableEq β] [DecidableRel G.Adj] :
     ∀ {x y : α × β}, (G □ H).Walk x y → G.Walk x.1 y.1
@@ -135,7 +174,9 @@ def ofBoxProdLeft [DecidableEq β] [DecidableRel G.Adj] :
     Or.by_cases h (fun hG => w.ofBoxProdLeft.cons hG.1) fun hH =>
       show G.Walk x.1 z.1 by rw [hH.2] <;> exact w.of_box_prod_left
 #align simple_graph.walk.of_box_prod_left SimpleGraph.Walk.ofBoxProdLeft
+-/
 
+#print SimpleGraph.Walk.ofBoxProdRight /-
 /-- Project a walk on `G □ H` to a walk on `H` by discarding the moves in the direction of `G`. -/
 def ofBoxProdRight [DecidableEq α] [DecidableRel H.Adj] :
     ∀ {x y : α × β}, (G □ H).Walk x y → H.Walk x.2 y.2
@@ -144,7 +185,9 @@ def ofBoxProdRight [DecidableEq α] [DecidableRel H.Adj] :
     (Or.symm h).byCases (fun hH => w.ofBoxProdRight.cons hH.1) fun hG =>
       show H.Walk x.2 z.2 by rw [hG.2] <;> exact w.of_box_prod_right
 #align simple_graph.walk.of_box_prod_right SimpleGraph.Walk.ofBoxProdRight
+-/
 
+#print SimpleGraph.Walk.ofBoxProdLeft_boxProdLeft /-
 @[simp]
 theorem ofBoxProdLeft_boxProdLeft [DecidableEq β] [DecidableRel G.Adj] :
     ∀ {a₁ a₂ : α} (w : G.Walk a₁ a₂), (w.boxProdLeft H b).ofBoxProdLeft = w
@@ -155,9 +198,11 @@ theorem ofBoxProdLeft_boxProdLeft [DecidableEq β] [DecidableRel G.Adj] :
       of_box_prod_left_box_prod_left]
     exacts[rfl, ⟨h, rfl⟩]
 #align simple_graph.walk.of_box_prod_left_box_prod_left SimpleGraph.Walk.ofBoxProdLeft_boxProdLeft
+-/
 
+#print SimpleGraph.Walk.ofBoxProdLeft_boxProdRight /-
 @[simp]
-theorem of_box_prod_left_boxProdRight [DecidableEq α] [DecidableRel G.Adj] :
+theorem ofBoxProdLeft_boxProdRight [DecidableEq α] [DecidableRel G.Adj] :
     ∀ {b₁ b₂ : α} (w : G.Walk b₁ b₂), (w.boxProdRight G a).ofBoxProdRight = w
   | _, _, nil => rfl
   | _, _, cons' x y z h w =>
@@ -165,12 +210,19 @@ theorem of_box_prod_left_boxProdRight [DecidableEq α] [DecidableRel G.Adj] :
     rw [walk.box_prod_right, map_cons, of_box_prod_right, Or.by_cases, dif_pos, ←
       walk.box_prod_right, of_box_prod_left_box_prod_right]
     exacts[rfl, ⟨h, rfl⟩]
-#align simple_graph.walk.of_box_prod_left_box_prod_right SimpleGraph.Walk.of_box_prod_left_boxProdRight
+#align simple_graph.walk.of_box_prod_left_box_prod_right SimpleGraph.Walk.ofBoxProdLeft_boxProdRight
+-/
 
 end Walk
 
 variable {G H}
 
+/- warning: simple_graph.preconnected.box_prod -> SimpleGraph.Preconnected.boxProd is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β}, (SimpleGraph.Preconnected.{u1} α G) -> (SimpleGraph.Preconnected.{u2} β H) -> (SimpleGraph.Preconnected.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H))
+but is expected to have type
+  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β}, (SimpleGraph.Preconnected.{u2} α G) -> (SimpleGraph.Preconnected.{u1} β H) -> (SimpleGraph.Preconnected.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H))
+Case conversion may be inaccurate. Consider using '#align simple_graph.preconnected.box_prod SimpleGraph.Preconnected.boxProdₓ'. -/
 protected theorem Preconnected.boxProd (hG : G.Preconnected) (hH : H.Preconnected) :
     (G □ H).Preconnected := by
   rintro x y
@@ -180,22 +232,36 @@ protected theorem Preconnected.boxProd (hG : G.Preconnected) (hH : H.Preconnecte
   exact ⟨(w₁.box_prod_left _ _).append (w₂.box_prod_right _ _)⟩
 #align simple_graph.preconnected.box_prod SimpleGraph.Preconnected.boxProd
 
-protected theorem Preconnected.of_boxProd_left [Nonempty β] (h : (G □ H).Preconnected) :
+#print SimpleGraph.Preconnected.ofBoxProdLeft /-
+protected theorem Preconnected.ofBoxProdLeft [Nonempty β] (h : (G □ H).Preconnected) :
     G.Preconnected := by
   classical
     rintro a₁ a₂
     obtain ⟨w⟩ := h (a₁, Classical.arbitrary _) (a₂, Classical.arbitrary _)
     exact ⟨w.of_box_prod_left⟩
-#align simple_graph.preconnected.of_box_prod_left SimpleGraph.Preconnected.of_boxProd_left
+#align simple_graph.preconnected.of_box_prod_left SimpleGraph.Preconnected.ofBoxProdLeft
+-/
 
-protected theorem Preconnected.of_boxProd_right [Nonempty α] (h : (G □ H).Preconnected) :
+/- warning: simple_graph.preconnected.of_box_prod_right -> SimpleGraph.Preconnected.ofBoxProdRight is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β} [_inst_1 : Nonempty.{succ u1} α], (SimpleGraph.Preconnected.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H)) -> (SimpleGraph.Preconnected.{u2} β H)
+but is expected to have type
+  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β} [_inst_1 : Nonempty.{succ u2} α], (SimpleGraph.Preconnected.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H)) -> (SimpleGraph.Preconnected.{u1} β H)
+Case conversion may be inaccurate. Consider using '#align simple_graph.preconnected.of_box_prod_right SimpleGraph.Preconnected.ofBoxProdRightₓ'. -/
+protected theorem Preconnected.ofBoxProdRight [Nonempty α] (h : (G □ H).Preconnected) :
     H.Preconnected := by
   classical
     rintro b₁ b₂
     obtain ⟨w⟩ := h (Classical.arbitrary _, b₁) (Classical.arbitrary _, b₂)
     exact ⟨w.of_box_prod_right⟩
-#align simple_graph.preconnected.of_box_prod_right SimpleGraph.Preconnected.of_boxProd_right
-
+#align simple_graph.preconnected.of_box_prod_right SimpleGraph.Preconnected.ofBoxProdRight
+
+/- warning: simple_graph.connected.box_prod -> SimpleGraph.Connected.boxProd is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β}, (SimpleGraph.Connected.{u1} α G) -> (SimpleGraph.Connected.{u2} β H) -> (SimpleGraph.Connected.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H))
+but is expected to have type
+  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β}, (SimpleGraph.Connected.{u2} α G) -> (SimpleGraph.Connected.{u1} β H) -> (SimpleGraph.Connected.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H))
+Case conversion may be inaccurate. Consider using '#align simple_graph.connected.box_prod SimpleGraph.Connected.boxProdₓ'. -/
 protected theorem Connected.boxProd (hG : G.Connected) (hH : H.Connected) : (G □ H).Connected :=
   by
   haveI := hG.nonempty
@@ -203,20 +269,38 @@ protected theorem Connected.boxProd (hG : G.Connected) (hH : H.Connected) : (G 
   exact ⟨hG.preconnected.box_prod hH.preconnected⟩
 #align simple_graph.connected.box_prod SimpleGraph.Connected.boxProd
 
-protected theorem Connected.of_boxProd_left (h : (G □ H).Connected) : G.Connected :=
+/- warning: simple_graph.connected.of_box_prod_left -> SimpleGraph.Connected.ofBoxProdLeft is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β}, (SimpleGraph.Connected.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H)) -> (SimpleGraph.Connected.{u1} α G)
+but is expected to have type
+  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β}, (SimpleGraph.Connected.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H)) -> (SimpleGraph.Connected.{u2} α G)
+Case conversion may be inaccurate. Consider using '#align simple_graph.connected.of_box_prod_left SimpleGraph.Connected.ofBoxProdLeftₓ'. -/
+protected theorem Connected.ofBoxProdLeft (h : (G □ H).Connected) : G.Connected :=
   by
   haveI := (nonempty_prod.1 h.nonempty).1
   haveI := (nonempty_prod.1 h.nonempty).2
   exact ⟨h.preconnected.of_box_prod_left⟩
-#align simple_graph.connected.of_box_prod_left SimpleGraph.Connected.of_boxProd_left
-
-protected theorem Connected.of_boxProd_right (h : (G □ H).Connected) : H.Connected :=
+#align simple_graph.connected.of_box_prod_left SimpleGraph.Connected.ofBoxProdLeft
+
+/- warning: simple_graph.connected.of_box_prod_right -> SimpleGraph.Connected.ofBoxProdRight is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β}, (SimpleGraph.Connected.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H)) -> (SimpleGraph.Connected.{u2} β H)
+but is expected to have type
+  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β}, (SimpleGraph.Connected.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H)) -> (SimpleGraph.Connected.{u1} β H)
+Case conversion may be inaccurate. Consider using '#align simple_graph.connected.of_box_prod_right SimpleGraph.Connected.ofBoxProdRightₓ'. -/
+protected theorem Connected.ofBoxProdRight (h : (G □ H).Connected) : H.Connected :=
   by
   haveI := (nonempty_prod.1 h.nonempty).1
   haveI := (nonempty_prod.1 h.nonempty).2
   exact ⟨h.preconnected.of_box_prod_right⟩
-#align simple_graph.connected.of_box_prod_right SimpleGraph.Connected.of_boxProd_right
-
+#align simple_graph.connected.of_box_prod_right SimpleGraph.Connected.ofBoxProdRight
+
+/- warning: simple_graph.box_prod_connected -> SimpleGraph.boxProd_connected is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β}, Iff (SimpleGraph.Connected.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H)) (And (SimpleGraph.Connected.{u1} α G) (SimpleGraph.Connected.{u2} β H))
+but is expected to have type
+  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β}, Iff (SimpleGraph.Connected.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H)) (And (SimpleGraph.Connected.{u2} α G) (SimpleGraph.Connected.{u1} β H))
+Case conversion may be inaccurate. Consider using '#align simple_graph.box_prod_connected SimpleGraph.boxProd_connectedₓ'. -/
 @[simp]
 theorem boxProd_connected : (G □ H).Connected ↔ G.Connected ∧ H.Connected :=
   ⟨fun h => ⟨h.ofBoxProdLeft, h.ofBoxProdRight⟩, fun h => h.1.boxProd h.2⟩
@@ -224,6 +308,7 @@ theorem boxProd_connected : (G □ H).Connected ↔ G.Connected ∧ H.Connected
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+#print SimpleGraph.boxProdFintypeNeighborSet /-
 instance boxProdFintypeNeighborSet (x : α × β) [Fintype (G.neighborSet x.1)]
     [Fintype (H.neighborSet x.2)] : Fintype ((G □ H).neighborSet x) :=
   Fintype.ofEquiv
@@ -235,7 +320,14 @@ instance boxProdFintypeNeighborSet (x : α × β) [Fintype (G.neighborSet x.1)]
         mem_neighbor_set, Equiv.refl_apply, box_prod_adj]
       simp only [eq_comm, and_comm'])
 #align simple_graph.box_prod_fintype_neighbor_set SimpleGraph.boxProdFintypeNeighborSet
+-/
 
+/- warning: simple_graph.box_prod_neighbor_finset -> SimpleGraph.boxProd_neighborFinset is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β} (x : Prod.{u1, u2} α β) [_inst_1 : Fintype.{u1} (coeSort.{succ u1, succ (succ u1)} (Set.{u1} α) Type.{u1} (Set.hasCoeToSort.{u1} α) (SimpleGraph.neighborSet.{u1} α G (Prod.fst.{u1, u2} α β x)))] [_inst_2 : Fintype.{u2} (coeSort.{succ u2, succ (succ u2)} (Set.{u2} β) Type.{u2} (Set.hasCoeToSort.{u2} β) (SimpleGraph.neighborSet.{u2} β H (Prod.snd.{u1, u2} α β x)))] [_inst_3 : Fintype.{max u1 u2} (coeSort.{succ (max u1 u2), succ (succ (max u1 u2))} (Set.{max u1 u2} (Prod.{u1, u2} α β)) Type.{max u1 u2} (Set.hasCoeToSort.{max u1 u2} (Prod.{u1, u2} α β)) (SimpleGraph.neighborSet.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) x))], Eq.{succ (max u1 u2)} (Finset.{max u1 u2} (Prod.{u1, u2} α β)) (SimpleGraph.neighborFinset.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) x _inst_3) (Finset.disjUnion.{max u1 u2} (Prod.{u1, u2} α β) (Finset.product.{u1, u2} α β (SimpleGraph.neighborFinset.{u1} α G (Prod.fst.{u1, u2} α β x) _inst_1) (Singleton.singleton.{u2, u2} β (Finset.{u2} β) (Finset.hasSingleton.{u2} β) (Prod.snd.{u1, u2} α β x))) (Finset.product.{u1, u2} α β (Singleton.singleton.{u1, u1} α (Finset.{u1} α) (Finset.hasSingleton.{u1} α) (Prod.fst.{u1, u2} α β x)) (SimpleGraph.neighborFinset.{u2} β H (Prod.snd.{u1, u2} α β x) _inst_2)) (Iff.mpr (Disjoint.{max u1 u2} (Finset.{max u1 u2} (Prod.{u1, u2} α β)) (Finset.partialOrder.{max u1 u2} (Prod.{u1, u2} α β)) (Finset.orderBot.{max u1 u2} (Prod.{u1, u2} α β)) (Finset.product.{u1, u2} α β (SimpleGraph.neighborFinset.{u1} α G (Prod.fst.{u1, u2} α β x) _inst_1) (Singleton.singleton.{u2, u2} β (Finset.{u2} β) (Finset.hasSingleton.{u2} β) (Prod.snd.{u1, u2} α β x))) (Finset.product.{u1, u2} α β (Singleton.singleton.{u1, u1} α (Finset.{u1} α) (Finset.hasSingleton.{u1} α) (Prod.fst.{u1, u2} α β x)) (SimpleGraph.neighborFinset.{u2} β H (Prod.snd.{u1, u2} α β x) _inst_2))) (Or (Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.orderBot.{u1} α) (SimpleGraph.neighborFinset.{u1} α G (Prod.fst.{u1, u2} α β x) _inst_1) (Singleton.singleton.{u1, u1} α (Finset.{u1} α) (Finset.hasSingleton.{u1} α) (Prod.fst.{u1, u2} α β x))) (Disjoint.{u2} (Finset.{u2} β) (Finset.partialOrder.{u2} β) (Finset.orderBot.{u2} β) (Singleton.singleton.{u2, u2} β (Finset.{u2} β) (Finset.hasSingleton.{u2} β) (Prod.snd.{u1, u2} α β x)) (SimpleGraph.neighborFinset.{u2} β H (Prod.snd.{u1, u2} α β x) _inst_2))) (Finset.disjoint_product.{u1, u2} α β (SimpleGraph.neighborFinset.{u1} α G (Prod.fst.{u1, u2} α β x) _inst_1) (Singleton.singleton.{u1, u1} α (Finset.{u1} α) (Finset.hasSingleton.{u1} α) (Prod.fst.{u1, u2} α β x)) (Singleton.singleton.{u2, u2} β (Finset.{u2} β) (Finset.hasSingleton.{u2} β) (Prod.snd.{u1, u2} α β x)) (SimpleGraph.neighborFinset.{u2} β H (Prod.snd.{u1, u2} α β x) _inst_2)) (Or.inl (Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.orderBot.{u1} α) (SimpleGraph.neighborFinset.{u1} α G (Prod.fst.{u1, u2} α β x) _inst_1) (Singleton.singleton.{u1, u1} α (Finset.{u1} α) (Finset.hasSingleton.{u1} α) (Prod.fst.{u1, u2} α β x))) (Disjoint.{u2} (Finset.{u2} β) (Finset.partialOrder.{u2} β) (Finset.orderBot.{u2} β) (Singleton.singleton.{u2, u2} β (Finset.{u2} β) (Finset.hasSingleton.{u2} β) (Prod.snd.{u1, u2} α β x)) (SimpleGraph.neighborFinset.{u2} β H (Prod.snd.{u1, u2} α β x) _inst_2)) (SimpleGraph.neighborFinset_disjoint_singleton.{u1} α G (Prod.fst.{u1, u2} α β x) _inst_1))))
+but is expected to have type
+  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β} (x : Prod.{u2, u1} α β) [_inst_1 : Fintype.{u2} (Set.Elem.{u2} α (SimpleGraph.neighborSet.{u2} α G (Prod.fst.{u2, u1} α β x)))] [_inst_2 : Fintype.{u1} (Set.Elem.{u1} β (SimpleGraph.neighborSet.{u1} β H (Prod.snd.{u2, u1} α β x)))] [_inst_3 : Fintype.{max u2 u1} (Set.Elem.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.neighborSet.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) x))], Eq.{max (succ u2) (succ u1)} (Finset.{max u2 u1} (Prod.{u2, u1} α β)) (SimpleGraph.neighborFinset.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) x _inst_3) (Finset.disjUnion.{max u2 u1} (Prod.{u2, u1} α β) (Finset.product.{u2, u1} α β (SimpleGraph.neighborFinset.{u2} α G (Prod.fst.{u2, u1} α β x) _inst_1) (Singleton.singleton.{u1, u1} β (Finset.{u1} β) (Finset.instSingletonFinset.{u1} β) (Prod.snd.{u2, u1} α β x))) (Finset.product.{u2, u1} α β (Singleton.singleton.{u2, u2} α (Finset.{u2} α) (Finset.instSingletonFinset.{u2} α) (Prod.fst.{u2, u1} α β x)) (SimpleGraph.neighborFinset.{u1} β H (Prod.snd.{u2, u1} α β x) _inst_2)) (Iff.mpr (Disjoint.{max u1 u2} (Finset.{max u1 u2} (Prod.{u2, u1} α β)) (Finset.partialOrder.{max u2 u1} (Prod.{u2, u1} α β)) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{max u2 u1} (Prod.{u2, u1} α β)) (Finset.product.{u2, u1} α β (SimpleGraph.neighborFinset.{u2} α G (Prod.fst.{u2, u1} α β x) _inst_1) (Singleton.singleton.{u1, u1} β (Finset.{u1} β) (Finset.instSingletonFinset.{u1} β) (Prod.snd.{u2, u1} α β x))) (Finset.product.{u2, u1} α β (Singleton.singleton.{u2, u2} α (Finset.{u2} α) (Finset.instSingletonFinset.{u2} α) (Prod.fst.{u2, u1} α β x)) (SimpleGraph.neighborFinset.{u1} β H (Prod.snd.{u2, u1} α β x) _inst_2))) (Or (Disjoint.{u2} (Finset.{u2} α) (Finset.partialOrder.{u2} α) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u2} α) (SimpleGraph.neighborFinset.{u2} α G (Prod.fst.{u2, u1} α β x) _inst_1) (Singleton.singleton.{u2, u2} α (Finset.{u2} α) (Finset.instSingletonFinset.{u2} α) (Prod.fst.{u2, u1} α β x))) (Disjoint.{u1} (Finset.{u1} β) (Finset.partialOrder.{u1} β) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u1} β) (Singleton.singleton.{u1, u1} β (Finset.{u1} β) (Finset.instSingletonFinset.{u1} β) (Prod.snd.{u2, u1} α β x)) (SimpleGraph.neighborFinset.{u1} β H (Prod.snd.{u2, u1} α β x) _inst_2))) (Finset.disjoint_product.{u2, u1} α β (SimpleGraph.neighborFinset.{u2} α G (Prod.fst.{u2, u1} α β x) _inst_1) (Singleton.singleton.{u2, u2} α (Finset.{u2} α) (Finset.instSingletonFinset.{u2} α) (Prod.fst.{u2, u1} α β x)) (Singleton.singleton.{u1, u1} β (Finset.{u1} β) (Finset.instSingletonFinset.{u1} β) (Prod.snd.{u2, u1} α β x)) (SimpleGraph.neighborFinset.{u1} β H (Prod.snd.{u2, u1} α β x) _inst_2)) (Or.inl (Disjoint.{u2} (Finset.{u2} α) (Finset.partialOrder.{u2} α) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u2} α) (SimpleGraph.neighborFinset.{u2} α G (Prod.fst.{u2, u1} α β x) _inst_1) (Singleton.singleton.{u2, u2} α (Finset.{u2} α) (Finset.instSingletonFinset.{u2} α) (Prod.fst.{u2, u1} α β x))) (Disjoint.{u1} (Finset.{u1} β) (Finset.partialOrder.{u1} β) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u1} β) (Singleton.singleton.{u1, u1} β (Finset.{u1} β) (Finset.instSingletonFinset.{u1} β) (Prod.snd.{u2, u1} α β x)) (SimpleGraph.neighborFinset.{u1} β H (Prod.snd.{u2, u1} α β x) _inst_2)) (SimpleGraph.neighborFinset_disjoint_singleton.{u2} α G (Prod.fst.{u2, u1} α β x) _inst_1))))
+Case conversion may be inaccurate. Consider using '#align simple_graph.box_prod_neighbor_finset SimpleGraph.boxProd_neighborFinsetₓ'. -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 theorem boxProd_neighborFinset (x : α × β) [Fintype (G.neighborSet x.1)]
@@ -250,6 +342,12 @@ theorem boxProd_neighborFinset (x : α × β) [Fintype (G.neighborSet x.1)]
   convert Finset.map_map _ (Function.Embedding.subtype _) Finset.univ
 #align simple_graph.box_prod_neighbor_finset SimpleGraph.boxProd_neighborFinset
 
+/- warning: simple_graph.box_prod_degree -> SimpleGraph.boxProd_degree is a dubious translation:
+lean 3 declaration is
+  forall {α : Type.{u1}} {β : Type.{u2}} {G : SimpleGraph.{u1} α} {H : SimpleGraph.{u2} β} (x : Prod.{u1, u2} α β) [_inst_1 : Fintype.{u1} (coeSort.{succ u1, succ (succ u1)} (Set.{u1} α) Type.{u1} (Set.hasCoeToSort.{u1} α) (SimpleGraph.neighborSet.{u1} α G (Prod.fst.{u1, u2} α β x)))] [_inst_2 : Fintype.{u2} (coeSort.{succ u2, succ (succ u2)} (Set.{u2} β) Type.{u2} (Set.hasCoeToSort.{u2} β) (SimpleGraph.neighborSet.{u2} β H (Prod.snd.{u1, u2} α β x)))] [_inst_3 : Fintype.{max u1 u2} (coeSort.{succ (max u1 u2), succ (succ (max u1 u2))} (Set.{max u1 u2} (Prod.{u1, u2} α β)) Type.{max u1 u2} (Set.hasCoeToSort.{max u1 u2} (Prod.{u1, u2} α β)) (SimpleGraph.neighborSet.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) x))], Eq.{1} Nat (SimpleGraph.degree.{max u1 u2} (Prod.{u1, u2} α β) (SimpleGraph.boxProd.{u1, u2} α β G H) x _inst_3) (HAdd.hAdd.{0, 0, 0} Nat Nat Nat (instHAdd.{0} Nat Nat.hasAdd) (SimpleGraph.degree.{u1} α G (Prod.fst.{u1, u2} α β x) _inst_1) (SimpleGraph.degree.{u2} β H (Prod.snd.{u1, u2} α β x) _inst_2))
+but is expected to have type
+  forall {α : Type.{u2}} {β : Type.{u1}} {G : SimpleGraph.{u2} α} {H : SimpleGraph.{u1} β} (x : Prod.{u2, u1} α β) [_inst_1 : Fintype.{u2} (Set.Elem.{u2} α (SimpleGraph.neighborSet.{u2} α G (Prod.fst.{u2, u1} α β x)))] [_inst_2 : Fintype.{u1} (Set.Elem.{u1} β (SimpleGraph.neighborSet.{u1} β H (Prod.snd.{u2, u1} α β x)))] [_inst_3 : Fintype.{max u2 u1} (Set.Elem.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.neighborSet.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) x))], Eq.{1} Nat (SimpleGraph.degree.{max u2 u1} (Prod.{u2, u1} α β) (SimpleGraph.boxProd.{u2, u1} α β G H) x _inst_3) (HAdd.hAdd.{0, 0, 0} Nat Nat Nat (instHAdd.{0} Nat instAddNat) (SimpleGraph.degree.{u2} α G (Prod.fst.{u2, u1} α β x) _inst_1) (SimpleGraph.degree.{u1} β H (Prod.snd.{u2, u1} α β x) _inst_2))
+Case conversion may be inaccurate. Consider using '#align simple_graph.box_prod_degree SimpleGraph.boxProd_degreeₓ'. -/
 theorem boxProd_degree (x : α × β) [Fintype (G.neighborSet x.1)] [Fintype (H.neighborSet x.2)]
     [Fintype ((G □ H).neighborSet x)] : (G □ H).degree x = G.degree x.1 + H.degree x.2 :=
   by

Changes in mathlib4

mathlib3
mathlib4
chore: adapt to multiple goal linter 1 (#12338)

A PR accompanying #12339.

Zulip discussion

Diff
@@ -151,8 +151,8 @@ theorem ofBoxProdLeft_boxProdLeft [DecidableEq β] [DecidableRel G.Adj] {a₁ a
   | nil => rfl
   | cons' x y z h w => by
     rw [Walk.boxProdLeft, map_cons, ofBoxProdLeft, Or.by_cases, dif_pos, ← Walk.boxProdLeft]
-    simp [ofBoxProdLeft_boxProdLeft]
-    exact ⟨h, rfl⟩
+    · simp [ofBoxProdLeft_boxProdLeft]
+    · exact ⟨h, rfl⟩
 #align simple_graph.walk.of_box_prod_left_box_prod_left SimpleGraph.Walk.ofBoxProdLeft_boxProdLeft
 
 set_option autoImplicit true in
@@ -163,8 +163,8 @@ theorem ofBoxProdLeft_boxProdRight [DecidableEq α] [DecidableRel G.Adj] {b₁ b
   | cons' x y z h w => by
     rw [Walk.boxProdRight, map_cons, ofBoxProdRight, Or.by_cases, dif_pos, ←
       Walk.boxProdRight]
-    simp [ofBoxProdLeft_boxProdRight]
-    exact ⟨h, rfl⟩
+    · simp [ofBoxProdLeft_boxProdRight]
+    · exact ⟨h, rfl⟩
 #align simple_graph.walk.of_box_prod_left_box_prod_right SimpleGraph.Walk.ofBoxProdLeft_boxProdRight
 
 end Walk
chore: remove autoImplicit from more files (#11798)

and reduce its scope in a few other instances. Mostly in CategoryTheory and Data this time; some Combinatorics also.

Co-authored-by: Richard Osborn <richardosborn@mac.com>

Diff
@@ -28,9 +28,6 @@ two edges is a square.
 Define all other graph products!
 -/
 
-set_option autoImplicit true
-
-
 variable {α β γ : Type*}
 
 namespace SimpleGraph
@@ -51,16 +48,19 @@ def boxProd (G : SimpleGraph α) (H : SimpleGraph β) : SimpleGraph (α × β) w
 and `(a, b₁)` and `(a, b₂)` if `H` relates `b₁` and `b₂`. -/
 infixl:70 " □ " => boxProd
 
+set_option autoImplicit true in
 @[simp]
 theorem boxProd_adj : (G □ H).Adj x y ↔ G.Adj x.1 y.1 ∧ x.2 = y.2 ∨ H.Adj x.2 y.2 ∧ x.1 = y.1 :=
   Iff.rfl
 #align simple_graph.box_prod_adj SimpleGraph.boxProd_adj
 
+set_option autoImplicit true in
 --@[simp] Porting note (#10618): `simp` can prove
 theorem boxProd_adj_left : (G □ H).Adj (a₁, b) (a₂, b) ↔ G.Adj a₁ a₂ := by
   simp only [boxProd_adj, and_true, SimpleGraph.irrefl, false_and, or_false]
 #align simple_graph.box_prod_adj_left SimpleGraph.boxProd_adj_left
 
+set_option autoImplicit true in
 --@[simp] Porting note (#10618): `simp` can prove
 theorem boxProd_adj_right : (G □ H).Adj (a, b₁) (a, b₂) ↔ H.Adj b₁ b₂ := by
   simp only [boxProd_adj, SimpleGraph.irrefl, false_and, and_true, false_or]
@@ -108,6 +108,7 @@ namespace Walk
 
 variable {G}
 
+set_option autoImplicit true in
 /-- Turn a walk on `G` into a walk on `G □ H`. -/
 protected def boxProdLeft (b : β) : G.Walk a₁ a₂ → (G □ H).Walk (a₁, b) (a₂, b) :=
   Walk.map (G.boxProdLeft H b).toHom
@@ -115,6 +116,7 @@ protected def boxProdLeft (b : β) : G.Walk a₁ a₂ → (G □ H).Walk (a₁,
 
 variable (G) {H}
 
+set_option autoImplicit true in
 /-- Turn a walk on `H` into a walk on `G □ H`. -/
 protected def boxProdRight (a : α) : H.Walk b₁ b₂ → (G □ H).Walk (a, b₁) (a, b₂) :=
   Walk.map (G.boxProdRight H a).toHom
@@ -142,6 +144,7 @@ def ofBoxProdRight [DecidableEq α] [DecidableRel H.Adj] {x y : α × β} :
       (fun hG => hG.2 ▸ w.ofBoxProdRight)
 #align simple_graph.walk.of_box_prod_right SimpleGraph.Walk.ofBoxProdRight
 
+set_option autoImplicit true in
 @[simp]
 theorem ofBoxProdLeft_boxProdLeft [DecidableEq β] [DecidableRel G.Adj] {a₁ a₂ : α} :
     ∀ (w : G.Walk a₁ a₂), (w.boxProdLeft H b).ofBoxProdLeft = w
@@ -152,6 +155,7 @@ theorem ofBoxProdLeft_boxProdLeft [DecidableEq β] [DecidableRel G.Adj] {a₁ a
     exact ⟨h, rfl⟩
 #align simple_graph.walk.of_box_prod_left_box_prod_left SimpleGraph.Walk.ofBoxProdLeft_boxProdLeft
 
+set_option autoImplicit true in
 @[simp]
 theorem ofBoxProdLeft_boxProdRight [DecidableEq α] [DecidableRel G.Adj] {b₁ b₂ : α} :
     ∀ (w : G.Walk b₁ b₂), (w.boxProdRight G a).ofBoxProdRight = w
chore: remove mathport name: <expression> lines (#11928)

Quoting [@digama0](https://github.com/digama0):

These were actually never meant to go in the file, they are basically debugging information and only useful on significantly broken mathport files. You can safely remove all of them.

Diff
@@ -47,7 +47,6 @@ def boxProd (G : SimpleGraph α) (H : SimpleGraph β) : SimpleGraph (α × β) w
   loopless x := by simp
 #align simple_graph.box_prod SimpleGraph.boxProd
 
--- mathport name: «expr □ »
 /-- Box product of simple graphs. It relates `(a₁, b)` and `(a₂, b)` if `G` relates `a₁` and `a₂`,
 and `(a, b₁)` and `(a, b₂)` if `H` relates `b₁` and `b₂`. -/
 infixl:70 " □ " => boxProd
chore: classify simp can do this porting notes (#10619)

Classify by adding issue number (#10618) to porting notes claiming anything semantically equivalent to simp can prove this or simp can simplify this.

Diff
@@ -57,12 +57,12 @@ theorem boxProd_adj : (G □ H).Adj x y ↔ G.Adj x.1 y.1 ∧ x.2 = y.2 ∨ H.Ad
   Iff.rfl
 #align simple_graph.box_prod_adj SimpleGraph.boxProd_adj
 
---@[simp] porting note: `simp` can prove
+--@[simp] Porting note (#10618): `simp` can prove
 theorem boxProd_adj_left : (G □ H).Adj (a₁, b) (a₂, b) ↔ G.Adj a₁ a₂ := by
   simp only [boxProd_adj, and_true, SimpleGraph.irrefl, false_and, or_false]
 #align simple_graph.box_prod_adj_left SimpleGraph.boxProd_adj_left
 
---@[simp] porting note: `simp` can prove
+--@[simp] Porting note (#10618): `simp` can prove
 theorem boxProd_adj_right : (G □ H).Adj (a, b₁) (a, b₂) ↔ H.Adj b₁ b₂ := by
   simp only [boxProd_adj, SimpleGraph.irrefl, false_and, and_true, false_or]
 #align simple_graph.box_prod_adj_right SimpleGraph.boxProd_adj_right
chore: cleanup typo in filter_upwards (#7719)

mathport was forgetting a space in filter_upwards [...]with instead of filter_upwards [...] with.

Diff
@@ -161,7 +161,7 @@ theorem ofBoxProdLeft_boxProdRight [DecidableEq α] [DecidableRel G.Adj] {b₁ b
     rw [Walk.boxProdRight, map_cons, ofBoxProdRight, Or.by_cases, dif_pos, ←
       Walk.boxProdRight]
     simp [ofBoxProdLeft_boxProdRight]
-    exact⟨h, rfl⟩
+    exact ⟨h, rfl⟩
 #align simple_graph.walk.of_box_prod_left_box_prod_right SimpleGraph.Walk.ofBoxProdLeft_boxProdRight
 
 end Walk
chore: cleanup Mathlib.Init.Data.Prod (#6972)

Removing from Mathlib.Init.Data.Prod from the early parts of the import hierarchy.

While at it, remove unnecessary uses of Prod.mk.eta across the library.

Co-authored-by: Scott Morrison <scott.morrison@gmail.com>

Diff
@@ -173,7 +173,6 @@ protected theorem Preconnected.boxProd (hG : G.Preconnected) (hH : H.Preconnecte
   rintro x y
   obtain ⟨w₁⟩ := hG x.1 y.1
   obtain ⟨w₂⟩ := hH x.2 y.2
-  rw [← @Prod.mk.eta _ _ x, ← @Prod.mk.eta _ _ y]
   exact ⟨(w₁.boxProdLeft _ _).append (w₂.boxProdRight _ _)⟩
 #align simple_graph.preconnected.box_prod SimpleGraph.Preconnected.boxProd
 
fix: disable autoImplicit globally (#6528)

Autoimplicits are highly controversial and also defeat the performance-improving work in #6474.

The intent of this PR is to make autoImplicit opt-in on a per-file basis, by disabling it in the lakefile and enabling it again with set_option autoImplicit true in the few files that rely on it.

That also keeps this PR small, as opposed to attempting to "fix" files to not need it any more.

I claim that many of the uses of autoImplicit in these files are accidental; situations such as:

  • Assuming variables are in scope, but pasting the lemma in the wrong section
  • Pasting in a lemma from a scratch file without checking to see if the variable names are consistent with the rest of the file
  • Making a copy-paste error between lemmas and forgetting to add an explicit arguments.

Having set_option autoImplicit false as the default prevents these types of mistake being made in the 90% of files where autoImplicits are not used at all, and causes them to be caught by CI during review.

I think there were various points during the port where we encouraged porters to delete the universes u v lines; I think having autoparams for universe variables only would cover a lot of the cases we actually use them, while avoiding any real shortcomings.

A Zulip poll (after combining overlapping votes accordingly) was in favor of this change with 5:5:18 as the no:dontcare:yes vote ratio.

While this PR was being reviewed, a handful of files gained some more likely-accidental autoImplicits. In these places, set_option autoImplicit true has been placed locally within a section, rather than at the top of the file.

Diff
@@ -28,6 +28,8 @@ two edges is a square.
 Define all other graph products!
 -/
 
+set_option autoImplicit true
+
 
 variable {α β γ : Type*}
 
chore: banish Type _ and Sort _ (#6499)

We remove all possible occurences of Type _ and Sort _ in favor of Type* and Sort*.

This has nice performance benefits.

Diff
@@ -29,7 +29,7 @@ Define all other graph products!
 -/
 
 
-variable {α β γ : Type _}
+variable {α β γ : Type*}
 
 namespace SimpleGraph
 
@@ -84,7 +84,7 @@ def boxProdComm : G □ H ≃g H □ G := ⟨Equiv.prodComm _ _, or_comm⟩
 def boxProdAssoc (I : SimpleGraph γ) : G □ H □ I ≃g G □ (H □ I) :=
   ⟨Equiv.prodAssoc _ _ _, fun {x y} => by
     simp only [boxProd_adj, Equiv.prodAssoc_apply, or_and_right, or_assoc, Prod.ext_iff,
-      and_assoc, @and_comm (x.fst.fst = _)]; tauto⟩
+      and_assoc, @and_comm (x.fst.fst = _)]⟩
 #align simple_graph.box_prod_assoc SimpleGraph.boxProdAssoc
 
 /-- The embedding of `G` into `G □ H` given by `b`. -/
chore: script to replace headers with #align_import statements (#5979)

Open in Gitpod

Co-authored-by: Eric Wieser <wieser.eric@gmail.com> Co-authored-by: Scott Morrison <scott.morrison@gmail.com>

Diff
@@ -2,14 +2,11 @@
 Copyright (c) 2022 George Peter Banyard, Yaël Dillies, Kyle Miller. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: George Peter Banyard, Yaël Dillies, Kyle Miller
-
-! This file was ported from Lean 3 source module combinatorics.simple_graph.prod
-! leanprover-community/mathlib commit 2985fa3c31a27274aed06c433510bc14b73d6488
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathlib.Combinatorics.SimpleGraph.Connectivity
 
+#align_import combinatorics.simple_graph.prod from "leanprover-community/mathlib"@"2985fa3c31a27274aed06c433510bc14b73d6488"
+
 /-!
 # Graph products
 
refactor: use the typeclass SProd to implement overloaded notation · ×ˢ · (#4200)

Currently, the following notations are changed from · ×ˢ · because Lean 4 can't deal with ambiguous notations. | Definition | Notation | | :

Co-authored-by: Jeremy Tan Jie Rui <reddeloostw@gmail.com> Co-authored-by: Kyle Miller <kmill31415@gmail.com> Co-authored-by: Chris Hughes <chrishughes24@gmail.com>

Diff
@@ -221,9 +221,8 @@ instance boxProdFintypeNeighborSet (x : α × β)
     [Fintype (G.neighborSet x.1)] [Fintype (H.neighborSet x.2)] :
     Fintype ((G □ H).neighborSet x) :=
   Fintype.ofEquiv
-    -- porting note: was `×ˢ`
-    ((G.neighborFinset x.1 ×ᶠ {x.2}).disjUnion ({x.1} ×ᶠ H.neighborFinset x.2) <|
-      Finset.disjoint_product.mpr <| Or.inl <| neighborFinset_disjoint_singleton _ _)
+    ((G.neighborFinset x.1 ×ˢ {x.2}).disjUnion ({x.1} ×ˢ H.neighborFinset x.2) <|
+        Finset.disjoint_product.mpr <| Or.inl <| neighborFinset_disjoint_singleton _ _)
     ((Equiv.refl _).subtypeEquiv fun y => by
       simp_rw [Finset.mem_disjUnion, Finset.mem_product, Finset.mem_singleton, mem_neighborFinset,
         mem_neighborSet, Equiv.refl_apply, boxProd_adj]
@@ -233,8 +232,7 @@ instance boxProdFintypeNeighborSet (x : α × β)
 theorem boxProd_neighborFinset (x : α × β)
     [Fintype (G.neighborSet x.1)] [Fintype (H.neighborSet x.2)] [Fintype ((G □ H).neighborSet x)] :
     (G □ H).neighborFinset x =
-      -- porting note: was `×ˢ`
-      (G.neighborFinset x.1 ×ᶠ {x.2}).disjUnion ({x.1} ×ᶠ H.neighborFinset x.2)
+      (G.neighborFinset x.1 ×ˢ {x.2}).disjUnion ({x.1} ×ˢ H.neighborFinset x.2)
         (Finset.disjoint_product.mpr <| Or.inl <| neighborFinset_disjoint_singleton _ _) := by
   -- swap out the fintype instance for the canonical one
   letI : Fintype ((G □ H).neighborSet x) := SimpleGraph.boxProdFintypeNeighborSet _
feat: improvements to congr! and convert (#2606)
  • There is now configuration for congr!, convert, and convert_to to control parts of the congruence algorithm, in particular transparency settings when applying congruence lemmas.
  • congr! now applies congruence lemmas with reducible transparency by default. This prevents it from unfolding definitions when applying congruence lemmas. It also now tries both the LHS-biased and RHS-biased simp congruence lemmas, with a configuration option to set which it should try first.
  • There is now a new HEq congruence lemma generator that gives each hypothesis access to the proofs of previous hypotheses. This means that if you have an equality ⊢ ⟨a, x⟩ = ⟨b, y⟩ of sigma types, congr! turns this into goals ⊢ a = b and ⊢ a = b → HEq x y (note that congr! will also auto-introduce a = b for you in the second goal). This congruence lemma generator applies to more cases than the simp congruence lemma generator does.
  • congr! (and hence convert) are more careful about applying lemmas that don't force definitions to unfold. There were a number of cases in mathlib where the implementation of congr was being abused to unfold definitions.
  • With set_option trace.congr! true you can see what congr! sees when it is deciding on congruence lemmas.
  • There is also a bug fix in convert_to to do using 1 when there is no using clause, to match its documentation.

Note that congr! is more capable than congr at finding a way to equate left-hand sides and right-hand sides, so you will frequently need to limit its depth with a using clause. However, there is also a new heuristic to prevent considering unlikely-to-be-provable type equalities (controlled by the typeEqs option), which can help limit the depth automatically.

There is also a predefined configuration that you can invoke with, for example, convert (config := .unfoldSameFun) h, that causes it to behave more like congr, including using default transparency when unfolding.

Diff
@@ -238,7 +238,7 @@ theorem boxProd_neighborFinset (x : α × β)
         (Finset.disjoint_product.mpr <| Or.inl <| neighborFinset_disjoint_singleton _ _) := by
   -- swap out the fintype instance for the canonical one
   letI : Fintype ((G □ H).neighborSet x) := SimpleGraph.boxProdFintypeNeighborSet _
-  convert_to (G □ H).neighborFinset x = _
+  convert_to (G □ H).neighborFinset x = _ using 2
   exact Eq.trans (Finset.map_map _ _ _) Finset.attach_map_val
 #align simple_graph.box_prod_neighbor_finset SimpleGraph.boxProd_neighborFinset
 
feat Port/Combinatorics.SimpleGraph.Prod (#2565)

Co-authored-by: Kyle Miller <kmill31415@gmail.com> Co-authored-by: Moritz Firsching <firsching@google.com>

Dependencies 6 + 219

220 files ported (97.3%)
100477 lines ported (97.9%)
Show graph

The unported dependencies are