Processing math: 100%
Finite sum over a monoid
Function
context
⟨
⟨
M
,
∗
⟩
⟩
… monoid
let
e
… unit of
⟨
⟨
M
,
∗
⟩
⟩
definition
∑
n
:
∏
S
:
S
e
q
u
e
n
c
e
(
M
)
r
a
n
g
e
(
l
e
n
g
t
h
(
S
)
)
→
M
definition
∑
n
k
=
1
S
k
:=
{
e
i
f
n
=
0
(
∑
n
−
1
k
=
1
S
k
)
∗
S
n
e
l
s
e
Discussion
Here
∏
S
:
S
e
q
u
e
n
c
e
(
M
)
is a dependent function type former.
Context
Monoid
,
Sequence length
Requirements
Sequence length