Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
frama-c
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container Registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
pub
frama-c
Commits
1025f2f6
Commit
1025f2f6
authored
1 year ago
by
Allan Blanchard
Browse files
Options
Downloads
Patches
Plain Diff
[wp] no more axiom in Qed Why3 theory
parent
8363a1f3
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/plugins/wp/share/why3/frama_c_wp/qed.mlw
+8
-16
8 additions, 16 deletions
src/plugins/wp/share/why3/frama_c_wp/qed.mlw
with
8 additions
and
16 deletions
src/plugins/wp/share/why3/frama_c_wp/qed.mlw
+
8
−
16
View file @
1025f2f6
...
...
@@ -31,23 +31,14 @@ theory Qed
(** The definitions are in comment because its not useful for coq
(no if-then-else on formula) and not tested on automatic provers *)
function eqb (x y : 'a) : bool
(*
= if x = y then True else False
*)
axiom eqb : forall x:'a, y:'a. eqb x y = True <-> x = y
function eqb (x y : 'a) : bool = if x = y then True else False
function neqb (x y : 'a) : bool = if x <> y then True else False
function
neqb
(x y :
'a
) : bool
(*
= if x <
>
y then True else False
*)
axiom neqb : forall x:'a, y:'a. neqb x y = True <-> x <> y
function
zlt
(x y :
int
) : bool = if x < y
then True else False
function zleq (x y : int) : bool = if x <= y then True else False
function zlt (x y : int) : bool(* = if x < y then True else False*)
function zleq (x y : int) : bool(* = if x <= y then True else False*)
axiom zlt : forall x:int, y:int. zlt x y = True <-> x < y
axiom zleq : forall x:int, y:int. zleq x y = True <-> x <= y
function rlt (x y : real) : bool(* = if x <. y then True else False*)
function rleq (x y : real) : bool(* = if x <=. y then True else False*)
axiom rlt : forall x:real, y:real. rlt x y = True <-> x <. y
axiom rleq : forall x:real, y:real. rleq x y = True <-> x <=. y
function rlt (x y : real) : bool = if x <. y then True else False
function rleq (x y : real) : bool = if x <=. y then True else False
function real_of_int (x:int) : real = FromInt.from_int x
meta "inline:no" function real_of_int
...
...
@@ -68,5 +59,6 @@ theory Qed
forall a,b,n:int.
0 <= a -> 0 <= b -> 0 <= b-a < n ->
CD.mod a n = CD.mod b n -> a = b
by b - a = n * (CD.div (b - a) n) + CD.mod (b - a) n
so (CD.div b n) - (CD.div a n) = CD.div (b - a) n
end
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