src/HOL/Library/Extended_Real.thy
changeset 63040 eb4ddd18d635
parent 62975 1d066f6ab25d
child 63060 293ede07b775
equal deleted inserted replaced
63039:1a20fd9cf281 63040:eb4ddd18d635
  3898   assumes "F \<noteq> bot"
  3898   assumes "F \<noteq> bot"
  3899   assumes nonneg: "eventually (\<lambda>x. f x \<ge> (0::ereal)) F"
  3899   assumes nonneg: "eventually (\<lambda>x. f x \<ge> (0::ereal)) F"
  3900   shows   Liminf_inverse_ereal: "Liminf F (\<lambda>x. inverse (f x)) = inverse (Limsup F f)"
  3900   shows   Liminf_inverse_ereal: "Liminf F (\<lambda>x. inverse (f x)) = inverse (Limsup F f)"
  3901   and     Limsup_inverse_ereal: "Limsup F (\<lambda>x. inverse (f x)) = inverse (Liminf F f)"
  3901   and     Limsup_inverse_ereal: "Limsup F (\<lambda>x. inverse (f x)) = inverse (Liminf F f)"
  3902 proof -
  3902 proof -
  3903   def inv \<equiv> "\<lambda>x. if x \<le> 0 then \<infinity> else inverse x :: ereal"
  3903   define inv where [abs_def]: "inv x = (if x \<le> 0 then \<infinity> else inverse x)" for x :: ereal
  3904   have "continuous_on ({..0} \<union> {0..}) inv" unfolding inv_def
  3904   have "continuous_on ({..0} \<union> {0..}) inv" unfolding inv_def
  3905     by (intro continuous_on_If) (auto intro!: continuous_intros)
  3905     by (intro continuous_on_If) (auto intro!: continuous_intros)
  3906   also have "{..0} \<union> {0..} = (UNIV :: ereal set)" by auto
  3906   also have "{..0} \<union> {0..} = (UNIV :: ereal set)" by auto
  3907   finally have cont: "continuous_on UNIV inv" .
  3907   finally have cont: "continuous_on UNIV inv" .
  3908   have antimono: "antimono inv" unfolding inv_def antimono_def
  3908   have antimono: "antimono inv" unfolding inv_def antimono_def