[STATEMENT]
lemma (in aGroup) nsum_add_nmTr:
  "(\<forall>j \<le> n. f j \<in> carrier A) \<and> (\<forall>j \<le> m. g j \<in> carrier A) \<longrightarrow>
   nsum A (jointfun n f m g) (Suc (n + m)) = (nsum A f n) \<plusminus> (nsum A g m)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>m. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f m g Suc (n + m) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g m
[PROOF STEP]
apply (induct_tac m)
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>0. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f 0 g Suc (n + 0) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g 0
 2. \<And>na. (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f na g Suc (n + na) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na \<Longrightarrow> (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>Suc na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f (Suc na) g Suc (n + Suc na) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g Suc na
[PROOF STEP]
apply (simp add:jointfun_def sliden_def)
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. (\<forall>j\<le>n. f j \<in> carrier A) \<and> g 0 \<in> carrier A \<longrightarrow> \<Sigma>\<^sub>e A (\<lambda>a. if a \<le> n then f a else g (sliden (Suc n) a)) n \<plusminus> g 0 = \<Sigma>\<^sub>e A f n \<plusminus> g 0
 2. \<And>na. (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f na g Suc (n + na) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na \<Longrightarrow> (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>Suc na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f (Suc na) g Suc (n + Suc na) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g Suc na
[PROOF STEP]
apply (rule impI)
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. (\<forall>j\<le>n. f j \<in> carrier A) \<and> g 0 \<in> carrier A \<Longrightarrow> \<Sigma>\<^sub>e A (\<lambda>a. if a \<le> n then f a else g (sliden (Suc n) a)) n \<plusminus> g 0 = \<Sigma>\<^sub>e A f n \<plusminus> g 0
 2. \<And>na. (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f na g Suc (n + na) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na \<Longrightarrow> (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>Suc na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f (Suc na) g Suc (n + Suc na) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g Suc na
[PROOF STEP]
apply (rule ag_pOp_add_r)
[PROOF STATE]
proof (prove)
goal (5 subgoals):
 1. (\<forall>j\<le>n. f j \<in> carrier A) \<and> g 0 \<in> carrier A \<Longrightarrow> \<Sigma>\<^sub>e A (\<lambda>a. if a \<le> n then f a else g (sliden (Suc n) a)) n \<in> carrier A
 2. (\<forall>j\<le>n. f j \<in> carrier A) \<and> g 0 \<in> carrier A \<Longrightarrow> \<Sigma>\<^sub>e A f n \<in> carrier A
 3. (\<forall>j\<le>n. f j \<in> carrier A) \<and> g 0 \<in> carrier A \<Longrightarrow> g 0 \<in> carrier A
 4. (\<forall>j\<le>n. f j \<in> carrier A) \<and> g 0 \<in> carrier A \<Longrightarrow> \<Sigma>\<^sub>e A (\<lambda>a. if a \<le> n then f a else g (sliden (Suc n) a)) n = \<Sigma>\<^sub>e A f n
 5. \<And>na. (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f na g Suc (n + na) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na \<Longrightarrow> (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>Suc na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f (Suc na) g Suc (n + Suc na) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g Suc na
[PROOF STEP]
apply (rule nsum_mem, rule allI, erule conjE, rule impI, simp)
[PROOF STATE]
proof (prove)
goal (4 subgoals):
 1. (\<forall>j\<le>n. f j \<in> carrier A) \<and> g 0 \<in> carrier A \<Longrightarrow> \<Sigma>\<^sub>e A f n \<in> carrier A
 2. (\<forall>j\<le>n. f j \<in> carrier A) \<and> g 0 \<in> carrier A \<Longrightarrow> g 0 \<in> carrier A
 3. (\<forall>j\<le>n. f j \<in> carrier A) \<and> g 0 \<in> carrier A \<Longrightarrow> \<Sigma>\<^sub>e A (\<lambda>a. if a \<le> n then f a else g (sliden (Suc n) a)) n = \<Sigma>\<^sub>e A f n
 4. \<And>na. (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f na g Suc (n + na) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na \<Longrightarrow> (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>Suc na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f (Suc na) g Suc (n + Suc na) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g Suc na
[PROOF STEP]
apply (erule conjE, simp add:nsum_mem, simp)
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. (\<forall>j\<le>n. f j \<in> carrier A) \<and> g 0 \<in> carrier A \<Longrightarrow> \<Sigma>\<^sub>e A (\<lambda>a. if a \<le> n then f a else g (sliden (Suc n) a)) n = \<Sigma>\<^sub>e A f n
 2. \<And>na. (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f na g Suc (n + na) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na \<Longrightarrow> (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>Suc na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f (Suc na) g Suc (n + Suc na) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g Suc na
[PROOF STEP]
apply (rule nsum_eq[of n], simp+)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<And>na. (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f na g (n + na) \<plusminus> jointfun n f na g (Suc (n + na)) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na \<Longrightarrow> (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>Suc na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A jointfun n f (Suc na) g (n + na) \<plusminus> jointfun n f (Suc na) g (Suc (n + na)) \<plusminus> jointfun n f (Suc na) g (Suc (Suc (n + na))) = \<Sigma>\<^sub>e A f n \<plusminus> (\<Sigma>\<^sub>e A g na \<plusminus> g (Suc na))
[PROOF STEP]
apply (simp add:jointfun_def)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<And>na. (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A (\<lambda>i. if i \<le> n then f i else g (sliden (Suc n) i)) (n + na) \<plusminus> g (sliden (Suc n) (Suc (n + na))) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na \<Longrightarrow> (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>Suc na. g j \<in> carrier A) \<longrightarrow> \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na \<plusminus> g (sliden (Suc n) (Suc (Suc (n + na)))) = \<Sigma>\<^sub>e A f n \<plusminus> (\<Sigma>\<^sub>e A g na \<plusminus> g (Suc na))
[PROOF STEP]
apply (rule impI, simp)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<And>na. \<lbrakk>\<Sigma>\<^sub>e A (\<lambda>i. if i \<le> n then f i else g (sliden (Suc n) i)) (n + na) \<plusminus> g (sliden (Suc n) (Suc (n + na))) = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na; (\<forall>j\<le>n. f j \<in> carrier A) \<and> (\<forall>j\<le>Suc na. g j \<in> carrier A)\<rbrakk> \<Longrightarrow> \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na \<plusminus> g (sliden (Suc n) (Suc (Suc (n + na)))) = \<Sigma>\<^sub>e A f n \<plusminus> (\<Sigma>\<^sub>e A g na \<plusminus> g (Suc na))
[PROOF STEP]
apply (erule conjE, simp add:sliden_def)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<And>na. \<lbrakk>\<Sigma>\<^sub>e A (\<lambda>i. if i \<le> n then f i else g (sliden (Suc n) i)) (n + na) \<plusminus> g na = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na; \<forall>j\<le>n. f j \<in> carrier A; \<forall>j\<le>Suc na. g j \<in> carrier A\<rbrakk> \<Longrightarrow> \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na \<plusminus> g (Suc na) = \<Sigma>\<^sub>e A f n \<plusminus> (\<Sigma>\<^sub>e A g na \<plusminus> g (Suc na))
[PROOF STEP]
apply (thin_tac "\<Sigma>\<^sub>e A (\<lambda>i. if i \<le> n then f i else g (sliden (Suc n) i))
        (n + na) \<plusminus> g na = \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na")
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<And>na. \<lbrakk>\<forall>j\<le>n. f j \<in> carrier A; \<forall>j\<le>Suc na. g j \<in> carrier A\<rbrakk> \<Longrightarrow> \<Sigma>\<^sub>e A f n \<plusminus> \<Sigma>\<^sub>e A g na \<plusminus> g (Suc na) = \<Sigma>\<^sub>e A f n \<plusminus> (\<Sigma>\<^sub>e A g na \<plusminus> g (Suc na))
[PROOF STEP]
apply (subst ag_pOp_assoc)
[PROOF STATE]
proof (prove)
goal (4 subgoals):
 1. \<And>na. \<lbrakk>\<forall>j\<le>n. f j \<in> carrier A; \<forall>j\<le>Suc na. g j \<in> carrier A\<rbrakk> \<Longrightarrow> \<Sigma>\<^sub>e A f n \<in> carrier A
 2. \<And>na. \<lbrakk>\<forall>j\<le>n. f j \<in> carrier A; \<forall>j\<le>Suc na. g j \<in> carrier A\<rbrakk> \<Longrightarrow> \<Sigma>\<^sub>e A g na \<in> carrier A
 3. \<And>na. \<lbrakk>\<forall>j\<le>n. f j \<in> carrier A; \<forall>j\<le>Suc na. g j \<in> carrier A\<rbrakk> \<Longrightarrow> g (Suc na) \<in> carrier A
 4. \<And>na. \<lbrakk>\<forall>j\<le>n. f j \<in> carrier A; \<forall>j\<le>Suc na. g j \<in> carrier A\<rbrakk> \<Longrightarrow> \<Sigma>\<^sub>e A f n \<plusminus> (\<Sigma>\<^sub>e A g na \<plusminus> g (Suc na)) = \<Sigma>\<^sub>e A f n \<plusminus> (\<Sigma>\<^sub>e A g na \<plusminus> g (Suc na))
[PROOF STEP]
apply (simp add:nsum_mem)
[PROOF STATE]
proof (prove)
goal (3 subgoals):
 1. \<And>na. \<lbrakk>\<forall>j\<le>n. f j \<in> carrier A; \<forall>j\<le>Suc na. g j \<in> carrier A\<rbrakk> \<Longrightarrow> \<Sigma>\<^sub>e A g na \<in> carrier A
 2. \<And>na. \<lbrakk>\<forall>j\<le>n. f j \<in> carrier A; \<forall>j\<le>Suc na. g j \<in> carrier A\<rbrakk> \<Longrightarrow> g (Suc na) \<in> carrier A
 3. \<And>na. \<lbrakk>\<forall>j\<le>n. f j \<in> carrier A; \<forall>j\<le>Suc na. g j \<in> carrier A\<rbrakk> \<Longrightarrow> \<Sigma>\<^sub>e A f n \<plusminus> (\<Sigma>\<^sub>e A g na \<plusminus> g (Suc na)) = \<Sigma>\<^sub>e A f n \<plusminus> (\<Sigma>\<^sub>e A g na \<plusminus> g (Suc na))
[PROOF STEP]
apply (simp add:nsum_mem, simp)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<And>na. \<lbrakk>\<forall>j\<le>n. f j \<in> carrier A; \<forall>j\<le>Suc na. g j \<in> carrier A\<rbrakk> \<Longrightarrow> \<Sigma>\<^sub>e A f n \<plusminus> (\<Sigma>\<^sub>e A g na \<plusminus> g (Suc na)) = \<Sigma>\<^sub>e A f n \<plusminus> (\<Sigma>\<^sub>e A g na \<plusminus> g (Suc na))
[PROOF STEP]
apply simp
[PROOF STATE]
proof (prove)
goal:
No subgoals!
[PROOF STEP]
done


[STATEMENT]
lemma extended_Gromov_product_boundary_inside_aux:
  assumes "y \<in> Gromov_boundary"
  shows "extended_Gromov_product_at e y (to_Gromov_completion x) = Inf {liminf (\<lambda>n. ereal(Gromov_product_at e (v n) x)) |v. (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. extended_Gromov_product_at e y (to_Gromov_completion x) = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (v n) x)) |v. (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
using extended_Gromov_product_inside_boundary_aux[OF assms]
[PROOF STATE]
proof (prove)
using this:
extended_Gromov_product_at ?e (to_Gromov_completion ?x) y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at ?e ?x (v n))) |v. (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}

goal (1 subgoal):
 1. extended_Gromov_product_at e y (to_Gromov_completion x) = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (v n) x)) |v. (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
by (simp add: extended_Gromov_product_at_commute Gromov_product_commute)


[STATEMENT]
lemma nrows_transpose: "nrows (transpose A) = ncols A"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. nrows (Finite_Cartesian_Product.transpose A) = ncols A
[PROOF STEP]
unfolding nrows_def ncols_def
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. CARD('c) = CARD('c)
[PROOF STEP]
..


[STATEMENT]
lemma find_base_vector_not_1:
    "find_base_vector A \<in> carrier_vec n"
    "find_base_vector A \<noteq> 0\<^sub>v n"
    "A *\<^sub>v find_base_vector A = 0\<^sub>v n"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. find_base_vector A \<in> carrier_vec n &&& find_base_vector A \<noteq> 0\<^sub>v n &&& A *\<^sub>v find_base_vector A = 0\<^sub>v n
[PROOF STEP]
using find_base_vector[OF ref A find_base_vector_not_1_pivot_positions]
[PROOF STATE]
proof (prove)
using this:
find_base_vector A \<in> carrier_vec n
find_base_vector A \<noteq> 0\<^sub>v n
A *\<^sub>v find_base_vector A = 0\<^sub>v n

goal (1 subgoal):
 1. find_base_vector A \<in> carrier_vec n &&& find_base_vector A \<noteq> 0\<^sub>v n &&& A *\<^sub>v find_base_vector A = 0\<^sub>v n
[PROOF STEP]
.


[STATEMENT]
lemma brnL_pickFT_BrnFT[simp]:
assumes "properL cl" and "WtFT cl = 1"
shows "brnL cl (pickFT cl) \<in> BrnFT cl dl"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. brnL cl (pickFT cl) \<in> BrnFT cl dl
[PROOF STEP]
using assms brn_gt_0_L
[PROOF STATE]
proof (prove)
using this:
properL cl
WtFT cl = 1
\<lbrakk>properL ?cl; ?c \<in> set ?cl\<rbrakk> \<Longrightarrow> 0 < brn ?c

goal (1 subgoal):
 1. brnL cl (pickFT cl) \<in> BrnFT cl dl
[PROOF STEP]
unfolding BrnFT_def
[PROOF STATE]
proof (prove)
using this:
properL cl
WtFT cl = 1
\<lbrakk>properL ?cl; ?c \<in> set ?cl\<rbrakk> \<Longrightarrow> 0 < brn ?c

goal (1 subgoal):
 1. brnL cl (pickFT cl) \<in> (\<Union>n\<in>theFTOne cl dl. {brnL cl n..<brnL cl n + brn (cl ! n)})
[PROOF STEP]
by auto


[STATEMENT]
lemma inheritedUNEq[rule_format]:
  "finite A --> inherited subs P --> (!x:A. P (B x)) = P (UN a:A. B a)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. finite A \<longrightarrow> inherited subs P \<longrightarrow> (\<forall>x\<in>A. P (B x)) = P (\<Union> (B ` A))
[PROOF STEP]
apply(intro impI)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>finite A; inherited subs P\<rbrakk> \<Longrightarrow> (\<forall>x\<in>A. P (B x)) = P (\<Union> (B ` A))
[PROOF STEP]
apply(erule finite_induct)
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. inherited subs P \<Longrightarrow> (\<forall>x\<in>{}. P (B x)) = P (\<Union> (B ` {}))
 2. \<And>x F. \<lbrakk>inherited subs P; finite F; x \<notin> F; (\<forall>x\<in>F. P (B x)) = P (\<Union> (B ` F))\<rbrakk> \<Longrightarrow> (\<forall>x\<in>insert x F. P (B x)) = P (\<Union> (B ` insert x F))
[PROOF STEP]
apply simp
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. inherited subs P \<Longrightarrow> P {}
 2. \<And>x F. \<lbrakk>inherited subs P; finite F; x \<notin> F; (\<forall>x\<in>F. P (B x)) = P (\<Union> (B ` F))\<rbrakk> \<Longrightarrow> (\<forall>x\<in>insert x F. P (B x)) = P (\<Union> (B ` insert x F))
[PROOF STEP]
apply(simp add: inheritedEmpty)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<And>x F. \<lbrakk>inherited subs P; finite F; x \<notin> F; (\<forall>x\<in>F. P (B x)) = P (\<Union> (B ` F))\<rbrakk> \<Longrightarrow> (\<forall>x\<in>insert x F. P (B x)) = P (\<Union> (B ` insert x F))
[PROOF STEP]
apply(force dest: inheritedUnEq)
[PROOF STATE]
proof (prove)
goal:
No subgoals!
[PROOF STEP]
done


[STATEMENT]
lemma eventually_nhds_top:
  fixes P :: "'a :: {order_top,linorder_topology} \<Rightarrow> bool"
    and b :: 'a
  assumes "b < top"
  shows "eventually P (nhds top) \<longleftrightarrow> (\<exists>b<top. (\<forall>z. b < z \<longrightarrow> P z))"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. eventually P (nhds top) = (\<exists>b<top. \<forall>z>b. P z)
[PROOF STEP]
unfolding eventually_nhds
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<exists>S. open S \<and> top \<in> S \<and> Ball S P) = (\<exists>b<top. \<forall>z>b. P z)
[PROOF STEP]
proof safe
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. \<And>S. \<lbrakk>open S; top \<in> S; Ball S P\<rbrakk> \<Longrightarrow> \<exists>b<top. \<forall>z>b. P z
 2. \<And>b. \<lbrakk>b < top; \<forall>z>b. P z\<rbrakk> \<Longrightarrow> \<exists>S. open S \<and> top \<in> S \<and> Ball S P
[PROOF STEP]
fix S :: "'a set"
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. \<And>S. \<lbrakk>open S; top \<in> S; Ball S P\<rbrakk> \<Longrightarrow> \<exists>b<top. \<forall>z>b. P z
 2. \<And>b. \<lbrakk>b < top; \<forall>z>b. P z\<rbrakk> \<Longrightarrow> \<exists>S. open S \<and> top \<in> S \<and> Ball S P
[PROOF STEP]
assume "open S" "top \<in> S"
[PROOF STATE]
proof (state)
this:
open S
top \<in> S

goal (2 subgoals):
 1. \<And>S. \<lbrakk>open S; top \<in> S; Ball S P\<rbrakk> \<Longrightarrow> \<exists>b<top. \<forall>z>b. P z
 2. \<And>b. \<lbrakk>b < top; \<forall>z>b. P z\<rbrakk> \<Longrightarrow> \<exists>S. open S \<and> top \<in> S \<and> Ball S P
[PROOF STEP]
note open_left[OF this \<open>b < top\<close>]
[PROOF STATE]
proof (state)
this:
\<exists>b<top. {b<..top} \<subseteq> S

goal (2 subgoals):
 1. \<And>S. \<lbrakk>open S; top \<in> S; Ball S P\<rbrakk> \<Longrightarrow> \<exists>b<top. \<forall>z>b. P z
 2. \<And>b. \<lbrakk>b < top; \<forall>z>b. P z\<rbrakk> \<Longrightarrow> \<exists>S. open S \<and> top \<in> S \<and> Ball S P
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
\<exists>b<top. {b<..top} \<subseteq> S

goal (2 subgoals):
 1. \<And>S. \<lbrakk>open S; top \<in> S; Ball S P\<rbrakk> \<Longrightarrow> \<exists>b<top. \<forall>z>b. P z
 2. \<And>b. \<lbrakk>b < top; \<forall>z>b. P z\<rbrakk> \<Longrightarrow> \<exists>S. open S \<and> top \<in> S \<and> Ball S P
[PROOF STEP]
assume "\<forall>s\<in>S. P s"
[PROOF STATE]
proof (state)
this:
\<forall>s\<in>S. P s

goal (2 subgoals):
 1. \<And>S. \<lbrakk>open S; top \<in> S; Ball S P\<rbrakk> \<Longrightarrow> \<exists>b<top. \<forall>z>b. P z
 2. \<And>b. \<lbrakk>b < top; \<forall>z>b. P z\<rbrakk> \<Longrightarrow> \<exists>S. open S \<and> top \<in> S \<and> Ball S P
[PROOF STEP]
ultimately
[PROOF STATE]
proof (chain)
picking this:
\<exists>b<top. {b<..top} \<subseteq> S
\<forall>s\<in>S. P s
[PROOF STEP]
show "\<exists>b<top. \<forall>z>b. P z"
[PROOF STATE]
proof (prove)
using this:
\<exists>b<top. {b<..top} \<subseteq> S
\<forall>s\<in>S. P s

goal (1 subgoal):
 1. \<exists>b<top. \<forall>z>b. P z
[PROOF STEP]
by (auto simp: subset_eq Ball_def)
[PROOF STATE]
proof (state)
this:
\<exists>b<top. \<forall>z>b. P z

goal (1 subgoal):
 1. \<And>b. \<lbrakk>b < top; \<forall>z>b. P z\<rbrakk> \<Longrightarrow> \<exists>S. open S \<and> top \<in> S \<and> Ball S P
[PROOF STEP]
next
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>b. \<lbrakk>b < top; \<forall>z>b. P z\<rbrakk> \<Longrightarrow> \<exists>S. open S \<and> top \<in> S \<and> Ball S P
[PROOF STEP]
fix b
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>b. \<lbrakk>b < top; \<forall>z>b. P z\<rbrakk> \<Longrightarrow> \<exists>S. open S \<and> top \<in> S \<and> Ball S P
[PROOF STEP]
assume "b < top" "\<forall>z>b. P z"
[PROOF STATE]
proof (state)
this:
b < top
\<forall>z>b. P z

goal (1 subgoal):
 1. \<And>b. \<lbrakk>b < top; \<forall>z>b. P z\<rbrakk> \<Longrightarrow> \<exists>S. open S \<and> top \<in> S \<and> Ball S P
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
b < top
\<forall>z>b. P z
[PROOF STEP]
show "\<exists>S. open S \<and> top \<in> S \<and> (\<forall>xa\<in>S. P xa)"
[PROOF STATE]
proof (prove)
using this:
b < top
\<forall>z>b. P z

goal (1 subgoal):
 1. \<exists>S. open S \<and> top \<in> S \<and> (\<forall>xa\<in>S. P xa)
[PROOF STEP]
by (intro exI[of _ "{b <..}"]) auto
[PROOF STATE]
proof (state)
this:
\<exists>S. open S \<and> top \<in> S \<and> (\<forall>xa\<in>S. P xa)

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma bv_slice_length [simp]: "[| j \<le> i; i < length w |] ==> length (bv_slice w (i,j)) = i - j + 1"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>j \<le> i; i < length w\<rbrakk> \<Longrightarrow> length (bv_slice w (i, j)) = i - j + 1
[PROOF STEP]
by (auto simp add: bv_slice_def)


[STATEMENT]
lemma Red_I_Sup_subset_Red_I_Liminf:
  "chain (\<rhd>) Ns \<Longrightarrow> Red_I (Sup_llist Ns) \<subseteq> Red_I (Liminf_llist Ns)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. chain (\<rhd>) Ns \<Longrightarrow> Red_I (Sup_llist Ns) \<subseteq> Red_I (Liminf_llist Ns)
[PROOF STEP]
by (metis Liminf_llist_subset_Sup_llist Red_I_of_Red_F_subset Red_in_Sup double_diff subset_refl)


[STATEMENT]
lemma aligned_add_xor:
  \<open>(x + 2 ^ n) XOR 2 ^ n = x\<close>
  if al: \<open>is_aligned (x::'a::len word) n'\<close> and le: \<open>n < n'\<close>
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. x + 2 ^ n XOR 2 ^ n = x
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. x + 2 ^ n XOR 2 ^ n = x
[PROOF STEP]
have \<open>\<not> bit x n\<close>
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<not> bit x n
[PROOF STEP]
using that
[PROOF STATE]
proof (prove)
using this:
is_aligned x n'
n < n'

goal (1 subgoal):
 1. \<not> bit x n
[PROOF STEP]
by (rule is_aligned_imp_not_bit)
[PROOF STATE]
proof (state)
this:
\<not> bit x n

goal (1 subgoal):
 1. x + 2 ^ n XOR 2 ^ n = x
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
\<not> bit x n
[PROOF STEP]
have \<open>x + 2 ^ n = x OR 2 ^ n\<close>
[PROOF STATE]
proof (prove)
using this:
\<not> bit x n

goal (1 subgoal):
 1. x + 2 ^ n = x OR 2 ^ n
[PROOF STEP]
by (subst disjunctive_add) (auto simp add: bit_simps disjunctive_add)
[PROOF STATE]
proof (state)
this:
x + 2 ^ n = x OR 2 ^ n

goal (1 subgoal):
 1. x + 2 ^ n XOR 2 ^ n = x
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
x + 2 ^ n = x OR 2 ^ n

goal (1 subgoal):
 1. x + 2 ^ n XOR 2 ^ n = x
[PROOF STEP]
have \<open>(x OR 2 ^ n) XOR 2 ^ n = x\<close>
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (x OR 2 ^ n) XOR 2 ^ n = x
[PROOF STEP]
by (rule bit_word_eqI) (auto simp add: bit_simps \<open>\<not> bit x n\<close>)
[PROOF STATE]
proof (state)
this:
(x OR 2 ^ n) XOR 2 ^ n = x

goal (1 subgoal):
 1. x + 2 ^ n XOR 2 ^ n = x
[PROOF STEP]
ultimately
[PROOF STATE]
proof (chain)
picking this:
x + 2 ^ n = x OR 2 ^ n
(x OR 2 ^ n) XOR 2 ^ n = x
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
x + 2 ^ n = x OR 2 ^ n
(x OR 2 ^ n) XOR 2 ^ n = x

goal (1 subgoal):
 1. x + 2 ^ n XOR 2 ^ n = x
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
x + 2 ^ n XOR 2 ^ n = x

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma assertion_fun_disj_less_one: "assertion_fun = Apply.disjunctive \<inter> {x::'a::boolean_algebra \<Rightarrow> 'a . x \<le> id}"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. assertion_fun = Apply.disjunctive \<inter> {x. x \<le> id}
[PROOF STEP]
apply safe
[PROOF STATE]
proof (prove)
goal (3 subgoals):
 1. \<And>x. x \<in> assertion_fun \<Longrightarrow> x \<in> Apply.disjunctive
 2. \<And>x. x \<in> assertion_fun \<Longrightarrow> x \<le> id
 3. \<And>x. \<lbrakk>x \<in> Apply.disjunctive; x \<le> id\<rbrakk> \<Longrightarrow> x \<in> assertion_fun
[PROOF STEP]
apply (simp_all add: assertion_fun_def, auto simp add: image_def)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<And>x. \<lbrakk>x \<in> Apply.disjunctive; x \<le> id\<rbrakk> \<Longrightarrow> \<exists>xa. x = assert_fun xa
[PROOF STEP]
apply (rule_tac x = "x \<top>" in exI)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<And>x. \<lbrakk>x \<in> Apply.disjunctive; x \<le> id\<rbrakk> \<Longrightarrow> x = assert_fun (x \<top>)
[PROOF STEP]
by (rule assert_cont, simp_all)


[STATEMENT]
lemma float_divr_nonneg_neg_upper_bound:
  "0 \<le> real_of_float x \<Longrightarrow> real_of_float y \<le> 0 \<Longrightarrow> real_of_float (float_divr prec x y) \<le> 0"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>0 \<le> real_of_float x; real_of_float y \<le> 0\<rbrakk> \<Longrightarrow> real_of_float (float_divr prec x y) \<le> 0
[PROOF STEP]
by transfer (rule real_divr_nonneg_neg_upper_bound)


[STATEMENT]
lemma Im_sum [simp]:
  \<open>Im (sum f s) = (\<Sum>x\<in>s. Im (f x))\<close>
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. Im (sum f s) = (\<Sum>x\<in>s. Im (f x))
[PROOF STEP]
by (induct s rule: infinite_finite_induct) auto


[STATEMENT]
lemma is_hom_GB_boundD:
  "is_hom_GB_bound F b \<Longrightarrow> (\<And>f. f \<in> F \<Longrightarrow> homogeneous f) \<Longrightarrow> g \<in> punit.reduced_GB F \<Longrightarrow> poly_deg g \<le> b"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>is_hom_GB_bound F b; \<And>f. f \<in> F \<Longrightarrow> homogeneous f; g \<in> punit.reduced_GB F\<rbrakk> \<Longrightarrow> poly_deg g \<le> b
[PROOF STEP]
unfolding is_hom_GB_bound_def
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>Ball F homogeneous \<longrightarrow> (\<forall>g\<in>punit.reduced_GB F. poly_deg g \<le> b); \<And>f. f \<in> F \<Longrightarrow> homogeneous f; g \<in> punit.reduced_GB F\<rbrakk> \<Longrightarrow> poly_deg g \<le> b
[PROOF STEP]
by blast


[STATEMENT]
lemma isom_tgch_unitsTr0_3:"\<lbrakk>Ugp E; Gchain (Suc n) g; \<not> g (Suc n) \<cong> E\<rbrakk>
      \<Longrightarrow> {i. i \<le> (Suc n) \<and> g i \<cong> E} = {i. i \<le> n \<and> g i \<cong> E}"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>Ugp E; Gchain (Suc n) g; \<not> g (Suc n) \<cong> E\<rbrakk> \<Longrightarrow> {i. i \<le> Suc n \<and> g i \<cong> E} = {i. i \<le> n \<and> g i \<cong> E}
[PROOF STEP]
apply (rule equalityI)
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. \<lbrakk>Ugp E; Gchain (Suc n) g; \<not> g (Suc n) \<cong> E\<rbrakk> \<Longrightarrow> {i. i \<le> Suc n \<and> g i \<cong> E} \<subseteq> {i. i \<le> n \<and> g i \<cong> E}
 2. \<lbrakk>Ugp E; Gchain (Suc n) g; \<not> g (Suc n) \<cong> E\<rbrakk> \<Longrightarrow> {i. i \<le> n \<and> g i \<cong> E} \<subseteq> {i. i \<le> Suc n \<and> g i \<cong> E}
[PROOF STEP]
apply (rule subsetI, simp add:CollectI)
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. \<And>x. \<lbrakk>Ugp E; Gchain (Suc n) g; \<not> g (Suc n) \<cong> E; x \<le> Suc n \<and> g x \<cong> E\<rbrakk> \<Longrightarrow> x \<le> n
 2. \<lbrakk>Ugp E; Gchain (Suc n) g; \<not> g (Suc n) \<cong> E\<rbrakk> \<Longrightarrow> {i. i \<le> n \<and> g i \<cong> E} \<subseteq> {i. i \<le> Suc n \<and> g i \<cong> E}
[PROOF STEP]
apply (case_tac "x = Suc n", simp, erule conjE)
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. \<And>x. \<lbrakk>Ugp E; Gchain (Suc n) g; \<not> g (Suc n) \<cong> E; x \<noteq> Suc n; x \<le> Suc n; g x \<cong> E\<rbrakk> \<Longrightarrow> x \<le> n
 2. \<lbrakk>Ugp E; Gchain (Suc n) g; \<not> g (Suc n) \<cong> E\<rbrakk> \<Longrightarrow> {i. i \<le> n \<and> g i \<cong> E} \<subseteq> {i. i \<le> Suc n \<and> g i \<cong> E}
[PROOF STEP]
apply arith
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>Ugp E; Gchain (Suc n) g; \<not> g (Suc n) \<cong> E\<rbrakk> \<Longrightarrow> {i. i \<le> n \<and> g i \<cong> E} \<subseteq> {i. i \<le> Suc n \<and> g i \<cong> E}
[PROOF STEP]
apply (rule subsetI, simp add:CollectI)
[PROOF STATE]
proof (prove)
goal:
No subgoals!
[PROOF STEP]
done


[STATEMENT]
lemma  cross_basis_nonzero:
  "u \<noteq> 0 \<Longrightarrow> u \<times> axis 1 1 \<noteq> 0 \<or> u \<times> axis 2 1 \<noteq> 0 \<or> u \<times> axis 3 1 \<noteq> 0"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. u \<noteq> 0 \<Longrightarrow> u \<times> axis 1 1 \<noteq> 0 \<or> u \<times> axis 2 1 \<noteq> 0 \<or> u \<times> axis 3 1 \<noteq> 0
[PROOF STEP]
by (clarsimp simp add: axis_def cross3_simps) (metis exhaust_3)


[STATEMENT]
lemma rel_list_all2_Cons [iff]:
  "list_all2 (fun_of S) (x#xs) (y#ys) =
   ((x,y) \<in> S \<and> list_all2 (fun_of S) xs ys)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. list_all2 (fun_of S) (x # xs) (y # ys) = ((x, y) \<in> S \<and> list_all2 (fun_of S) xs ys)
[PROOF STEP]
(*<*)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. list_all2 (fun_of S) (x # xs) (y # ys) = ((x, y) \<in> S \<and> list_all2 (fun_of S) xs ys)
[PROOF STEP]
by simp


[STATEMENT]
lemma n_anti_iff: "n x \<le> n y \<longleftrightarrow> t y \<le> t x"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (!x \<le> !y) = (t y \<le> t x)
[PROOF STEP]
using n_anti
[PROOF STATE]
proof (prove)
using this:
!?x \<le> !?y \<Longrightarrow> t ?y \<le> t ?x

goal (1 subgoal):
 1. (!x \<le> !y) = (t y \<le> t x)
[PROOF STEP]
by fastforce


[STATEMENT]
lemma enumerateE:
  assumes "finite A"
  assumes "a \<in> A"
  shows "\<exists> i < card A. a = (enumerate A) i"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<exists>i<card A. a = Generated_Boolean_Algebra.enumerate A i
[PROOF STEP]
using  enumerate_enumerates[of A] enumeratesE[of A] assms
[PROOF STATE]
proof (prove)
using this:
finite A \<Longrightarrow> enumerates A (Generated_Boolean_Algebra.enumerate A)
enumerates A ?f \<Longrightarrow> finite A
enumerates A ?f \<Longrightarrow> A = ?f ` {..<card A}
enumerates A ?f \<Longrightarrow> inj_on ?f {..<card A}
finite A
a \<in> A

goal (1 subgoal):
 1. \<exists>i<card A. a = Generated_Boolean_Algebra.enumerate A i
[PROOF STEP]
by blast


[STATEMENT]
lemma class_linorder_compare: "class.linorder (le_of_comp compare) (lt_of_comp compare)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. class.linorder (le_of_comp compare) (lt_of_comp compare)
[PROOF STEP]
apply standard
[PROOF STATE]
proof (prove)
goal (5 subgoals):
 1. \<And>x y. lt_of_comp compare x y = strict (le_of_comp compare) x y
 2. \<And>x. le_of_comp compare x x
 3. \<And>x y z. \<lbrakk>le_of_comp compare x y; le_of_comp compare y z\<rbrakk> \<Longrightarrow> le_of_comp compare x z
 4. \<And>x y. \<lbrakk>le_of_comp compare x y; le_of_comp compare y x\<rbrakk> \<Longrightarrow> x = y
 5. \<And>x y. le_of_comp compare x y \<or> le_of_comp compare y x
[PROOF STEP]
apply (simp_all add: lt_of_comp_def le_of_comp_def split: order.splits)
[PROOF STATE]
proof (prove)
goal (4 subgoals):
 1. \<And>x y. compare y x = Lt \<longrightarrow> compare x y \<noteq> Lt
 2. \<And>x y z. \<lbrakk>compare x y = Lt; compare y z = Lt\<rbrakk> \<Longrightarrow> compare x z \<noteq> Gt
 3. \<And>x y. \<lbrakk>compare x y = Lt; compare y x = Lt\<rbrakk> \<Longrightarrow> x = y
 4. \<And>x y. compare x y = Gt \<longrightarrow> compare y x \<noteq> Gt
[PROOF STEP]
apply (metis comparator.sym comparator_compare invert_order.simps(1) order.distinct(5))
[PROOF STATE]
proof (prove)
goal (3 subgoals):
 1. \<And>x y z. \<lbrakk>compare x y = Lt; compare y z = Lt\<rbrakk> \<Longrightarrow> compare x z \<noteq> Gt
 2. \<And>x y. \<lbrakk>compare x y = Lt; compare y x = Lt\<rbrakk> \<Longrightarrow> x = y
 3. \<And>x y. compare x y = Gt \<longrightarrow> compare y x \<noteq> Gt
[PROOF STEP]
apply (metis comparator_compare comparator_def order.distinct(5))
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. \<And>x y. \<lbrakk>compare x y = Lt; compare y x = Lt\<rbrakk> \<Longrightarrow> x = y
 2. \<And>x y. compare x y = Gt \<longrightarrow> compare y x \<noteq> Gt
[PROOF STEP]
apply (metis comparator.sym comparator_compare invert_order.simps(1) order.distinct(5))
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<And>x y. compare x y = Gt \<longrightarrow> compare y x \<noteq> Gt
[PROOF STEP]
by (metis comparator.sym comparator_compare invert_order.simps(2) order.distinct(5))


[STATEMENT]
lemma ord_option_Some1_iff: "ord_option R (Some a) y \<longleftrightarrow> (\<exists>b. y = Some b \<and> R a b)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. ord_option R (Some a) y = (\<exists>b. y = Some b \<and> R a b)
[PROOF STEP]
by (cases y; auto)


[STATEMENT]
lemma evalid_def2: "\<Turnstile>\<^sub>e {P} e {Q} = (\<forall>n. \<Turnstile>n:\<^sub>e (P,e,Q))"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<Turnstile>\<^sub>e {P} e {Q} = (\<forall>n. \<Turnstile>n:\<^sub>e (P, e, Q))
[PROOF STEP]
apply (simp add: evalid_def envalid_def2)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<forall>s. P s \<longrightarrow> (\<forall>v t. (\<exists>n. s -e\<succ>v-n\<rightarrow> t) \<longrightarrow> Q v t)) = (\<forall>n s v t. s -e\<succ>v-n\<rightarrow> t \<longrightarrow> P s \<longrightarrow> Q v t)
[PROOF STEP]
apply blast
[PROOF STATE]
proof (prove)
goal:
No subgoals!
[PROOF STEP]
done


[STATEMENT]
lemma sets_distinct5: "(s::int) < g \<Longrightarrow> {(a::int, b::int). a = s} \<noteq> {(a::int, b::int).  g < a}"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. s < g \<Longrightarrow> {(a, b). a = s} \<noteq> {(a, b). g < a}
[PROOF STEP]
apply (auto simp: sets_distinct3)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>s < g; {(a, b). a = s} = {(a, b). g < a}\<rbrakk> \<Longrightarrow> False
[PROOF STEP]
apply (subgoal_tac "(s,4) \<in> {(a::int,b::int). a = (s)}")
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. \<lbrakk>s < g; {(a, b). a = s} = {(a, b). g < a}; (s, 4) \<in> {(a, b). a = s}\<rbrakk> \<Longrightarrow> False
 2. \<lbrakk>s < g; {(a, b). a = s} = {(a, b). g < a}\<rbrakk> \<Longrightarrow> (s, 4) \<in> {(a, b). a = s}
[PROOF STEP]
apply (subgoal_tac "(s,4) \<notin> {(a::int,b::int). g < a}")
[PROOF STATE]
proof (prove)
goal (3 subgoals):
 1. \<lbrakk>s < g; {(a, b). a = s} = {(a, b). g < a}; (s, 4) \<in> {(a, b). a = s}; (s, 4) \<notin> {(a, b). g < a}\<rbrakk> \<Longrightarrow> False
 2. \<lbrakk>s < g; {(a, b). a = s} = {(a, b). g < a}; (s, 4) \<in> {(a, b). a = s}\<rbrakk> \<Longrightarrow> (s, 4) \<notin> {(a, b). g < a}
 3. \<lbrakk>s < g; {(a, b). a = s} = {(a, b). g < a}\<rbrakk> \<Longrightarrow> (s, 4) \<in> {(a, b). a = s}
[PROOF STEP]
apply (erule aux)
[PROOF STATE]
proof (prove)
goal (4 subgoals):
 1. \<lbrakk>s < g; {(a, b). a = s} = {(a, b). g < a}; (s, 4) \<notin> {(a, b). g < a}\<rbrakk> \<Longrightarrow> (s, 4) \<notin> ?d3
 2. \<lbrakk>s < g; {(a, b). a = s} = {(a, b). g < a}; (s, 4) \<notin> {(a, b). g < a}\<rbrakk> \<Longrightarrow> {(a, b). a = s} = ?d3
 3. \<lbrakk>s < g; {(a, b). a = s} = {(a, b). g < a}; (s, 4) \<in> {(a, b). a = s}\<rbrakk> \<Longrightarrow> (s, 4) \<notin> {(a, b). g < a}
 4. \<lbrakk>s < g; {(a, b). a = s} = {(a, b). g < a}\<rbrakk> \<Longrightarrow> (s, 4) \<in> {(a, b). a = s}
[PROOF STEP]
apply assumption+
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. \<lbrakk>s < g; {(a, b). a = s} = {(a, b). g < a}; (s, 4) \<in> {(a, b). a = s}\<rbrakk> \<Longrightarrow> (s, 4) \<notin> {(a, b). g < a}
 2. \<lbrakk>s < g; {(a, b). a = s} = {(a, b). g < a}\<rbrakk> \<Longrightarrow> (s, 4) \<in> {(a, b). a = s}
[PROOF STEP]
apply simp
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>s < g; {(a, b). a = s} = {(a, b). g < a}\<rbrakk> \<Longrightarrow> (s, 4) \<in> {(a, b). a = s}
[PROOF STEP]
by blast


[STATEMENT]
lemma connected_component_sym_eq: "connected_component S x y \<longleftrightarrow> connected_component S y x"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. connected_component S x y = connected_component S y x
[PROOF STEP]
using connected_component_sym
[PROOF STATE]
proof (prove)
using this:
connected_component ?S ?x ?y \<Longrightarrow> connected_component ?S ?y ?x

goal (1 subgoal):
 1. connected_component S x y = connected_component S y x
[PROOF STEP]
by blast


[STATEMENT]
lemma strict_ex_refine_lemma:
     "strict_ex_prop X
      ==> (\<forall>H. F ok H & G ok H & F\<squnion>H \<in> X --> G\<squnion>H \<in> X)
              = (F \<in> X --> G \<in> X)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. strict_ex_prop X \<Longrightarrow> (\<forall>H. F ok H \<and> G ok H \<and> F \<squnion> H \<in> X \<longrightarrow> G \<squnion> H \<in> X) = (F \<in> X \<longrightarrow> G \<in> X)
[PROOF STEP]
by (unfold strict_ex_prop_def, auto)