src/HOL/Analysis/Extended_Real_Limits.thy
changeset 71633 07bec530f02e
parent 71172 575b3a818de5
child 73932 fd21b4a93043
equal deleted inserted replaced
71629:2e8f861d21d4 71633:07bec530f02e
   302   unfolding Liminf_def eventually_at
   302   unfolding Liminf_def eventually_at
   303 proof (rule SUP_eq, simp_all add: Ball_def Bex_def, safe)
   303 proof (rule SUP_eq, simp_all add: Ball_def Bex_def, safe)
   304   fix P d
   304   fix P d
   305   assume "0 < d" and "\<forall>y. y \<in> S \<longrightarrow> y \<noteq> x \<and> dist y x < d \<longrightarrow> P y"
   305   assume "0 < d" and "\<forall>y. y \<in> S \<longrightarrow> y \<noteq> x \<and> dist y x < d \<longrightarrow> P y"
   306   then have "S \<inter> ball x d - {x} \<subseteq> {x. P x}"
   306   then have "S \<inter> ball x d - {x} \<subseteq> {x. P x}"
   307     by (auto simp: zero_less_dist_iff dist_commute)
   307     by (auto simp: dist_commute)
   308   then show "\<exists>r>0. Inf (f ` (Collect P)) \<le> Inf (f ` (S \<inter> ball x r - {x}))"
   308   then show "\<exists>r>0. Inf (f ` (Collect P)) \<le> Inf (f ` (S \<inter> ball x r - {x}))"
   309     by (intro exI[of _ d] INF_mono conjI \<open>0 < d\<close>) auto
   309     by (intro exI[of _ d] INF_mono conjI \<open>0 < d\<close>) auto
   310 next
   310 next
   311   fix d :: real
   311   fix d :: real
   312   assume "0 < d"
   312   assume "0 < d"
   322   unfolding Limsup_def eventually_at
   322   unfolding Limsup_def eventually_at
   323 proof (rule INF_eq, simp_all add: Ball_def Bex_def, safe)
   323 proof (rule INF_eq, simp_all add: Ball_def Bex_def, safe)
   324   fix P d
   324   fix P d
   325   assume "0 < d" and "\<forall>y. y \<in> S \<longrightarrow> y \<noteq> x \<and> dist y x < d \<longrightarrow> P y"
   325   assume "0 < d" and "\<forall>y. y \<in> S \<longrightarrow> y \<noteq> x \<and> dist y x < d \<longrightarrow> P y"
   326   then have "S \<inter> ball x d - {x} \<subseteq> {x. P x}"
   326   then have "S \<inter> ball x d - {x} \<subseteq> {x. P x}"
   327     by (auto simp: zero_less_dist_iff dist_commute)
   327     by (auto simp: dist_commute)
   328   then show "\<exists>r>0. Sup (f ` (S \<inter> ball x r - {x})) \<le> Sup (f ` (Collect P))"
   328   then show "\<exists>r>0. Sup (f ` (S \<inter> ball x r - {x})) \<le> Sup (f ` (Collect P))"
   329     by (intro exI[of _ d] SUP_mono conjI \<open>0 < d\<close>) auto
   329     by (intro exI[of _ d] SUP_mono conjI \<open>0 < d\<close>) auto
   330 next
   330 next
   331   fix d :: real
   331   fix d :: real
   332   assume "0 < d"
   332   assume "0 < d"