Zulip Chat Archive
Stream: mathlib4
Topic: Preferred spelling of Sup (e '' s)
Violeta Hernández (Oct 07 2024 at 22:10):
The lemma docs#OrderIso.map_sSup is spelled with ⨆ x : s, e x
, while docs#OrderIso.map_sSup' uses Sup (e '' s)
. What's the preferred form?
Violeta Hernández (Oct 07 2024 at 22:10):
I want to prove some lemmas that are analogous to this but I don't want to be adding any new primed lemmas.
Eric Wieser (Oct 07 2024 at 22:19):
@Kevin Buzzard and I were discussing this recently; my vote was that you should keep sSup on the RHS if it was present on the LHS, but I think @Yury G. Kudryashov argues we should always use iSup on the RHS if we can
Violeta Hernández (Oct 07 2024 at 22:21):
My own two cents is that I find it very awkward to write ⨆ x : s
. I could understand ⨆ x ∈ s
but that's subject to the binder weirdness that's been previously discussed.
Yury G. Kudryashov (Oct 07 2024 at 22:23):
I agree that we should use sSup (e '' s)
for conditionally complete lattices. I would use ⨆ x ∈ s, e x
for complete lattices.
Yury G. Kudryashov (Oct 07 2024 at 22:24):
(or disable this notation)
Eric Wieser (Oct 07 2024 at 22:25):
Would you also argue for using ⨆ x ∈ s, x
in complete lattices instead of sSup s
?
Yury G. Kudryashov (Oct 07 2024 at 22:26):
No.
Eric Wieser (Oct 07 2024 at 22:29):
Ah, that's unfortunate. I was hoping we could declare it the simp-normal form there, and then we could have our lemmas as:
sSup s = ⨆ x ∈ s, x
as a simp lemmaf (⨆ i, x i) = ⨆ i, f (x i)
for people working with the simp-normal formf (sSup s) = sSup (f '' s)
for people who know that in their applicationsSup
really is easier- No
f (sSup s) = ⨆ i, f (x i)
lemmas at all, if you want these you have to go through lemma 1
Yury G. Kudryashov (Oct 07 2024 at 22:31):
More precisely: I'm equally happy with sSup s
and ⨆ x ∈ s, x
. It would be nice not to have simp
normal form so much dependent on α
being a conditionally complete lattice or a complete lattice.
Yury G. Kudryashov (Oct 07 2024 at 22:31):
(I have no proposals)
Eric Wieser (Oct 07 2024 at 22:32):
Would you be opposed to a refactor doing 2, 3, and 4, but leaving 1 as not simp to avoid that simp-normal form weirdness?
Eric Wieser (Oct 07 2024 at 22:33):
That is, to switch between sSup and iSup you have to ask explicitly, and otherwise all the lemmas only exist in one world or the other.
Violeta Hernández (Oct 07 2024 at 22:34):
I like the idea of keeping sSup
and iSup
separate
Violeta Hernández (Oct 07 2024 at 22:34):
That way we don't have to write our lemmas in every single combination of sSup
and iSup
Violeta Hernández (Oct 07 2024 at 22:36):
I do think ⨆ x ∈ s, x
is a very silly spelling. If we're going to be using this, why have sSup
at all?
Yury G. Kudryashov (Oct 07 2024 at 22:58):
I wouldn't oppose such a refactor.
Violeta Hernández (Oct 08 2024 at 00:33):
Well, for the moment being, I would like some sort of consensus on how to write these map_xSup
lemmas.
Violeta Hernández (Oct 08 2024 at 00:33):
Should I apply the 2, 3, 4 refactor to at least this subset of results?
Last updated: May 02 2025 at 03:31 UTC