src/HOL/Multivariate_Analysis/Integration.thy
changeset 57447 87429bdecad5
parent 57418 6ab1c7cb0b8d
child 57512 cc97b347b301
equal deleted inserted replaced
57446:06e195515deb 57447:87429bdecad5
   213   then show ?thesis by auto
   213   then show ?thesis by auto
   214 qed
   214 qed
   215 
   215 
   216 
   216 
   217 subsection {* Some useful lemmas about intervals. *}
   217 subsection {* Some useful lemmas about intervals. *}
   218 
       
   219 abbreviation One :: "'a::euclidean_space"
       
   220   where "One \<equiv> \<Sum>Basis"
       
   221 
   218 
   222 lemma empty_as_interval: "{} = cbox One (0::'a::euclidean_space)"
   219 lemma empty_as_interval: "{} = cbox One (0::'a::euclidean_space)"
   223   using nonempty_Basis
   220   using nonempty_Basis
   224   by (fastforce simp add: set_eq_iff mem_box)
   221   by (fastforce simp add: set_eq_iff mem_box)
   225 
   222 
  2706         apply (auto simp add: field_simps)
  2703         apply (auto simp add: field_simps)
  2707         done
  2704         done
  2708     qed
  2705     qed
  2709   qed
  2706   qed
  2710 qed
  2707 qed
       
  2708 
       
  2709 lemma has_integral_scaleR_left: 
       
  2710   "(f has_integral y) s \<Longrightarrow> ((\<lambda>x. f x *\<^sub>R c) has_integral (y *\<^sub>R c)) s"
       
  2711   using has_integral_linear[OF _ bounded_linear_scaleR_left] by (simp add: comp_def)
       
  2712 
       
  2713 lemma has_integral_mult_left:
       
  2714   fixes c :: "_ :: {real_normed_algebra}"
       
  2715   shows "(f has_integral y) s \<Longrightarrow> ((\<lambda>x. f x * c) has_integral (y * c)) s"
       
  2716   using has_integral_linear[OF _ bounded_linear_mult_left] by (simp add: comp_def)
  2711 
  2717 
  2712 lemma has_integral_cmul: "(f has_integral k) s \<Longrightarrow> ((\<lambda>x. c *\<^sub>R f x) has_integral (c *\<^sub>R k)) s"
  2718 lemma has_integral_cmul: "(f has_integral k) s \<Longrightarrow> ((\<lambda>x. c *\<^sub>R f x) has_integral (c *\<^sub>R k)) s"
  2713   unfolding o_def[symmetric]
  2719   unfolding o_def[symmetric]
  2714   apply (rule has_integral_linear,assumption)
  2720   apply (rule has_integral_linear,assumption)
  2715   apply (rule bounded_linear_scaleR_right)
  2721   apply (rule bounded_linear_scaleR_right)
 10957     using assms(1)
 10963     using assms(1)
 10958     apply auto
 10964     apply auto
 10959     apply (rule LIMSEQ_imp_Suc)
 10965     apply (rule LIMSEQ_imp_Suc)
 10960     apply assumption
 10966     apply assumption
 10961     done
 10967     done
       
 10968 qed
       
 10969 
       
 10970 lemma has_integral_monotone_convergence_increasing:
       
 10971   fixes f :: "nat \<Rightarrow> 'a::euclidean_space \<Rightarrow> real"
       
 10972   assumes f: "\<And>k. (f k has_integral x k) s"
       
 10973   assumes "\<And>k x. x \<in> s \<Longrightarrow> f k x \<le> f (Suc k) x"
       
 10974   assumes "\<And>x. x \<in> s \<Longrightarrow> (\<lambda>k. f k x) ----> g x"
       
 10975   assumes "x ----> x'"
       
 10976   shows "(g has_integral x') s"
       
 10977 proof -
       
 10978   have x_eq: "x = (\<lambda>i. integral s (f i))"
       
 10979     by (simp add: integral_unique[OF f])
       
 10980   then have x: "{integral s (f k) |k. True} = range x"
       
 10981     by auto
       
 10982 
       
 10983   have "g integrable_on s \<and> (\<lambda>k. integral s (f k)) ----> integral s g"
       
 10984   proof (intro monotone_convergence_increasing allI ballI assms)
       
 10985     show "bounded {integral s (f k) |k. True}"
       
 10986       unfolding x by (rule convergent_imp_bounded) fact
       
 10987   qed (auto intro: f)
       
 10988   moreover then have "integral s g = x'"
       
 10989     by (intro LIMSEQ_unique[OF _ `x ----> x'`]) (simp add: x_eq)
       
 10990   ultimately show ?thesis
       
 10991     by (simp add: has_integral_integral)
 10962 qed
 10992 qed
 10963 
 10993 
 10964 lemma monotone_convergence_decreasing:
 10994 lemma monotone_convergence_decreasing:
 10965   fixes f :: "nat \<Rightarrow> 'n::euclidean_space \<Rightarrow> real"
 10995   fixes f :: "nat \<Rightarrow> 'n::euclidean_space \<Rightarrow> real"
 10966   assumes "\<forall>k. (f k) integrable_on s"
 10996   assumes "\<forall>k. (f k) integrable_on s"
 12381 qed auto
 12411 qed auto
 12382 
 12412 
 12383 
 12413 
 12384 subsection {* Dominated convergence *}
 12414 subsection {* Dominated convergence *}
 12385 
 12415 
       
 12416 (* GENERALIZE the following theorems *)
       
 12417 
 12386 lemma dominated_convergence:
 12418 lemma dominated_convergence:
 12387   fixes f :: "nat \<Rightarrow> 'n::euclidean_space \<Rightarrow> real"
 12419   fixes f :: "nat \<Rightarrow> 'n::euclidean_space \<Rightarrow> real"
 12388   assumes "\<And>k. (f k) integrable_on s" "h integrable_on s"
 12420   assumes "\<And>k. (f k) integrable_on s" "h integrable_on s"
 12389     and "\<And>k. \<forall>x \<in> s. norm (f k x) \<le> h x"
 12421     and "\<And>k. \<forall>x \<in> s. norm (f k x) \<le> h x"
 12390     and "\<forall>x \<in> s. ((\<lambda>k. f k x) ---> g x) sequentially"
 12422     and "\<forall>x \<in> s. ((\<lambda>k. f k x) ---> g x) sequentially"
 12655       qed (insert n, auto)
 12687       qed (insert n, auto)
 12656     qed
 12688     qed
 12657   qed
 12689   qed
 12658 qed
 12690 qed
 12659 
 12691 
       
 12692 lemma has_integral_dominated_convergence:
       
 12693   fixes f :: "nat \<Rightarrow> 'n::euclidean_space \<Rightarrow> real"
       
 12694   assumes "\<And>k. (f k has_integral y k) s" "h integrable_on s"
       
 12695     "\<And>k. \<forall>x\<in>s. norm (f k x) \<le> h x" "\<forall>x\<in>s. (\<lambda>k. f k x) ----> g x"
       
 12696     and x: "y ----> x"
       
 12697   shows "(g has_integral x) s"
       
 12698 proof -
       
 12699   have int_f: "\<And>k. (f k) integrable_on s"
       
 12700     using assms by (auto simp: integrable_on_def)
       
 12701   have "(g has_integral (integral s g)) s"
       
 12702     by (intro integrable_integral dominated_convergence[OF int_f assms(2)]) fact+
       
 12703   moreover have "integral s g = x"
       
 12704   proof (rule LIMSEQ_unique)
       
 12705     show "(\<lambda>i. integral s (f i)) ----> x"
       
 12706       using integral_unique[OF assms(1)] x by simp
       
 12707     show "(\<lambda>i. integral s (f i)) ----> integral s g"
       
 12708       by (intro dominated_convergence[OF int_f assms(2)]) fact+
       
 12709   qed
       
 12710   ultimately show ?thesis
       
 12711     by simp
       
 12712 qed
       
 12713 
 12660 end
 12714 end