Zulip Chat Archive

Stream: mathlib4

Topic: Metric.isClosed_ball later than Defs file


Yakov Pechersky (Jul 15 2024 at 15:42):

docs#Metric.isClosed_ball (and also about a sphere) is proven using a more conceptual proof, but in Mathlib.Topology.MetricSpace.Pseudo.Lemmas, not in Mathlib.Topology.MetricSpace.Pseudo.Defs. Is that desired, or would it make sense to use a more primitive proof in Defs?

Yury G. Kudryashov (Jul 15 2024 at 17:20):

Do we have reasons to have this lemma available earlier in the import graph?

Yury G. Kudryashov (Jul 15 2024 at 17:21):

IMHO, Defs files are for definitions and basic theorems unfolding these definitions.

Yakov Pechersky (Jul 15 2024 at 21:28):

The openness of a open ball is in Defs, and I thought we try to prove what we can at the site-of-declaration. Not a big issue to import Lemmas over Defs. Lemmas ends up pulling in more files about Order.IsLUB, DenselyOrdered, some bornology constructions, and things about intervals.

Yaël Dillies (Jul 15 2024 at 21:34):

I was the one splitting the file this way and many lemmas ended up in Lemmas solely because they depend on isClosed_ball

Yury G. Kudryashov (Jul 16 2024 at 02:10):

If we're worried about imports, then we can split Lemmas into smaller files (and move more from Defs - as I wrote above, I think that these files are for definitions only).

Yury G. Kudryashov (Jul 16 2024 at 02:10):

I don't think that we should use more complicated proofs for no reason.

Yury G. Kudryashov (Jul 16 2024 at 02:15):

E.g., I don't think that docs#Metric.totallyBounded_of_finite_discretization belongs in a Defs file.


Last updated: May 02 2025 at 03:31 UTC