Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
Iris
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Rice Wine
Iris
Commits
1097ab91
Commit
1097ab91
authored
8 years ago
by
Robbert Krebbers
Browse files
Options
Downloads
Patches
Plain Diff
Homomorphism properties for big ops on multisets.
parent
e5cd45f3
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
algebra/cmra_big_op.v
+38
-3
38 additions, 3 deletions
algebra/cmra_big_op.v
with
38 additions
and
3 deletions
algebra/cmra_big_op.v
+
38
−
3
View file @
1097ab91
...
...
@@ -455,14 +455,14 @@ Section gmultiset.
Lemma
big_opMS_delete
f
X
x
:
x
∈
X
→
([
⋅
mset
]
y
∈
X
,
f
y
)
≡
f
x
⋅
[
⋅
mset
]
y
∈
X
∖
{[
x
]},
f
y
.
Proof
.
intros
?
%
gmultiset_elem_of_subseteq
.
rewrite
-
big_opMS_singleton
.
by
rewrite
-
big_opMS_union
-
gmultiset_union_difference
.
intros
.
rewrite
-
big_opMS_singleton
-
big_opMS_union
.
by
rewrite
-
gmultiset_union_difference
'
.
Qed
.
Lemma
big_opMS_elem_of
f
X
x
:
x
∈
X
→
f
x
≼
[
⋅
mset
]
y
∈
X
,
f
y
.
Proof
.
intros
.
rewrite
big_opMS_delete
//.
apply
cmra_included_l
.
Qed
.
Lemma
big_opMS_opS
f
g
X
:
Lemma
big_opMS_op
M
S
f
g
X
:
([
⋅
mset
]
y
∈
X
,
f
y
⋅
g
y
)
≡
([
⋅
mset
]
y
∈
X
,
f
y
)
⋅
([
⋅
mset
]
y
∈
X
,
g
y
)
.
Proof
.
rewrite
/
big_opMS
.
...
...
@@ -497,6 +497,14 @@ Proof.
induction
X
as
[|
x
X
?
IH
]
using
collection_ind_L
;
[
done
|]
.
rewrite
-
equiv_None
big_opS_insert
//
equiv_None
op_None
IH
.
set_solver
.
Qed
.
Lemma
big_opMS_None
{
M
:
cmraT
}
`{
Countable
A
}
(
f
:
A
→
option
M
)
X
:
([
⋅
mset
]
x
∈
X
,
f
x
)
=
None
↔
∀
x
,
x
∈
X
→
f
x
=
None
.
Proof
.
induction
X
as
[|
x
X
IH
]
using
gmultiset_ind
.
{
rewrite
big_opMS_empty
.
set_solver
.
}
rewrite
-
equiv_None
big_opMS_union
big_opMS_singleton
equiv_None
op_None
IH
.
set_solver
.
Qed
.
(** Commuting with respect to homomorphisms *)
Lemma
big_opL_commute
{
M1
M2
:
ucmraT
}
{
A
}
(
h
:
M1
→
M2
)
...
...
@@ -552,6 +560,24 @@ Proof.
-
by
rewrite
!
big_opS_insert
//
cmra_homomorphism
-
IH
//.
Qed
.
Lemma
big_opMS_commute
{
M1
M2
:
ucmraT
}
`{
Countable
A
}
(
h
:
M1
→
M2
)
`{
!
UCMRAHomomorphism
h
}
(
f
:
A
→
M1
)
X
:
h
([
⋅
mset
]
x
∈
X
,
f
x
)
≡
([
⋅
mset
]
x
∈
X
,
h
(
f
x
))
.
Proof
.
intros
.
induction
X
as
[|
x
X
IH
]
using
gmultiset_ind
.
-
by
rewrite
!
big_opMS_empty
ucmra_homomorphism_unit
.
-
by
rewrite
!
big_opMS_union
!
big_opMS_singleton
cmra_homomorphism
-
IH
.
Qed
.
Lemma
big_opMS_commute1
{
M1
M2
:
ucmraT
}
`{
Countable
A
}
(
h
:
M1
→
M2
)
`{
!
CMRAHomomorphism
h
}
(
f
:
A
→
M1
)
X
:
X
≠
∅
→
h
([
⋅
mset
]
x
∈
X
,
f
x
)
≡
([
⋅
mset
]
x
∈
X
,
h
(
f
x
))
.
Proof
.
intros
.
induction
X
as
[|
x
X
IH
]
using
gmultiset_ind
;
[
done
|]
.
destruct
(
decide
(
X
=
∅
))
as
[
->
|]
.
-
by
rewrite
!
big_opMS_union
!
big_opMS_singleton
!
big_opMS_empty
!
right_id
.
-
by
rewrite
!
big_opMS_union
!
big_opMS_singleton
cmra_homomorphism
-
IH
//.
Qed
.
Lemma
big_opL_commute_L
{
M1
M2
:
ucmraT
}
`{
!
LeibnizEquiv
M2
}
{
A
}
(
h
:
M1
→
M2
)
`{
!
UCMRAHomomorphism
h
}
(
f
:
nat
→
A
→
M1
)
l
:
h
([
⋅
list
]
k
↦
x
∈
l
,
f
k
x
)
=
([
⋅
list
]
k
↦
x
∈
l
,
h
(
f
k
x
))
.
...
...
@@ -578,3 +604,12 @@ Lemma big_opS_commute1_L {M1 M2 : ucmraT} `{!LeibnizEquiv M2, Countable A}
(
h
:
M1
→
M2
)
`{
!
CMRAHomomorphism
h
}
(
f
:
A
→
M1
)
X
:
X
≠
∅
→
h
([
⋅
set
]
x
∈
X
,
f
x
)
=
([
⋅
set
]
x
∈
X
,
h
(
f
x
))
.
Proof
.
intros
.
rewrite
<-
leibniz_equiv_iff
.
by
apply
big_opS_commute1
.
Qed
.
Lemma
big_opMS_commute_L
{
M1
M2
:
ucmraT
}
`{
!
LeibnizEquiv
M2
,
Countable
A
}
(
h
:
M1
→
M2
)
`{
!
UCMRAHomomorphism
h
}
(
f
:
A
→
M1
)
X
:
h
([
⋅
mset
]
x
∈
X
,
f
x
)
=
([
⋅
mset
]
x
∈
X
,
h
(
f
x
))
.
Proof
.
unfold_leibniz
.
by
apply
big_opMS_commute
.
Qed
.
Lemma
big_opMS_commute1_L
{
M1
M2
:
ucmraT
}
`{
!
LeibnizEquiv
M2
,
Countable
A
}
(
h
:
M1
→
M2
)
`{
!
CMRAHomomorphism
h
}
(
f
:
A
→
M1
)
X
:
X
≠
∅
→
h
([
⋅
mset
]
x
∈
X
,
f
x
)
=
([
⋅
mset
]
x
∈
X
,
h
(
f
x
))
.
Proof
.
intros
.
rewrite
<-
leibniz_equiv_iff
.
by
apply
big_opMS_commute1
.
Qed
.
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment