src/HOL/Analysis/Equivalence_Lebesgue_Henstock_Integration.thy
changeset 70721 47258727fa42
parent 70707 125705f5965f
child 70726 91587befabfd
equal deleted inserted replaced
70720:99e24569cc1f 70721:47258727fa42
  1105 
  1105 
  1106 lemma absolutely_integrable_on_subinterval:
  1106 lemma absolutely_integrable_on_subinterval:
  1107   fixes f :: "real \<Rightarrow> 'b::euclidean_space"
  1107   fixes f :: "real \<Rightarrow> 'b::euclidean_space"
  1108   shows "\<lbrakk>f absolutely_integrable_on S; {a..b} \<subseteq> S\<rbrakk> \<Longrightarrow> f absolutely_integrable_on {a..b}"
  1108   shows "\<lbrakk>f absolutely_integrable_on S; {a..b} \<subseteq> S\<rbrakk> \<Longrightarrow> f absolutely_integrable_on {a..b}"
  1109   using absolutely_integrable_on_subcbox by fastforce
  1109   using absolutely_integrable_on_subcbox by fastforce
       
  1110 
       
  1111 lemma integrable_subinterval:
       
  1112   fixes f :: "real \<Rightarrow> 'a::euclidean_space"
       
  1113   assumes "integrable (lebesgue_on {a..b}) f"
       
  1114     and "{c..d} \<subseteq> {a..b}"
       
  1115   shows "integrable (lebesgue_on {c..d}) f"
       
  1116 proof (rule absolutely_integrable_imp_integrable)
       
  1117   show "f absolutely_integrable_on {c..d}"
       
  1118   proof -
       
  1119     have "f integrable_on {c..d}"
       
  1120       using assms integrable_on_lebesgue_on integrable_on_subinterval by fastforce
       
  1121     moreover have "(\<lambda>x. norm (f x)) integrable_on {c..d}"
       
  1122     proof (rule integrable_on_subinterval)
       
  1123       show "(\<lambda>x. norm (f x)) integrable_on {a..b}"
       
  1124         by (simp add: assms integrable_on_lebesgue_on)
       
  1125     qed (use assms in auto)
       
  1126     ultimately show ?thesis
       
  1127       by (auto simp: absolutely_integrable_on_def)
       
  1128   qed
       
  1129 qed auto
       
  1130 
       
  1131 lemma indefinite_integral_continuous_real:
       
  1132   fixes f :: "real \<Rightarrow> 'a::euclidean_space"
       
  1133   assumes "integrable (lebesgue_on {a..b}) f"
       
  1134   shows "continuous_on {a..b} (\<lambda>x. integral\<^sup>L (lebesgue_on {a..x}) f)"
       
  1135 proof -
       
  1136   have "f integrable_on {a..b}"
       
  1137     by (simp add: assms integrable_on_lebesgue_on)
       
  1138   then have "continuous_on {a..b} (\<lambda>x. integral {a..x} f)"
       
  1139     using indefinite_integral_continuous_1 by blast
       
  1140   moreover have "integral\<^sup>L (lebesgue_on {a..x}) f = integral {a..x} f" if "a \<le> x" "x \<le> b" for x
       
  1141   proof -
       
  1142     have "{a..x} \<subseteq> {a..b}"
       
  1143       using that by auto
       
  1144     then have "integrable (lebesgue_on {a..x}) f"
       
  1145       using integrable_subinterval assms by blast
       
  1146     then show "integral\<^sup>L (lebesgue_on {a..x}) f = integral {a..x} f"
       
  1147       by (simp add: lebesgue_integral_eq_integral)
       
  1148   qed
       
  1149   ultimately show ?thesis
       
  1150     by (metis (no_types, lifting) atLeastAtMost_iff continuous_on_cong)
       
  1151 qed
  1110 
  1152 
  1111 lemma lmeasurable_iff_integrable_on: "S \<in> lmeasurable \<longleftrightarrow> (\<lambda>x. 1::real) integrable_on S"
  1153 lemma lmeasurable_iff_integrable_on: "S \<in> lmeasurable \<longleftrightarrow> (\<lambda>x. 1::real) integrable_on S"
  1112   by (subst absolutely_integrable_on_iff_nonneg[symmetric])
  1154   by (subst absolutely_integrable_on_iff_nonneg[symmetric])
  1113      (simp_all add: lmeasurable_iff_integrable set_integrable_def)
  1155      (simp_all add: lmeasurable_iff_integrable set_integrable_def)
  1114 
  1156 
  3130         using \<open>C>0\<close> \<open>D>0\<close> by (metis mult_zero_left real_mult_less_iff1)
  3172         using \<open>C>0\<close> \<open>D>0\<close> by (metis mult_zero_left real_mult_less_iff1)
  3131     qed
  3173     qed
  3132   qed
  3174   qed
  3133 qed
  3175 qed
  3134 
  3176 
  3135 
       
  3136 subsection\<open>Lemmas about absolute integrability\<close>
  3177 subsection\<open>Lemmas about absolute integrability\<close>
  3137 
       
  3138 text\<open>FIXME Redundant!\<close>
       
  3139 lemma absolutely_integrable_add[intro]:
       
  3140   fixes f g :: "'n::euclidean_space \<Rightarrow> 'm::euclidean_space"
       
  3141   shows "f absolutely_integrable_on s \<Longrightarrow> g absolutely_integrable_on s \<Longrightarrow> (\<lambda>x. f x + g x) absolutely_integrable_on s"
       
  3142   by (rule set_integral_add)
       
  3143 
       
  3144 text\<open>FIXME Redundant!\<close>
       
  3145 lemma absolutely_integrable_diff[intro]:
       
  3146   fixes f g :: "'n::euclidean_space \<Rightarrow> 'm::euclidean_space"
       
  3147   shows "f absolutely_integrable_on s \<Longrightarrow> g absolutely_integrable_on s \<Longrightarrow> (\<lambda>x. f x - g x) absolutely_integrable_on s"
       
  3148   by (rule set_integral_diff)
       
  3149 
  3178 
  3150 lemma absolutely_integrable_linear:
  3179 lemma absolutely_integrable_linear:
  3151   fixes f :: "'m::euclidean_space \<Rightarrow> 'n::euclidean_space"
  3180   fixes f :: "'m::euclidean_space \<Rightarrow> 'n::euclidean_space"
  3152     and h :: "'n::euclidean_space \<Rightarrow> 'p::euclidean_space"
  3181     and h :: "'n::euclidean_space \<Rightarrow> 'p::euclidean_space"
  3153   shows "f absolutely_integrable_on s \<Longrightarrow> bounded_linear h \<Longrightarrow> (h \<circ> f) absolutely_integrable_on s"
  3182   shows "f absolutely_integrable_on s \<Longrightarrow> bounded_linear h \<Longrightarrow> (h \<circ> f) absolutely_integrable_on s"
  3373     show "(\<Sum>i\<in>Basis. max (f x \<bullet> i) (g x \<bullet> i) *\<^sub>R i) =
  3402     show "(\<Sum>i\<in>Basis. max (f x \<bullet> i) (g x \<bullet> i) *\<^sub>R i) =
  3374          (1 / 2) *\<^sub>R (f x + g x + (\<Sum>i\<in>Basis. \<bar>f x \<bullet> i - g x \<bullet> i\<bar> *\<^sub>R i))" .
  3403          (1 / 2) *\<^sub>R (f x + g x + (\<Sum>i\<in>Basis. \<bar>f x \<bullet> i - g x \<bullet> i\<bar> *\<^sub>R i))" .
  3375   qed
  3404   qed
  3376   moreover have "(\<lambda>x. (1 / 2) *\<^sub>R (f x + g x + (\<Sum>i\<in>Basis. \<bar>f x \<bullet> i - g x \<bullet> i\<bar> *\<^sub>R i)))
  3405   moreover have "(\<lambda>x. (1 / 2) *\<^sub>R (f x + g x + (\<Sum>i\<in>Basis. \<bar>f x \<bullet> i - g x \<bullet> i\<bar> *\<^sub>R i)))
  3377                  absolutely_integrable_on S"
  3406                  absolutely_integrable_on S"
  3378     apply (intro absolutely_integrable_add absolutely_integrable_scaleR_left assms)
  3407     apply (intro set_integral_add absolutely_integrable_scaleR_left assms)
  3379     using absolutely_integrable_abs [OF absolutely_integrable_diff [OF assms]]
  3408     using absolutely_integrable_abs [OF set_integral_diff(1) [OF assms]]
  3380     apply (simp add: algebra_simps)
  3409     apply (simp add: algebra_simps)
  3381     done
  3410     done
  3382   ultimately show ?thesis by metis
  3411   ultimately show ?thesis by metis
  3383 qed
  3412 qed
  3384 
  3413 
  3408     show "(\<Sum>i\<in>Basis. min (f x \<bullet> i) (g x \<bullet> i) *\<^sub>R i) =
  3437     show "(\<Sum>i\<in>Basis. min (f x \<bullet> i) (g x \<bullet> i) *\<^sub>R i) =
  3409          (1 / 2) *\<^sub>R (f x + g x - (\<Sum>i\<in>Basis. \<bar>f x \<bullet> i - g x \<bullet> i\<bar> *\<^sub>R i))" .
  3438          (1 / 2) *\<^sub>R (f x + g x - (\<Sum>i\<in>Basis. \<bar>f x \<bullet> i - g x \<bullet> i\<bar> *\<^sub>R i))" .
  3410   qed
  3439   qed
  3411   moreover have "(\<lambda>x. (1 / 2) *\<^sub>R (f x + g x - (\<Sum>i\<in>Basis. \<bar>f x \<bullet> i - g x \<bullet> i\<bar> *\<^sub>R i)))
  3440   moreover have "(\<lambda>x. (1 / 2) *\<^sub>R (f x + g x - (\<Sum>i\<in>Basis. \<bar>f x \<bullet> i - g x \<bullet> i\<bar> *\<^sub>R i)))
  3412                  absolutely_integrable_on S"
  3441                  absolutely_integrable_on S"
  3413     apply (intro absolutely_integrable_add absolutely_integrable_diff absolutely_integrable_scaleR_left assms)
  3442     apply (intro set_integral_add set_integral_diff absolutely_integrable_scaleR_left assms)
  3414     using absolutely_integrable_abs [OF absolutely_integrable_diff [OF assms]]
  3443     using absolutely_integrable_abs [OF set_integral_diff(1) [OF assms]]
  3415     apply (simp add: algebra_simps)
  3444     apply (simp add: algebra_simps)
  3416     done
  3445     done
  3417   ultimately show ?thesis by metis
  3446   ultimately show ?thesis by metis
  3418 qed
  3447 qed
  3419 
  3448 
  3448   assumes f: "f integrable_on A" and g: "g absolutely_integrable_on A"
  3477   assumes f: "f integrable_on A" and g: "g absolutely_integrable_on A"
  3449       and comp: "\<And>x b. \<lbrakk>x \<in> A; b \<in> Basis\<rbrakk> \<Longrightarrow> f x \<bullet> b \<le> g x \<bullet> b"
  3478       and comp: "\<And>x b. \<lbrakk>x \<in> A; b \<in> Basis\<rbrakk> \<Longrightarrow> f x \<bullet> b \<le> g x \<bullet> b"
  3450   shows "f absolutely_integrable_on A"
  3479   shows "f absolutely_integrable_on A"
  3451 proof -
  3480 proof -
  3452   have "(\<lambda>x. g x - (g x - f x)) absolutely_integrable_on A"
  3481   have "(\<lambda>x. g x - (g x - f x)) absolutely_integrable_on A"
  3453     apply (rule absolutely_integrable_diff [OF g nonnegative_absolutely_integrable])
  3482     apply (rule set_integral_diff [OF g nonnegative_absolutely_integrable])
  3454     using Henstock_Kurzweil_Integration.integrable_diff absolutely_integrable_on_def f g apply blast
  3483     using Henstock_Kurzweil_Integration.integrable_diff absolutely_integrable_on_def f g apply blast
  3455     by (simp add: comp inner_diff_left)
  3484     by (simp add: comp inner_diff_left)
  3456   then show ?thesis
  3485   then show ?thesis
  3457     by simp
  3486     by simp
  3458 qed
  3487 qed
  3462   assumes f: "f absolutely_integrable_on A" and g: "g integrable_on A"
  3491   assumes f: "f absolutely_integrable_on A" and g: "g integrable_on A"
  3463       and comp: "\<And>x b. \<lbrakk>x \<in> A; b \<in> Basis\<rbrakk> \<Longrightarrow> f x \<bullet> b \<le> g x \<bullet> b"
  3492       and comp: "\<And>x b. \<lbrakk>x \<in> A; b \<in> Basis\<rbrakk> \<Longrightarrow> f x \<bullet> b \<le> g x \<bullet> b"
  3464   shows "g absolutely_integrable_on A"
  3493   shows "g absolutely_integrable_on A"
  3465 proof -
  3494 proof -
  3466   have "(\<lambda>x. f x + (g x - f x)) absolutely_integrable_on A"
  3495   have "(\<lambda>x. f x + (g x - f x)) absolutely_integrable_on A"
  3467     apply (rule absolutely_integrable_add [OF f nonnegative_absolutely_integrable])
  3496     apply (rule set_integral_add [OF f nonnegative_absolutely_integrable])
  3468     using Henstock_Kurzweil_Integration.integrable_diff absolutely_integrable_on_def f g apply blast
  3497     using Henstock_Kurzweil_Integration.integrable_diff absolutely_integrable_on_def f g apply blast
  3469     by (simp add: comp inner_diff_left)
  3498     by (simp add: comp inner_diff_left)
  3470   then show ?thesis
  3499   then show ?thesis
  3471     by simp
  3500     by simp
  3472 qed
  3501 qed
  4493     by (auto simp: eq)
  4522     by (auto simp: eq)
  4494   then show ?thesis
  4523   then show ?thesis
  4495     by (auto simp: has_bochner_integral_restrict_space)
  4524     by (auto simp: has_bochner_integral_restrict_space)
  4496 qed
  4525 qed
  4497 
  4526 
       
  4527 lemma has_bochner_integral_reflect_real[simp]:
       
  4528   fixes f :: "real \<Rightarrow> 'a::euclidean_space"
       
  4529   shows "has_bochner_integral (lebesgue_on {-b..-a}) (\<lambda>x. f(-x)) i \<longleftrightarrow> has_bochner_integral (lebesgue_on {a..b}) f i"
       
  4530   by (auto simp: dest: has_bochner_integral_reflect_real_lemma)
       
  4531 
       
  4532 lemma integrable_reflect_real[simp]:
       
  4533   fixes f :: "real \<Rightarrow> 'a::euclidean_space"
       
  4534   shows "integrable (lebesgue_on {-b..-a}) (\<lambda>x. f(-x)) \<longleftrightarrow> integrable (lebesgue_on {a..b}) f"
       
  4535   by (metis has_bochner_integral_iff has_bochner_integral_reflect_real)
       
  4536 
       
  4537 lemma integral_reflect_real[simp]:
       
  4538   fixes f :: "real \<Rightarrow> 'a::euclidean_space"
       
  4539   shows "integral\<^sup>L (lebesgue_on {-b .. -a}) (\<lambda>x. f(-x)) = integral\<^sup>L (lebesgue_on {a..b::real}) f"
       
  4540   using has_bochner_integral_reflect_real [of b a f]
       
  4541   by (metis has_bochner_integral_iff not_integrable_integral_eq)
       
  4542 
  4498 subsection\<open>More results on integrability\<close>
  4543 subsection\<open>More results on integrability\<close>
  4499 
  4544 
  4500 lemma integrable_on_all_intervals_UNIV:
  4545 lemma integrable_on_all_intervals_UNIV:
  4501   fixes f :: "'a::euclidean_space \<Rightarrow> 'b::banach"
  4546   fixes f :: "'a::euclidean_space \<Rightarrow> 'b::banach"
  4502   assumes intf: "\<And>a b. f integrable_on cbox a b"
  4547   assumes intf: "\<And>a b. f integrable_on cbox a b"
  4788     using absolutely_integrable_restrict_UNIV by blast
  4833     using absolutely_integrable_restrict_UNIV by blast
  4789   have "(\<lambda>x. if x \<in> S then f x else 0) absolutely_integrable_on UNIV"
  4834   have "(\<lambda>x. if x \<in> S then f x else 0) absolutely_integrable_on UNIV"
  4790        "(\<lambda>x. if x \<in> T then f x else 0) absolutely_integrable_on UNIV"
  4835        "(\<lambda>x. if x \<in> T then f x else 0) absolutely_integrable_on UNIV"
  4791     using S T absolutely_integrable_restrict_UNIV by blast+
  4836     using S T absolutely_integrable_restrict_UNIV by blast+
  4792   then have "(\<lambda>x. (if x \<in> S then f x else 0) + (if x \<in> T then f x else 0)) absolutely_integrable_on UNIV"
  4837   then have "(\<lambda>x. (if x \<in> S then f x else 0) + (if x \<in> T then f x else 0)) absolutely_integrable_on UNIV"
  4793     by (rule absolutely_integrable_add)
  4838     by (rule set_integral_add)
  4794   then have "(\<lambda>x. ((if x \<in> S then f x else 0) + (if x \<in> T then f x else 0)) - (if x \<in> ?ST then f x else 0)) absolutely_integrable_on UNIV"
  4839   then have "(\<lambda>x. ((if x \<in> S then f x else 0) + (if x \<in> T then f x else 0)) - (if x \<in> ?ST then f x else 0)) absolutely_integrable_on UNIV"
  4795     using Int by (rule absolutely_integrable_diff)
  4840     using Int by (rule set_integral_diff)
  4796   then have "(\<lambda>x. if x \<in> S \<union> T then f x else 0) absolutely_integrable_on UNIV"
  4841   then have "(\<lambda>x. if x \<in> S \<union> T then f x else 0) absolutely_integrable_on UNIV"
  4797     by (rule absolutely_integrable_spike) (auto intro: empty_imp_negligible)
  4842     by (rule absolutely_integrable_spike) (auto intro: empty_imp_negligible)
  4798   then show ?thesis
  4843   then show ?thesis
  4799     unfolding absolutely_integrable_restrict_UNIV .
  4844     unfolding absolutely_integrable_restrict_UNIV .
  4800 qed
  4845 qed