src/HOL/Multivariate_Analysis/Integration.thy
changeset 61518 ff12606337e9
parent 61424 c3658c18b7bc
child 61524 f2e51e704a96
equal deleted inserted replaced
61515:c64628dbac00 61518:ff12606337e9
  1209     note p = this division_ofD[OF this(1)]
  1209     note p = this division_ofD[OF this(1)]
  1210     have "interior (cbox a b \<inter> \<Union>(p - {cbox u v})) = interior(cbox u v \<inter> \<Union>(p - {cbox u v}))"
  1210     have "interior (cbox a b \<inter> \<Union>(p - {cbox u v})) = interior(cbox u v \<inter> \<Union>(p - {cbox u v}))"
  1211       apply (rule arg_cong[of _ _ interior])
  1211       apply (rule arg_cong[of _ _ interior])
  1212       using p(8) uv by auto
  1212       using p(8) uv by auto
  1213     also have "\<dots> = {}"
  1213     also have "\<dots> = {}"
  1214       unfolding interior_inter
  1214       unfolding interior_Int
  1215       apply (rule inter_interior_unions_intervals)
  1215       apply (rule inter_interior_unions_intervals)
  1216       using p(6) p(7)[OF p(2)] p(3)
  1216       using p(6) p(7)[OF p(2)] p(3)
  1217       apply auto
  1217       apply auto
  1218       done
  1218       done
  1219     finally have [simp]: "interior (cbox a b) \<inter> interior (\<Union>(p - {cbox u v})) = {}" by simp
  1219     finally have [simp]: "interior (cbox a b) \<inter> interior (\<Union>(p - {cbox u v})) = {}" by simp
  4870             "cbox m n \<in> snd ` p" "cbox u v \<in> snd ` p"
  4870             "cbox m n \<in> snd ` p" "cbox u v \<in> snd ` p"
  4871             "cbox m n \<noteq> cbox u v"
  4871             "cbox m n \<noteq> cbox u v"
  4872             "cbox m n \<inter> {x. \<bar>x \<bullet> k - c\<bar> \<le> d} = cbox u v \<inter> {x. \<bar>x \<bullet> k - c\<bar> \<le> d}"
  4872             "cbox m n \<inter> {x. \<bar>x \<bullet> k - c\<bar> \<le> d} = cbox u v \<inter> {x. \<bar>x \<bullet> k - c\<bar> \<le> d}"
  4873           have "(cbox m n \<inter> {x. \<bar>x \<bullet> k - c\<bar> \<le> d}) \<inter> (cbox u v \<inter> {x. \<bar>x \<bullet> k - c\<bar> \<le> d}) \<subseteq> cbox m n \<inter> cbox u v"
  4873           have "(cbox m n \<inter> {x. \<bar>x \<bullet> k - c\<bar> \<le> d}) \<inter> (cbox u v \<inter> {x. \<bar>x \<bullet> k - c\<bar> \<le> d}) \<subseteq> cbox m n \<inter> cbox u v"
  4874             by blast
  4874             by blast
  4875           note interior_mono[OF this, unfolded division_ofD(5)[OF p'' as(1-3)] interior_inter[of "cbox m n"]]
  4875           note interior_mono[OF this, unfolded division_ofD(5)[OF p'' as(1-3)] interior_Int[of "cbox m n"]]
  4876           then have "interior (cbox m n \<inter> {x. \<bar>x \<bullet> k - c\<bar> \<le> d}) = {}"
  4876           then have "interior (cbox m n \<inter> {x. \<bar>x \<bullet> k - c\<bar> \<le> d}) = {}"
  4877             unfolding as Int_absorb by auto
  4877             unfolding as Int_absorb by auto
  4878           then show "content (cbox m n \<inter> {x. \<bar>x \<bullet> k - c\<bar> \<le> d}) = 0"
  4878           then show "content (cbox m n \<inter> {x. \<bar>x \<bullet> k - c\<bar> \<le> d}) = 0"
  4879             unfolding interval_doublesplit[OF k] content_eq_0_interior[symmetric] .
  4879             unfolding interval_doublesplit[OF k] content_eq_0_interior[symmetric] .
  4880         qed
  4880         qed
  7339               assume k: "(a, k) \<in> p" "(a, k') \<in> p" "content k \<noteq> 0" "content k' \<noteq> 0"
  7339               assume k: "(a, k) \<in> p" "(a, k') \<in> p" "content k \<noteq> 0" "content k' \<noteq> 0"
  7340               guess v using pa[OF k(1)] .. note v = conjunctD2[OF this]
  7340               guess v using pa[OF k(1)] .. note v = conjunctD2[OF this]
  7341               guess v' using pa[OF k(2)] .. note v' = conjunctD2[OF this] let ?v = "min v v'"
  7341               guess v' using pa[OF k(2)] .. note v' = conjunctD2[OF this] let ?v = "min v v'"
  7342               have "box a ?v \<subseteq> k \<inter> k'"
  7342               have "box a ?v \<subseteq> k \<inter> k'"
  7343                 unfolding v v' by (auto simp add: mem_box)
  7343                 unfolding v v' by (auto simp add: mem_box)
  7344               note interior_mono[OF this,unfolded interior_inter]
  7344               note interior_mono[OF this,unfolded interior_Int]
  7345               moreover have "(a + ?v)/2 \<in> box a ?v"
  7345               moreover have "(a + ?v)/2 \<in> box a ?v"
  7346                 using k(3-)
  7346                 using k(3-)
  7347                 unfolding v v' content_eq_0 not_le
  7347                 unfolding v v' content_eq_0 not_le
  7348                 by (auto simp add: mem_box)
  7348                 by (auto simp add: mem_box)
  7349               ultimately have "(a + ?v)/2 \<in> interior k \<inter> interior k'"
  7349               ultimately have "(a + ?v)/2 \<in> interior k \<inter> interior k'"
  7370               guess v using pb[OF k(1)] .. note v = conjunctD2[OF this]
  7370               guess v using pb[OF k(1)] .. note v = conjunctD2[OF this]
  7371               guess v' using pb[OF k(2)] .. note v' = conjunctD2[OF this]
  7371               guess v' using pb[OF k(2)] .. note v' = conjunctD2[OF this]
  7372               let ?v = "max v v'"
  7372               let ?v = "max v v'"
  7373               have "box ?v b \<subseteq> k \<inter> k'"
  7373               have "box ?v b \<subseteq> k \<inter> k'"
  7374                 unfolding v v' by (auto simp: mem_box)
  7374                 unfolding v v' by (auto simp: mem_box)
  7375                 note interior_mono[OF this,unfolded interior_inter]
  7375                 note interior_mono[OF this,unfolded interior_Int]
  7376               moreover have " ((b + ?v)/2) \<in> box ?v b"
  7376               moreover have " ((b + ?v)/2) \<in> box ?v b"
  7377                 using k(3-) unfolding v v' content_eq_0 not_le by (auto simp: mem_box)
  7377                 using k(3-) unfolding v v' content_eq_0 not_le by (auto simp: mem_box)
  7378               ultimately have " ((b + ?v)/2) \<in> interior k \<inter> interior k'"
  7378               ultimately have " ((b + ?v)/2) \<in> interior k \<inter> interior k'"
  7379                 unfolding interior_open[OF open_box] by auto
  7379                 unfolding interior_open[OF open_box] by auto
  7380               then have *: "k = k'"
  7380               then have *: "k = k'"
  8012 proof -
  8012 proof -
  8013   have "{x \<in> s. f x \<in> {y}} = {} \<or> {x \<in> s. f x \<in> {y}} = s"
  8013   have "{x \<in> s. f x \<in> {y}} = {} \<or> {x \<in> s. f x \<in> {y}} = s"
  8014     apply (rule assms(1)[unfolded connected_clopen,rule_format])
  8014     apply (rule assms(1)[unfolded connected_clopen,rule_format])
  8015     apply rule
  8015     apply rule
  8016     defer
  8016     defer
  8017     apply (rule continuous_closed_in_preimage[OF assms(4) closed_singleton])
  8017     apply (rule continuous_closedin_preimage[OF assms(4) closed_singleton])
  8018     apply (rule open_openin_trans[OF assms(2)])
  8018     apply (rule open_openin_trans[OF assms(2)])
  8019     unfolding open_contains_ball
  8019     unfolding open_contains_ball
  8020   proof safe
  8020   proof safe
  8021     fix x
  8021     fix x
  8022     assume "x \<in> s"
  8022     assume "x \<in> s"
  9425     assume "(x, m) \<in> T1" "(x, m) \<in> T2" "T1 \<noteq> T2" "k \<in> r" "l \<in> r" "T1 = qq k" "T2 = qq l"
  9425     assume "(x, m) \<in> T1" "(x, m) \<in> T2" "T1 \<noteq> T2" "k \<in> r" "l \<in> r" "T1 = qq k" "T2 = qq l"
  9426     note as = this(1-5)[unfolded this(6-)]
  9426     note as = this(1-5)[unfolded this(6-)]
  9427     note kl = tagged_division_ofD(3,4)[OF qq[THEN conjunct1]]
  9427     note kl = tagged_division_ofD(3,4)[OF qq[THEN conjunct1]]
  9428     from this(2)[OF as(4,1)] guess u v by (elim exE) note uv=this
  9428     from this(2)[OF as(4,1)] guess u v by (elim exE) note uv=this
  9429     have *: "interior (k \<inter> l) = {}"
  9429     have *: "interior (k \<inter> l) = {}"
  9430       unfolding interior_inter
  9430       unfolding interior_Int
  9431       apply (rule q')
  9431       apply (rule q')
  9432       using as
  9432       using as
  9433       unfolding r_def
  9433       unfolding r_def
  9434       apply auto
  9434       apply auto
  9435       done
  9435       done
 10769             apply (rule finite_imageI)
 10769             apply (rule finite_imageI)
 10770             apply (rule p')
 10770             apply (rule p')
 10771           proof goal_cases
 10771           proof goal_cases
 10772             case prems: (1 l y)
 10772             case prems: (1 l y)
 10773             have "interior (k \<inter> l) \<subseteq> interior (l \<inter> y)"
 10773             have "interior (k \<inter> l) \<subseteq> interior (l \<inter> y)"
 10774               apply (subst(2) interior_inter)
 10774               apply (subst(2) interior_Int)
 10775               apply (rule Int_greatest)
 10775               apply (rule Int_greatest)
 10776               defer
 10776               defer
 10777               apply (subst prems(4))
 10777               apply (subst prems(4))
 10778               apply auto
 10778               apply auto
 10779               done
 10779               done
 10958           proof goal_cases
 10958           proof goal_cases
 10959             case prems: (1 k y)
 10959             case prems: (1 k y)
 10960             from d'(4)[OF this(1)] d'(4)[OF this(2)]
 10960             from d'(4)[OF this(1)] d'(4)[OF this(2)]
 10961             guess u1 v1 u2 v2 by (elim exE) note uv=this
 10961             guess u1 v1 u2 v2 by (elim exE) note uv=this
 10962             have "{} = interior ((k \<inter> y) \<inter> cbox u v)"
 10962             have "{} = interior ((k \<inter> y) \<inter> cbox u v)"
 10963               apply (subst interior_inter)
 10963               apply (subst interior_Int)
 10964               using d'(5)[OF prems(1-3)]
 10964               using d'(5)[OF prems(1-3)]
 10965               apply auto
 10965               apply auto
 10966               done
 10966               done
 10967             also have "\<dots> = interior (y \<inter> (k \<inter> cbox u v))"
 10967             also have "\<dots> = interior (y \<inter> (k \<inter> cbox u v))"
 10968               by auto
 10968               by auto