@@ -6,6 +6,7 @@ Authors: Jovan Gerbscheid, Newell Jensen
66module
77
88public import Mathlib.Topology.MetricSpace.Congruence
9+ public import Mathlib.Topology.MetricSpace.Dilation
910public import Mathlib.Tactic.FinCases
1011
1112/-!
@@ -113,6 +114,53 @@ lemma index_equiv (f : ι' ≃ ι) (v₁ : ι → P₁) (v₂ : ι → P₂) :
113114 refine ⟨r, hr, fun i₁ i₂ => ?_⟩
114115 simpa [f.right_inv i₁, f.right_inv i₂] using h (f.symm i₁) (f.symm i₂)
115116
117+ /-! Similarity is preserved under dilations. -/
118+
119+ section Dilation
120+ variable {F}
121+
122+ lemma comp_left [FunLike F P₁ P₃] [DilationClass F P₁ P₃] (f : F) (h : v₁ ∼ v₂) :
123+ f ∘ v₁ ∼ v₂ :=
124+ .trans ⟨Dilation.ratio f, Dilation.ratio_ne_zero f, fun _ _ => Dilation.edist_eq f _ _⟩ h
125+
126+ lemma comp_right [FunLike F P₂ P₃] [DilationClass F P₂ P₃] (f : F) (h : v₁ ∼ v₂) : v₁ ∼ f ∘ v₂ :=
127+ .symm (h.symm.comp_left f)
128+
129+ @[simp]
130+ lemma comp_left_iff [FunLike F P₁ P₃] [DilationClass F P₁ P₃] (f : F) : f ∘ v₁ ∼ v₂ ↔ v₁ ∼ v₂ :=
131+ ⟨.trans <| .comp_right f (.refl _), .comp_left f⟩
132+
133+ @[simp]
134+ lemma comp_right_iff [FunLike F P₂ P₃] [DilationClass F P₂ P₃] (f : F) : v₁ ∼ f ∘ v₂ ↔ v₁ ∼ v₂ := by
135+ rw [similar_comm, comp_left_iff, similar_comm]
136+
137+ end Dilation
138+
139+ /-! Similarity is preserved under isometries.
140+
141+ While these are trivial consequences of the dilation results, they avoid ending up with a
142+ `toDilation` in the expression, and so are easier to apply to plain functions.
143+ If `Dilation` were a predicate like `Isometry` then these would not be needed.
144+ -/
145+
146+ section Isometry
147+
148+ lemma comp_isometry_left {f : P₁ → P₃} (hf : Isometry f) (h : v₁ ∼ v₂) : f ∘ v₁ ∼ v₂ :=
149+ comp_left hf.toDilation h
150+
151+ lemma comp_isometry_right {f : P₂ → P₃} (hf : Isometry f) (h : v₁ ∼ v₂) : v₁ ∼ f ∘ v₂ :=
152+ comp_right hf.toDilation h
153+
154+ @[simp]
155+ lemma comp_isometry_left_iff {f : P₁ → P₃} (hf : Isometry f) : f ∘ v₁ ∼ v₂ ↔ v₁ ∼ v₂ :=
156+ comp_left_iff hf.toDilation
157+
158+ @[simp]
159+ lemma comp_isometry_right_iff {f : P₂ → P₃} (hf : Isometry f) : v₁ ∼ f ∘ v₂ ↔ v₁ ∼ v₂ :=
160+ comp_right_iff hf.toDilation
161+
162+ end Isometry
163+
116164section Triangle
117165
118166variable {a b c : P₁} {a' b' c' : P₂}
0 commit comments