equal
deleted
inserted
replaced
106 |
106 |
107 (**** real_minus: additive inverse on real ****) |
107 (**** real_minus: additive inverse on real ****) |
108 |
108 |
109 Goalw [congruent_def] |
109 Goalw [congruent_def] |
110 "congruent realrel (%p. (%(x,y). realrel^^{(y,x)}) p)"; |
110 "congruent realrel (%p. (%(x,y). realrel^^{(y,x)}) p)"; |
111 by Safe_tac; |
111 by (Clarify_tac 1); |
112 by (asm_full_simp_tac (simpset() addsimps [preal_add_commute]) 1); |
112 by (asm_full_simp_tac (simpset() addsimps [preal_add_commute]) 1); |
113 qed "real_minus_congruent"; |
113 qed "real_minus_congruent"; |
114 |
114 |
115 Goalw [real_minus_def] |
115 Goalw [real_minus_def] |
116 "- (Abs_real(realrel^^{(x,y)})) = Abs_real(realrel ^^ {(y,x)})"; |
116 "- (Abs_real(realrel^^{(x,y)})) = Abs_real(realrel ^^ {(y,x)})"; |
149 |
149 |
150 (*** Congruence property for addition ***) |
150 (*** Congruence property for addition ***) |
151 Goalw [congruent2_def] |
151 Goalw [congruent2_def] |
152 "congruent2 realrel (%p1 p2. \ |
152 "congruent2 realrel (%p1 p2. \ |
153 \ (%(x1,y1). (%(x2,y2). realrel^^{(x1+x2, y1+y2)}) p2) p1)"; |
153 \ (%(x1,y1). (%(x2,y2). realrel^^{(x1+x2, y1+y2)}) p2) p1)"; |
154 by Safe_tac; |
154 by (Clarify_tac 1); |
155 by (asm_simp_tac (simpset() addsimps [preal_add_assoc]) 1); |
155 by (asm_simp_tac (simpset() addsimps [preal_add_assoc]) 1); |
156 by (res_inst_tac [("z1.1","x1a")] (preal_add_left_commute RS ssubst) 1); |
156 by (res_inst_tac [("z1.1","x1a")] (preal_add_left_commute RS ssubst) 1); |
157 by (asm_simp_tac (simpset() addsimps [preal_add_assoc RS sym]) 1); |
157 by (asm_simp_tac (simpset() addsimps [preal_add_assoc RS sym]) 1); |
158 by (asm_simp_tac (simpset() addsimps preal_add_ac) 1); |
158 by (asm_simp_tac (simpset() addsimps preal_add_ac) 1); |
159 qed "real_add_congruent2"; |
159 qed "real_add_congruent2"; |
315 |
315 |
316 Goal |
316 Goal |
317 "congruent2 realrel (%p1 p2. \ |
317 "congruent2 realrel (%p1 p2. \ |
318 \ (%(x1,y1). (%(x2,y2). realrel^^{(x1*x2 + y1*y2, x1*y2+x2*y1)}) p2) p1)"; |
318 \ (%(x1,y1). (%(x2,y2). realrel^^{(x1*x2 + y1*y2, x1*y2+x2*y1)}) p2) p1)"; |
319 by (rtac (equiv_realrel RS congruent2_commuteI) 1); |
319 by (rtac (equiv_realrel RS congruent2_commuteI) 1); |
320 by Safe_tac; |
320 by (Clarify_tac 1); |
321 by (rewtac split_def); |
321 by (rewtac split_def); |
322 by (asm_simp_tac (simpset() addsimps [preal_mult_commute,preal_add_commute]) 1); |
322 by (asm_simp_tac (simpset() addsimps [preal_mult_commute,preal_add_commute]) 1); |
323 by (auto_tac (claset(),simpset() addsimps [real_mult_congruent2_lemma])); |
323 by (auto_tac (claset(),simpset() addsimps [real_mult_congruent2_lemma])); |
324 qed "real_mult_congruent2"; |
324 qed "real_mult_congruent2"; |
325 |
325 |
645 by (dtac real_less_trans 1 THEN assume_tac 1); |
645 by (dtac real_less_trans 1 THEN assume_tac 1); |
646 by (asm_full_simp_tac (simpset() addsimps [real_less_not_refl]) 1); |
646 by (asm_full_simp_tac (simpset() addsimps [real_less_not_refl]) 1); |
647 qed "real_less_not_sym"; |
647 qed "real_less_not_sym"; |
648 |
648 |
649 (* [| x < y; ~P ==> y < x |] ==> P *) |
649 (* [| x < y; ~P ==> y < x |] ==> P *) |
650 bind_thm ("real_less_asym", real_less_not_sym RS swap); |
650 bind_thm ("real_less_asym", real_less_not_sym RS contrapos_np); |
651 |
651 |
652 Goalw [real_of_preal_def] |
652 Goalw [real_of_preal_def] |
653 "real_of_preal ((z1::preal) + z2) = \ |
653 "real_of_preal ((z1::preal) + z2) = \ |
654 \ real_of_preal z1 + real_of_preal z2"; |
654 \ real_of_preal z1 + real_of_preal z2"; |
655 by (asm_simp_tac (simpset() addsimps [real_add, |
655 by (asm_simp_tac (simpset() addsimps [real_add, |