Zulip Chat Archive
Stream: Is there code for X?
Topic: (Free/Semifree) Multiplication on sigma types.
Wrenna Robson (Nov 20 2024 at 12:10):
Here's a notion.
Suppose I have β : ℕ → Type u
such that I have an instance HMul (β n) (β n) (β (n + 1))
for all n. Consider Sigma β
. I could define a free semigroup on this with FreeSemiGroup (Sigma β)
. Is it possible to define "the free semigroup on Sigma β
, respecting the HMul
on the β n
" - i.e. if I have (n, a) and (n, b) in Sigma β
, then in this "semi-free semigroup" their product will be (n + 1, a*b), but if I also have (m, c)
, then (n, a)*(m, c)*(n, b)
won't interact unless m = n
.
Wrenna Robson (Nov 20 2024 at 12:10):
This feels like a reasonably natural definition but if it exists I can't find it - is there a better way to do things like this?
Wrenna Robson (Nov 20 2024 at 12:13):
Effectively I want to lift the set of hetrogenous multiplications on the β n
into one (associative) multiplication on Sigma β
.
Eric Wieser (Nov 20 2024 at 12:29):
What do you mean by "won't interact"?
Wrenna Robson (Nov 20 2024 at 12:30):
As in a free multiplication, (n, a)*(m, c)*(n, b)
simply "has no meaning" outside of what it is.
Wrenna Robson (Nov 20 2024 at 12:30):
It "doesn't cancel down" (I appreciate this language is imprecise).
Eric Wieser (Nov 20 2024 at 12:32):
Ah, but crucially you also mean "still type-checks"!
Wrenna Robson (Nov 20 2024 at 12:32):
Ah, yes, sorry - indeed!
Wrenna Robson (Nov 20 2024 at 12:33):
It's still a member of the type.
Wrenna Robson (Nov 20 2024 at 12:33):
Member? Do we say member for type? It typechecks, yes.
Wrenna Robson (Nov 20 2024 at 12:34):
I suppose ultimately this is a quotient by a suitable relation.
Wrenna Robson (Nov 20 2024 at 12:34):
Or something of that kind. I want (n, a)*(n, b) ~ (n + 1, a*b)
and suchlike.
Eric Wieser (Nov 20 2024 at 12:47):
docs#Monoid.CoprodI looks somewhat related, though obviously doesn't use HMul
Wrenna Robson (Nov 20 2024 at 12:48):
No, nothing really seems to use HMul.
Wrenna Robson (Nov 20 2024 at 13:53):
Not sure about the transitivity of this relation.
Last updated: May 02 2025 at 03:31 UTC