Skip to content

[Merged by Bors] - feat(Geometry/Euclidean/Sphere): add lemmas about points on a sphere#41143

Closed
Scarlett-le wants to merge 2 commits into
leanprover-community:masterfrom
Scarlett-le:sphere-ne-center
Closed

[Merged by Bors] - feat(Geometry/Euclidean/Sphere): add lemmas about points on a sphere#41143
Scarlett-le wants to merge 2 commits into
leanprover-community:masterfrom
Scarlett-le:sphere-ne-center

Conversation

@Scarlett-le

Copy link
Copy Markdown
Contributor

Adds three lemmas to Mathlib/Geometry/Euclidean/Sphere/Basic.lean.

No mathematical content changes; the existing proofs are only shortened.

@github-actions

github-actions Bot commented Jun 29, 2026

Copy link
Copy Markdown

PR summary e50a6ccb22

Import changes for modified files

No significant changes to the import graph

Import changes for all files
Files Import difference

Declarations diff (regex)

+ Sphere.ne_center_of_mem_of_mem_of_ne
+ center_mem_affineSpan_pair_iff_isDiameter
+ norm_vsub_center_eq_radius

You can run this locally as follows
## from your `mathlib4` directory:
git clone https://github.com/leanprover-community/mathlib-ci.git ../mathlib-ci

## summary with just the declaration names:
../mathlib-ci/scripts/pr_summary/declarations_diff.sh <optional_commit>

## more verbose report:
../mathlib-ci/scripts/pr_summary/declarations_diff.sh long <optional_commit>

The doc-module for scripts/pr_summary/declarations_diff.sh in the mathlib-ci repository contains some details about this script.

Declarations diff (Lean)

Lean-aware diff — post-build, computed from the Lean environment (commit e50a6cc).

  • +3 new declarations
  • −0 removed declarations
+EuclideanGeometry.Sphere.center_mem_affineSpan_pair_iff_isDiameter
+EuclideanGeometry.Sphere.ne_center_of_mem_of_mem_of_ne
+EuclideanGeometry.norm_vsub_center_eq_radius

No changes to strong technical debt.

No changes to weak technical debt.

Current commit e50a6ccb22
Reference commit b2b4255167

This script lives in the mathlib-ci repository. To run it locally, from your mathlib4 directory:

git clone https://github.com/leanprover-community/mathlib-ci.git ../mathlib-ci
../mathlib-ci/scripts/reporting/technical-debt-metrics.sh pr_summary
  • The relative value is the weighted sum of the differences with weight given by the inverse of the current value of the statistic.
  • The absolute value is the relative value divided by the total sum of the inverses of the current values (i.e. the weighted average of the differences).

@jsm28

jsm28 commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

maintainer merge

@github-actions

Copy link
Copy Markdown

🚀 Pull request has been placed on the maintainer queue by jsm28.

@mathlib-triage mathlib-triage Bot added the maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. label Jun 29, 2026

@j-loreaux j-loreaux left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

Comment thread Mathlib/Geometry/Euclidean/Sphere/Basic.lean Outdated
@j-loreaux j-loreaux added the auto-merge-after-CI Please do not add manually. Requests for a bot to merge automatically once CI is done. label Jul 1, 2026
@mathlib-auto-merge

Copy link
Copy Markdown

As this PR is labelled auto-merge-after-CI, we are now sending it to bors:

bors merge

@mathlib-bors mathlib-bors Bot added the ready-to-merge This PR has been sent to bors. label Jul 1, 2026
mathlib-bors Bot pushed a commit that referenced this pull request Jul 1, 2026
…41143)

Adds three lemmas to `Mathlib/Geometry/Euclidean/Sphere/Basic.lean`.

- `Sphere.ne_center_of_mem_of_mem_of_ne`: a point of a sphere that differs
  from another point of the sphere is not its center. Extracted at a
  reviewer's suggestion; this fact was reproved inline four times across
  #41121 and #41123.

- `norm_vsub_center_eq_radius`: for a point `p` on a sphere `s`,
  `‖p -ᵥ s.center‖ = s.radius`. This pattern occurs ten times in #34164 and
  four more times in the present file (twice in `inner_vsub_center_vsub_pos`
  and twice in `Sphere.dist_center_lt_radius_of_sbtw`); those four in-file
  occurrences are golfed to use it here.

- `Sphere.center_mem_affineSpan_pair_iff_isDiameter`: for two distinct points
  of a sphere, the center lies on the line through them if and only if those
  points are the endpoints of a diameter.

No mathematical content changes; the existing proofs are only shortened.

Co-authored-by: Scarlett-le <735979178@qq.com>
Co-authored-by: Jireh Loreaux <loreaujy@gmail.com>
@mathlib-bors mathlib-bors Bot added the bors-staging This PR is currently being built by bors on the staging branch. label Jul 1, 2026
@mathlib-bors

mathlib-bors Bot commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

@mathlib-bors mathlib-bors Bot changed the title feat(Geometry/Euclidean/Sphere): add lemmas about points on a sphere [Merged by Bors] - feat(Geometry/Euclidean/Sphere): add lemmas about points on a sphere Jul 1, 2026
@mathlib-bors mathlib-bors Bot closed this Jul 1, 2026
joelriou pushed a commit to joelriou/mathlib4 that referenced this pull request Jul 4, 2026
…eanprover-community#41143)

Adds three lemmas to `Mathlib/Geometry/Euclidean/Sphere/Basic.lean`.

- `Sphere.ne_center_of_mem_of_mem_of_ne`: a point of a sphere that differs
  from another point of the sphere is not its center. Extracted at a
  reviewer's suggestion; this fact was reproved inline four times across
  leanprover-community#41121 and leanprover-community#41123.

- `norm_vsub_center_eq_radius`: for a point `p` on a sphere `s`,
  `‖p -ᵥ s.center‖ = s.radius`. This pattern occurs ten times in leanprover-community#34164 and
  four more times in the present file (twice in `inner_vsub_center_vsub_pos`
  and twice in `Sphere.dist_center_lt_radius_of_sbtw`); those four in-file
  occurrences are golfed to use it here.

- `Sphere.center_mem_affineSpan_pair_iff_isDiameter`: for two distinct points
  of a sphere, the center lies on the line through them if and only if those
  points are the endpoints of a diameter.

No mathematical content changes; the existing proofs are only shortened.

Co-authored-by: Scarlett-le <735979178@qq.com>
Co-authored-by: Jireh Loreaux <loreaujy@gmail.com>
michaellee94 pushed a commit to michaellee94/mathlib4 that referenced this pull request Jul 11, 2026
…eanprover-community#41143)

Adds three lemmas to `Mathlib/Geometry/Euclidean/Sphere/Basic.lean`.

- `Sphere.ne_center_of_mem_of_mem_of_ne`: a point of a sphere that differs
  from another point of the sphere is not its center. Extracted at a
  reviewer's suggestion; this fact was reproved inline four times across
  leanprover-community#41121 and leanprover-community#41123.

- `norm_vsub_center_eq_radius`: for a point `p` on a sphere `s`,
  `‖p -ᵥ s.center‖ = s.radius`. This pattern occurs ten times in leanprover-community#34164 and
  four more times in the present file (twice in `inner_vsub_center_vsub_pos`
  and twice in `Sphere.dist_center_lt_radius_of_sbtw`); those four in-file
  occurrences are golfed to use it here.

- `Sphere.center_mem_affineSpan_pair_iff_isDiameter`: for two distinct points
  of a sphere, the center lies on the line through them if and only if those
  points are the endpoints of a diameter.

No mathematical content changes; the existing proofs are only shortened.

Co-authored-by: Scarlett-le <735979178@qq.com>
Co-authored-by: Jireh Loreaux <loreaujy@gmail.com>
mathlib-bors Bot pushed a commit that referenced this pull request Jul 20, 2026
…is (#41582)

This PR removes the `p₁ ≠ p₂` hypothesis from `Sphere.center_mem_affineSpan_pair_iff_isDiameter`: the iff also holds when the points coincide (both sides then say `p₁ = s.center`), and the neighbouring `isDiameter_iff_*` lemmas carry no distinctness hypotheses. The degenerate case is handled by a one-line `simp`.

Follow-up to [#41143 (feat(Geometry/Euclidean/Sphere): lemmas about points on a sphere)](#41143).

🤖 Prepared with Claude Code
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

auto-merge-after-CI Please do not add manually. Requests for a bot to merge automatically once CI is done. bors-staging This PR is currently being built by bors on the staging branch. maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. ready-to-merge This PR has been sent to bors. t-euclidean-geometry Affine and axiomatic geometry

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants