model_theory.definability
⟷
Mathlib.ModelTheory.Definability
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.
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(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)
mathlib commit https://github.com/leanprover-community/mathlib/commit/65a1391a0106c9204fe45bc73a039f056558cb83
@@ -129,13 +129,21 @@ theorem Definable.union {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.De
#print Set.definable_finset_inf /-
theorem definable_finset_inf {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
- (s : Finset ι) : A.Definable L (s.inf f) := by classical
+ (s : Finset ι) : A.Definable L (s.inf f) := by
+ classical
+ refine' Finset.induction definable_univ (fun i s is h => _) s
+ rw [Finset.inf_insert]
+ exact (hf i).inter h
#align set.definable_finset_inf Set.definable_finset_inf
-/
#print Set.definable_finset_sup /-
theorem definable_finset_sup {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
- (s : Finset ι) : A.Definable L (s.sup f) := by classical
+ (s : Finset ι) : A.Definable L (s.sup f) := by
+ classical
+ refine' Finset.induction definable_empty (fun i s is h => _) s
+ rw [Finset.sup_insert]
+ exact (hf i).union h
#align set.definable_finset_sup Set.definable_finset_sup
-/
@@ -224,14 +232,60 @@ theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) →
#print Set.Definable.image_comp_embedding /-
/-- Shows that definability is closed under finite projections. -/
theorem Definable.image_comp_embedding {s : Set (β → M)} (h : A.Definable L s) (f : α ↪ β)
- [Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by classical
+ [Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by
+ classical
+ cases nonempty_fintype β
+ refine'
+ (congr rfl (ext fun x => _)).mp
+ (((h.image_comp_equiv (Equiv.Set.sumCompl (range f))).image_comp_equiv
+ (Equiv.sumCongr (Equiv.ofInjective f f.injective)
+ (Fintype.equivFin _).symm)).image_comp_sum_inl_fin
+ _)
+ simp only [mem_preimage, mem_image, exists_exists_and_eq_and]
+ refine' exists_congr fun y => and_congr_right fun ys => Eq.congr_left (funext fun a => _)
+ simp
#align set.definable.image_comp_embedding Set.Definable.image_comp_embedding
-/
#print Set.Definable.image_comp /-
/-- Shows that definability is closed under finite projections. -/
theorem Definable.image_comp {s : Set (β → M)} (h : A.Definable L s) (f : α → β) [Finite α]
- [Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by classical
+ [Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by
+ classical
+ cases nonempty_fintype α
+ cases nonempty_fintype β
+ have h :=
+ (((h.image_comp_equiv (Equiv.Set.sumCompl (range f))).image_comp_equiv
+ (Equiv.sumCongr (_root_.equiv.refl _)
+ (Fintype.equivFin _).symm)).image_comp_sum_inl_fin
+ _).preimage_comp
+ (range_splitting f)
+ have h' :
+ A.definable L {x : α → M | ∀ a, x a = x (range_splitting f (range_factorization f a))} :=
+ by
+ have h' :
+ ∀ a, A.definable L {x : α → M | x a = x (range_splitting f (range_factorization f a))} :=
+ by
+ refine' fun a => ⟨(var a).equal (var (range_splitting f (range_factorization f a))), ext _⟩
+ simp
+ refine' (congr rfl (ext _)).mp (definable_finset_bInter h' Finset.univ)
+ simp
+ refine' (congr rfl (ext fun x => _)).mp (h.inter h')
+ simp only [Equiv.coe_trans, mem_inter_iff, mem_preimage, mem_image, exists_exists_and_eq_and,
+ mem_set_of_eq]
+ constructor
+ · rintro ⟨⟨y, ys, hy⟩, hx⟩
+ refine' ⟨y, ys, _⟩
+ ext a
+ rw [hx a, ← Function.comp_apply x, ← hy]
+ simp
+ · rintro ⟨y, ys, rfl⟩
+ refine' ⟨⟨y, ys, _⟩, fun a => _⟩
+ · ext
+ simp [Set.apply_rangeSplitting f]
+ ·
+ rw [Function.comp_apply, Function.comp_apply, apply_range_splitting f,
+ range_factorization_coe]
#align set.definable.image_comp Set.Definable.image_comp
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/65a1391a0106c9204fe45bc73a039f056558cb83
@@ -129,21 +129,13 @@ theorem Definable.union {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.De
#print Set.definable_finset_inf /-
theorem definable_finset_inf {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
- (s : Finset ι) : A.Definable L (s.inf f) := by
- classical
- refine' Finset.induction definable_univ (fun i s is h => _) s
- rw [Finset.inf_insert]
- exact (hf i).inter h
+ (s : Finset ι) : A.Definable L (s.inf f) := by classical
#align set.definable_finset_inf Set.definable_finset_inf
-/
#print Set.definable_finset_sup /-
theorem definable_finset_sup {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
- (s : Finset ι) : A.Definable L (s.sup f) := by
- classical
- refine' Finset.induction definable_empty (fun i s is h => _) s
- rw [Finset.sup_insert]
- exact (hf i).union h
+ (s : Finset ι) : A.Definable L (s.sup f) := by classical
#align set.definable_finset_sup Set.definable_finset_sup
-/
@@ -232,60 +224,14 @@ theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) →
#print Set.Definable.image_comp_embedding /-
/-- Shows that definability is closed under finite projections. -/
theorem Definable.image_comp_embedding {s : Set (β → M)} (h : A.Definable L s) (f : α ↪ β)
- [Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by
- classical
- cases nonempty_fintype β
- refine'
- (congr rfl (ext fun x => _)).mp
- (((h.image_comp_equiv (Equiv.Set.sumCompl (range f))).image_comp_equiv
- (Equiv.sumCongr (Equiv.ofInjective f f.injective)
- (Fintype.equivFin _).symm)).image_comp_sum_inl_fin
- _)
- simp only [mem_preimage, mem_image, exists_exists_and_eq_and]
- refine' exists_congr fun y => and_congr_right fun ys => Eq.congr_left (funext fun a => _)
- simp
+ [Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by classical
#align set.definable.image_comp_embedding Set.Definable.image_comp_embedding
-/
#print Set.Definable.image_comp /-
/-- Shows that definability is closed under finite projections. -/
theorem Definable.image_comp {s : Set (β → M)} (h : A.Definable L s) (f : α → β) [Finite α]
- [Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by
- classical
- cases nonempty_fintype α
- cases nonempty_fintype β
- have h :=
- (((h.image_comp_equiv (Equiv.Set.sumCompl (range f))).image_comp_equiv
- (Equiv.sumCongr (_root_.equiv.refl _)
- (Fintype.equivFin _).symm)).image_comp_sum_inl_fin
- _).preimage_comp
- (range_splitting f)
- have h' :
- A.definable L {x : α → M | ∀ a, x a = x (range_splitting f (range_factorization f a))} :=
- by
- have h' :
- ∀ a, A.definable L {x : α → M | x a = x (range_splitting f (range_factorization f a))} :=
- by
- refine' fun a => ⟨(var a).equal (var (range_splitting f (range_factorization f a))), ext _⟩
- simp
- refine' (congr rfl (ext _)).mp (definable_finset_bInter h' Finset.univ)
- simp
- refine' (congr rfl (ext fun x => _)).mp (h.inter h')
- simp only [Equiv.coe_trans, mem_inter_iff, mem_preimage, mem_image, exists_exists_and_eq_and,
- mem_set_of_eq]
- constructor
- · rintro ⟨⟨y, ys, hy⟩, hx⟩
- refine' ⟨y, ys, _⟩
- ext a
- rw [hx a, ← Function.comp_apply x, ← hy]
- simp
- · rintro ⟨y, ys, rfl⟩
- refine' ⟨⟨y, ys, _⟩, fun a => _⟩
- · ext
- simp [Set.apply_rangeSplitting f]
- ·
- rw [Function.comp_apply, Function.comp_apply, apply_range_splitting f,
- range_factorization_coe]
+ [Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by classical
#align set.definable.image_comp Set.Definable.image_comp
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/65a1391a0106c9204fe45bc73a039f056558cb83
@@ -219,7 +219,7 @@ theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) →
refine' ⟨(bounded_formula.relabel id φ).exs, _⟩
ext x
simp only [Set.mem_image, mem_set_of_eq, bounded_formula.realize_exs,
- bounded_formula.realize_relabel, Function.comp.right_id, Fin.castAdd_zero, Fin.castIso_refl]
+ bounded_formula.realize_relabel, Function.comp_id, Fin.castAdd_zero, Fin.castIso_refl]
constructor
· rintro ⟨y, hy, rfl⟩
exact
mathlib commit https://github.com/leanprover-community/mathlib/commit/ce64cd319bb6b3e82f31c2d38e79080d377be451
@@ -3,8 +3,8 @@ Copyright (c) 2021 Aaron Anderson. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Aaron Anderson
-/
-import Mathbin.Data.SetLike.Basic
-import Mathbin.ModelTheory.Semantics
+import Data.SetLike.Basic
+import ModelTheory.Semantics
#align_import model_theory.definability from "leanprover-community/mathlib"@"6cf5900728239efa287df7761ec2a1ac9cf39b29"
mathlib commit https://github.com/leanprover-community/mathlib/commit/8ea5598db6caeddde6cb734aa179cc2408dbd345
@@ -2,15 +2,12 @@
Copyright (c) 2021 Aaron Anderson. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Aaron Anderson
-
-! This file was ported from Lean 3 source module model_theory.definability
-! leanprover-community/mathlib commit 6cf5900728239efa287df7761ec2a1ac9cf39b29
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
-/
import Mathbin.Data.SetLike.Basic
import Mathbin.ModelTheory.Semantics
+#align_import model_theory.definability from "leanprover-community/mathlib"@"6cf5900728239efa287df7761ec2a1ac9cf39b29"
+
/-!
# Definable Sets
mathlib commit https://github.com/leanprover-community/mathlib/commit/728ef9dbb281241906f25cbeb30f90d83e0bb451
@@ -222,7 +222,7 @@ theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) →
refine' ⟨(bounded_formula.relabel id φ).exs, _⟩
ext x
simp only [Set.mem_image, mem_set_of_eq, bounded_formula.realize_exs,
- bounded_formula.realize_relabel, Function.comp.right_id, Fin.castAdd_zero, Fin.cast_refl]
+ bounded_formula.realize_relabel, Function.comp.right_id, Fin.castAdd_zero, Fin.castIso_refl]
constructor
· rintro ⟨y, hy, rfl⟩
exact
mathlib commit https://github.com/leanprover-community/mathlib/commit/9fb8964792b4237dac6200193a0d533f1b3f7423
@@ -58,6 +58,7 @@ def Definable (s : Set (α → M)) : Prop :=
variable {L} {A} {B : Set M} {s : Set (α → M)}
+#print Set.Definable.map_expansion /-
theorem Definable.map_expansion {L' : FirstOrder.Language} [L'.Structure M] (h : A.Definable L s)
(φ : L →ᴸ L') [φ.IsExpansionOn M] : A.Definable L' s :=
by
@@ -66,6 +67,7 @@ theorem Definable.map_expansion {L' : FirstOrder.Language} [L'.Structure M] (h :
ext x
simp only [mem_set_of_eq, Lhom.realize_on_formula]
#align set.definable.map_expansion Set.Definable.map_expansion
+-/
#print Set.empty_definable_iff /-
theorem empty_definable_iff : (∅ : Set M).Definable L s ↔ ∃ φ : L.Formula α, s = setOf φ.realize :=
@@ -104,6 +106,7 @@ theorem definable_univ : A.Definable L (univ : Set (α → M)) :=
#align set.definable_univ Set.definable_univ
-/
+#print Set.Definable.inter /-
@[simp]
theorem Definable.inter {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.Definable L g) :
A.Definable L (f ∩ g) := by
@@ -113,7 +116,9 @@ theorem Definable.inter {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.De
ext
simp
#align set.definable.inter Set.Definable.inter
+-/
+#print Set.Definable.union /-
@[simp]
theorem Definable.union {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.Definable L g) :
A.Definable L (f ∪ g) := by
@@ -123,7 +128,9 @@ theorem Definable.union {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.De
ext
rw [hφ, hθ, mem_set_of_eq, formula.realize_sup, mem_union, mem_set_of_eq, mem_set_of_eq]
#align set.definable.union Set.Definable.union
+-/
+#print Set.definable_finset_inf /-
theorem definable_finset_inf {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
(s : Finset ι) : A.Definable L (s.inf f) := by
classical
@@ -131,7 +138,9 @@ theorem definable_finset_inf {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf
rw [Finset.inf_insert]
exact (hf i).inter h
#align set.definable_finset_inf Set.definable_finset_inf
+-/
+#print Set.definable_finset_sup /-
theorem definable_finset_sup {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
(s : Finset ι) : A.Definable L (s.sup f) := by
classical
@@ -139,21 +148,27 @@ theorem definable_finset_sup {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf
rw [Finset.sup_insert]
exact (hf i).union h
#align set.definable_finset_sup Set.definable_finset_sup
+-/
+#print Set.definable_finset_biInter /-
theorem definable_finset_biInter {ι : Type _} {f : ∀ i : ι, Set (α → M)}
(hf : ∀ i, A.Definable L (f i)) (s : Finset ι) : A.Definable L (⋂ i ∈ s, f i) :=
by
rw [← Finset.inf_set_eq_iInter]
exact definable_finset_inf hf s
#align set.definable_finset_bInter Set.definable_finset_biInter
+-/
+#print Set.definable_finset_biUnion /-
theorem definable_finset_biUnion {ι : Type _} {f : ∀ i : ι, Set (α → M)}
(hf : ∀ i, A.Definable L (f i)) (s : Finset ι) : A.Definable L (⋃ i ∈ s, f i) :=
by
rw [← Finset.sup_set_eq_biUnion]
exact definable_finset_sup hf s
#align set.definable_finset_bUnion Set.definable_finset_biUnion
+-/
+#print Set.Definable.compl /-
@[simp]
theorem Definable.compl {s : Set (α → M)} (hf : A.Definable L s) : A.Definable L (sᶜ) :=
by
@@ -162,13 +177,17 @@ theorem Definable.compl {s : Set (α → M)} (hf : A.Definable L s) : A.Definabl
rw [hφ]
rfl
#align set.definable.compl Set.Definable.compl
+-/
+#print Set.Definable.sdiff /-
@[simp]
theorem Definable.sdiff {s t : Set (α → M)} (hs : A.Definable L s) (ht : A.Definable L t) :
A.Definable L (s \ t) :=
hs.inter ht.compl
#align set.definable.sdiff Set.Definable.sdiff
+-/
+#print Set.Definable.preimage_comp /-
theorem Definable.preimage_comp (f : α → β) {s : Set (α → M)} (h : A.Definable L s) :
A.Definable L ((fun g : β → M => g ∘ f) ⁻¹' s) :=
by
@@ -177,7 +196,9 @@ theorem Definable.preimage_comp (f : α → β) {s : Set (α → M)} (h : A.Defi
ext
simp only [Set.preimage_setOf_eq, mem_set_of_eq, formula.realize_relabel]
#align set.definable.preimage_comp Set.Definable.preimage_comp
+-/
+#print Set.Definable.image_comp_equiv /-
theorem Definable.image_comp_equiv {s : Set (β → M)} (h : A.Definable L s) (f : α ≃ β) :
A.Definable L ((fun g : β → M => g ∘ f) '' s) :=
by
@@ -190,6 +211,7 @@ theorem Definable.image_comp_equiv {s : Set (β → M)} (h : A.Definable L s) (f
ext a
simp
#align set.definable.image_comp_equiv Set.Definable.image_comp_equiv
+-/
#print Set.Definable.image_comp_sum_inl_fin /-
/-- This lemma is only intended as a helper for `definable.image_comp. -/
@@ -210,6 +232,7 @@ theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) →
#align set.definable.image_comp_sum_inl_fin Set.Definable.image_comp_sum_inl_fin
-/
+#print Set.Definable.image_comp_embedding /-
/-- Shows that definability is closed under finite projections. -/
theorem Definable.image_comp_embedding {s : Set (β → M)} (h : A.Definable L s) (f : α ↪ β)
[Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by
@@ -225,7 +248,9 @@ theorem Definable.image_comp_embedding {s : Set (β → M)} (h : A.Definable L s
refine' exists_congr fun y => and_congr_right fun ys => Eq.congr_left (funext fun a => _)
simp
#align set.definable.image_comp_embedding Set.Definable.image_comp_embedding
+-/
+#print Set.Definable.image_comp /-
/-- Shows that definability is closed under finite projections. -/
theorem Definable.image_comp {s : Set (β → M)} (h : A.Definable L s) (f : α → β) [Finite α]
[Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by
@@ -265,6 +290,7 @@ theorem Definable.image_comp {s : Set (β → M)} (h : A.Definable L s) (f : α
rw [Function.comp_apply, Function.comp_apply, apply_range_splitting f,
range_factorization_coe]
#align set.definable.image_comp Set.Definable.image_comp
+-/
variable (L) {M} (A)
@@ -330,9 +356,11 @@ instance : SDiff (L.DefinableSet A α) :=
instance : Inhabited (L.DefinableSet A α) :=
⟨⊥⟩
+#print FirstOrder.Language.DefinableSet.le_iff /-
theorem le_iff : s ≤ t ↔ (s : Set (α → M)) ≤ (t : Set (α → M)) :=
Iff.rfl
#align first_order.language.definable_set.le_iff FirstOrder.Language.DefinableSet.le_iff
+-/
#print FirstOrder.Language.DefinableSet.mem_top /-
@[simp]
@@ -390,25 +418,33 @@ theorem coe_bot : ((⊥ : L.DefinableSet A α) : Set (α → M)) = ∅ :=
#align first_order.language.definable_set.coe_bot FirstOrder.Language.DefinableSet.coe_bot
-/
+#print FirstOrder.Language.DefinableSet.coe_sup /-
@[simp, norm_cast]
theorem coe_sup (s t : L.DefinableSet A α) : (↑(s ⊔ t) : Set (α → M)) = s ∪ t :=
rfl
#align first_order.language.definable_set.coe_sup FirstOrder.Language.DefinableSet.coe_sup
+-/
+#print FirstOrder.Language.DefinableSet.coe_inf /-
@[simp, norm_cast]
theorem coe_inf (s t : L.DefinableSet A α) : (↑(s ⊓ t) : Set (α → M)) = s ∩ t :=
rfl
#align first_order.language.definable_set.coe_inf FirstOrder.Language.DefinableSet.coe_inf
+-/
+#print FirstOrder.Language.DefinableSet.coe_compl /-
@[simp, norm_cast]
theorem coe_compl (s : L.DefinableSet A α) : (↑(sᶜ) : Set (α → M)) = sᶜ :=
rfl
#align first_order.language.definable_set.coe_compl FirstOrder.Language.DefinableSet.coe_compl
+-/
+#print FirstOrder.Language.DefinableSet.coe_sdiff /-
@[simp, norm_cast]
theorem coe_sdiff (s t : L.DefinableSet A α) : (↑(s \ t) : Set (α → M)) = s \ t :=
rfl
#align first_order.language.definable_set.coe_sdiff FirstOrder.Language.DefinableSet.coe_sdiff
+-/
instance : BooleanAlgebra (L.DefinableSet A α) :=
Subtype.coe_injective.BooleanAlgebra _ coe_sup coe_inf coe_top coe_bot coe_compl coe_sdiff
mathlib commit https://github.com/leanprover-community/mathlib/commit/5f25c089cb34db4db112556f23c50d12da81b297
@@ -127,17 +127,17 @@ theorem Definable.union {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.De
theorem definable_finset_inf {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
(s : Finset ι) : A.Definable L (s.inf f) := by
classical
- refine' Finset.induction definable_univ (fun i s is h => _) s
- rw [Finset.inf_insert]
- exact (hf i).inter h
+ refine' Finset.induction definable_univ (fun i s is h => _) s
+ rw [Finset.inf_insert]
+ exact (hf i).inter h
#align set.definable_finset_inf Set.definable_finset_inf
theorem definable_finset_sup {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
(s : Finset ι) : A.Definable L (s.sup f) := by
classical
- refine' Finset.induction definable_empty (fun i s is h => _) s
- rw [Finset.sup_insert]
- exact (hf i).union h
+ refine' Finset.induction definable_empty (fun i s is h => _) s
+ rw [Finset.sup_insert]
+ exact (hf i).union h
#align set.definable_finset_sup Set.definable_finset_sup
theorem definable_finset_biInter {ι : Type _} {f : ∀ i : ι, Set (α → M)}
@@ -214,56 +214,56 @@ theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) →
theorem Definable.image_comp_embedding {s : Set (β → M)} (h : A.Definable L s) (f : α ↪ β)
[Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by
classical
- cases nonempty_fintype β
- refine'
- (congr rfl (ext fun x => _)).mp
- (((h.image_comp_equiv (Equiv.Set.sumCompl (range f))).image_comp_equiv
- (Equiv.sumCongr (Equiv.ofInjective f f.injective)
- (Fintype.equivFin _).symm)).image_comp_sum_inl_fin
- _)
- simp only [mem_preimage, mem_image, exists_exists_and_eq_and]
- refine' exists_congr fun y => and_congr_right fun ys => Eq.congr_left (funext fun a => _)
- simp
+ cases nonempty_fintype β
+ refine'
+ (congr rfl (ext fun x => _)).mp
+ (((h.image_comp_equiv (Equiv.Set.sumCompl (range f))).image_comp_equiv
+ (Equiv.sumCongr (Equiv.ofInjective f f.injective)
+ (Fintype.equivFin _).symm)).image_comp_sum_inl_fin
+ _)
+ simp only [mem_preimage, mem_image, exists_exists_and_eq_and]
+ refine' exists_congr fun y => and_congr_right fun ys => Eq.congr_left (funext fun a => _)
+ simp
#align set.definable.image_comp_embedding Set.Definable.image_comp_embedding
/-- Shows that definability is closed under finite projections. -/
theorem Definable.image_comp {s : Set (β → M)} (h : A.Definable L s) (f : α → β) [Finite α]
[Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by
classical
- cases nonempty_fintype α
- cases nonempty_fintype β
- have h :=
- (((h.image_comp_equiv (Equiv.Set.sumCompl (range f))).image_comp_equiv
- (Equiv.sumCongr (_root_.equiv.refl _)
- (Fintype.equivFin _).symm)).image_comp_sum_inl_fin
- _).preimage_comp
- (range_splitting f)
+ cases nonempty_fintype α
+ cases nonempty_fintype β
+ have h :=
+ (((h.image_comp_equiv (Equiv.Set.sumCompl (range f))).image_comp_equiv
+ (Equiv.sumCongr (_root_.equiv.refl _)
+ (Fintype.equivFin _).symm)).image_comp_sum_inl_fin
+ _).preimage_comp
+ (range_splitting f)
+ have h' :
+ A.definable L {x : α → M | ∀ a, x a = x (range_splitting f (range_factorization f a))} :=
+ by
have h' :
- A.definable L { x : α → M | ∀ a, x a = x (range_splitting f (range_factorization f a)) } :=
+ ∀ a, A.definable L {x : α → M | x a = x (range_splitting f (range_factorization f a))} :=
by
- have h' :
- ∀ a, A.definable L { x : α → M | x a = x (range_splitting f (range_factorization f a)) } :=
- by
- refine' fun a => ⟨(var a).equal (var (range_splitting f (range_factorization f a))), ext _⟩
- simp
- refine' (congr rfl (ext _)).mp (definable_finset_bInter h' Finset.univ)
+ refine' fun a => ⟨(var a).equal (var (range_splitting f (range_factorization f a))), ext _⟩
simp
- refine' (congr rfl (ext fun x => _)).mp (h.inter h')
- simp only [Equiv.coe_trans, mem_inter_iff, mem_preimage, mem_image, exists_exists_and_eq_and,
- mem_set_of_eq]
- constructor
- · rintro ⟨⟨y, ys, hy⟩, hx⟩
- refine' ⟨y, ys, _⟩
- ext a
- rw [hx a, ← Function.comp_apply x, ← hy]
- simp
- · rintro ⟨y, ys, rfl⟩
- refine' ⟨⟨y, ys, _⟩, fun a => _⟩
- · ext
- simp [Set.apply_rangeSplitting f]
- ·
- rw [Function.comp_apply, Function.comp_apply, apply_range_splitting f,
- range_factorization_coe]
+ refine' (congr rfl (ext _)).mp (definable_finset_bInter h' Finset.univ)
+ simp
+ refine' (congr rfl (ext fun x => _)).mp (h.inter h')
+ simp only [Equiv.coe_trans, mem_inter_iff, mem_preimage, mem_image, exists_exists_and_eq_and,
+ mem_set_of_eq]
+ constructor
+ · rintro ⟨⟨y, ys, hy⟩, hx⟩
+ refine' ⟨y, ys, _⟩
+ ext a
+ rw [hx a, ← Function.comp_apply x, ← hy]
+ simp
+ · rintro ⟨y, ys, rfl⟩
+ refine' ⟨⟨y, ys, _⟩, fun a => _⟩
+ · ext
+ simp [Set.apply_rangeSplitting f]
+ ·
+ rw [Function.comp_apply, Function.comp_apply, apply_range_splitting f,
+ range_factorization_coe]
#align set.definable.image_comp Set.Definable.image_comp
variable (L) {M} (A)
@@ -271,14 +271,14 @@ variable (L) {M} (A)
#print Set.Definable₁ /-
/-- A 1-dimensional version of `definable`, for `set M`. -/
def Definable₁ (s : Set M) : Prop :=
- A.Definable L { x : Fin 1 → M | x 0 ∈ s }
+ A.Definable L {x : Fin 1 → M | x 0 ∈ s}
#align set.definable₁ Set.Definable₁
-/
#print Set.Definable₂ /-
/-- A 2-dimensional version of `definable`, for `set (M × M)`. -/
def Definable₂ (s : Set (M × M)) : Prop :=
- A.Definable L { x : Fin 2 → M | (x 0, x 1) ∈ s }
+ A.Definable L {x : Fin 2 → M | (x 0, x 1) ∈ s}
#align set.definable₂ Set.Definable₂
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -42,7 +42,7 @@ namespace Set
variable {M : Type w} (A : Set M) (L : FirstOrder.Language.{u, v}) [L.Structure M]
-open FirstOrder
+open scoped FirstOrder
open FirstOrder.Language FirstOrder.Language.Structure
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -58,12 +58,6 @@ def Definable (s : Set (α → M)) : Prop :=
variable {L} {A} {B : Set M} {s : Set (α → M)}
-/- warning: set.definable.map_expansion -> Set.Definable.map_expansion is a dubious translation:
-lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {s : Set.{max u4 u3} (α -> M)} {L' : FirstOrder.Language.{u5, u6}} [_inst_2 : FirstOrder.Language.Structure.{u5, u6, u3} L' M], (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α s) -> (forall (φ : FirstOrder.Language.LHom.{u1, u2, u5, u6} L L') [_inst_3 : FirstOrder.Language.LHom.IsExpansionOn.{u1, u2, u5, u6, u3} L L' φ M _inst_1 _inst_2], Set.Definable.{u5, u6, u3, u4} M A L' _inst_2 α s)
-but is expected to have type
- forall {M : Type.{u5}} {A : Set.{u5} M} {L : FirstOrder.Language.{u3, u4}} [_inst_1 : FirstOrder.Language.Structure.{u3, u4, u5} L M] {α : Type.{u6}} {s : Set.{max u6 u5} (α -> M)} {L' : FirstOrder.Language.{u2, u1}} [_inst_2 : FirstOrder.Language.Structure.{u2, u1, u5} L' M], (Set.Definable.{u3, u4, u5, u6} M A L _inst_1 α s) -> (forall (φ : FirstOrder.Language.LHom.{u3, u4, u2, u1} L L') [_inst_3 : FirstOrder.Language.LHom.IsExpansionOn.{u3, u4, u2, u1, u5} L L' φ M _inst_1 _inst_2], Set.Definable.{u2, u1, u5, u6} M A L' _inst_2 α s)
-Case conversion may be inaccurate. Consider using '#align set.definable.map_expansion Set.Definable.map_expansionₓ'. -/
theorem Definable.map_expansion {L' : FirstOrder.Language} [L'.Structure M] (h : A.Definable L s)
(φ : L →ᴸ L') [φ.IsExpansionOn M] : A.Definable L' s :=
by
@@ -110,12 +104,6 @@ theorem definable_univ : A.Definable L (univ : Set (α → M)) :=
#align set.definable_univ Set.definable_univ
-/
-/- warning: set.definable.inter -> Set.Definable.inter is a dubious translation:
-lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {f : Set.{max u4 u3} (α -> M)} {g : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α f) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α g) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Inter.inter.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.hasInter.{max u4 u3} (α -> M)) f g))
-but is expected to have type
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {f : Set.{max u4 u3} (α -> M)} {g : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α f) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α g) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Inter.inter.{max u3 u4} (Set.{max u4 u3} (α -> M)) (Set.instInterSet.{max u4 u3} (α -> M)) f g))
-Case conversion may be inaccurate. Consider using '#align set.definable.inter Set.Definable.interₓ'. -/
@[simp]
theorem Definable.inter {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.Definable L g) :
A.Definable L (f ∩ g) := by
@@ -126,12 +114,6 @@ theorem Definable.inter {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.De
simp
#align set.definable.inter Set.Definable.inter
-/- warning: set.definable.union -> Set.Definable.union is a dubious translation:
-lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {f : Set.{max u4 u3} (α -> M)} {g : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α f) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α g) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Union.union.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.hasUnion.{max u4 u3} (α -> M)) f g))
-but is expected to have type
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {f : Set.{max u4 u3} (α -> M)} {g : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α f) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α g) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Union.union.{max u3 u4} (Set.{max u4 u3} (α -> M)) (Set.instUnionSet.{max u4 u3} (α -> M)) f g))
-Case conversion may be inaccurate. Consider using '#align set.definable.union Set.Definable.unionₓ'. -/
@[simp]
theorem Definable.union {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.Definable L g) :
A.Definable L (f ∪ g) := by
@@ -142,12 +124,6 @@ theorem Definable.union {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.De
rw [hφ, hθ, mem_set_of_eq, formula.realize_sup, mem_union, mem_set_of_eq, mem_set_of_eq]
#align set.definable.union Set.Definable.union
-/- warning: set.definable_finset_inf -> Set.definable_finset_inf is a dubious translation:
-lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {ι : Type.{u5}} {f : ι -> (Set.{max u4 u3} (α -> M))}, (forall (i : ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u5} ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Finset.inf.{max u4 u3, u5} (Set.{max u4 u3} (α -> M)) ι (Lattice.toSemilatticeInf.{max u4 u3} (Set.{max u4 u3} (α -> M)) (ConditionallyCompleteLattice.toLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (CompleteLattice.toConditionallyCompleteLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Order.Coframe.toCompleteLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (CompleteDistribLattice.toCoframe.{max u4 u3} (Set.{max u4 u3} (α -> M)) (CompleteBooleanAlgebra.toCompleteDistribLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.completeBooleanAlgebra.{max u4 u3} (α -> M)))))))) (Set.orderTop.{max u4 u3} (α -> M)) s f))
-but is expected to have type
- forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {ι : Type.{u1}} {f : ι -> (Set.{max u5 u4} (α -> M))}, (forall (i : ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u1} ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Finset.inf.{max u4 u5, u1} (Set.{max u5 u4} (α -> M)) ι (Lattice.toSemilatticeInf.{max u5 u4} (Set.{max u5 u4} (α -> M)) (ConditionallyCompleteLattice.toLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteLattice.toConditionallyCompleteLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Order.Coframe.toCompleteLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteDistribLattice.toCoframe.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteBooleanAlgebra.toCompleteDistribLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Set.instCompleteBooleanAlgebraSet.{max u5 u4} (α -> M)))))))) (Set.instOrderTopSetInstLESet.{max u5 u4} (α -> M)) s f))
-Case conversion may be inaccurate. Consider using '#align set.definable_finset_inf Set.definable_finset_infₓ'. -/
theorem definable_finset_inf {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
(s : Finset ι) : A.Definable L (s.inf f) := by
classical
@@ -156,12 +132,6 @@ theorem definable_finset_inf {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf
exact (hf i).inter h
#align set.definable_finset_inf Set.definable_finset_inf
-/- warning: set.definable_finset_sup -> Set.definable_finset_sup is a dubious translation:
-lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {ι : Type.{u5}} {f : ι -> (Set.{max u4 u3} (α -> M))}, (forall (i : ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u5} ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Finset.sup.{max u4 u3, u5} (Set.{max u4 u3} (α -> M)) ι (Lattice.toSemilatticeSup.{max u4 u3} (Set.{max u4 u3} (α -> M)) (ConditionallyCompleteLattice.toLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (CompleteLattice.toConditionallyCompleteLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Order.Coframe.toCompleteLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (CompleteDistribLattice.toCoframe.{max u4 u3} (Set.{max u4 u3} (α -> M)) (CompleteBooleanAlgebra.toCompleteDistribLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.completeBooleanAlgebra.{max u4 u3} (α -> M)))))))) (GeneralizedBooleanAlgebra.toOrderBot.{max u4 u3} (Set.{max u4 u3} (α -> M)) (BooleanAlgebra.toGeneralizedBooleanAlgebra.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.booleanAlgebra.{max u4 u3} (α -> M)))) s f))
-but is expected to have type
- forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {ι : Type.{u1}} {f : ι -> (Set.{max u5 u4} (α -> M))}, (forall (i : ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u1} ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Finset.sup.{max u4 u5, u1} (Set.{max u5 u4} (α -> M)) ι (Lattice.toSemilatticeSup.{max u5 u4} (Set.{max u5 u4} (α -> M)) (ConditionallyCompleteLattice.toLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteLattice.toConditionallyCompleteLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Order.Coframe.toCompleteLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteDistribLattice.toCoframe.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteBooleanAlgebra.toCompleteDistribLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Set.instCompleteBooleanAlgebraSet.{max u5 u4} (α -> M)))))))) (BoundedOrder.toOrderBot.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Preorder.toLE.{max u4 u5} (Set.{max u5 u4} (α -> M)) (PartialOrder.toPreorder.{max u4 u5} (Set.{max u5 u4} (α -> M)) (SemilatticeSup.toPartialOrder.{max u4 u5} (Set.{max u5 u4} (α -> M)) (Lattice.toSemilatticeSup.{max u5 u4} (Set.{max u5 u4} (α -> M)) (ConditionallyCompleteLattice.toLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteLattice.toConditionallyCompleteLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Order.Coframe.toCompleteLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteDistribLattice.toCoframe.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteBooleanAlgebra.toCompleteDistribLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Set.instCompleteBooleanAlgebraSet.{max u5 u4} (α -> M))))))))))) (CompleteLattice.toBoundedOrder.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Order.Coframe.toCompleteLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteDistribLattice.toCoframe.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteBooleanAlgebra.toCompleteDistribLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Set.instCompleteBooleanAlgebraSet.{max u5 u4} (α -> M))))))) s f))
-Case conversion may be inaccurate. Consider using '#align set.definable_finset_sup Set.definable_finset_supₓ'. -/
theorem definable_finset_sup {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
(s : Finset ι) : A.Definable L (s.sup f) := by
classical
@@ -170,12 +140,6 @@ theorem definable_finset_sup {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf
exact (hf i).union h
#align set.definable_finset_sup Set.definable_finset_sup
-/- warning: set.definable_finset_bInter -> Set.definable_finset_biInter is a dubious translation:
-lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {ι : Type.{u5}} {f : ι -> (Set.{max u4 u3} (α -> M))}, (forall (i : ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u5} ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.iInter.{max u4 u3, succ u5} (α -> M) ι (fun (i : ι) => Set.iInter.{max u4 u3, 0} (α -> M) (Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) (fun (H : Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) => f i))))
-but is expected to have type
- forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {ι : Type.{u1}} {f : ι -> (Set.{max u5 u4} (α -> M))}, (forall (i : ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u1} ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.iInter.{max u4 u5, succ u1} (α -> M) ι (fun (i : ι) => Set.iInter.{max u4 u5, 0} (α -> M) (Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) (fun (H : Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) => f i))))
-Case conversion may be inaccurate. Consider using '#align set.definable_finset_bInter Set.definable_finset_biInterₓ'. -/
theorem definable_finset_biInter {ι : Type _} {f : ∀ i : ι, Set (α → M)}
(hf : ∀ i, A.Definable L (f i)) (s : Finset ι) : A.Definable L (⋂ i ∈ s, f i) :=
by
@@ -183,12 +147,6 @@ theorem definable_finset_biInter {ι : Type _} {f : ∀ i : ι, Set (α → M)}
exact definable_finset_inf hf s
#align set.definable_finset_bInter Set.definable_finset_biInter
-/- warning: set.definable_finset_bUnion -> Set.definable_finset_biUnion is a dubious translation:
-lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {ι : Type.{u5}} {f : ι -> (Set.{max u4 u3} (α -> M))}, (forall (i : ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u5} ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.iUnion.{max u4 u3, succ u5} (α -> M) ι (fun (i : ι) => Set.iUnion.{max u4 u3, 0} (α -> M) (Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) (fun (H : Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) => f i))))
-but is expected to have type
- forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {ι : Type.{u1}} {f : ι -> (Set.{max u5 u4} (α -> M))}, (forall (i : ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u1} ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.iUnion.{max u4 u5, succ u1} (α -> M) ι (fun (i : ι) => Set.iUnion.{max u4 u5, 0} (α -> M) (Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) (fun (H : Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) => f i))))
-Case conversion may be inaccurate. Consider using '#align set.definable_finset_bUnion Set.definable_finset_biUnionₓ'. -/
theorem definable_finset_biUnion {ι : Type _} {f : ∀ i : ι, Set (α → M)}
(hf : ∀ i, A.Definable L (f i)) (s : Finset ι) : A.Definable L (⋃ i ∈ s, f i) :=
by
@@ -196,12 +154,6 @@ theorem definable_finset_biUnion {ι : Type _} {f : ∀ i : ι, Set (α → M)}
exact definable_finset_sup hf s
#align set.definable_finset_bUnion Set.definable_finset_biUnion
-/- warning: set.definable.compl -> Set.Definable.compl is a dubious translation:
-lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {s : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α s) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (HasCompl.compl.{max u4 u3} (Set.{max u4 u3} (α -> M)) (BooleanAlgebra.toHasCompl.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.booleanAlgebra.{max u4 u3} (α -> M))) s))
-but is expected to have type
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {s : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α s) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (HasCompl.compl.{max u3 u4} (Set.{max u4 u3} (α -> M)) (BooleanAlgebra.toHasCompl.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.instBooleanAlgebraSet.{max u4 u3} (α -> M))) s))
-Case conversion may be inaccurate. Consider using '#align set.definable.compl Set.Definable.complₓ'. -/
@[simp]
theorem Definable.compl {s : Set (α → M)} (hf : A.Definable L s) : A.Definable L (sᶜ) :=
by
@@ -211,24 +163,12 @@ theorem Definable.compl {s : Set (α → M)} (hf : A.Definable L s) : A.Definabl
rfl
#align set.definable.compl Set.Definable.compl
-/- warning: set.definable.sdiff -> Set.Definable.sdiff is a dubious translation:
-lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {s : Set.{max u4 u3} (α -> M)} {t : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α s) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α t) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (SDiff.sdiff.{max u4 u3} (Set.{max u4 u3} (α -> M)) (BooleanAlgebra.toHasSdiff.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.booleanAlgebra.{max u4 u3} (α -> M))) s t))
-but is expected to have type
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {s : Set.{max u4 u3} (α -> M)} {t : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α s) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α t) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (SDiff.sdiff.{max u3 u4} (Set.{max u4 u3} (α -> M)) (Set.instSDiffSet.{max u4 u3} (α -> M)) s t))
-Case conversion may be inaccurate. Consider using '#align set.definable.sdiff Set.Definable.sdiffₓ'. -/
@[simp]
theorem Definable.sdiff {s t : Set (α → M)} (hs : A.Definable L s) (ht : A.Definable L t) :
A.Definable L (s \ t) :=
hs.inter ht.compl
#align set.definable.sdiff Set.Definable.sdiff
-/- warning: set.definable.preimage_comp -> Set.Definable.preimage_comp is a dubious translation:
-lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {β : Type.{u5}} (f : α -> β) {s : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α s) -> (Set.Definable.{u1, u2, u3, u5} M A L _inst_1 β (Set.preimage.{max u5 u3, max u4 u3} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u4, succ u5, succ u3} α β M g f) s))
-but is expected to have type
- forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {β : Type.{u1}} (f : α -> β) {s : Set.{max u5 u4} (α -> M)}, (Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α s) -> (Set.Definable.{u2, u3, u4, u1} M A L _inst_1 β (Set.preimage.{max u4 u1, max u5 u4} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u5, succ u1, succ u4} α β M g f) s))
-Case conversion may be inaccurate. Consider using '#align set.definable.preimage_comp Set.Definable.preimage_compₓ'. -/
theorem Definable.preimage_comp (f : α → β) {s : Set (α → M)} (h : A.Definable L s) :
A.Definable L ((fun g : β → M => g ∘ f) ⁻¹' s) :=
by
@@ -238,12 +178,6 @@ theorem Definable.preimage_comp (f : α → β) {s : Set (α → M)} (h : A.Defi
simp only [Set.preimage_setOf_eq, mem_set_of_eq, formula.realize_relabel]
#align set.definable.preimage_comp Set.Definable.preimage_comp
-/- warning: set.definable.image_comp_equiv -> Set.Definable.image_comp_equiv is a dubious translation:
-lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {β : Type.{u5}} {s : Set.{max u5 u3} (β -> M)}, (Set.Definable.{u1, u2, u3, u5} M A L _inst_1 β s) -> (forall (f : Equiv.{succ u4, succ u5} α β), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.image.{max u5 u3, max u4 u3} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u4, succ u5, succ u3} α β M g (coeFn.{max 1 (max (succ u4) (succ u5)) (succ u5) (succ u4), max (succ u4) (succ u5)} (Equiv.{succ u4, succ u5} α β) (fun (_x : Equiv.{succ u4, succ u5} α β) => α -> β) (Equiv.hasCoeToFun.{succ u4, succ u5} α β) f)) s))
-but is expected to have type
- forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {β : Type.{u1}} {s : Set.{max u4 u1} (β -> M)}, (Set.Definable.{u2, u3, u4, u1} M A L _inst_1 β s) -> (forall (f : Equiv.{succ u5, succ u1} α β), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.image.{max u4 u1, max u4 u5} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u5, succ u1, succ u4} α β M g (FunLike.coe.{max (succ u5) (succ u1), succ u5, succ u1} (Equiv.{succ u5, succ u1} α β) α (fun (_x : α) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : α) => β) _x) (Equiv.instFunLikeEquiv.{succ u5, succ u1} α β) f)) s))
-Case conversion may be inaccurate. Consider using '#align set.definable.image_comp_equiv Set.Definable.image_comp_equivₓ'. -/
theorem Definable.image_comp_equiv {s : Set (β → M)} (h : A.Definable L s) (f : α ≃ β) :
A.Definable L ((fun g : β → M => g ∘ f) '' s) :=
by
@@ -276,12 +210,6 @@ theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) →
#align set.definable.image_comp_sum_inl_fin Set.Definable.image_comp_sum_inl_fin
-/
-/- warning: set.definable.image_comp_embedding -> Set.Definable.image_comp_embedding is a dubious translation:
-lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {β : Type.{u5}} {s : Set.{max u5 u3} (β -> M)}, (Set.Definable.{u1, u2, u3, u5} M A L _inst_1 β s) -> (forall (f : Function.Embedding.{succ u4, succ u5} α β) [_inst_2 : Finite.{succ u5} β], Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.image.{max u5 u3, max u4 u3} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u4, succ u5, succ u3} α β M g (coeFn.{max 1 (succ u4) (succ u5), max (succ u4) (succ u5)} (Function.Embedding.{succ u4, succ u5} α β) (fun (_x : Function.Embedding.{succ u4, succ u5} α β) => α -> β) (Function.Embedding.hasCoeToFun.{succ u4, succ u5} α β) f)) s))
-but is expected to have type
- forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {β : Type.{u1}} {s : Set.{max u4 u1} (β -> M)}, (Set.Definable.{u2, u3, u4, u1} M A L _inst_1 β s) -> (forall (f : Function.Embedding.{succ u5, succ u1} α β) [_inst_2 : Finite.{succ u1} β], Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.image.{max u4 u1, max u4 u5} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u5, succ u1, succ u4} α β M g (FunLike.coe.{max (succ u5) (succ u1), succ u5, succ u1} (Function.Embedding.{succ u5, succ u1} α β) α (fun (_x : α) => (fun (x._@.Mathlib.Data.FunLike.Embedding._hyg.19 : α) => β) _x) (EmbeddingLike.toFunLike.{max (succ u5) (succ u1), succ u5, succ u1} (Function.Embedding.{succ u5, succ u1} α β) α β (Function.instEmbeddingLikeEmbedding.{succ u5, succ u1} α β)) f)) s))
-Case conversion may be inaccurate. Consider using '#align set.definable.image_comp_embedding Set.Definable.image_comp_embeddingₓ'. -/
/-- Shows that definability is closed under finite projections. -/
theorem Definable.image_comp_embedding {s : Set (β → M)} (h : A.Definable L s) (f : α ↪ β)
[Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by
@@ -298,12 +226,6 @@ theorem Definable.image_comp_embedding {s : Set (β → M)} (h : A.Definable L s
simp
#align set.definable.image_comp_embedding Set.Definable.image_comp_embedding
-/- warning: set.definable.image_comp -> Set.Definable.image_comp is a dubious translation:
-lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {β : Type.{u5}} {s : Set.{max u5 u3} (β -> M)}, (Set.Definable.{u1, u2, u3, u5} M A L _inst_1 β s) -> (forall (f : α -> β) [_inst_2 : Finite.{succ u4} α] [_inst_3 : Finite.{succ u5} β], Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.image.{max u5 u3, max u4 u3} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u4, succ u5, succ u3} α β M g f) s))
-but is expected to have type
- forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {β : Type.{u1}} {s : Set.{max u4 u1} (β -> M)}, (Set.Definable.{u2, u3, u4, u1} M A L _inst_1 β s) -> (forall (f : α -> β) [_inst_2 : Finite.{succ u5} α] [_inst_3 : Finite.{succ u1} β], Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.image.{max u4 u1, max u4 u5} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u5, succ u1, succ u4} α β M g f) s))
-Case conversion may be inaccurate. Consider using '#align set.definable.image_comp Set.Definable.image_compₓ'. -/
/-- Shows that definability is closed under finite projections. -/
theorem Definable.image_comp {s : Set (β → M)} (h : A.Definable L s) (f : α → β) [Finite α]
[Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by
@@ -408,12 +330,6 @@ instance : SDiff (L.DefinableSet A α) :=
instance : Inhabited (L.DefinableSet A α) :=
⟨⊥⟩
-/- warning: first_order.language.definable_set.le_iff -> FirstOrder.Language.DefinableSet.le_iff is a dubious translation:
-lean 3 declaration is
- forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} {s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α} {t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α}, Iff (LE.le.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Preorder.toHasLe.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (PartialOrder.toPreorder.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (SetLike.partialOrder.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s t) (LE.le.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.hasLe.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) t))
-but is expected to have type
- forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} {s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α} {t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α}, Iff (LE.le.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Preorder.toLE.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (PartialOrder.toPreorder.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (SetLike.instPartialOrder.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s t) (LE.le.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.instLESet.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) s) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) t))
-Case conversion may be inaccurate. Consider using '#align first_order.language.definable_set.le_iff FirstOrder.Language.DefinableSet.le_iffₓ'. -/
theorem le_iff : s ≤ t ↔ (s : Set (α → M)) ≤ (t : Set (α → M)) :=
Iff.rfl
#align first_order.language.definable_set.le_iff FirstOrder.Language.DefinableSet.le_iff
@@ -474,45 +390,21 @@ theorem coe_bot : ((⊥ : L.DefinableSet A α) : Set (α → M)) = ∅ :=
#align first_order.language.definable_set.coe_bot FirstOrder.Language.DefinableSet.coe_bot
-/
-/- warning: first_order.language.definable_set.coe_sup -> FirstOrder.Language.DefinableSet.coe_sup is a dubious translation:
-lean 3 declaration is
- forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{succ (max u4 u3)} (Set.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) (Sup.sup.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instSup.{u1, u2, u3, u4} L M _inst_1 A α) s t)) (Union.union.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.hasUnion.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) t))
-but is expected to have type
- forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{max (succ u4) (succ u3)} (Set.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) (Sup.sup.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instSup.{u1, u2, u3, u4} L M _inst_1 A α) s t)) (Union.union.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.instUnionSet.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) s) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) t))
-Case conversion may be inaccurate. Consider using '#align first_order.language.definable_set.coe_sup FirstOrder.Language.DefinableSet.coe_supₓ'. -/
@[simp, norm_cast]
theorem coe_sup (s t : L.DefinableSet A α) : (↑(s ⊔ t) : Set (α → M)) = s ∪ t :=
rfl
#align first_order.language.definable_set.coe_sup FirstOrder.Language.DefinableSet.coe_sup
-/- warning: first_order.language.definable_set.coe_inf -> FirstOrder.Language.DefinableSet.coe_inf is a dubious translation:
-lean 3 declaration is
- forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{succ (max u4 u3)} (Set.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) (Inf.inf.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instInf.{u1, u2, u3, u4} L M _inst_1 A α) s t)) (Inter.inter.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.hasInter.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) t))
-but is expected to have type
- forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{max (succ u4) (succ u3)} (Set.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) (Inf.inf.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instInf.{u1, u2, u3, u4} L M _inst_1 A α) s t)) (Inter.inter.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.instInterSet.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) s) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) t))
-Case conversion may be inaccurate. Consider using '#align first_order.language.definable_set.coe_inf FirstOrder.Language.DefinableSet.coe_infₓ'. -/
@[simp, norm_cast]
theorem coe_inf (s t : L.DefinableSet A α) : (↑(s ⊓ t) : Set (α → M)) = s ∩ t :=
rfl
#align first_order.language.definable_set.coe_inf FirstOrder.Language.DefinableSet.coe_inf
-/- warning: first_order.language.definable_set.coe_compl -> FirstOrder.Language.DefinableSet.coe_compl is a dubious translation:
-lean 3 declaration is
- forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{succ (max u4 u3)} (Set.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) (HasCompl.compl.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instHasCompl.{u1, u2, u3, u4} L M _inst_1 A α) s)) (HasCompl.compl.{max u4 u3} (Set.{max u4 u3} (α -> M)) (BooleanAlgebra.toHasCompl.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.booleanAlgebra.{max u4 u3} (α -> M))) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s))
-but is expected to have type
- forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{max (succ u4) (succ u3)} (Set.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) (HasCompl.compl.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instHasCompl.{u1, u2, u3, u4} L M _inst_1 A α) s)) (HasCompl.compl.{max u4 u3} (Set.{max u4 u3} (α -> M)) (BooleanAlgebra.toHasCompl.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.instBooleanAlgebraSet.{max u4 u3} (α -> M))) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) s))
-Case conversion may be inaccurate. Consider using '#align first_order.language.definable_set.coe_compl FirstOrder.Language.DefinableSet.coe_complₓ'. -/
@[simp, norm_cast]
theorem coe_compl (s : L.DefinableSet A α) : (↑(sᶜ) : Set (α → M)) = sᶜ :=
rfl
#align first_order.language.definable_set.coe_compl FirstOrder.Language.DefinableSet.coe_compl
-/- warning: first_order.language.definable_set.coe_sdiff -> FirstOrder.Language.DefinableSet.coe_sdiff is a dubious translation:
-lean 3 declaration is
- forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{succ (max u4 u3)} (Set.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) (SDiff.sdiff.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instSDiff.{u1, u2, u3, u4} L M _inst_1 A α) s t)) (SDiff.sdiff.{max u4 u3} (Set.{max u4 u3} (α -> M)) (BooleanAlgebra.toHasSdiff.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.booleanAlgebra.{max u4 u3} (α -> M))) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) t))
-but is expected to have type
- forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{max (succ u4) (succ u3)} (Set.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) (SDiff.sdiff.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instSDiff.{u1, u2, u3, u4} L M _inst_1 A α) s t)) (SDiff.sdiff.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.instSDiffSet.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) s) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) t))
-Case conversion may be inaccurate. Consider using '#align first_order.language.definable_set.coe_sdiff FirstOrder.Language.DefinableSet.coe_sdiffₓ'. -/
@[simp, norm_cast]
theorem coe_sdiff (s t : L.DefinableSet A α) : (↑(s \ t) : Set (α → M)) = s \ t :=
rfl
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -99,18 +99,14 @@ theorem Definable.mono (hAs : A.Definable L s) (hAB : A ⊆ B) : B.Definable L s
#print Set.definable_empty /-
@[simp]
theorem definable_empty : A.Definable L (∅ : Set (α → M)) :=
- ⟨⊥, by
- ext
- simp⟩
+ ⟨⊥, by ext; simp⟩
#align set.definable_empty Set.definable_empty
-/
#print Set.definable_univ /-
@[simp]
theorem definable_univ : A.Definable L (univ : Set (α → M)) :=
- ⟨⊤, by
- ext
- simp⟩
+ ⟨⊤, by ext; simp⟩
#align set.definable_univ Set.definable_univ
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/95a87616d63b3cb49d3fe678d416fbe9c4217bf4
@@ -246,7 +246,7 @@ theorem Definable.preimage_comp (f : α → β) {s : Set (α → M)} (h : A.Defi
lean 3 declaration is
forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {β : Type.{u5}} {s : Set.{max u5 u3} (β -> M)}, (Set.Definable.{u1, u2, u3, u5} M A L _inst_1 β s) -> (forall (f : Equiv.{succ u4, succ u5} α β), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.image.{max u5 u3, max u4 u3} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u4, succ u5, succ u3} α β M g (coeFn.{max 1 (max (succ u4) (succ u5)) (succ u5) (succ u4), max (succ u4) (succ u5)} (Equiv.{succ u4, succ u5} α β) (fun (_x : Equiv.{succ u4, succ u5} α β) => α -> β) (Equiv.hasCoeToFun.{succ u4, succ u5} α β) f)) s))
but is expected to have type
- forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {β : Type.{u1}} {s : Set.{max u4 u1} (β -> M)}, (Set.Definable.{u2, u3, u4, u1} M A L _inst_1 β s) -> (forall (f : Equiv.{succ u5, succ u1} α β), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.image.{max u4 u1, max u4 u5} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u5, succ u1, succ u4} α β M g (FunLike.coe.{max (succ u5) (succ u1), succ u5, succ u1} (Equiv.{succ u5, succ u1} α β) α (fun (_x : α) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : α) => β) _x) (Equiv.instFunLikeEquiv.{succ u5, succ u1} α β) f)) s))
+ forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {β : Type.{u1}} {s : Set.{max u4 u1} (β -> M)}, (Set.Definable.{u2, u3, u4, u1} M A L _inst_1 β s) -> (forall (f : Equiv.{succ u5, succ u1} α β), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.image.{max u4 u1, max u4 u5} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u5, succ u1, succ u4} α β M g (FunLike.coe.{max (succ u5) (succ u1), succ u5, succ u1} (Equiv.{succ u5, succ u1} α β) α (fun (_x : α) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : α) => β) _x) (Equiv.instFunLikeEquiv.{succ u5, succ u1} α β) f)) s))
Case conversion may be inaccurate. Consider using '#align set.definable.image_comp_equiv Set.Definable.image_comp_equivₓ'. -/
theorem Definable.image_comp_equiv {s : Set (β → M)} (h : A.Definable L s) (f : α ≃ β) :
A.Definable L ((fun g : β → M => g ∘ f) '' s) :=
mathlib commit https://github.com/leanprover-community/mathlib/commit/0b9eaaa7686280fad8cce467f5c3c57ee6ce77f8
@@ -414,7 +414,7 @@ instance : Inhabited (L.DefinableSet A α) :=
/- warning: first_order.language.definable_set.le_iff -> FirstOrder.Language.DefinableSet.le_iff is a dubious translation:
lean 3 declaration is
- forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} {s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α} {t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α}, Iff (LE.le.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Preorder.toLE.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (PartialOrder.toPreorder.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (SetLike.partialOrder.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s t) (LE.le.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.hasLe.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) t))
+ forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} {s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α} {t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α}, Iff (LE.le.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Preorder.toHasLe.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (PartialOrder.toPreorder.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (SetLike.partialOrder.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s t) (LE.le.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.hasLe.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) t))
but is expected to have type
forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} {s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α} {t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α}, Iff (LE.le.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Preorder.toLE.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (PartialOrder.toPreorder.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (SetLike.instPartialOrder.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s t) (LE.le.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.instLESet.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) s) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) t))
Case conversion may be inaccurate. Consider using '#align first_order.language.definable_set.le_iff FirstOrder.Language.DefinableSet.le_iffₓ'. -/
mathlib commit https://github.com/leanprover-community/mathlib/commit/e3fb84046afd187b710170887195d50bada934ee
@@ -174,31 +174,31 @@ theorem definable_finset_sup {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf
exact (hf i).union h
#align set.definable_finset_sup Set.definable_finset_sup
-/- warning: set.definable_finset_bInter -> Set.definable_finset_binterᵢ is a dubious translation:
+/- warning: set.definable_finset_bInter -> Set.definable_finset_biInter is a dubious translation:
lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {ι : Type.{u5}} {f : ι -> (Set.{max u4 u3} (α -> M))}, (forall (i : ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u5} ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.interᵢ.{max u4 u3, succ u5} (α -> M) ι (fun (i : ι) => Set.interᵢ.{max u4 u3, 0} (α -> M) (Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) (fun (H : Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) => f i))))
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {ι : Type.{u5}} {f : ι -> (Set.{max u4 u3} (α -> M))}, (forall (i : ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u5} ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.iInter.{max u4 u3, succ u5} (α -> M) ι (fun (i : ι) => Set.iInter.{max u4 u3, 0} (α -> M) (Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) (fun (H : Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) => f i))))
but is expected to have type
- forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {ι : Type.{u1}} {f : ι -> (Set.{max u5 u4} (α -> M))}, (forall (i : ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u1} ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.interᵢ.{max u4 u5, succ u1} (α -> M) ι (fun (i : ι) => Set.interᵢ.{max u4 u5, 0} (α -> M) (Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) (fun (H : Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) => f i))))
-Case conversion may be inaccurate. Consider using '#align set.definable_finset_bInter Set.definable_finset_binterᵢₓ'. -/
-theorem definable_finset_binterᵢ {ι : Type _} {f : ∀ i : ι, Set (α → M)}
+ forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {ι : Type.{u1}} {f : ι -> (Set.{max u5 u4} (α -> M))}, (forall (i : ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u1} ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.iInter.{max u4 u5, succ u1} (α -> M) ι (fun (i : ι) => Set.iInter.{max u4 u5, 0} (α -> M) (Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) (fun (H : Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) => f i))))
+Case conversion may be inaccurate. Consider using '#align set.definable_finset_bInter Set.definable_finset_biInterₓ'. -/
+theorem definable_finset_biInter {ι : Type _} {f : ∀ i : ι, Set (α → M)}
(hf : ∀ i, A.Definable L (f i)) (s : Finset ι) : A.Definable L (⋂ i ∈ s, f i) :=
by
- rw [← Finset.inf_set_eq_interᵢ]
+ rw [← Finset.inf_set_eq_iInter]
exact definable_finset_inf hf s
-#align set.definable_finset_bInter Set.definable_finset_binterᵢ
+#align set.definable_finset_bInter Set.definable_finset_biInter
-/- warning: set.definable_finset_bUnion -> Set.definable_finset_bunionᵢ is a dubious translation:
+/- warning: set.definable_finset_bUnion -> Set.definable_finset_biUnion is a dubious translation:
lean 3 declaration is
- forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {ι : Type.{u5}} {f : ι -> (Set.{max u4 u3} (α -> M))}, (forall (i : ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u5} ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.unionᵢ.{max u4 u3, succ u5} (α -> M) ι (fun (i : ι) => Set.unionᵢ.{max u4 u3, 0} (α -> M) (Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) (fun (H : Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) => f i))))
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {ι : Type.{u5}} {f : ι -> (Set.{max u4 u3} (α -> M))}, (forall (i : ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u5} ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.iUnion.{max u4 u3, succ u5} (α -> M) ι (fun (i : ι) => Set.iUnion.{max u4 u3, 0} (α -> M) (Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) (fun (H : Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) => f i))))
but is expected to have type
- forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {ι : Type.{u1}} {f : ι -> (Set.{max u5 u4} (α -> M))}, (forall (i : ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u1} ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.unionᵢ.{max u4 u5, succ u1} (α -> M) ι (fun (i : ι) => Set.unionᵢ.{max u4 u5, 0} (α -> M) (Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) (fun (H : Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) => f i))))
-Case conversion may be inaccurate. Consider using '#align set.definable_finset_bUnion Set.definable_finset_bunionᵢₓ'. -/
-theorem definable_finset_bunionᵢ {ι : Type _} {f : ∀ i : ι, Set (α → M)}
+ forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {ι : Type.{u1}} {f : ι -> (Set.{max u5 u4} (α -> M))}, (forall (i : ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u1} ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.iUnion.{max u4 u5, succ u1} (α -> M) ι (fun (i : ι) => Set.iUnion.{max u4 u5, 0} (α -> M) (Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) (fun (H : Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) => f i))))
+Case conversion may be inaccurate. Consider using '#align set.definable_finset_bUnion Set.definable_finset_biUnionₓ'. -/
+theorem definable_finset_biUnion {ι : Type _} {f : ∀ i : ι, Set (α → M)}
(hf : ∀ i, A.Definable L (f i)) (s : Finset ι) : A.Definable L (⋃ i ∈ s, f i) :=
by
- rw [← Finset.sup_set_eq_bunionᵢ]
+ rw [← Finset.sup_set_eq_biUnion]
exact definable_finset_sup hf s
-#align set.definable_finset_bUnion Set.definable_finset_bunionᵢ
+#align set.definable_finset_bUnion Set.definable_finset_biUnion
/- warning: set.definable.compl -> Set.Definable.compl is a dubious translation:
lean 3 declaration is
mathlib commit https://github.com/leanprover-community/mathlib/commit/e3fb84046afd187b710170887195d50bada934ee
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Aaron Anderson
! This file was ported from Lean 3 source module model_theory.definability
-! leanprover-community/mathlib commit 70fd9563a21e7b963887c9360bd29b2393e6225a
+! leanprover-community/mathlib commit 6cf5900728239efa287df7761ec2a1ac9cf39b29
! Please do not edit these lines, except to modify the commit id
! if you have ported upstream changes.
-/
@@ -13,6 +13,9 @@ import Mathbin.ModelTheory.Semantics
/-!
# Definable Sets
+
+> THIS FILE IS SYNCHRONIZED WITH MATHLIB4.
+> Any changes to this file require a corresponding PR to mathlib4.
This file defines what it means for a set over a first-order structure to be definable.
## Main Definitions
mathlib commit https://github.com/leanprover-community/mathlib/commit/2f8347015b12b0864dfaf366ec4909eb70c78740
@@ -45,14 +45,22 @@ open FirstOrder.Language FirstOrder.Language.Structure
variable {α : Type _} {β : Type _}
+#print Set.Definable /-
/-- A subset of a finite Cartesian product of a structure is definable over a set `A` when
membership in the set is given by a first-order formula with parameters from `A`. -/
def Definable (s : Set (α → M)) : Prop :=
∃ φ : L[[A]].Formula α, s = setOf φ.realize
#align set.definable Set.Definable
+-/
variable {L} {A} {B : Set M} {s : Set (α → M)}
+/- warning: set.definable.map_expansion -> Set.Definable.map_expansion is a dubious translation:
+lean 3 declaration is
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {s : Set.{max u4 u3} (α -> M)} {L' : FirstOrder.Language.{u5, u6}} [_inst_2 : FirstOrder.Language.Structure.{u5, u6, u3} L' M], (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α s) -> (forall (φ : FirstOrder.Language.LHom.{u1, u2, u5, u6} L L') [_inst_3 : FirstOrder.Language.LHom.IsExpansionOn.{u1, u2, u5, u6, u3} L L' φ M _inst_1 _inst_2], Set.Definable.{u5, u6, u3, u4} M A L' _inst_2 α s)
+but is expected to have type
+ forall {M : Type.{u5}} {A : Set.{u5} M} {L : FirstOrder.Language.{u3, u4}} [_inst_1 : FirstOrder.Language.Structure.{u3, u4, u5} L M] {α : Type.{u6}} {s : Set.{max u6 u5} (α -> M)} {L' : FirstOrder.Language.{u2, u1}} [_inst_2 : FirstOrder.Language.Structure.{u2, u1, u5} L' M], (Set.Definable.{u3, u4, u5, u6} M A L _inst_1 α s) -> (forall (φ : FirstOrder.Language.LHom.{u3, u4, u2, u1} L L') [_inst_3 : FirstOrder.Language.LHom.IsExpansionOn.{u3, u4, u2, u1, u5} L L' φ M _inst_1 _inst_2], Set.Definable.{u2, u1, u5, u6} M A L' _inst_2 α s)
+Case conversion may be inaccurate. Consider using '#align set.definable.map_expansion Set.Definable.map_expansionₓ'. -/
theorem Definable.map_expansion {L' : FirstOrder.Language} [L'.Structure M] (h : A.Definable L s)
(φ : L →ᴸ L') [φ.IsExpansionOn M] : A.Definable L' s :=
by
@@ -62,37 +70,53 @@ theorem Definable.map_expansion {L' : FirstOrder.Language} [L'.Structure M] (h :
simp only [mem_set_of_eq, Lhom.realize_on_formula]
#align set.definable.map_expansion Set.Definable.map_expansion
+#print Set.empty_definable_iff /-
theorem empty_definable_iff : (∅ : Set M).Definable L s ↔ ∃ φ : L.Formula α, s = setOf φ.realize :=
by
rw [definable, Equiv.exists_congr_left (Lequiv.add_empty_constants L (∅ : Set M)).onFormula]
simp
#align set.empty_definable_iff Set.empty_definable_iff
+-/
+#print Set.definable_iff_empty_definable_with_params /-
theorem definable_iff_empty_definable_with_params :
A.Definable L s ↔ (∅ : Set M).Definable (L[[A]]) s :=
empty_definable_iff.symm
#align set.definable_iff_empty_definable_with_params Set.definable_iff_empty_definable_with_params
+-/
+#print Set.Definable.mono /-
theorem Definable.mono (hAs : A.Definable L s) (hAB : A ⊆ B) : B.Definable L s :=
by
rw [definable_iff_empty_definable_with_params] at *
exact hAs.map_expansion (L.Lhom_with_constants_map (Set.inclusion hAB))
#align set.definable.mono Set.Definable.mono
+-/
+#print Set.definable_empty /-
@[simp]
theorem definable_empty : A.Definable L (∅ : Set (α → M)) :=
⟨⊥, by
ext
simp⟩
#align set.definable_empty Set.definable_empty
+-/
+#print Set.definable_univ /-
@[simp]
theorem definable_univ : A.Definable L (univ : Set (α → M)) :=
⟨⊤, by
ext
simp⟩
#align set.definable_univ Set.definable_univ
+-/
+/- warning: set.definable.inter -> Set.Definable.inter is a dubious translation:
+lean 3 declaration is
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {f : Set.{max u4 u3} (α -> M)} {g : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α f) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α g) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Inter.inter.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.hasInter.{max u4 u3} (α -> M)) f g))
+but is expected to have type
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {f : Set.{max u4 u3} (α -> M)} {g : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α f) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α g) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Inter.inter.{max u3 u4} (Set.{max u4 u3} (α -> M)) (Set.instInterSet.{max u4 u3} (α -> M)) f g))
+Case conversion may be inaccurate. Consider using '#align set.definable.inter Set.Definable.interₓ'. -/
@[simp]
theorem Definable.inter {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.Definable L g) :
A.Definable L (f ∩ g) := by
@@ -103,6 +127,12 @@ theorem Definable.inter {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.De
simp
#align set.definable.inter Set.Definable.inter
+/- warning: set.definable.union -> Set.Definable.union is a dubious translation:
+lean 3 declaration is
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {f : Set.{max u4 u3} (α -> M)} {g : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α f) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α g) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Union.union.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.hasUnion.{max u4 u3} (α -> M)) f g))
+but is expected to have type
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {f : Set.{max u4 u3} (α -> M)} {g : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α f) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α g) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Union.union.{max u3 u4} (Set.{max u4 u3} (α -> M)) (Set.instUnionSet.{max u4 u3} (α -> M)) f g))
+Case conversion may be inaccurate. Consider using '#align set.definable.union Set.Definable.unionₓ'. -/
@[simp]
theorem Definable.union {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.Definable L g) :
A.Definable L (f ∪ g) := by
@@ -113,6 +143,12 @@ theorem Definable.union {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.De
rw [hφ, hθ, mem_set_of_eq, formula.realize_sup, mem_union, mem_set_of_eq, mem_set_of_eq]
#align set.definable.union Set.Definable.union
+/- warning: set.definable_finset_inf -> Set.definable_finset_inf is a dubious translation:
+lean 3 declaration is
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {ι : Type.{u5}} {f : ι -> (Set.{max u4 u3} (α -> M))}, (forall (i : ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u5} ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Finset.inf.{max u4 u3, u5} (Set.{max u4 u3} (α -> M)) ι (Lattice.toSemilatticeInf.{max u4 u3} (Set.{max u4 u3} (α -> M)) (ConditionallyCompleteLattice.toLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (CompleteLattice.toConditionallyCompleteLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Order.Coframe.toCompleteLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (CompleteDistribLattice.toCoframe.{max u4 u3} (Set.{max u4 u3} (α -> M)) (CompleteBooleanAlgebra.toCompleteDistribLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.completeBooleanAlgebra.{max u4 u3} (α -> M)))))))) (Set.orderTop.{max u4 u3} (α -> M)) s f))
+but is expected to have type
+ forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {ι : Type.{u1}} {f : ι -> (Set.{max u5 u4} (α -> M))}, (forall (i : ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u1} ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Finset.inf.{max u4 u5, u1} (Set.{max u5 u4} (α -> M)) ι (Lattice.toSemilatticeInf.{max u5 u4} (Set.{max u5 u4} (α -> M)) (ConditionallyCompleteLattice.toLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteLattice.toConditionallyCompleteLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Order.Coframe.toCompleteLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteDistribLattice.toCoframe.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteBooleanAlgebra.toCompleteDistribLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Set.instCompleteBooleanAlgebraSet.{max u5 u4} (α -> M)))))))) (Set.instOrderTopSetInstLESet.{max u5 u4} (α -> M)) s f))
+Case conversion may be inaccurate. Consider using '#align set.definable_finset_inf Set.definable_finset_infₓ'. -/
theorem definable_finset_inf {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
(s : Finset ι) : A.Definable L (s.inf f) := by
classical
@@ -121,6 +157,12 @@ theorem definable_finset_inf {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf
exact (hf i).inter h
#align set.definable_finset_inf Set.definable_finset_inf
+/- warning: set.definable_finset_sup -> Set.definable_finset_sup is a dubious translation:
+lean 3 declaration is
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {ι : Type.{u5}} {f : ι -> (Set.{max u4 u3} (α -> M))}, (forall (i : ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u5} ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Finset.sup.{max u4 u3, u5} (Set.{max u4 u3} (α -> M)) ι (Lattice.toSemilatticeSup.{max u4 u3} (Set.{max u4 u3} (α -> M)) (ConditionallyCompleteLattice.toLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (CompleteLattice.toConditionallyCompleteLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Order.Coframe.toCompleteLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (CompleteDistribLattice.toCoframe.{max u4 u3} (Set.{max u4 u3} (α -> M)) (CompleteBooleanAlgebra.toCompleteDistribLattice.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.completeBooleanAlgebra.{max u4 u3} (α -> M)))))))) (GeneralizedBooleanAlgebra.toOrderBot.{max u4 u3} (Set.{max u4 u3} (α -> M)) (BooleanAlgebra.toGeneralizedBooleanAlgebra.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.booleanAlgebra.{max u4 u3} (α -> M)))) s f))
+but is expected to have type
+ forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {ι : Type.{u1}} {f : ι -> (Set.{max u5 u4} (α -> M))}, (forall (i : ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u1} ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Finset.sup.{max u4 u5, u1} (Set.{max u5 u4} (α -> M)) ι (Lattice.toSemilatticeSup.{max u5 u4} (Set.{max u5 u4} (α -> M)) (ConditionallyCompleteLattice.toLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteLattice.toConditionallyCompleteLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Order.Coframe.toCompleteLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteDistribLattice.toCoframe.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteBooleanAlgebra.toCompleteDistribLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Set.instCompleteBooleanAlgebraSet.{max u5 u4} (α -> M)))))))) (BoundedOrder.toOrderBot.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Preorder.toLE.{max u4 u5} (Set.{max u5 u4} (α -> M)) (PartialOrder.toPreorder.{max u4 u5} (Set.{max u5 u4} (α -> M)) (SemilatticeSup.toPartialOrder.{max u4 u5} (Set.{max u5 u4} (α -> M)) (Lattice.toSemilatticeSup.{max u5 u4} (Set.{max u5 u4} (α -> M)) (ConditionallyCompleteLattice.toLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteLattice.toConditionallyCompleteLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Order.Coframe.toCompleteLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteDistribLattice.toCoframe.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteBooleanAlgebra.toCompleteDistribLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Set.instCompleteBooleanAlgebraSet.{max u5 u4} (α -> M))))))))))) (CompleteLattice.toBoundedOrder.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Order.Coframe.toCompleteLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteDistribLattice.toCoframe.{max u5 u4} (Set.{max u5 u4} (α -> M)) (CompleteBooleanAlgebra.toCompleteDistribLattice.{max u5 u4} (Set.{max u5 u4} (α -> M)) (Set.instCompleteBooleanAlgebraSet.{max u5 u4} (α -> M))))))) s f))
+Case conversion may be inaccurate. Consider using '#align set.definable_finset_sup Set.definable_finset_supₓ'. -/
theorem definable_finset_sup {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
(s : Finset ι) : A.Definable L (s.sup f) := by
classical
@@ -129,20 +171,38 @@ theorem definable_finset_sup {ι : Type _} {f : ∀ i : ι, Set (α → M)} (hf
exact (hf i).union h
#align set.definable_finset_sup Set.definable_finset_sup
-theorem definable_finset_bInter {ι : Type _} {f : ∀ i : ι, Set (α → M)}
+/- warning: set.definable_finset_bInter -> Set.definable_finset_binterᵢ is a dubious translation:
+lean 3 declaration is
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {ι : Type.{u5}} {f : ι -> (Set.{max u4 u3} (α -> M))}, (forall (i : ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u5} ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.interᵢ.{max u4 u3, succ u5} (α -> M) ι (fun (i : ι) => Set.interᵢ.{max u4 u3, 0} (α -> M) (Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) (fun (H : Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) => f i))))
+but is expected to have type
+ forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {ι : Type.{u1}} {f : ι -> (Set.{max u5 u4} (α -> M))}, (forall (i : ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u1} ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.interᵢ.{max u4 u5, succ u1} (α -> M) ι (fun (i : ι) => Set.interᵢ.{max u4 u5, 0} (α -> M) (Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) (fun (H : Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) => f i))))
+Case conversion may be inaccurate. Consider using '#align set.definable_finset_bInter Set.definable_finset_binterᵢₓ'. -/
+theorem definable_finset_binterᵢ {ι : Type _} {f : ∀ i : ι, Set (α → M)}
(hf : ∀ i, A.Definable L (f i)) (s : Finset ι) : A.Definable L (⋂ i ∈ s, f i) :=
by
rw [← Finset.inf_set_eq_interᵢ]
exact definable_finset_inf hf s
-#align set.definable_finset_bInter Set.definable_finset_bInter
-
-theorem definable_finset_bUnion {ι : Type _} {f : ∀ i : ι, Set (α → M)}
+#align set.definable_finset_bInter Set.definable_finset_binterᵢ
+
+/- warning: set.definable_finset_bUnion -> Set.definable_finset_bunionᵢ is a dubious translation:
+lean 3 declaration is
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {ι : Type.{u5}} {f : ι -> (Set.{max u4 u3} (α -> M))}, (forall (i : ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u5} ι), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.unionᵢ.{max u4 u3, succ u5} (α -> M) ι (fun (i : ι) => Set.unionᵢ.{max u4 u3, 0} (α -> M) (Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) (fun (H : Membership.Mem.{u5, u5} ι (Finset.{u5} ι) (Finset.hasMem.{u5} ι) i s) => f i))))
+but is expected to have type
+ forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {ι : Type.{u1}} {f : ι -> (Set.{max u5 u4} (α -> M))}, (forall (i : ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (f i)) -> (forall (s : Finset.{u1} ι), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.unionᵢ.{max u4 u5, succ u1} (α -> M) ι (fun (i : ι) => Set.unionᵢ.{max u4 u5, 0} (α -> M) (Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) (fun (H : Membership.mem.{u1, u1} ι (Finset.{u1} ι) (Finset.instMembershipFinset.{u1} ι) i s) => f i))))
+Case conversion may be inaccurate. Consider using '#align set.definable_finset_bUnion Set.definable_finset_bunionᵢₓ'. -/
+theorem definable_finset_bunionᵢ {ι : Type _} {f : ∀ i : ι, Set (α → M)}
(hf : ∀ i, A.Definable L (f i)) (s : Finset ι) : A.Definable L (⋃ i ∈ s, f i) :=
by
rw [← Finset.sup_set_eq_bunionᵢ]
exact definable_finset_sup hf s
-#align set.definable_finset_bUnion Set.definable_finset_bUnion
-
+#align set.definable_finset_bUnion Set.definable_finset_bunionᵢ
+
+/- warning: set.definable.compl -> Set.Definable.compl is a dubious translation:
+lean 3 declaration is
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {s : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α s) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (HasCompl.compl.{max u4 u3} (Set.{max u4 u3} (α -> M)) (BooleanAlgebra.toHasCompl.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.booleanAlgebra.{max u4 u3} (α -> M))) s))
+but is expected to have type
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {s : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α s) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (HasCompl.compl.{max u3 u4} (Set.{max u4 u3} (α -> M)) (BooleanAlgebra.toHasCompl.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.instBooleanAlgebraSet.{max u4 u3} (α -> M))) s))
+Case conversion may be inaccurate. Consider using '#align set.definable.compl Set.Definable.complₓ'. -/
@[simp]
theorem Definable.compl {s : Set (α → M)} (hf : A.Definable L s) : A.Definable L (sᶜ) :=
by
@@ -152,12 +212,24 @@ theorem Definable.compl {s : Set (α → M)} (hf : A.Definable L s) : A.Definabl
rfl
#align set.definable.compl Set.Definable.compl
+/- warning: set.definable.sdiff -> Set.Definable.sdiff is a dubious translation:
+lean 3 declaration is
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {s : Set.{max u4 u3} (α -> M)} {t : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α s) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α t) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (SDiff.sdiff.{max u4 u3} (Set.{max u4 u3} (α -> M)) (BooleanAlgebra.toHasSdiff.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.booleanAlgebra.{max u4 u3} (α -> M))) s t))
+but is expected to have type
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {s : Set.{max u4 u3} (α -> M)} {t : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α s) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α t) -> (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (SDiff.sdiff.{max u3 u4} (Set.{max u4 u3} (α -> M)) (Set.instSDiffSet.{max u4 u3} (α -> M)) s t))
+Case conversion may be inaccurate. Consider using '#align set.definable.sdiff Set.Definable.sdiffₓ'. -/
@[simp]
theorem Definable.sdiff {s t : Set (α → M)} (hs : A.Definable L s) (ht : A.Definable L t) :
A.Definable L (s \ t) :=
hs.inter ht.compl
#align set.definable.sdiff Set.Definable.sdiff
+/- warning: set.definable.preimage_comp -> Set.Definable.preimage_comp is a dubious translation:
+lean 3 declaration is
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {β : Type.{u5}} (f : α -> β) {s : Set.{max u4 u3} (α -> M)}, (Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α s) -> (Set.Definable.{u1, u2, u3, u5} M A L _inst_1 β (Set.preimage.{max u5 u3, max u4 u3} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u4, succ u5, succ u3} α β M g f) s))
+but is expected to have type
+ forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {β : Type.{u1}} (f : α -> β) {s : Set.{max u5 u4} (α -> M)}, (Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α s) -> (Set.Definable.{u2, u3, u4, u1} M A L _inst_1 β (Set.preimage.{max u4 u1, max u5 u4} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u5, succ u1, succ u4} α β M g f) s))
+Case conversion may be inaccurate. Consider using '#align set.definable.preimage_comp Set.Definable.preimage_compₓ'. -/
theorem Definable.preimage_comp (f : α → β) {s : Set (α → M)} (h : A.Definable L s) :
A.Definable L ((fun g : β → M => g ∘ f) ⁻¹' s) :=
by
@@ -167,6 +239,12 @@ theorem Definable.preimage_comp (f : α → β) {s : Set (α → M)} (h : A.Defi
simp only [Set.preimage_setOf_eq, mem_set_of_eq, formula.realize_relabel]
#align set.definable.preimage_comp Set.Definable.preimage_comp
+/- warning: set.definable.image_comp_equiv -> Set.Definable.image_comp_equiv is a dubious translation:
+lean 3 declaration is
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {β : Type.{u5}} {s : Set.{max u5 u3} (β -> M)}, (Set.Definable.{u1, u2, u3, u5} M A L _inst_1 β s) -> (forall (f : Equiv.{succ u4, succ u5} α β), Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.image.{max u5 u3, max u4 u3} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u4, succ u5, succ u3} α β M g (coeFn.{max 1 (max (succ u4) (succ u5)) (succ u5) (succ u4), max (succ u4) (succ u5)} (Equiv.{succ u4, succ u5} α β) (fun (_x : Equiv.{succ u4, succ u5} α β) => α -> β) (Equiv.hasCoeToFun.{succ u4, succ u5} α β) f)) s))
+but is expected to have type
+ forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {β : Type.{u1}} {s : Set.{max u4 u1} (β -> M)}, (Set.Definable.{u2, u3, u4, u1} M A L _inst_1 β s) -> (forall (f : Equiv.{succ u5, succ u1} α β), Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.image.{max u4 u1, max u4 u5} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u5, succ u1, succ u4} α β M g (FunLike.coe.{max (succ u5) (succ u1), succ u5, succ u1} (Equiv.{succ u5, succ u1} α β) α (fun (_x : α) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : α) => β) _x) (Equiv.instFunLikeEquiv.{succ u5, succ u1} α β) f)) s))
+Case conversion may be inaccurate. Consider using '#align set.definable.image_comp_equiv Set.Definable.image_comp_equivₓ'. -/
theorem Definable.image_comp_equiv {s : Set (β → M)} (h : A.Definable L s) (f : α ≃ β) :
A.Definable L ((fun g : β → M => g ∘ f) '' s) :=
by
@@ -180,6 +258,7 @@ theorem Definable.image_comp_equiv {s : Set (β → M)} (h : A.Definable L s) (f
simp
#align set.definable.image_comp_equiv Set.Definable.image_comp_equiv
+#print Set.Definable.image_comp_sum_inl_fin /-
/-- This lemma is only intended as a helper for `definable.image_comp. -/
theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) → M)}
(h : A.Definable L s) : A.Definable L ((fun g : Sum α (Fin m) → M => g ∘ Sum.inl) '' s) :=
@@ -196,7 +275,14 @@ theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) →
· rintro ⟨y, hy⟩
exact ⟨Sum.elim x y, (congr rfl (funext finZeroElim)).mp hy, Sum.elim_comp_inl _ _⟩
#align set.definable.image_comp_sum_inl_fin Set.Definable.image_comp_sum_inl_fin
+-/
+/- warning: set.definable.image_comp_embedding -> Set.Definable.image_comp_embedding is a dubious translation:
+lean 3 declaration is
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {β : Type.{u5}} {s : Set.{max u5 u3} (β -> M)}, (Set.Definable.{u1, u2, u3, u5} M A L _inst_1 β s) -> (forall (f : Function.Embedding.{succ u4, succ u5} α β) [_inst_2 : Finite.{succ u5} β], Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.image.{max u5 u3, max u4 u3} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u4, succ u5, succ u3} α β M g (coeFn.{max 1 (succ u4) (succ u5), max (succ u4) (succ u5)} (Function.Embedding.{succ u4, succ u5} α β) (fun (_x : Function.Embedding.{succ u4, succ u5} α β) => α -> β) (Function.Embedding.hasCoeToFun.{succ u4, succ u5} α β) f)) s))
+but is expected to have type
+ forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {β : Type.{u1}} {s : Set.{max u4 u1} (β -> M)}, (Set.Definable.{u2, u3, u4, u1} M A L _inst_1 β s) -> (forall (f : Function.Embedding.{succ u5, succ u1} α β) [_inst_2 : Finite.{succ u1} β], Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.image.{max u4 u1, max u4 u5} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u5, succ u1, succ u4} α β M g (FunLike.coe.{max (succ u5) (succ u1), succ u5, succ u1} (Function.Embedding.{succ u5, succ u1} α β) α (fun (_x : α) => (fun (x._@.Mathlib.Data.FunLike.Embedding._hyg.19 : α) => β) _x) (EmbeddingLike.toFunLike.{max (succ u5) (succ u1), succ u5, succ u1} (Function.Embedding.{succ u5, succ u1} α β) α β (Function.instEmbeddingLikeEmbedding.{succ u5, succ u1} α β)) f)) s))
+Case conversion may be inaccurate. Consider using '#align set.definable.image_comp_embedding Set.Definable.image_comp_embeddingₓ'. -/
/-- Shows that definability is closed under finite projections. -/
theorem Definable.image_comp_embedding {s : Set (β → M)} (h : A.Definable L s) (f : α ↪ β)
[Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by
@@ -213,6 +299,12 @@ theorem Definable.image_comp_embedding {s : Set (β → M)} (h : A.Definable L s
simp
#align set.definable.image_comp_embedding Set.Definable.image_comp_embedding
+/- warning: set.definable.image_comp -> Set.Definable.image_comp is a dubious translation:
+lean 3 declaration is
+ forall {M : Type.{u3}} {A : Set.{u3} M} {L : FirstOrder.Language.{u1, u2}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {α : Type.{u4}} {β : Type.{u5}} {s : Set.{max u5 u3} (β -> M)}, (Set.Definable.{u1, u2, u3, u5} M A L _inst_1 β s) -> (forall (f : α -> β) [_inst_2 : Finite.{succ u4} α] [_inst_3 : Finite.{succ u5} β], Set.Definable.{u1, u2, u3, u4} M A L _inst_1 α (Set.image.{max u5 u3, max u4 u3} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u4, succ u5, succ u3} α β M g f) s))
+but is expected to have type
+ forall {M : Type.{u4}} {A : Set.{u4} M} {L : FirstOrder.Language.{u2, u3}} [_inst_1 : FirstOrder.Language.Structure.{u2, u3, u4} L M] {α : Type.{u5}} {β : Type.{u1}} {s : Set.{max u4 u1} (β -> M)}, (Set.Definable.{u2, u3, u4, u1} M A L _inst_1 β s) -> (forall (f : α -> β) [_inst_2 : Finite.{succ u5} α] [_inst_3 : Finite.{succ u1} β], Set.Definable.{u2, u3, u4, u5} M A L _inst_1 α (Set.image.{max u4 u1, max u4 u5} (β -> M) (α -> M) (fun (g : β -> M) => Function.comp.{succ u5, succ u1, succ u4} α β M g f) s))
+Case conversion may be inaccurate. Consider using '#align set.definable.image_comp Set.Definable.image_compₓ'. -/
/-- Shows that definability is closed under finite projections. -/
theorem Definable.image_comp {s : Set (β → M)} (h : A.Definable L s) (f : α → β) [Finite α]
[Finite β] : A.Definable L ((fun g : β → M => g ∘ f) '' s) := by
@@ -255,15 +347,19 @@ theorem Definable.image_comp {s : Set (β → M)} (h : A.Definable L s) (f : α
variable (L) {M} (A)
+#print Set.Definable₁ /-
/-- A 1-dimensional version of `definable`, for `set M`. -/
def Definable₁ (s : Set M) : Prop :=
A.Definable L { x : Fin 1 → M | x 0 ∈ s }
#align set.definable₁ Set.Definable₁
+-/
+#print Set.Definable₂ /-
/-- A 2-dimensional version of `definable`, for `set (M × M)`. -/
def Definable₂ (s : Set (M × M)) : Prop :=
A.Definable L { x : Fin 2 → M | (x 0, x 1) ∈ s }
#align set.definable₂ Set.Definable₂
+-/
end Set
@@ -275,11 +371,13 @@ open Set
variable (L : FirstOrder.Language.{u, v}) {M : Type w} [L.Structure M] (A : Set M) (α : Type _)
+#print FirstOrder.Language.DefinableSet /-
/-- Definable sets are subsets of finite Cartesian products of a structure such that membership is
given by a first-order formula. -/
def DefinableSet :=
{ s : Set (α → M) // A.Definable L s }
#align first_order.language.definable_set FirstOrder.Language.DefinableSet
+-/
namespace DefinableSet
@@ -311,65 +409,111 @@ instance : SDiff (L.DefinableSet A α) :=
instance : Inhabited (L.DefinableSet A α) :=
⟨⊥⟩
+/- warning: first_order.language.definable_set.le_iff -> FirstOrder.Language.DefinableSet.le_iff is a dubious translation:
+lean 3 declaration is
+ forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} {s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α} {t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α}, Iff (LE.le.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Preorder.toLE.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (PartialOrder.toPreorder.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (SetLike.partialOrder.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s t) (LE.le.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.hasLe.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) t))
+but is expected to have type
+ forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} {s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α} {t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α}, Iff (LE.le.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Preorder.toLE.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (PartialOrder.toPreorder.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (SetLike.instPartialOrder.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s t) (LE.le.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.instLESet.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) s) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) t))
+Case conversion may be inaccurate. Consider using '#align first_order.language.definable_set.le_iff FirstOrder.Language.DefinableSet.le_iffₓ'. -/
theorem le_iff : s ≤ t ↔ (s : Set (α → M)) ≤ (t : Set (α → M)) :=
Iff.rfl
#align first_order.language.definable_set.le_iff FirstOrder.Language.DefinableSet.le_iff
+#print FirstOrder.Language.DefinableSet.mem_top /-
@[simp]
theorem mem_top : x ∈ (⊤ : L.DefinableSet A α) :=
mem_univ x
#align first_order.language.definable_set.mem_top FirstOrder.Language.DefinableSet.mem_top
+-/
+#print FirstOrder.Language.DefinableSet.not_mem_bot /-
@[simp]
theorem not_mem_bot {x : α → M} : ¬x ∈ (⊥ : L.DefinableSet A α) :=
not_mem_empty x
#align first_order.language.definable_set.not_mem_bot FirstOrder.Language.DefinableSet.not_mem_bot
+-/
+#print FirstOrder.Language.DefinableSet.mem_sup /-
@[simp]
theorem mem_sup : x ∈ s ⊔ t ↔ x ∈ s ∨ x ∈ t :=
Iff.rfl
#align first_order.language.definable_set.mem_sup FirstOrder.Language.DefinableSet.mem_sup
+-/
+#print FirstOrder.Language.DefinableSet.mem_inf /-
@[simp]
theorem mem_inf : x ∈ s ⊓ t ↔ x ∈ s ∧ x ∈ t :=
Iff.rfl
#align first_order.language.definable_set.mem_inf FirstOrder.Language.DefinableSet.mem_inf
+-/
+#print FirstOrder.Language.DefinableSet.mem_compl /-
@[simp]
theorem mem_compl : x ∈ sᶜ ↔ ¬x ∈ s :=
Iff.rfl
#align first_order.language.definable_set.mem_compl FirstOrder.Language.DefinableSet.mem_compl
+-/
+#print FirstOrder.Language.DefinableSet.mem_sdiff /-
@[simp]
theorem mem_sdiff : x ∈ s \ t ↔ x ∈ s ∧ ¬x ∈ t :=
Iff.rfl
#align first_order.language.definable_set.mem_sdiff FirstOrder.Language.DefinableSet.mem_sdiff
+-/
+#print FirstOrder.Language.DefinableSet.coe_top /-
@[simp, norm_cast]
theorem coe_top : ((⊤ : L.DefinableSet A α) : Set (α → M)) = univ :=
rfl
#align first_order.language.definable_set.coe_top FirstOrder.Language.DefinableSet.coe_top
+-/
+#print FirstOrder.Language.DefinableSet.coe_bot /-
@[simp, norm_cast]
theorem coe_bot : ((⊥ : L.DefinableSet A α) : Set (α → M)) = ∅ :=
rfl
#align first_order.language.definable_set.coe_bot FirstOrder.Language.DefinableSet.coe_bot
+-/
+/- warning: first_order.language.definable_set.coe_sup -> FirstOrder.Language.DefinableSet.coe_sup is a dubious translation:
+lean 3 declaration is
+ forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{succ (max u4 u3)} (Set.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) (Sup.sup.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instSup.{u1, u2, u3, u4} L M _inst_1 A α) s t)) (Union.union.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.hasUnion.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) t))
+but is expected to have type
+ forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{max (succ u4) (succ u3)} (Set.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) (Sup.sup.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instSup.{u1, u2, u3, u4} L M _inst_1 A α) s t)) (Union.union.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.instUnionSet.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) s) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) t))
+Case conversion may be inaccurate. Consider using '#align first_order.language.definable_set.coe_sup FirstOrder.Language.DefinableSet.coe_supₓ'. -/
@[simp, norm_cast]
theorem coe_sup (s t : L.DefinableSet A α) : (↑(s ⊔ t) : Set (α → M)) = s ∪ t :=
rfl
#align first_order.language.definable_set.coe_sup FirstOrder.Language.DefinableSet.coe_sup
+/- warning: first_order.language.definable_set.coe_inf -> FirstOrder.Language.DefinableSet.coe_inf is a dubious translation:
+lean 3 declaration is
+ forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{succ (max u4 u3)} (Set.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) (Inf.inf.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instInf.{u1, u2, u3, u4} L M _inst_1 A α) s t)) (Inter.inter.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.hasInter.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) t))
+but is expected to have type
+ forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{max (succ u4) (succ u3)} (Set.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) (Inf.inf.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instInf.{u1, u2, u3, u4} L M _inst_1 A α) s t)) (Inter.inter.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.instInterSet.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) s) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) t))
+Case conversion may be inaccurate. Consider using '#align first_order.language.definable_set.coe_inf FirstOrder.Language.DefinableSet.coe_infₓ'. -/
@[simp, norm_cast]
theorem coe_inf (s t : L.DefinableSet A α) : (↑(s ⊓ t) : Set (α → M)) = s ∩ t :=
rfl
#align first_order.language.definable_set.coe_inf FirstOrder.Language.DefinableSet.coe_inf
+/- warning: first_order.language.definable_set.coe_compl -> FirstOrder.Language.DefinableSet.coe_compl is a dubious translation:
+lean 3 declaration is
+ forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{succ (max u4 u3)} (Set.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) (HasCompl.compl.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instHasCompl.{u1, u2, u3, u4} L M _inst_1 A α) s)) (HasCompl.compl.{max u4 u3} (Set.{max u4 u3} (α -> M)) (BooleanAlgebra.toHasCompl.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.booleanAlgebra.{max u4 u3} (α -> M))) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s))
+but is expected to have type
+ forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{max (succ u4) (succ u3)} (Set.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) (HasCompl.compl.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instHasCompl.{u1, u2, u3, u4} L M _inst_1 A α) s)) (HasCompl.compl.{max u4 u3} (Set.{max u4 u3} (α -> M)) (BooleanAlgebra.toHasCompl.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.instBooleanAlgebraSet.{max u4 u3} (α -> M))) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) s))
+Case conversion may be inaccurate. Consider using '#align first_order.language.definable_set.coe_compl FirstOrder.Language.DefinableSet.coe_complₓ'. -/
@[simp, norm_cast]
theorem coe_compl (s : L.DefinableSet A α) : (↑(sᶜ) : Set (α → M)) = sᶜ :=
rfl
#align first_order.language.definable_set.coe_compl FirstOrder.Language.DefinableSet.coe_compl
+/- warning: first_order.language.definable_set.coe_sdiff -> FirstOrder.Language.DefinableSet.coe_sdiff is a dubious translation:
+lean 3 declaration is
+ forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{succ (max u4 u3)} (Set.{max u4 u3} (α -> M)) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) (SDiff.sdiff.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instSDiff.{u1, u2, u3, u4} L M _inst_1 A α) s t)) (SDiff.sdiff.{max u4 u3} (Set.{max u4 u3} (α -> M)) (BooleanAlgebra.toHasSdiff.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.booleanAlgebra.{max u4 u3} (α -> M))) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) s) ((fun (a : Type.{max u4 u3}) (b : Type.{max u4 u3}) [self : HasLiftT.{succ (max u4 u3), succ (max u4 u3)} a b] => self.0) (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (HasLiftT.mk.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (CoeTCₓ.coe.{succ (max u4 u3), succ (max u4 u3)} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (Set.{max u4 u3} (α -> M)) (SetLike.Set.hasCoeT.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α)))) t))
+but is expected to have type
+ forall {L : FirstOrder.Language.{u1, u2}} {M : Type.{u3}} [_inst_1 : FirstOrder.Language.Structure.{u1, u2, u3} L M] {A : Set.{u3} M} {α : Type.{u4}} (s : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (t : FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α), Eq.{max (succ u4) (succ u3)} (Set.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) (SDiff.sdiff.{max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (FirstOrder.Language.DefinableSet.instSDiff.{u1, u2, u3, u4} L M _inst_1 A α) s t)) (SDiff.sdiff.{max u4 u3} (Set.{max u4 u3} (α -> M)) (Set.instSDiffSet.{max u4 u3} (α -> M)) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) s) (SetLike.coe.{max u4 u3, max u4 u3} (FirstOrder.Language.DefinableSet.{u1, u2, u3, u4} L M _inst_1 A α) (α -> M) (FirstOrder.Language.DefinableSet.instSetLike.{u1, u2, u3, u4} L M _inst_1 A α) t))
+Case conversion may be inaccurate. Consider using '#align first_order.language.definable_set.coe_sdiff FirstOrder.Language.DefinableSet.coe_sdiffₓ'. -/
@[simp, norm_cast]
theorem coe_sdiff (s t : L.DefinableSet A α) : (↑(s \ t) : Set (α → M)) = s \ t :=
rfl
mathlib commit https://github.com/leanprover-community/mathlib/commit/9da1b3534b65d9661eb8f42443598a92bbb49211
@@ -296,10 +296,10 @@ instance : Top (L.DefinableSet A α) :=
instance : Bot (L.DefinableSet A α) :=
⟨⟨⊥, definable_empty⟩⟩
-instance : HasSup (L.DefinableSet A α) :=
+instance : Sup (L.DefinableSet A α) :=
⟨fun s t => ⟨s ∪ t, s.2.union t.2⟩⟩
-instance : HasInf (L.DefinableSet A α) :=
+instance : Inf (L.DefinableSet A α) :=
⟨fun s t => ⟨s ∩ t, s.2.inter t.2⟩⟩
instance : HasCompl (L.DefinableSet A α) :=
mathlib commit https://github.com/leanprover-community/mathlib/commit/bd9851ca476957ea4549eb19b40e7b5ade9428cc
@@ -205,8 +205,8 @@ theorem definable_iff_finitely_definable :
Set.mem_setOf_eq]
apply Iff.symm
convert BoundedFormula.realize_restrictFreeVar _
- · ext a
- rcases a with ⟨_ | _, _⟩ <;> simp
+ ext a
+ rcases a with ⟨_ | _, _⟩ <;> simp
· rintro ⟨A0, hA0, hd⟩
exact Definable.mono hd hA0
@@ -60,7 +60,7 @@ theorem Definable.map_expansion {L' : FirstOrder.Language} [L'.Structure M] (h :
theorem definable_iff_exists_formula_sum :
A.Definable L s ↔ ∃ φ : L.Formula (A ⊕ α), s = {v | φ.Realize (Sum.elim (↑) v)} := by
rw [Definable, Equiv.exists_congr_left (BoundedFormula.constantsVarsEquiv)]
- refine exists_congr (fun φ => iff_iff_eq.2 (congr_arg (s = .) ?_))
+ refine exists_congr (fun φ => iff_iff_eq.2 (congr_arg (s = ·) ?_))
ext
simp only [Formula.Realize, BoundedFormula.constantsVarsEquiv, constantsOn, mk₂_Relations,
BoundedFormula.mapTermRelEquiv_symm_apply, mem_setOf_eq]
@@ -194,11 +194,11 @@ theorem definable_iff_finitely_definable :
rintro ⟨φ, rfl⟩
let A0 := (φ.freeVarFinset.preimage Sum.inl
(Function.Injective.injOn Sum.inl_injective _)).image Subtype.val
- have hA0 : (A0 : Set M) ⊆ A := by simp
+ have hA0 : (A0 : Set M) ⊆ A := by simp [A0]
refine ⟨A0, hA0, (φ.restrictFreeVar
(Set.inclusion (Set.Subset.refl _))).relabel ?_, ?_⟩
· rintro ⟨a | a, ha⟩
- · exact Sum.inl (Sum.inl ⟨a, by simpa using ha⟩)
+ · exact Sum.inl (Sum.inl ⟨a, by simpa [A0] using ha⟩)
· exact Sum.inl (Sum.inr a)
· ext v
simp only [Formula.Realize, BoundedFormula.realize_relabel,
Move toNat
and toPartENat
to new files.
No changes in the code moved to the new files.
One lemma remains in Basic
but used toNat
in the proof,
so I changed the proof.
I'm going to redefine them in terms of toENat
, so I need to move them out of Basic
first.
@@ -4,6 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Aaron Anderson
-/
import Mathlib.Data.SetLike.Basic
+import Mathlib.Data.Finset.Preimage
import Mathlib.ModelTheory.Semantics
#align_import model_theory.definability from "leanprover-community/mathlib"@"70fd9563a21e7b963887c9360bd29b2393e6225a"
Function.left_id
and Function.comp.left_id
into Function.id_comp
.Function.right_id
and Function.comp.right_id
into Function.comp_id
.Function.comp_const_right
and Function.comp_const
into Function.comp_const
, use explicit arguments.Function.const_comp
to Mathlib.Init.Function
, use explicit arguments.@@ -216,7 +216,7 @@ theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) →
refine' ⟨(BoundedFormula.relabel id φ).exs, _⟩
ext x
simp only [Set.mem_image, mem_setOf_eq, BoundedFormula.realize_exs,
- BoundedFormula.realize_relabel, Function.comp.right_id, Fin.castAdd_zero, Fin.cast_refl]
+ BoundedFormula.realize_relabel, Function.comp_id, Fin.castAdd_zero, Fin.cast_refl]
constructor
· rintro ⟨y, hy, rfl⟩
exact
@@ -121,7 +121,7 @@ theorem Definable.union {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.De
rw [hφ, hθ, mem_setOf_eq, Formula.realize_sup, mem_union, mem_setOf_eq, mem_setOf_eq]
#align set.definable.union Set.Definable.union
-theorem definable_finset_inf {ι : Type*} {f : ∀ _ : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
+theorem definable_finset_inf {ι : Type*} {f : ι → Set (α → M)} (hf : ∀ i, A.Definable L (f i))
(s : Finset ι) : A.Definable L (s.inf f) := by
classical
refine' Finset.induction definable_univ (fun i s _ h => _) s
@@ -129,7 +129,7 @@ theorem definable_finset_inf {ι : Type*} {f : ∀ _ : ι, Set (α → M)} (hf :
exact (hf i).inter h
#align set.definable_finset_inf Set.definable_finset_inf
-theorem definable_finset_sup {ι : Type*} {f : ∀ _ : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
+theorem definable_finset_sup {ι : Type*} {f : ι → Set (α → M)} (hf : ∀ i, A.Definable L (f i))
(s : Finset ι) : A.Definable L (s.sup f) := by
classical
refine' Finset.induction definable_empty (fun i s _ h => _) s
@@ -137,13 +137,13 @@ theorem definable_finset_sup {ι : Type*} {f : ∀ _ : ι, Set (α → M)} (hf :
exact (hf i).union h
#align set.definable_finset_sup Set.definable_finset_sup
-theorem definable_finset_biInter {ι : Type*} {f : ∀ _ : ι, Set (α → M)}
+theorem definable_finset_biInter {ι : Type*} {f : ι → Set (α → M)}
(hf : ∀ i, A.Definable L (f i)) (s : Finset ι) : A.Definable L (⋂ i ∈ s, f i) := by
rw [← Finset.inf_set_eq_iInter]
exact definable_finset_inf hf s
#align set.definable_finset_bInter Set.definable_finset_biInter
-theorem definable_finset_biUnion {ι : Type*} {f : ∀ _ : ι, Set (α → M)}
+theorem definable_finset_biUnion {ι : Type*} {f : ι → Set (α → M)}
(hf : ∀ i, A.Definable L (f i)) (s : Finset ι) : A.Definable L (⋃ i ∈ s, f i) := by
rw [← Finset.sup_set_eq_biUnion]
exact definable_finset_sup hf s
Fin.castIso
and Fin.revPerm
with Fin.cast
and Fin.rev
for the bump of Std (#5847)
Some theorems in Data.Fin.Basic
are copied to Std at the recent commit in Std.
These are written using Fin.cast
and Fin.rev
, so declarations using Fin.castIso
and Fin.revPerm
in Mathlib should be rewritten.
Co-authored-by: Pol'tta / Miyahara Kō <52843868+Komyyy@users.noreply.github.com> Co-authored-by: Johan Commelin <johan@commelin.net>
@@ -216,7 +216,7 @@ theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) →
refine' ⟨(BoundedFormula.relabel id φ).exs, _⟩
ext x
simp only [Set.mem_image, mem_setOf_eq, BoundedFormula.realize_exs,
- BoundedFormula.realize_relabel, Function.comp.right_id, Fin.castAdd_zero, Fin.castIso_refl]
+ BoundedFormula.realize_relabel, Function.comp.right_id, Fin.castAdd_zero, Fin.cast_refl]
constructor
· rintro ⟨y, hy, rfl⟩
exact
@@ -183,6 +183,32 @@ theorem Definable.image_comp_equiv {s : Set (β → M)} (h : A.Definable L s) (f
simp
#align set.definable.image_comp_equiv Set.Definable.image_comp_equiv
+theorem definable_iff_finitely_definable :
+ A.Definable L s ↔ ∃ (A0 : Finset M), (A0 : Set M) ⊆ A ∧
+ (A0 : Set M).Definable L s := by
+ letI := Classical.decEq M
+ letI := Classical.decEq α
+ constructor
+ · simp only [definable_iff_exists_formula_sum]
+ rintro ⟨φ, rfl⟩
+ let A0 := (φ.freeVarFinset.preimage Sum.inl
+ (Function.Injective.injOn Sum.inl_injective _)).image Subtype.val
+ have hA0 : (A0 : Set M) ⊆ A := by simp
+ refine ⟨A0, hA0, (φ.restrictFreeVar
+ (Set.inclusion (Set.Subset.refl _))).relabel ?_, ?_⟩
+ · rintro ⟨a | a, ha⟩
+ · exact Sum.inl (Sum.inl ⟨a, by simpa using ha⟩)
+ · exact Sum.inl (Sum.inr a)
+ · ext v
+ simp only [Formula.Realize, BoundedFormula.realize_relabel,
+ Set.mem_setOf_eq]
+ apply Iff.symm
+ convert BoundedFormula.realize_restrictFreeVar _
+ · ext a
+ rcases a with ⟨_ | _, _⟩ <;> simp
+ · rintro ⟨A0, hA0, hd⟩
+ exact Definable.mono hd hA0
+
/-- This lemma is only intended as a helper for `Definable.image_comp`. -/
theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) → M)}
(h : A.Definable L s) : A.Definable L ((fun g : Sum α (Fin m) → M => g ∘ Sum.inl) '' s) := by
@@ -56,6 +56,21 @@ theorem Definable.map_expansion {L' : FirstOrder.Language} [L'.Structure M] (h :
simp only [mem_setOf_eq, LHom.realize_onFormula]
#align set.definable.map_expansion Set.Definable.map_expansion
+theorem definable_iff_exists_formula_sum :
+ A.Definable L s ↔ ∃ φ : L.Formula (A ⊕ α), s = {v | φ.Realize (Sum.elim (↑) v)} := by
+ rw [Definable, Equiv.exists_congr_left (BoundedFormula.constantsVarsEquiv)]
+ refine exists_congr (fun φ => iff_iff_eq.2 (congr_arg (s = .) ?_))
+ ext
+ simp only [Formula.Realize, BoundedFormula.constantsVarsEquiv, constantsOn, mk₂_Relations,
+ BoundedFormula.mapTermRelEquiv_symm_apply, mem_setOf_eq]
+ refine BoundedFormula.realize_mapTermRel_id ?_ (fun _ _ _ => rfl)
+ intros
+ simp only [Term.constantsVarsEquivLeft_symm_apply, Term.realize_varsToConstants,
+ coe_con, Term.realize_relabel]
+ congr
+ ext a
+ rcases a with (_ | _) | _ <;> rfl
+
theorem empty_definable_iff :
(∅ : Set M).Definable L s ↔ ∃ φ : L.Formula α, s = setOf φ.Realize := by
rw [Definable, Equiv.exists_congr_left (LEquiv.addEmptyConstants L (∅ : Set M)).onFormula]
Type _
and Sort _
(#6499)
We remove all possible occurences of Type _
and Sort _
in favor of Type*
and Sort*
.
This has nice performance benefits.
@@ -38,7 +38,7 @@ variable {M : Type w} (A : Set M) (L : FirstOrder.Language.{u, v}) [L.Structure
open FirstOrder FirstOrder.Language FirstOrder.Language.Structure
-variable {α : Type u₁} {β : Type _}
+variable {α : Type u₁} {β : Type*}
/-- A subset of a finite Cartesian product of a structure is definable over a set `A` when
membership in the set is given by a first-order formula with parameters from `A`. -/
@@ -106,7 +106,7 @@ theorem Definable.union {f g : Set (α → M)} (hf : A.Definable L f) (hg : A.De
rw [hφ, hθ, mem_setOf_eq, Formula.realize_sup, mem_union, mem_setOf_eq, mem_setOf_eq]
#align set.definable.union Set.Definable.union
-theorem definable_finset_inf {ι : Type _} {f : ∀ _ : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
+theorem definable_finset_inf {ι : Type*} {f : ∀ _ : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
(s : Finset ι) : A.Definable L (s.inf f) := by
classical
refine' Finset.induction definable_univ (fun i s _ h => _) s
@@ -114,7 +114,7 @@ theorem definable_finset_inf {ι : Type _} {f : ∀ _ : ι, Set (α → M)} (hf
exact (hf i).inter h
#align set.definable_finset_inf Set.definable_finset_inf
-theorem definable_finset_sup {ι : Type _} {f : ∀ _ : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
+theorem definable_finset_sup {ι : Type*} {f : ∀ _ : ι, Set (α → M)} (hf : ∀ i, A.Definable L (f i))
(s : Finset ι) : A.Definable L (s.sup f) := by
classical
refine' Finset.induction definable_empty (fun i s _ h => _) s
@@ -122,13 +122,13 @@ theorem definable_finset_sup {ι : Type _} {f : ∀ _ : ι, Set (α → M)} (hf
exact (hf i).union h
#align set.definable_finset_sup Set.definable_finset_sup
-theorem definable_finset_biInter {ι : Type _} {f : ∀ _ : ι, Set (α → M)}
+theorem definable_finset_biInter {ι : Type*} {f : ∀ _ : ι, Set (α → M)}
(hf : ∀ i, A.Definable L (f i)) (s : Finset ι) : A.Definable L (⋂ i ∈ s, f i) := by
rw [← Finset.inf_set_eq_iInter]
exact definable_finset_inf hf s
#align set.definable_finset_bInter Set.definable_finset_biInter
-theorem definable_finset_biUnion {ι : Type _} {f : ∀ _ : ι, Set (α → M)}
+theorem definable_finset_biUnion {ι : Type*} {f : ∀ _ : ι, Set (α → M)}
(hf : ∀ i, A.Definable L (f i)) (s : Finset ι) : A.Definable L (⋃ i ∈ s, f i) := by
rw [← Finset.sup_set_eq_biUnion]
exact definable_finset_sup hf s
@@ -2,15 +2,12 @@
Copyright (c) 2021 Aaron Anderson. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Aaron Anderson
-
-! This file was ported from Lean 3 source module model_theory.definability
-! leanprover-community/mathlib commit 70fd9563a21e7b963887c9360bd29b2393e6225a
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
-/
import Mathlib.Data.SetLike.Basic
import Mathlib.ModelTheory.Semantics
+#align_import model_theory.definability from "leanprover-community/mathlib"@"70fd9563a21e7b963887c9360bd29b2393e6225a"
+
/-!
# Definable Sets
This file defines what it means for a set over a first-order structure to be definable.
@@ -178,7 +178,7 @@ theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) →
refine' ⟨(BoundedFormula.relabel id φ).exs, _⟩
ext x
simp only [Set.mem_image, mem_setOf_eq, BoundedFormula.realize_exs,
- BoundedFormula.realize_relabel, Function.comp.right_id, Fin.castAdd_zero, Fin.cast_refl]
+ BoundedFormula.realize_relabel, Function.comp.right_id, Fin.castAdd_zero, Fin.castIso_refl]
constructor
· rintro ⟨y, hy, rfl⟩
exact
@@ -138,7 +138,7 @@ theorem definable_finset_biUnion {ι : Type _} {f : ∀ _ : ι, Set (α → M)}
#align set.definable_finset_bUnion Set.definable_finset_biUnion
@[simp]
-theorem Definable.compl {s : Set (α → M)} (hf : A.Definable L s) : A.Definable L (sᶜ) := by
+theorem Definable.compl {s : Set (α → M)} (hf : A.Definable L s) : A.Definable L sᶜ := by
rcases hf with ⟨φ, hφ⟩
refine' ⟨φ.not, _⟩
ext v
@@ -196,7 +196,7 @@ theorem Definable.image_comp_embedding {s : Set (β → M)} (h : A.Definable L s
(congr rfl (ext fun x => _)).mp
(((h.image_comp_equiv (Equiv.Set.sumCompl (range f))).image_comp_equiv
(Equiv.sumCongr (Equiv.ofInjective f f.injective)
- (Fintype.equivFin (↥((range f)ᶜ))).symm)).image_comp_sum_inl_fin
+ (Fintype.equivFin (↥(range f)ᶜ)).symm)).image_comp_sum_inl_fin
_)
simp only [mem_preimage, mem_image, exists_exists_and_eq_and]
refine' exists_congr fun y => and_congr_right fun _ => Eq.congr_left (funext fun a => _)
compile_inductive%
and compile_def%
commands (#4097)
Add a #compile inductive
command to compile the recursors of an inductive type, which works by creating a recursive definition and using @[csimp]
.
Co-authored-by: Parth Shastri <31370288+cppio@users.noreply.github.com> Co-authored-by: Mario Carneiro <di.gama@gmail.com>
@@ -285,23 +285,19 @@ instance instBot : Bot (L.DefinableSet A α) :=
⟨⟨⊥, definable_empty⟩⟩
#align first_order.language.definable_set.has_bot FirstOrder.Language.DefinableSet.instBot
--- Porting note: added `noncomputable`
-noncomputable instance instSup : Sup (L.DefinableSet A α) :=
+instance instSup : Sup (L.DefinableSet A α) :=
⟨fun s t => ⟨s ∪ t, s.2.union t.2⟩⟩
#align first_order.language.definable_set.has_sup FirstOrder.Language.DefinableSet.instSup
--- Porting note: added `noncomputable`
-noncomputable instance instInf : Inf (L.DefinableSet A α) :=
+instance instInf : Inf (L.DefinableSet A α) :=
⟨fun s t => ⟨s ∩ t, s.2.inter t.2⟩⟩
#align first_order.language.definable_set.has_inf FirstOrder.Language.DefinableSet.instInf
--- Porting note: added `noncomputable`
-noncomputable instance instHasCompl : HasCompl (L.DefinableSet A α) :=
+instance instHasCompl : HasCompl (L.DefinableSet A α) :=
⟨fun s => ⟨sᶜ, s.2.compl⟩⟩
#align first_order.language.definable_set.has_compl FirstOrder.Language.DefinableSet.instHasCompl
--- Porting note: added `noncomputable`
-noncomputable instance instSDiff : SDiff (L.DefinableSet A α) :=
+instance instSDiff : SDiff (L.DefinableSet A α) :=
⟨fun s t => ⟨s \ t, s.2.sdiff t.2⟩⟩
#align first_order.language.definable_set.has_sdiff FirstOrder.Language.DefinableSet.instSDiff
@@ -377,8 +373,7 @@ theorem coe_sdiff (s t : L.DefinableSet A α) :
rfl
#align first_order.language.definable_set.coe_sdiff FirstOrder.Language.DefinableSet.coe_sdiff
--- Porting note: added `noncomputable`
-noncomputable instance instBooleanAlgebra : BooleanAlgebra (L.DefinableSet A α) :=
+instance instBooleanAlgebra : BooleanAlgebra (L.DefinableSet A α) :=
Function.Injective.booleanAlgebra (α := L.DefinableSet A α) _ Subtype.coe_injective
coe_sup coe_inf coe_top coe_bot coe_compl coe_sdiff
#align first_order.language.definable_set.boolean_algebra FirstOrder.Language.DefinableSet.instBooleanAlgebra
@@ -39,9 +39,7 @@ namespace Set
variable {M : Type w} (A : Set M) (L : FirstOrder.Language.{u, v}) [L.Structure M]
-open FirstOrder
-
-open FirstOrder.Language FirstOrder.Language.Structure
+open FirstOrder FirstOrder.Language FirstOrder.Language.Structure
variable {α : Type u₁} {β : Type _}
@@ -143,8 +141,8 @@ theorem definable_finset_biUnion {ι : Type _} {f : ∀ _ : ι, Set (α → M)}
theorem Definable.compl {s : Set (α → M)} (hf : A.Definable L s) : A.Definable L (sᶜ) := by
rcases hf with ⟨φ, hφ⟩
refine' ⟨φ.not, _⟩
- rw [hφ]
- rfl
+ ext v
+ rw [hφ, compl_setOf, mem_setOf, mem_setOf, Formula.realize_not]
#align set.definable.compl Set.Definable.compl
@[simp]
@@ -173,7 +171,7 @@ theorem Definable.image_comp_equiv {s : Set (β → M)} (h : A.Definable L s) (f
simp
#align set.definable.image_comp_equiv Set.Definable.image_comp_equiv
-/-- This lemma is only intended as a helper for `definable.image_comp. -/
+/-- This lemma is only intended as a helper for `Definable.image_comp`. -/
theorem Definable.image_comp_sum_inl_fin (m : ℕ) {s : Set (Sum α (Fin m) → M)}
(h : A.Definable L s) : A.Definable L ((fun g : Sum α (Fin m) → M => g ∘ Sum.inl) '' s) := by
obtain ⟨φ, rfl⟩ := h
sSup
/iSup
(#3938)
As discussed on Zulip
supₛ
→ sSup
infₛ
→ sInf
supᵢ
→ iSup
infᵢ
→ iInf
bsupₛ
→ bsSup
binfₛ
→ bsInf
bsupᵢ
→ biSup
binfᵢ
→ biInf
csupₛ
→ csSup
cinfₛ
→ csInf
csupᵢ
→ ciSup
cinfᵢ
→ ciInf
unionₛ
→ sUnion
interₛ
→ sInter
unionᵢ
→ iUnion
interᵢ
→ iInter
bunionₛ
→ bsUnion
binterₛ
→ bsInter
bunionᵢ
→ biUnion
binterᵢ
→ biInter
Co-authored-by: Parcly Taxel <reddeloostw@gmail.com>
@@ -127,17 +127,17 @@ theorem definable_finset_sup {ι : Type _} {f : ∀ _ : ι, Set (α → M)} (hf
exact (hf i).union h
#align set.definable_finset_sup Set.definable_finset_sup
-theorem definable_finset_binterᵢ {ι : Type _} {f : ∀ _ : ι, Set (α → M)}
+theorem definable_finset_biInter {ι : Type _} {f : ∀ _ : ι, Set (α → M)}
(hf : ∀ i, A.Definable L (f i)) (s : Finset ι) : A.Definable L (⋂ i ∈ s, f i) := by
- rw [← Finset.inf_set_eq_interᵢ]
+ rw [← Finset.inf_set_eq_iInter]
exact definable_finset_inf hf s
-#align set.definable_finset_bInter Set.definable_finset_binterᵢ
+#align set.definable_finset_bInter Set.definable_finset_biInter
-theorem definable_finset_bunionᵢ {ι : Type _} {f : ∀ _ : ι, Set (α → M)}
+theorem definable_finset_biUnion {ι : Type _} {f : ∀ _ : ι, Set (α → M)}
(hf : ∀ i, A.Definable L (f i)) (s : Finset ι) : A.Definable L (⋃ i ∈ s, f i) := by
- rw [← Finset.sup_set_eq_bunionᵢ]
+ rw [← Finset.sup_set_eq_biUnion]
exact definable_finset_sup hf s
-#align set.definable_finset_bUnion Set.definable_finset_bunionᵢ
+#align set.definable_finset_bUnion Set.definable_finset_biUnion
@[simp]
theorem Definable.compl {s : Set (α → M)} (hf : A.Definable L s) : A.Definable L (sᶜ) := by
@@ -223,7 +223,7 @@ theorem Definable.image_comp {s : Set (β → M)} (h : A.Definable L s) (f : α
A.Definable L { x : α → M | x a = x (rangeSplitting f (rangeFactorization f a)) } := by
refine' fun a => ⟨(var a).equal (var (rangeSplitting f (rangeFactorization f a))), ext _⟩
simp
- refine' (congr rfl (ext _)).mp (definable_finset_binterᵢ h' Finset.univ)
+ refine' (congr rfl (ext _)).mp (definable_finset_biInter h' Finset.univ)
simp
refine' (congr rfl (ext fun x => _)).mp (h.inter h')
simp only [Equiv.coe_trans, mem_inter_iff, mem_preimage, mem_image, exists_exists_and_eq_and,
The unported dependencies are