Skip to content

Commit 5ab5c34

Browse files
committed
feat(Geometry/Euclidean/Projection): orthogonalProjection_orthogonalProjection_of_le (#30474)
Add a lemma that `orthogonalProjection s₁ (orthogonalProjection s₂ p) = orthogonalProjection s₁ p` for `s₁ ≤ s₂`. (A similar lemma for projection onto submodules rather than affine subspaces already exists.)
1 parent e6f0e55 commit 5ab5c34

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

Mathlib/Geometry/Euclidean/Projection.lean

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -333,6 +333,14 @@ theorem orthogonalProjection_vadd_smul_vsub_orthogonalProjection {s : AffineSubs
333333
orthogonalProjection_vadd_eq_self hp
334334
(Submodule.smul_mem _ _ (vsub_orthogonalProjection_mem_direction_orthogonal s _))
335335

336+
lemma orthogonalProjection_orthogonalProjection_of_le {s₁ s₂ : AffineSubspace ℝ P} [Nonempty s₁]
337+
[Nonempty s₂] [s₁.direction.HasOrthogonalProjection] [s₂.direction.HasOrthogonalProjection]
338+
(h : s₁ ≤ s₂) (p : P) :
339+
orthogonalProjection s₁ (orthogonalProjection s₂ p) = orthogonalProjection s₁ p := by
340+
rw [orthogonalProjection_eq_orthogonalProjection_iff_vsub_mem]
341+
exact SetLike.le_def.1 (Submodule.orthogonal_le (direction_le h))
342+
(orthogonalProjection_vsub_mem_direction_orthogonal _ _)
343+
336344
/-- The square of the distance from a point in `s` to `p₂` equals the
337345
sum of the squares of the distances of the two points to the
338346
`orthogonalProjection`. -/

0 commit comments

Comments
 (0)