src/HOL/Hyperreal/HyperArith.thy
author paulson
Mon, 12 Jan 2004 16:45:35 +0100
changeset 14352 a8b1a44d8264
parent 14329 ff3210fe968f
child 14369 c50188fe6366
permissions -rw-r--r--
Modified real arithmetic simplification
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
14352
a8b1a44d8264 Modified real arithmetic simplification
paulson
parents: 14329
diff changeset
     1
theory HyperArith = HyperBin
10751
a81ea5d3dd41 separation of HOL-Hyperreal from HOL-Real
paulson
parents:
diff changeset
     2
files "hypreal_arith.ML":
a81ea5d3dd41 separation of HOL-Hyperreal from HOL-Real
paulson
parents:
diff changeset
     3
a81ea5d3dd41 separation of HOL-Hyperreal from HOL-Real
paulson
parents:
diff changeset
     4
setup hypreal_arith_setup
a81ea5d3dd41 separation of HOL-Hyperreal from HOL-Real
paulson
parents:
diff changeset
     5
14329
ff3210fe968f re-organized some hyperreal and real lemmas
paulson
parents: 14309
diff changeset
     6
text{*Used once in NSA*}
ff3210fe968f re-organized some hyperreal and real lemmas
paulson
parents: 14309
diff changeset
     7
lemma hypreal_add_minus_eq_minus: "x + y = (0::hypreal) ==> x = -y"
ff3210fe968f re-organized some hyperreal and real lemmas
paulson
parents: 14309
diff changeset
     8
apply arith
ff3210fe968f re-organized some hyperreal and real lemmas
paulson
parents: 14309
diff changeset
     9
done
ff3210fe968f re-organized some hyperreal and real lemmas
paulson
parents: 14309
diff changeset
    10
ff3210fe968f re-organized some hyperreal and real lemmas
paulson
parents: 14309
diff changeset
    11
ML
ff3210fe968f re-organized some hyperreal and real lemmas
paulson
parents: 14309
diff changeset
    12
{*
ff3210fe968f re-organized some hyperreal and real lemmas
paulson
parents: 14309
diff changeset
    13
val hypreal_add_minus_eq_minus = thm "hypreal_add_minus_eq_minus";
ff3210fe968f re-organized some hyperreal and real lemmas
paulson
parents: 14309
diff changeset
    14
*}
ff3210fe968f re-organized some hyperreal and real lemmas
paulson
parents: 14309
diff changeset
    15
14309
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    16
subsubsection{*Division By @{term 1} and @{term "-1"}*}
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    17
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    18
lemma hypreal_divide_minus1 [simp]: "x/-1 = -(x::hypreal)"
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    19
by simp
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    20
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    21
lemma hypreal_minus1_divide [simp]: "-1/(x::hypreal) = - (1/x)"
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    22
by (simp add: hypreal_divide_def hypreal_minus_inverse)
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    23
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    24
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    25
(*
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    26
FIXME: we should have this, as for type int, but many proofs would break.
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    27
It replaces x+-y by x-y.
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    28
Addsimps [symmetric hypreal_diff_def]
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    29
*)
f508492af9b4 moving HyperArith0.ML to other theories
paulson
parents: 10751
diff changeset
    30
10751
a81ea5d3dd41 separation of HOL-Hyperreal from HOL-Real
paulson
parents:
diff changeset
    31
end