Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
AVA
FloVer
Commits
23705abc
Commit
23705abc
authored
Feb 01, 2019
by
Joachim Bard
Browse files
adding inverse to smt_expr_eq
parent
e98bf643
Changes
1
Hide whitespace changes
Inline
Side-by-side
coq/SMTArith.v
View file @
23705abc
...
...
@@ -189,6 +189,7 @@ Fixpoint smt_expr_eq (e: SMTArith) (e': expr Q) : bool :=
|
Expressions
.
Const
_
r
'
,
ConstQ
r
=>
Qeq_bool
r
r
'
|
Var
_
x
'
,
VarQ
x
=>
beq_nat
x
x
'
|
Unop
Neg
e
'
,
UMinusQ
e
=>
smt_expr_eq
e
e
'
|
Unop
Inv
e
'
,
DivQ
(
ConstQ
(
1
#
1
))
e
=>
smt_expr_eq
e
e
'
|
Binop
Plus
e1
'
e2
'
,
PlusQ
e1
e2
=>
(
smt_expr_eq
e1
e1
'
)
&&
(
smt_expr_eq
e2
e2
'
)
|
Binop
Sub
e1
'
e2
'
,
MinusQ
e1
e2
=>
(
smt_expr_eq
e1
e1
'
)
&&
(
smt_expr_eq
e2
e2
'
)
|
Binop
Mult
e1
'
e2
'
,
TimesQ
e1
e2
=>
(
smt_expr_eq
e1
e1
'
)
&&
(
smt_expr_eq
e2
e2
'
)
...
...
@@ -214,11 +215,23 @@ Proof.
-
destruct
e
;
try
discriminate
.
intros
H
.
apply
Qeq_bool_eq
in
H
.
apply
Qeq_eqR
in
H
.
cbn
.
now
rewrite
H
.
-
destruct
e
,
u
;
try
discriminate
.
intros
Heq
H
.
inversion
H
;
subst
.
econstructor
;
eauto
.
destruct
m
;
try
discriminate
.
eapply
IHe
'
;
auto
.
+
intros
Heq
H
.
inversion
H
;
subst
.
econstructor
;
eauto
.
destruct
m
;
try
discriminate
.
eapply
IHe
'
;
auto
.
+
destruct
e1
;
try
discriminate
.
destruct
r
as
[
n
d
].
destruct
n
;
try
discriminate
.
destruct
p
;
try
discriminate
.
destruct
d
;
try
discriminate
.
cbn
.
intros
Heq
H
.
inversion
H
;
subst
.
destruct
m
;
try
discriminate
.
eapply
Binop_dist
'
;
eauto
.
cbn
.
rewrite
RMicromega
.
IQR_1
.
apply
RealSimps
.
inv_eq_1_div
.
-
intros
Heq
H
.
inversion
H
;
subst
.
assert
(
m1
=
REAL
)
by
(
eapply
toRTMap_eval_REAL
;
eauto
).
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment