2058 |
2058 |
2059 (*------------------------------------------------------------------------ |
2059 (*------------------------------------------------------------------------ |
2060 Infinitesimals as smaller than 1/n for all n::nat (> 0) |
2060 Infinitesimals as smaller than 1/n for all n::nat (> 0) |
2061 ------------------------------------------------------------------------*) |
2061 ------------------------------------------------------------------------*) |
2062 Goal "(ALL r. 0 < r --> x < r) = (ALL n. x < inverse(real_of_posnat n))"; |
2062 Goal "(ALL r. 0 < r --> x < r) = (ALL n. x < inverse(real_of_posnat n))"; |
2063 by (auto_tac (claset(),simpset() addsimps |
2063 by (auto_tac (claset(), |
2064 [rename_numerals (real_of_posnat_gt_zero RS real_inverse_gt_zero)])); |
2064 simpset() addsimps [rename_numerals real_of_posnat_gt_zero])); |
2065 by (blast_tac (claset() addSDs [rename_numerals reals_Archimedean] |
2065 by (blast_tac (claset() addSDs [rename_numerals reals_Archimedean] |
2066 addIs [real_less_trans]) 1); |
2066 addIs [order_less_trans]) 1); |
2067 qed "lemma_Infinitesimal"; |
2067 qed "lemma_Infinitesimal"; |
2068 |
2068 |
2069 Goal "(ALL r: SReal. 0 < r --> x < r) = \ |
2069 Goal "(ALL r: SReal. 0 < r --> x < r) = \ |
2070 \ (ALL n. x < inverse(hypreal_of_posnat n))"; |
2070 \ (ALL n. x < inverse(hypreal_of_posnat n))"; |
2071 by (Step_tac 1); |
2071 by (Step_tac 1); |
2073 by (Full_simp_tac 1); |
2073 by (Full_simp_tac 1); |
2074 by (rtac (real_of_posnat_gt_zero RS real_inverse_gt_zero RS |
2074 by (rtac (real_of_posnat_gt_zero RS real_inverse_gt_zero RS |
2075 (hypreal_of_real_less_iff RS iffD1) RSN(2,impE)) 1); |
2075 (hypreal_of_real_less_iff RS iffD1) RSN(2,impE)) 1); |
2076 by (assume_tac 2); |
2076 by (assume_tac 2); |
2077 by (asm_full_simp_tac (simpset() addsimps |
2077 by (asm_full_simp_tac (simpset() addsimps |
2078 [real_not_refl2 RS not_sym RS hypreal_of_real_inverse RS sym, |
2078 [real_not_refl2 RS not_sym RS hypreal_of_real_inverse RS sym, |
2079 rename_numerals real_of_posnat_gt_zero,hypreal_of_real_zero, |
2079 rename_numerals real_of_posnat_gt_zero,hypreal_of_real_zero, |
2080 hypreal_of_real_of_posnat]) 1); |
2080 hypreal_of_real_of_posnat]) 1); |
2081 by (auto_tac (claset() addSDs [reals_Archimedean], |
2081 by (auto_tac (claset() addSDs [reals_Archimedean], |
2082 simpset() addsimps [SReal_iff,hypreal_of_real_zero RS sym])); |
2082 simpset() addsimps [SReal_iff,hypreal_of_real_zero RS sym])); |
2083 by (dtac (hypreal_of_real_less_iff RS iffD1) 1); |
2083 by (dtac (hypreal_of_real_less_iff RS iffD1) 1); |
2084 by (asm_full_simp_tac (simpset() addsimps |
2084 by (asm_full_simp_tac (simpset() addsimps |
2085 [real_not_refl2 RS not_sym RS hypreal_of_real_inverse RS sym, |
2085 [real_not_refl2 RS not_sym RS hypreal_of_real_inverse RS sym, |
2086 rename_numerals real_of_posnat_gt_zero,hypreal_of_real_of_posnat])1); |
2086 rename_numerals real_of_posnat_gt_zero,hypreal_of_real_of_posnat])1); |
2087 by (blast_tac (claset() addIs [hypreal_less_trans]) 1); |
2087 by (blast_tac (claset() addIs [hypreal_less_trans]) 1); |
2088 qed "lemma_Infinitesimal2"; |
2088 qed "lemma_Infinitesimal2"; |
2089 |
2089 |
2090 Goalw [Infinitesimal_def] |
2090 Goalw [Infinitesimal_def] |
2091 "Infinitesimal = {x. ALL n. abs x < inverse (hypreal_of_posnat n)}"; |
2091 "Infinitesimal = {x. ALL n. abs x < inverse (hypreal_of_posnat n)}"; |
2115 |
2115 |
2116 Goal "finite {n. real_of_posnat n < u}"; |
2116 Goal "finite {n. real_of_posnat n < u}"; |
2117 by (cut_inst_tac [("x","u")] reals_Archimedean2 1); |
2117 by (cut_inst_tac [("x","u")] reals_Archimedean2 1); |
2118 by (Step_tac 1); |
2118 by (Step_tac 1); |
2119 by (rtac (finite_real_of_posnat_segment RSN (2,finite_subset)) 1); |
2119 by (rtac (finite_real_of_posnat_segment RSN (2,finite_subset)) 1); |
2120 by (auto_tac (claset() addDs [real_less_trans],simpset())); |
2120 by (auto_tac (claset() addDs [order_less_trans],simpset())); |
2121 qed "finite_real_of_posnat_less_real"; |
2121 qed "finite_real_of_posnat_less_real"; |
2122 |
2122 |
2123 Goal "{n. real_of_posnat n <= u} = \ |
2123 Goal "{n. real_of_posnat n <= u} = \ |
2124 \ {n. real_of_posnat n < u} Un {n. u = real_of_posnat n}"; |
2124 \ {n. real_of_posnat n < u} Un {n. u = real_of_posnat n}"; |
2125 by (auto_tac (claset() addDs [real_le_imp_less_or_eq], |
2125 by (auto_tac (claset() addDs [real_le_imp_less_or_eq], |
2263 -----------------------------------------------------*) |
2263 -----------------------------------------------------*) |
2264 Goal "ALL n. abs(X n + -x) < inverse(real_of_posnat n) \ |
2264 Goal "ALL n. abs(X n + -x) < inverse(real_of_posnat n) \ |
2265 \ ==> Abs_hypreal(hyprel^^{X}) + -hypreal_of_real x : Infinitesimal"; |
2265 \ ==> Abs_hypreal(hyprel^^{X}) + -hypreal_of_real x : Infinitesimal"; |
2266 by (auto_tac (claset() addSIs [bexI] addDs [rename_numerals |
2266 by (auto_tac (claset() addSIs [bexI] addDs [rename_numerals |
2267 FreeUltrafilterNat_inverse_real_of_posnat, |
2267 FreeUltrafilterNat_inverse_real_of_posnat, |
2268 FreeUltrafilterNat_all,FreeUltrafilterNat_Int] addIs [real_less_trans, |
2268 FreeUltrafilterNat_all,FreeUltrafilterNat_Int] addIs [order_less_trans, |
2269 FreeUltrafilterNat_subset],simpset() addsimps [hypreal_minus, |
2269 FreeUltrafilterNat_subset],simpset() addsimps [hypreal_minus, |
2270 hypreal_of_real_minus RS sym,hypreal_of_real_def,hypreal_add, |
2270 hypreal_of_real_minus RS sym,hypreal_of_real_def,hypreal_add, |
2271 Infinitesimal_FreeUltrafilterNat_iff,hypreal_inverse,hypreal_of_real_of_posnat])); |
2271 Infinitesimal_FreeUltrafilterNat_iff,hypreal_inverse,hypreal_of_real_of_posnat])); |
2272 qed "real_seq_to_hypreal_Infinitesimal"; |
2272 qed "real_seq_to_hypreal_Infinitesimal"; |
2273 |
2273 |
2285 qed "real_seq_to_hypreal_inf_close2"; |
2285 qed "real_seq_to_hypreal_inf_close2"; |
2286 |
2286 |
2287 Goal "ALL n. abs(X n + -Y n) < inverse(real_of_posnat n) \ |
2287 Goal "ALL n. abs(X n + -Y n) < inverse(real_of_posnat n) \ |
2288 \ ==> Abs_hypreal(hyprel^^{X}) + \ |
2288 \ ==> Abs_hypreal(hyprel^^{X}) + \ |
2289 \ -Abs_hypreal(hyprel^^{Y}) : Infinitesimal"; |
2289 \ -Abs_hypreal(hyprel^^{Y}) : Infinitesimal"; |
2290 by (auto_tac (claset() addSIs [bexI] addDs [rename_numerals |
2290 by (auto_tac (claset() addSIs [bexI] |
2291 FreeUltrafilterNat_inverse_real_of_posnat, |
2291 addDs [rename_numerals |
2292 FreeUltrafilterNat_all,FreeUltrafilterNat_Int] addIs [real_less_trans, |
2292 FreeUltrafilterNat_inverse_real_of_posnat, |
2293 FreeUltrafilterNat_subset],simpset() addsimps |
2293 FreeUltrafilterNat_all,FreeUltrafilterNat_Int] |
2294 [Infinitesimal_FreeUltrafilterNat_iff,hypreal_minus,hypreal_add, |
2294 addIs [order_less_trans, FreeUltrafilterNat_subset], |
2295 hypreal_inverse,hypreal_of_real_of_posnat])); |
2295 simpset() addsimps |
|
2296 [Infinitesimal_FreeUltrafilterNat_iff,hypreal_minus,hypreal_add, |
|
2297 hypreal_inverse,hypreal_of_real_of_posnat])); |
2296 qed "real_seq_to_hypreal_Infinitesimal2"; |
2298 qed "real_seq_to_hypreal_Infinitesimal2"; |
2297 |
2299 |