src/HOL/Analysis/Starlike.thy
changeset 69064 5840724b1d71
parent 68796 9ca183045102
child 69272 15e9ed5b28fb
equal deleted inserted replaced
69045:8c240fdeffcb 69064:5840724b1d71
  2900 qed
  2900 qed
  2901 
  2901 
  2902 lemma rel_interior_scaleR:
  2902 lemma rel_interior_scaleR:
  2903   fixes S :: "'n::euclidean_space set"
  2903   fixes S :: "'n::euclidean_space set"
  2904   assumes "c \<noteq> 0"
  2904   assumes "c \<noteq> 0"
  2905   shows "(( *\<^sub>R) c) ` (rel_interior S) = rel_interior ((( *\<^sub>R) c) ` S)"
  2905   shows "((*\<^sub>R) c) ` (rel_interior S) = rel_interior (((*\<^sub>R) c) ` S)"
  2906   using rel_interior_injective_linear_image[of "(( *\<^sub>R) c)" S]
  2906   using rel_interior_injective_linear_image[of "((*\<^sub>R) c)" S]
  2907     linear_conv_bounded_linear[of "( *\<^sub>R) c"] linear_scaleR injective_scaleR[of c] assms
  2907     linear_conv_bounded_linear[of "(*\<^sub>R) c"] linear_scaleR injective_scaleR[of c] assms
  2908   by auto
  2908   by auto
  2909 
  2909 
  2910 lemma rel_interior_convex_scaleR:
  2910 lemma rel_interior_convex_scaleR:
  2911   fixes S :: "'n::euclidean_space set"
  2911   fixes S :: "'n::euclidean_space set"
  2912   assumes "convex S"
  2912   assumes "convex S"
  2913   shows "(( *\<^sub>R) c) ` (rel_interior S) = rel_interior ((( *\<^sub>R) c) ` S)"
  2913   shows "((*\<^sub>R) c) ` (rel_interior S) = rel_interior (((*\<^sub>R) c) ` S)"
  2914   by (metis assms linear_scaleR rel_interior_convex_linear_image)
  2914   by (metis assms linear_scaleR rel_interior_convex_linear_image)
  2915 
  2915 
  2916 lemma convex_rel_open_scaleR:
  2916 lemma convex_rel_open_scaleR:
  2917   fixes S :: "'n::euclidean_space set"
  2917   fixes S :: "'n::euclidean_space set"
  2918   assumes "convex S"
  2918   assumes "convex S"
  2919     and "rel_open S"
  2919     and "rel_open S"
  2920   shows "convex ((( *\<^sub>R) c) ` S) \<and> rel_open ((( *\<^sub>R) c) ` S)"
  2920   shows "convex (((*\<^sub>R) c) ` S) \<and> rel_open (((*\<^sub>R) c) ` S)"
  2921   by (metis assms convex_scaling rel_interior_convex_scaleR rel_open_def)
  2921   by (metis assms convex_scaling rel_interior_convex_scaleR rel_open_def)
  2922 
  2922 
  2923 lemma convex_rel_open_finite_inter:
  2923 lemma convex_rel_open_finite_inter:
  2924   assumes "\<forall>S\<in>I. convex (S :: 'n::euclidean_space set) \<and> rel_open S"
  2924   assumes "\<forall>S\<in>I. convex (S :: 'n::euclidean_space set) \<and> rel_open S"
  2925     and "finite I"
  2925     and "finite I"
  3084   case True
  3084   case True
  3085   then show ?thesis
  3085   then show ?thesis
  3086     by (simp add: rel_interior_empty cone_0)
  3086     by (simp add: rel_interior_empty cone_0)
  3087 next
  3087 next
  3088   case False
  3088   case False
  3089   then have *: "0 \<in> S \<and> (\<forall>c. c > 0 \<longrightarrow> ( *\<^sub>R) c ` S = S)"
  3089   then have *: "0 \<in> S \<and> (\<forall>c. c > 0 \<longrightarrow> (*\<^sub>R) c ` S = S)"
  3090     using cone_iff[of S] assms by auto
  3090     using cone_iff[of S] assms by auto
  3091   then have *: "0 \<in> ({0} \<union> rel_interior S)"
  3091   then have *: "0 \<in> ({0} \<union> rel_interior S)"
  3092     and "\<forall>c. c > 0 \<longrightarrow> ( *\<^sub>R) c ` ({0} \<union> rel_interior S) = ({0} \<union> rel_interior S)"
  3092     and "\<forall>c. c > 0 \<longrightarrow> (*\<^sub>R) c ` ({0} \<union> rel_interior S) = ({0} \<union> rel_interior S)"
  3093     by (auto simp add: rel_interior_scaleR)
  3093     by (auto simp add: rel_interior_scaleR)
  3094   then show ?thesis
  3094   then show ?thesis
  3095     using cone_iff[of "{0} \<union> rel_interior S"] by auto
  3095     using cone_iff[of "{0} \<union> rel_interior S"] by auto
  3096 qed
  3096 qed
  3097 
  3097 
  3098 lemma rel_interior_convex_cone_aux:
  3098 lemma rel_interior_convex_cone_aux:
  3099   fixes S :: "'m::euclidean_space set"
  3099   fixes S :: "'m::euclidean_space set"
  3100   assumes "convex S"
  3100   assumes "convex S"
  3101   shows "(c, x) \<in> rel_interior (cone hull ({(1 :: real)} \<times> S)) \<longleftrightarrow>
  3101   shows "(c, x) \<in> rel_interior (cone hull ({(1 :: real)} \<times> S)) \<longleftrightarrow>
  3102     c > 0 \<and> x \<in> ((( *\<^sub>R) c) ` (rel_interior S))"
  3102     c > 0 \<and> x \<in> (((*\<^sub>R) c) ` (rel_interior S))"
  3103 proof (cases "S = {}")
  3103 proof (cases "S = {}")
  3104   case True
  3104   case True
  3105   then show ?thesis
  3105   then show ?thesis
  3106     by (simp add: rel_interior_empty cone_hull_empty)
  3106     by (simp add: rel_interior_empty cone_hull_empty)
  3107 next
  3107 next
  3130   then have **: "rel_interior {y. f y \<noteq> {}} = {0<..}"
  3130   then have **: "rel_interior {y. f y \<noteq> {}} = {0<..}"
  3131     using rel_interior_real_semiline by auto
  3131     using rel_interior_real_semiline by auto
  3132   {
  3132   {
  3133     fix c :: real
  3133     fix c :: real
  3134     assume "c > 0"
  3134     assume "c > 0"
  3135     then have "f c = (( *\<^sub>R) c ` S)"
  3135     then have "f c = ((*\<^sub>R) c ` S)"
  3136       using f_def cone_hull_expl[of "{1 :: real} \<times> S"] by auto
  3136       using f_def cone_hull_expl[of "{1 :: real} \<times> S"] by auto
  3137     then have "rel_interior (f c) = ( *\<^sub>R) c ` rel_interior S"
  3137     then have "rel_interior (f c) = (*\<^sub>R) c ` rel_interior S"
  3138       using rel_interior_convex_scaleR[of S c] assms by auto
  3138       using rel_interior_convex_scaleR[of S c] assms by auto
  3139   }
  3139   }
  3140   then show ?thesis using * ** by auto
  3140   then show ?thesis using * ** by auto
  3141 qed
  3141 qed
  3142 
  3142 
  8023       with \<open>span B = U\<close> span_finite [OF \<open>finite B\<close>]
  8023       with \<open>span B = U\<close> span_finite [OF \<open>finite B\<close>]
  8024       obtain u where u: "y = (\<Sum>b\<in>B. u b *\<^sub>R b)"
  8024       obtain u where u: "y = (\<Sum>b\<in>B. u b *\<^sub>R b)"
  8025         by auto
  8025         by auto
  8026       have "b \<bullet> (v - ?u) = 0" if "b \<in> B" for b
  8026       have "b \<bullet> (v - ?u) = 0" if "b \<in> B" for b
  8027         using that \<open>finite B\<close>
  8027         using that \<open>finite B\<close>
  8028         by (simp add: * algebra_simps inner_sum_right if_distrib [of "( *)v" for v] inner_commute cong: if_cong)
  8028         by (simp add: * algebra_simps inner_sum_right if_distrib [of "(*)v" for v] inner_commute cong: if_cong)
  8029       then show "y \<bullet> (v - ?u) = 0"
  8029       then show "y \<bullet> (v - ?u) = 0"
  8030         by (simp add: u inner_sum_left)
  8030         by (simp add: u inner_sum_left)
  8031     qed
  8031     qed
  8032     ultimately have "v \<in> U + U\<^sup>\<bottom>"
  8032     ultimately have "v \<in> U + U\<^sup>\<bottom>"
  8033       using set_plus_intro by fastforce
  8033       using set_plus_intro by fastforce