Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
R
rtproofs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Felipe Cerqueira
rtproofs
Commits
5d02df7f
Commit
5d02df7f
authored
Aug 22, 2016
by
Felipe Cerqueira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add lemmas about iter_fixpoint
parent
d3d75a3b
Changes
1
Hide whitespace changes
Inline
Sidebyside
Showing
1 changed file
with
44 additions
and
2 deletions
+44
2
util/fixedpoint.v
util/fixedpoint.v
+44
2
No files found.
util/fixedpoint.v
View file @
5d02df7f
...
...
@@ 72,6 +72,19 @@ Section FixedPoint.
End
FixedPoint
.
(
*
In
this
section
,
we
define
some
properties
of
relations
that
are
important
for
fixed

point
iterations
.
*
)
Section
Relations
.
Context
{
T
:
Type
}
.
Variable
R
:
rel
T
.
Variable
f
:
T
>
T
.
Definition
monotone
(
R
:
rel
T
)
:=
forall
x
y
,
R
x
y
>
R
(
f
x
)
(
f
y
).
End
Relations
.
(
*
In
this
section
we
define
a
fixed

point
iteration
function
that
stops
as
soon
as
it
finds
the
solution
.
If
no
solution
is
found
,
the
function
returns
None
.
*
)
...
...
@@ 88,7 +101,7 @@ Section Iteration.
else
iter_fixpoint
step
x
'
else
None
.
Section
Lemmas
.
Section
Basic
Lemmas
.
(
*
We
prove
that
iter_fixpoint
either
returns
either
None
or
Some
y
,
where
y
is
a
fixed
point
.
*
)
...
...
@@ 111,6 +124,35 @@ Section Iteration.
}
Qed
.
End
Lemmas
.
End
BasicLemmas
.
Section
RelationLemmas
.
Variable
R
:
rel
T
.
Hypothesis
H_reflexive
:
reflexive
R
.
Hypothesis
H_transitive
:
transitive
R
.
Hypothesis
H_monotone
:
monotone
f
R
.
Lemma
iter_fixpoint_ge_min
:
forall
max_steps
x0
x
,
iter_fixpoint
max_steps
x0
=
Some
x
>
R
x0
(
f
x0
)
>
R
x0
x
.
Proof
.
induction
max_steps
.
{
intros
x0
x
SOME
MIN
;
first
by
done
.
}
{
intros
x0
x
SOME
MIN
;
simpl
in
SOME
.
destruct
(
x0
==
f
x0
)
eqn
:
EQ1
;
first
by
inversion
SOME
;
apply
H_reflexive
.
apply
IHmax_steps
in
SOME
;
first
by
apply
H_transitive
with
(
y
:=
f
x0
).
by
apply
H_monotone
.
}
Qed
.
End
RelationLemmas
.
End
Iteration
.
\ No newline at end of file
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