Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
George Pirlea
Iris
Commits
1e519f29
Commit
1e519f29
authored
Mar 01, 2017
by
Ralf Jung
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
prove dist_later_dist; define constant chain
parent
711bead3
Changes
1
Hide whitespace changes
Inline
Sidebyside
Showing
1 changed file
with
20 additions
and
1 deletion
+20
1
theories/algebra/ofe.v
theories/algebra/ofe.v
+20
1
No files found.
theories/algebra/ofe.v
View file @
1e519f29
...
...
@@ 130,6 +130,14 @@ Lemma compl_chain_map `{Cofe A, Cofe B} (f : A → B) c `(NonExpansive f) :
compl
(
chain_map
f
c
)
≡
f
(
compl
c
).
Proof
.
apply
equiv_dist
=>
n
.
by
rewrite
!
conv_compl
.
Qed
.
Program
Definition
chain_const
{
A
:
ofeT
}
(
a
:
A
)
:
chain
A
:
=
{
chain_car
n
:
=
a
}.
Next
Obligation
.
by
intros
A
a
n
i
_
.
Qed
.
Lemma
compl_chain_const
{
A
:
ofeT
}
`
{!
Cofe
A
}
(
a
:
A
)
:
compl
(
chain_const
a
)
≡
a
.
Proof
.
apply
equiv_dist
=>
n
.
by
rewrite
conv_compl
.
Qed
.
(** General properties *)
Section
ofe
.
Context
{
A
:
ofeT
}.
...
...
@@ 192,6 +200,17 @@ Proof. destruct n as [n]. by split. apply dist_equivalence. Qed.
Lemma
dist_dist_later
{
A
:
ofeT
}
n
(
x
y
:
A
)
:
dist
n
x
y
→
dist_later
n
x
y
.
Proof
.
intros
Heq
.
destruct
n
;
first
done
.
exact
:
dist_S
.
Qed
.
Lemma
dist_later_dist
{
A
:
ofeT
}
n
(
x
y
:
A
)
:
dist_later
(
S
n
)
x
y
→
dist
n
x
y
.
Proof
.
done
.
Qed
.
(* We don't actually need this lemma (as our tactics deal with this through
other means), but technically speaking, this is the reason why
precomposing a nonexpansive function to a contractive function
preserves contractivity. *)
Lemma
ne_dist_later
{
A
B
:
ofeT
}
(
f
:
A
→
B
)
:
NonExpansive
f
→
∀
n
,
Proper
(
dist_later
n
==>
dist_later
n
)
f
.
Proof
.
intros
Hf
[
n
]
;
last
exact
:
Hf
.
hnf
.
by
intros
.
Qed
.
Notation
Contractive
f
:
=
(
∀
n
,
Proper
(
dist_later
n
==>
dist
n
)
f
).
Instance
const_contractive
{
A
B
:
ofeT
}
(
x
:
A
)
:
Contractive
(@
const
A
B
x
).
...
...
@@ 221,7 +240,7 @@ Ltac f_contractive :=
end
;
try
match
goal
with


@
dist_later
?A
?n
?x
?y
=>
destruct
n
as
[
n
]
;
[
done

change
(@
dist
A
_
n
x
y
)]
destruct
n
as
[
n
]
;
[
exact
I

change
(@
dist
A
_
n
x
y
)]
end
;
try
reflexivity
.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment