[STATEMENT]
lemma inf_less_eq_cases_3:
  "-y \<sqinter> -x \<le> -z \<sqinter> -x \<Longrightarrow> -y \<sqinter> --x \<le> -z \<sqinter> --x \<Longrightarrow> -y \<le> -z"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>- y \<sqinter> - x \<le> - z \<sqinter> - x; - y \<sqinter> - - x \<le> - z \<sqinter> - - x\<rbrakk> \<Longrightarrow> - y \<le> - z
[PROOF STEP]
by (simp add: inf_commutative inf_less_eq_cases_2)


[STATEMENT]
lemma foldr_conv_foldl: \<comment> \<open>The ``Third Duality Theorem'' in Bird \& Wadler:\<close>
  "foldr f xs a = foldl (\<lambda>x y. f y x) a (rev xs)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. foldr f xs a = foldl (\<lambda>x y. f y x) a (rev xs)
[PROOF STEP]
by (simp add: foldr_conv_fold foldl_conv_fold)


[STATEMENT]
lemma in_var_plus [simp]: "in_var (x +\<^sub>L y) = in_var x +\<^sub>L in_var y"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. in_var (x +\<^sub>L y) = in_var x +\<^sub>L in_var y
[PROOF STEP]
by (simp add: in_var_def)


[STATEMENT]
lemma coeff_gt_degree_eq_0:
  assumes "Poly_Mapping.lookup m i > MPoly_Type.degree p i"
  shows   "MPoly_Type.coeff p m = 0"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. MPoly_Type.coeff p m = (0::'a)
[PROOF STEP]
using assms degree_geI leD
[PROOF STATE]
proof (prove)
using this:
MPoly_Type.degree p i < lookup m i
MPoly_Type.coeff ?p ?m \<noteq> (0::?'a) \<Longrightarrow> lookup ?m ?i \<le> MPoly_Type.degree ?p ?i
?y \<le> ?x \<Longrightarrow> \<not> ?x < ?y

goal (1 subgoal):
 1. MPoly_Type.coeff p m = (0::'a)
[PROOF STEP]
by blast


[STATEMENT]
lemma cnj_inverse [simp]: "cnj (inverse x) = inverse (cnj x)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. Quaternions.cnj (inverse x) = inverse (Quaternions.cnj x)
[PROOF STEP]
by (simp add: quat_eq_iff)


[STATEMENT]
lemma size_union [simp]: "size (M + N::'a multiset) = size M + size N"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. size (M + N) = size M + size N
[PROOF STEP]
by (auto simp add: size_multiset_overloaded_def)


[STATEMENT]
lemma rtlE:
  fixes L :: "'L tree set"
  assumes A: "L\<in>regular_languages A"
  obtains TA::"(nat,'L) tree_automaton_rec" where
    "L=ta_lang TA"
    "ranked_tree_automaton TA A"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<And>TA. \<lbrakk>L = ta_lang TA; ranked_tree_automaton TA A\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
using A that
[PROOF STATE]
proof (prove)
using this:
L \<in> regular_languages A
\<lbrakk>L = ta_lang ?TA; ranked_tree_automaton ?TA A\<rbrakk> \<Longrightarrow> thesis

goal (1 subgoal):
 1. (\<And>TA. \<lbrakk>L = ta_lang TA; ranked_tree_automaton TA A\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
by (unfold regular_languages_def) blast


[STATEMENT]
lemma infsetsum_swap:
  fixes A :: "'a set" and B :: "'b set"
  fixes f :: "'a \<Rightarrow> 'b \<Rightarrow> 'c :: {banach, second_countable_topology}"
  assumes [simp]: "countable A" and [simp]: "countable B"
  assumes summable: "(\<lambda>(x,y). f x y) abs_summable_on A \<times> B"
  shows   "infsetsum (\<lambda>x. infsetsum (\<lambda>y. f x y) B) A = infsetsum (\<lambda>y. infsetsum (\<lambda>x. f x y) A) B"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. (\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)
[PROOF STEP]
from summable
[PROOF STATE]
proof (chain)
picking this:
(\<lambda>(x, y). f x y) abs_summable_on A \<times> B
[PROOF STEP]
have summable': "(\<lambda>(x,y). f y x) abs_summable_on B \<times> A"
[PROOF STATE]
proof (prove)
using this:
(\<lambda>(x, y). f x y) abs_summable_on A \<times> B

goal (1 subgoal):
 1. (\<lambda>(x, y). f y x) abs_summable_on B \<times> A
[PROOF STEP]
by (subst abs_summable_on_Times_swap) auto
[PROOF STATE]
proof (state)
this:
(\<lambda>(x, y). f y x) abs_summable_on B \<times> A

goal (1 subgoal):
 1. (\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)
[PROOF STEP]
have bij: "bij_betw (\<lambda>(x, y). (y, x)) (B \<times> A) (A \<times> B)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. bij_betw (\<lambda>(x, y). (y, x)) (B \<times> A) (A \<times> B)
[PROOF STEP]
by (auto simp: bij_betw_def inj_on_def)
[PROOF STATE]
proof (state)
this:
bij_betw (\<lambda>(x, y). (y, x)) (B \<times> A) (A \<times> B)

goal (1 subgoal):
 1. (\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)
[PROOF STEP]
have "infsetsum (\<lambda>x. infsetsum (\<lambda>y. f x y) B) A = infsetsum (\<lambda>(x,y). f x y) (A \<times> B)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>a(x, y)\<in>A \<times> B. f x y)
[PROOF STEP]
using summable
[PROOF STATE]
proof (prove)
using this:
(\<lambda>(x, y). f x y) abs_summable_on A \<times> B

goal (1 subgoal):
 1. (\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>a(x, y)\<in>A \<times> B. f x y)
[PROOF STEP]
by (subst infsetsum_Times) auto
[PROOF STATE]
proof (state)
this:
(\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>a(x, y)\<in>A \<times> B. f x y)

goal (1 subgoal):
 1. (\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
(\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>a(x, y)\<in>A \<times> B. f x y)

goal (1 subgoal):
 1. (\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)
[PROOF STEP]
have "\<dots> = infsetsum (\<lambda>(x,y). f y x) (B \<times> A)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<Sum>\<^sub>a(x, y)\<in>A \<times> B. f x y) = (\<Sum>\<^sub>a(x, y)\<in>B \<times> A. f y x)
[PROOF STEP]
by (subst infsetsum_reindex_bij_betw[OF bij, of "\<lambda>(x,y). f x y", symmetric])
       (simp_all add: case_prod_unfold)
[PROOF STATE]
proof (state)
this:
(\<Sum>\<^sub>a(x, y)\<in>A \<times> B. f x y) = (\<Sum>\<^sub>a(x, y)\<in>B \<times> A. f y x)

goal (1 subgoal):
 1. (\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
(\<Sum>\<^sub>a(x, y)\<in>A \<times> B. f x y) = (\<Sum>\<^sub>a(x, y)\<in>B \<times> A. f y x)

goal (1 subgoal):
 1. (\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)
[PROOF STEP]
have "\<dots> = infsetsum (\<lambda>y. infsetsum (\<lambda>x. f x y) A) B"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<Sum>\<^sub>a(x, y)\<in>B \<times> A. f y x) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)
[PROOF STEP]
using summable'
[PROOF STATE]
proof (prove)
using this:
(\<lambda>(x, y). f y x) abs_summable_on B \<times> A

goal (1 subgoal):
 1. (\<Sum>\<^sub>a(x, y)\<in>B \<times> A. f y x) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)
[PROOF STEP]
by (subst infsetsum_Times) auto
[PROOF STATE]
proof (state)
this:
(\<Sum>\<^sub>a(x, y)\<in>B \<times> A. f y x) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)

goal (1 subgoal):
 1. (\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)
[PROOF STEP]
finally
[PROOF STATE]
proof (chain)
picking this:
(\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
(\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)

goal (1 subgoal):
 1. (\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)
[PROOF STEP]
.
[PROOF STATE]
proof (state)
this:
(\<Sum>\<^sub>ax\<in>A. infsetsum (f x) B) = (\<Sum>\<^sub>ay\<in>B. \<Sum>\<^sub>ax\<in>A. f x y)

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma Lim_topological:
  "(f \<longlongrightarrow> l) net \<longleftrightarrow>
    trivial_limit net \<or> (\<forall>S. open S \<longrightarrow> l \<in> S \<longrightarrow> eventually (\<lambda>x. f x \<in> S) net)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (f \<longlongrightarrow> l) net = (net = bot \<or> (\<forall>S. open S \<longrightarrow> l \<in> S \<longrightarrow> (\<forall>\<^sub>F x in net. f x \<in> S)))
[PROOF STEP]
unfolding tendsto_def trivial_limit_eq
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<forall>S. open S \<longrightarrow> l \<in> S \<longrightarrow> (\<forall>\<^sub>F x in net. f x \<in> S)) = ((\<forall>P. eventually P net) \<or> (\<forall>S. open S \<longrightarrow> l \<in> S \<longrightarrow> (\<forall>\<^sub>F x in net. f x \<in> S)))
[PROOF STEP]
by auto


[STATEMENT]
lemma convergent_NSconvergent_iff: "convergent X = NSconvergent X"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. convergent X = NSconvergent X
[PROOF STEP]
by (simp add: convergent_def NSconvergent_def LIMSEQ_NSLIMSEQ_iff)


[STATEMENT]
lemma (in Ring) ideal_inv1_closed:"\<lbrakk> ideal R I; x \<in> I \<rbrakk> \<Longrightarrow> -\<^sub>a x \<in> I"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>ideal R I; x \<in> I\<rbrakk> \<Longrightarrow> -\<^sub>a x \<in> I
[PROOF STEP]
apply (cut_tac ring_is_ag)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>ideal R I; x \<in> I; aGroup R\<rbrakk> \<Longrightarrow> -\<^sub>a x \<in> I
[PROOF STEP]
apply (unfold ideal_def, frule conjunct1, fold ideal_def)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>ideal R I; x \<in> I; aGroup R; R +> I\<rbrakk> \<Longrightarrow> -\<^sub>a x \<in> I
[PROOF STEP]
apply (simp add:aGroup.asubg_mOp_closed[of "R" "I"])
[PROOF STATE]
proof (prove)
goal:
No subgoals!
[PROOF STEP]
done


[STATEMENT]
lemma iter_hcomp_insert:
  assumes "v |\<notin>| ws"
  shows "(\<Otimes>x |\<in>| finsert v ws. p x) = (p v \<otimes> (\<Otimes>x |\<in>| ws. p x))"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. iter_hcomp (finsert v ws) p = (p v \<otimes> iter_hcomp ws p)
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. iter_hcomp (finsert v ws) p = (p v \<otimes> iter_hcomp ws p)
[PROOF STEP]
interpret comp_fun_commute "((\<otimes>) \<circ> p)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. comp_fun_commute ((\<otimes>) \<circ> p)
[PROOF STEP]
by (metis comp_fun_commute.comp_comp_fun_commute comp_fun_commute_hcomp)
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. iter_hcomp (finsert v ws) p = (p v \<otimes> iter_hcomp ws p)
[PROOF STEP]
from assms
[PROOF STATE]
proof (chain)
picking this:
v |\<notin>| ws
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
v |\<notin>| ws

goal (1 subgoal):
 1. iter_hcomp (finsert v ws) p = (p v \<otimes> iter_hcomp ws p)
[PROOF STEP]
unfolding iter_hcomp_def
[PROOF STATE]
proof (prove)
using this:
v |\<notin>| ws

goal (1 subgoal):
 1. ffold ((\<otimes>) \<circ> p) \<epsilon> (finsert v ws) = (p v \<otimes> ffold ((\<otimes>) \<circ> p) \<epsilon> ws)
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
iter_hcomp (finsert v ws) p = (p v \<otimes> iter_hcomp ws p)

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma Un_set_drop_impl_correct:
  "Un_set_drop_impl i A \<le> SPEC (\<lambda>r. r=\<Union>(set (drop i A)))"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. Un_set_drop_impl i A \<le> SPEC (\<lambda>r. r = \<Union> (set (drop i A)))
[PROOF STEP]
unfolding Un_set_drop_impl_def
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. WHILE\<^sub>T (\<lambda>(i, res). i < length A) (\<lambda>(i, res). ASSERT (i < length A) \<bind> (\<lambda>_. let res = A ! i \<union> res; i = i + 1 in RETURN (i, res))) (i, {}) \<bind> (\<lambda>(uu_, res). RETURN res) \<le> SPEC (\<lambda>r. r = \<Union> (set (drop i A)))
[PROOF STEP]
apply (refine_rcg
    WHILET_rule[where I="\<lambda>(i',res). res=\<Union>(set ((drop i (take i' A)))) \<and> i\<le>i'"
    and R="measure (\<lambda>(i',_). length A - i')"]
    refine_vcg)
[PROOF STATE]
proof (prove)
goal (8 subgoals):
 1. wf (measure (\<lambda>(i', uu_). length A - i'))
 2. \<And>x1 x2. (i, {}) = (x1, x2) \<Longrightarrow> x2 = \<Union> (set (drop i (take x1 A)))
 3. \<And>x1 x2. (i, {}) = (x1, x2) \<Longrightarrow> i \<le> x1
 4. \<And>s a b. \<lbrakk>case s of (i', res) \<Rightarrow> res = \<Union> (set (drop i (take i' A))) \<and> i \<le> i'; case s of (i, res) \<Rightarrow> i < length A; s = (a, b)\<rbrakk> \<Longrightarrow> a < length A
 5. \<And>s a b x1 x2. \<lbrakk>case s of (i', res) \<Rightarrow> res = \<Union> (set (drop i (take i' A))) \<and> i \<le> i'; case s of (i, res) \<Rightarrow> i < length A; s = (a, b); a < length A; (a + 1, A ! a \<union> b) = (x1, x2)\<rbrakk> \<Longrightarrow> x2 = \<Union> (set (drop i (take x1 A)))
 6. \<And>s a b x1 x2. \<lbrakk>case s of (i', res) \<Rightarrow> res = \<Union> (set (drop i (take i' A))) \<and> i \<le> i'; case s of (i, res) \<Rightarrow> i < length A; s = (a, b); a < length A; (a + 1, A ! a \<union> b) = (x1, x2)\<rbrakk> \<Longrightarrow> i \<le> x1
 7. \<And>s a b. \<lbrakk>case s of (i', res) \<Rightarrow> res = \<Union> (set (drop i (take i' A))) \<and> i \<le> i'; case s of (i, res) \<Rightarrow> i < length A; s = (a, b); a < length A\<rbrakk> \<Longrightarrow> ((a + 1, A ! a \<union> b), s) \<in> measure (\<lambda>(i', uu_). length A - i')
 8. \<And>s a b. \<lbrakk>case s of (i', res) \<Rightarrow> res = \<Union> (set (drop i (take i' A))) \<and> i \<le> i'; \<not> (case s of (i, res) \<Rightarrow> i < length A); s = (a, b)\<rbrakk> \<Longrightarrow> b = \<Union> (set (drop i A))
[PROOF STEP]
apply (auto simp: take_Suc_conv_app_nth)
[PROOF STATE]
proof (prove)
goal:
No subgoals!
[PROOF STEP]
done


[STATEMENT]
lemma psup_le_ub: "\<lbrakk>\<And>X. X \<in> P \<Longrightarrow> X \<le> Y; P \<noteq> {}\<rbrakk> \<Longrightarrow> psup P \<le> Y"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>\<And>X. X \<in> P \<Longrightarrow> X \<le> Y; P \<noteq> {}\<rbrakk> \<Longrightarrow> psup P \<le> Y
[PROOF STEP]
using preal_sup [of P Y]
[PROOF STATE]
proof (prove)
using this:
\<lbrakk>\<And>X. X \<in> P \<Longrightarrow> X \<le> Y; P \<noteq> {}\<rbrakk> \<Longrightarrow> Dedekind_Real.cut (\<Union> (Rep_preal ` P))

goal (1 subgoal):
 1. \<lbrakk>\<And>X. X \<in> P \<Longrightarrow> X \<le> Y; P \<noteq> {}\<rbrakk> \<Longrightarrow> psup P \<le> Y
[PROOF STEP]
by (simp add: SUP_least preal_le_def psup_def)


[STATEMENT]
lemma closure_equiv_eq: "[P \<longleftrightarrow> Q] \<longleftrightarrow> (P = Q)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<forall>A. (P \<longleftrightarrow> Q) A) = (P = Q)
[PROOF STEP]
by (simp add: fun_eq_iff utp_defs)


[STATEMENT]
lemma SD_efficient_iff:
  assumes "p \<in> lotteries_on alts"
  shows   "SD_efficient R p \<longleftrightarrow> SD_efficient R (pmf_of_set (set_pmf p))"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. SD_efficient R p = SD_efficient R (pmf_of_set (set_pmf p))
[PROOF STEP]
using assms finite_alts
[PROOF STATE]
proof (prove)
using this:
p \<in> lotteries_on alts
finite alts

goal (1 subgoal):
 1. SD_efficient R p = SD_efficient R (pmf_of_set (set_pmf p))
[PROOF STEP]
by (intro SD_efficient_same_support)
     (simp, subst set_pmf_of_set,
      auto simp: set_pmf_not_empty lotteries_on_def intro: finite_subset[OF _ finite_alts])


[STATEMENT]
lemma inf_prefix_append[simp]: "(zs @ xs) \<sqinter> (zs @ ys) = zs @ (xs \<sqinter> ys)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (zs @ xs) \<sqinter> (zs @ ys) = zs @ xs \<sqinter> ys
[PROOF STEP]
apply (rule is_inf_prefix[symmetric], simp)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<And>i. i < length ((zs @ xs) \<sqinter> (zs @ ys)) \<Longrightarrow> (zs @ xs \<sqinter> ys) ! i = (zs @ xs) ! i \<and> (zs @ xs \<sqinter> ys) ! i = (zs @ ys) ! i
[PROOF STEP]
apply (clarsimp simp: nth_append)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<And>i. \<lbrakk>i < length zs + length (xs \<sqinter> ys); \<not> i < length zs\<rbrakk> \<Longrightarrow> (xs \<sqinter> ys) ! (i - length zs) = xs ! (i - length zs) \<and> (xs \<sqinter> ys) ! (i - length zs) = ys ! (i - length zs)
[PROOF STEP]
apply (intro conjI inf_prefix_correctL inf_prefix_correctR, simp+)
[PROOF STATE]
proof (prove)
goal:
No subgoals!
[PROOF STEP]
done


[STATEMENT]
lemma extended_Gromov_product_at_topological:
  "extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal(Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
proof (cases x)
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. \<And>xa. x = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
 2. x \<in> Gromov_boundary \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
case boundary
[PROOF STATE]
proof (state)
this:
x \<in> Gromov_boundary

goal (2 subgoals):
 1. \<And>xa. x = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
 2. x \<in> Gromov_boundary \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
proof (cases y)
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. \<And>xa. y = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
 2. y \<in> Gromov_boundary \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
case boundary
[PROOF STATE]
proof (state)
this:
y \<in> Gromov_boundary

goal (2 subgoals):
 1. \<And>xa. y = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
 2. y \<in> Gromov_boundary \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
y \<in> Gromov_boundary
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
y \<in> Gromov_boundary

goal (1 subgoal):
 1. extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
unfolding extended_Gromov_product_at_def Gromov_completion_converge_to_boundary[OF \<open>x \<in> Gromov_boundary\<close>] Gromov_completion_converge_to_boundary[OF \<open>y \<in> Gromov_boundary\<close>]
[PROOF STATE]
proof (prove)
using this:
y \<in> Gromov_boundary

goal (1 subgoal):
 1. Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. abs_Gromov_completion u = x \<and> abs_Gromov_completion v = y \<and> Gromov_completion_rel u u \<and> Gromov_completion_rel v v} = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (Gromov_completion_rel u u \<and> abs_Gromov_completion u = x) \<and> Gromov_completion_rel v v \<and> abs_Gromov_completion v = y}
[PROOF STEP]
by meson
[PROOF STATE]
proof (state)
this:
extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}

goal (1 subgoal):
 1. \<And>xa. y = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
next
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>xa. y = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
case (to_Gromov_completion yi)
[PROOF STATE]
proof (state)
this:
y = to_Gromov_completion yi

goal (1 subgoal):
 1. \<And>xa. y = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
have A: "liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))" if "v \<longlonglongrightarrow> yi" for u v
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))
[PROOF STEP]
define h where "h = (\<lambda>n. Gromov_product_at e (u n) (v n) - Gromov_product_at e (u n) yi)"
[PROOF STATE]
proof (state)
this:
h = (\<lambda>n. Gromov_product_at e (u n) (v n) - Gromov_product_at e (u n) yi)

goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))
[PROOF STEP]
have h: "h \<longlonglongrightarrow> 0"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. h \<longlonglongrightarrow> 0
[PROOF STEP]
apply (rule tendsto_rabs_zero_cancel, rule tendsto_sandwich[of "\<lambda>n. 0" _ _ "\<lambda>n. dist (v n) yi"])
[PROOF STATE]
proof (prove)
goal (4 subgoals):
 1. \<forall>\<^sub>F n in sequentially. 0 \<le> \<bar>h n\<bar>
 2. \<forall>\<^sub>F n in sequentially. \<bar>h n\<bar> \<le> dist (v n) yi
 3. (\<lambda>n. 0) \<longlonglongrightarrow> 0
 4. (\<lambda>n. dist (v n) yi) \<longlonglongrightarrow> 0
[PROOF STEP]
unfolding h_def
[PROOF STATE]
proof (prove)
goal (4 subgoals):
 1. \<forall>\<^sub>F n in sequentially. 0 \<le> \<bar>Gromov_product_at e (u n) (v n) - Gromov_product_at e (u n) yi\<bar>
 2. \<forall>\<^sub>F n in sequentially. \<bar>Gromov_product_at e (u n) (v n) - Gromov_product_at e (u n) yi\<bar> \<le> dist (v n) yi
 3. (\<lambda>n. 0) \<longlonglongrightarrow> 0
 4. (\<lambda>n. dist (v n) yi) \<longlonglongrightarrow> 0
[PROOF STEP]
using Gromov_product_at_diff3[of e _ _ yi] that
[PROOF STATE]
proof (prove)
using this:
\<bar>Gromov_product_at e ?x ?y - Gromov_product_at e ?x yi\<bar> \<le> dist ?y yi
v \<longlonglongrightarrow> yi

goal (4 subgoals):
 1. \<forall>\<^sub>F n in sequentially. 0 \<le> \<bar>Gromov_product_at e (u n) (v n) - Gromov_product_at e (u n) yi\<bar>
 2. \<forall>\<^sub>F n in sequentially. \<bar>Gromov_product_at e (u n) (v n) - Gromov_product_at e (u n) yi\<bar> \<le> dist (v n) yi
 3. (\<lambda>n. 0) \<longlonglongrightarrow> 0
 4. (\<lambda>n. dist (v n) yi) \<longlonglongrightarrow> 0
[PROOF STEP]
apply auto
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>\<And>x y. \<bar>Gromov_product_at e x y - Gromov_product_at e x yi\<bar> \<le> dist y yi; v \<longlonglongrightarrow> yi\<rbrakk> \<Longrightarrow> (\<lambda>n. dist (v n) yi) \<longlonglongrightarrow> 0
[PROOF STEP]
using tendsto_dist_iff
[PROOF STATE]
proof (prove)
using this:
(?f \<longlongrightarrow> ?l) ?F = ((\<lambda>x. dist (?f x) ?l) \<longlongrightarrow> 0) ?F

goal (1 subgoal):
 1. \<lbrakk>\<And>x y. \<bar>Gromov_product_at e x y - Gromov_product_at e x yi\<bar> \<le> dist y yi; v \<longlonglongrightarrow> yi\<rbrakk> \<Longrightarrow> (\<lambda>n. dist (v n) yi) \<longlonglongrightarrow> 0
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
h \<longlonglongrightarrow> 0

goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))
[PROOF STEP]
have *: "ereal (Gromov_product_at e (u n) (v n)) = h n + ereal (Gromov_product_at e (u n) yi)" for n
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. ereal (Gromov_product_at e (u n) (v n)) = ereal (h n) + ereal (Gromov_product_at e (u n) yi)
[PROOF STEP]
unfolding h_def
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. ereal (Gromov_product_at e (u n) (v n)) = ereal (Gromov_product_at e (u n) (v n) - Gromov_product_at e (u n) yi) + ereal (Gromov_product_at e (u n) yi)
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
ereal (Gromov_product_at e (u ?n) (v ?n)) = ereal (h ?n) + ereal (Gromov_product_at e (u ?n) yi)

goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))
[PROOF STEP]
have "liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = 0 + liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = 0 + liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))
[PROOF STEP]
unfolding *
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (h n) + ereal (Gromov_product_at e (u n) yi)) = 0 + liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))
[PROOF STEP]
apply (rule ereal_liminf_lim_add)
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. (\<lambda>n. ereal (h n)) \<longlonglongrightarrow> 0
 2. \<bar>0\<bar> \<noteq> \<infinity>
[PROOF STEP]
using h
[PROOF STATE]
proof (prove)
using this:
h \<longlonglongrightarrow> 0

goal (2 subgoals):
 1. (\<lambda>n. ereal (h n)) \<longlonglongrightarrow> 0
 2. \<bar>0\<bar> \<noteq> \<infinity>
[PROOF STEP]
by (auto simp add: zero_ereal_def)
[PROOF STATE]
proof (state)
this:
liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = 0 + liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))

goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = 0 + liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = 0 + liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))

goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (u n) yi))

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
?v \<longlonglongrightarrow> yi \<Longrightarrow> liminf (\<lambda>n. ereal (Gromov_product_at e (?u n) (?v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (?u n) yi))

goal (1 subgoal):
 1. \<And>xa. y = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
unfolding to_Gromov_completion extended_Gromov_product_boundary_inside_aux[OF \<open>x \<in> Gromov_boundary\<close>]
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (v n) yi)) |v. (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> x} = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> to_Gromov_completion yi}
[PROOF STEP]
apply (rule cong[of Inf Inf], auto)
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. \<And>v. (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> x \<Longrightarrow> \<exists>u va. liminf (\<lambda>n. ereal (Gromov_product_at e (v n) yi)) = liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (va n))) \<and> (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> va \<longlonglongrightarrow> yi
 2. \<And>u v. \<lbrakk>(\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x; v \<longlonglongrightarrow> yi\<rbrakk> \<Longrightarrow> \<exists>va. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (va n) yi)) \<and> (\<lambda>n. to_Gromov_completion (va n)) \<longlonglongrightarrow> x
[PROOF STEP]
using A
[PROOF STATE]
proof (prove)
using this:
?v \<longlonglongrightarrow> yi \<Longrightarrow> liminf (\<lambda>n. ereal (Gromov_product_at e (?u n) (?v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (?u n) yi))

goal (2 subgoals):
 1. \<And>v. (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> x \<Longrightarrow> \<exists>u va. liminf (\<lambda>n. ereal (Gromov_product_at e (v n) yi)) = liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (va n))) \<and> (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> va \<longlonglongrightarrow> yi
 2. \<And>u v. \<lbrakk>(\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x; v \<longlonglongrightarrow> yi\<rbrakk> \<Longrightarrow> \<exists>va. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (va n) yi)) \<and> (\<lambda>n. to_Gromov_completion (va n)) \<longlonglongrightarrow> x
[PROOF STEP]
by fast+
[PROOF STATE]
proof (state)
this:
extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}

goal (1 subgoal):
 1. \<And>xa. x = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
next
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>xa. x = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
case (to_Gromov_completion xi)
[PROOF STATE]
proof (state)
this:
x = to_Gromov_completion xi

goal (1 subgoal):
 1. \<And>xa. x = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
proof (cases y)
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. \<And>xa. y = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
 2. y \<in> Gromov_boundary \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
case boundary
[PROOF STATE]
proof (state)
this:
y \<in> Gromov_boundary

goal (2 subgoals):
 1. \<And>xa. y = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
 2. y \<in> Gromov_boundary \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
have A: "liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))" if "u \<longlonglongrightarrow> xi" for u v
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))
[PROOF STEP]
define h where "h = (\<lambda>n. Gromov_product_at e (u n) (v n) - Gromov_product_at e xi (v n))"
[PROOF STATE]
proof (state)
this:
h = (\<lambda>n. Gromov_product_at e (u n) (v n) - Gromov_product_at e xi (v n))

goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))
[PROOF STEP]
have h: "h \<longlonglongrightarrow> 0"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. h \<longlonglongrightarrow> 0
[PROOF STEP]
apply (rule tendsto_rabs_zero_cancel, rule tendsto_sandwich[of "\<lambda>n. 0" _ _ "\<lambda>n. dist (u n) xi"])
[PROOF STATE]
proof (prove)
goal (4 subgoals):
 1. \<forall>\<^sub>F n in sequentially. 0 \<le> \<bar>h n\<bar>
 2. \<forall>\<^sub>F n in sequentially. \<bar>h n\<bar> \<le> dist (u n) xi
 3. (\<lambda>n. 0) \<longlonglongrightarrow> 0
 4. (\<lambda>n. dist (u n) xi) \<longlonglongrightarrow> 0
[PROOF STEP]
unfolding h_def
[PROOF STATE]
proof (prove)
goal (4 subgoals):
 1. \<forall>\<^sub>F n in sequentially. 0 \<le> \<bar>Gromov_product_at e (u n) (v n) - Gromov_product_at e xi (v n)\<bar>
 2. \<forall>\<^sub>F n in sequentially. \<bar>Gromov_product_at e (u n) (v n) - Gromov_product_at e xi (v n)\<bar> \<le> dist (u n) xi
 3. (\<lambda>n. 0) \<longlonglongrightarrow> 0
 4. (\<lambda>n. dist (u n) xi) \<longlonglongrightarrow> 0
[PROOF STEP]
using Gromov_product_at_diff2[of e _ _ xi] that
[PROOF STATE]
proof (prove)
using this:
\<bar>Gromov_product_at e ?x ?z - Gromov_product_at e xi ?z\<bar> \<le> dist ?x xi
u \<longlonglongrightarrow> xi

goal (4 subgoals):
 1. \<forall>\<^sub>F n in sequentially. 0 \<le> \<bar>Gromov_product_at e (u n) (v n) - Gromov_product_at e xi (v n)\<bar>
 2. \<forall>\<^sub>F n in sequentially. \<bar>Gromov_product_at e (u n) (v n) - Gromov_product_at e xi (v n)\<bar> \<le> dist (u n) xi
 3. (\<lambda>n. 0) \<longlonglongrightarrow> 0
 4. (\<lambda>n. dist (u n) xi) \<longlonglongrightarrow> 0
[PROOF STEP]
apply auto
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>\<And>x z. \<bar>Gromov_product_at e x z - Gromov_product_at e xi z\<bar> \<le> dist x xi; u \<longlonglongrightarrow> xi\<rbrakk> \<Longrightarrow> (\<lambda>n. dist (u n) xi) \<longlonglongrightarrow> 0
[PROOF STEP]
using tendsto_dist_iff
[PROOF STATE]
proof (prove)
using this:
(?f \<longlongrightarrow> ?l) ?F = ((\<lambda>x. dist (?f x) ?l) \<longlongrightarrow> 0) ?F

goal (1 subgoal):
 1. \<lbrakk>\<And>x z. \<bar>Gromov_product_at e x z - Gromov_product_at e xi z\<bar> \<le> dist x xi; u \<longlonglongrightarrow> xi\<rbrakk> \<Longrightarrow> (\<lambda>n. dist (u n) xi) \<longlonglongrightarrow> 0
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
h \<longlonglongrightarrow> 0

goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))
[PROOF STEP]
have *: "ereal (Gromov_product_at e (u n) (v n)) = h n + ereal (Gromov_product_at e xi (v n))" for n
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. ereal (Gromov_product_at e (u n) (v n)) = ereal (h n) + ereal (Gromov_product_at e xi (v n))
[PROOF STEP]
unfolding h_def
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. ereal (Gromov_product_at e (u n) (v n)) = ereal (Gromov_product_at e (u n) (v n) - Gromov_product_at e xi (v n)) + ereal (Gromov_product_at e xi (v n))
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
ereal (Gromov_product_at e (u ?n) (v ?n)) = ereal (h ?n) + ereal (Gromov_product_at e xi (v ?n))

goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))
[PROOF STEP]
have "liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = 0 + liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = 0 + liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))
[PROOF STEP]
unfolding *
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (h n) + ereal (Gromov_product_at e xi (v n))) = 0 + liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))
[PROOF STEP]
apply (rule ereal_liminf_lim_add)
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. (\<lambda>n. ereal (h n)) \<longlonglongrightarrow> 0
 2. \<bar>0\<bar> \<noteq> \<infinity>
[PROOF STEP]
using h
[PROOF STATE]
proof (prove)
using this:
h \<longlonglongrightarrow> 0

goal (2 subgoals):
 1. (\<lambda>n. ereal (h n)) \<longlonglongrightarrow> 0
 2. \<bar>0\<bar> \<noteq> \<infinity>
[PROOF STEP]
by (auto simp add: zero_ereal_def)
[PROOF STATE]
proof (state)
this:
liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = 0 + liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))

goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = 0 + liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = 0 + liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))

goal (1 subgoal):
 1. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n)))

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
?u \<longlonglongrightarrow> xi \<Longrightarrow> liminf (\<lambda>n. ereal (Gromov_product_at e (?u n) (?v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e xi (?v n)))

goal (2 subgoals):
 1. \<And>xa. y = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
 2. y \<in> Gromov_boundary \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
unfolding to_Gromov_completion extended_Gromov_product_inside_boundary_aux[OF \<open>y \<in> Gromov_boundary\<close>]
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. Inf {liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n))) |v. (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y} = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> to_Gromov_completion xi \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
apply (rule cong[of Inf Inf], auto)
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. \<And>v. (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y \<Longrightarrow> \<exists>u va. liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (va n))) \<and> u \<longlonglongrightarrow> xi \<and> (\<lambda>n. to_Gromov_completion (va n)) \<longlonglongrightarrow> y
 2. \<And>u v. \<lbrakk>u \<longlonglongrightarrow> xi; (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y\<rbrakk> \<Longrightarrow> \<exists>va. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e xi (va n))) \<and> (\<lambda>n. to_Gromov_completion (va n)) \<longlonglongrightarrow> y
[PROOF STEP]
using A
[PROOF STATE]
proof (prove)
using this:
?u \<longlonglongrightarrow> xi \<Longrightarrow> liminf (\<lambda>n. ereal (Gromov_product_at e (?u n) (?v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e xi (?v n)))

goal (2 subgoals):
 1. \<And>v. (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y \<Longrightarrow> \<exists>u va. liminf (\<lambda>n. ereal (Gromov_product_at e xi (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (va n))) \<and> u \<longlonglongrightarrow> xi \<and> (\<lambda>n. to_Gromov_completion (va n)) \<longlonglongrightarrow> y
 2. \<And>u v. \<lbrakk>u \<longlonglongrightarrow> xi; (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y\<rbrakk> \<Longrightarrow> \<exists>va. liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) = liminf (\<lambda>n. ereal (Gromov_product_at e xi (va n))) \<and> (\<lambda>n. to_Gromov_completion (va n)) \<longlonglongrightarrow> y
[PROOF STEP]
by fast+
[PROOF STATE]
proof (state)
this:
extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}

goal (1 subgoal):
 1. \<And>xa. y = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
next
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>xa. y = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
case (to_Gromov_completion yi)
[PROOF STATE]
proof (state)
this:
y = to_Gromov_completion yi

goal (1 subgoal):
 1. \<And>xa. y = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
have B: "liminf (\<lambda>n. Gromov_product_at e (u n) (v n)) = Gromov_product_at e xi yi" if "u \<longlonglongrightarrow> xi" "v \<longlonglongrightarrow> yi" for u v
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. liminf (\<lambda>x. ereal (Gromov_product_at e (u x) (v x))) = ereal (Gromov_product_at e xi yi)
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. liminf (\<lambda>x. ereal (Gromov_product_at e (u x) (v x))) = ereal (Gromov_product_at e xi yi)
[PROOF STEP]
have "(\<lambda>n. Gromov_product_at e (u n) (v n)) \<longlonglongrightarrow> Gromov_product_at e xi yi"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<lambda>n. Gromov_product_at e (u n) (v n)) \<longlonglongrightarrow> Gromov_product_at e xi yi
[PROOF STEP]
apply (rule Gromov_product_at_continuous)
[PROOF STATE]
proof (prove)
goal (3 subgoals):
 1. (\<lambda>n. e) \<longlonglongrightarrow> e
 2. u \<longlonglongrightarrow> xi
 3. v \<longlonglongrightarrow> yi
[PROOF STEP]
using that
[PROOF STATE]
proof (prove)
using this:
u \<longlonglongrightarrow> xi
v \<longlonglongrightarrow> yi

goal (3 subgoals):
 1. (\<lambda>n. e) \<longlonglongrightarrow> e
 2. u \<longlonglongrightarrow> xi
 3. v \<longlonglongrightarrow> yi
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
(\<lambda>n. Gromov_product_at e (u n) (v n)) \<longlonglongrightarrow> Gromov_product_at e xi yi

goal (1 subgoal):
 1. liminf (\<lambda>x. ereal (Gromov_product_at e (u x) (v x))) = ereal (Gromov_product_at e xi yi)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
(\<lambda>n. Gromov_product_at e (u n) (v n)) \<longlonglongrightarrow> Gromov_product_at e xi yi
[PROOF STEP]
show "liminf (\<lambda>n. Gromov_product_at e (u n) (v n)) = Gromov_product_at e xi yi"
[PROOF STATE]
proof (prove)
using this:
(\<lambda>n. Gromov_product_at e (u n) (v n)) \<longlonglongrightarrow> Gromov_product_at e xi yi

goal (1 subgoal):
 1. liminf (\<lambda>x. ereal (Gromov_product_at e (u x) (v x))) = ereal (Gromov_product_at e xi yi)
[PROOF STEP]
by (simp add: lim_imp_Liminf)
[PROOF STATE]
proof (state)
this:
liminf (\<lambda>x. ereal (Gromov_product_at e (u x) (v x))) = ereal (Gromov_product_at e xi yi)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
\<lbrakk>?u \<longlonglongrightarrow> xi; ?v \<longlonglongrightarrow> yi\<rbrakk> \<Longrightarrow> liminf (\<lambda>x. ereal (Gromov_product_at e (?u x) (?v x))) = ereal (Gromov_product_at e xi yi)

goal (1 subgoal):
 1. \<And>xa. y = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
have *: "{liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. u \<longlonglongrightarrow> xi \<and> v \<longlonglongrightarrow> yi} = {ereal (Gromov_product_at e xi yi)}"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. u \<longlonglongrightarrow> xi \<and> v \<longlonglongrightarrow> yi} = {ereal (Gromov_product_at e xi yi)}
[PROOF STEP]
using B
[PROOF STATE]
proof (prove)
using this:
\<lbrakk>?u \<longlonglongrightarrow> xi; ?v \<longlonglongrightarrow> yi\<rbrakk> \<Longrightarrow> liminf (\<lambda>x. ereal (Gromov_product_at e (?u x) (?v x))) = ereal (Gromov_product_at e xi yi)

goal (1 subgoal):
 1. {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. u \<longlonglongrightarrow> xi \<and> v \<longlonglongrightarrow> yi} = {ereal (Gromov_product_at e xi yi)}
[PROOF STEP]
apply auto
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<And>u v. \<lbrakk>u \<longlonglongrightarrow> xi; v \<longlonglongrightarrow> yi\<rbrakk> \<Longrightarrow> liminf (\<lambda>x. ereal (Gromov_product_at e (u x) (v x))) = ereal (Gromov_product_at e xi yi)) \<Longrightarrow> \<exists>u v. ereal (Gromov_product_at e xi yi) = liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) \<and> u \<longlonglongrightarrow> xi \<and> v \<longlonglongrightarrow> yi
[PROOF STEP]
by (rule exI[of _ "\<lambda>n. xi"], rule exI[of _ "\<lambda>n. yi"], auto)
[PROOF STATE]
proof (state)
this:
{liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. u \<longlonglongrightarrow> xi \<and> v \<longlonglongrightarrow> yi} = {ereal (Gromov_product_at e xi yi)}

goal (1 subgoal):
 1. \<And>xa. y = to_Gromov_completion xa \<Longrightarrow> extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}
[PROOF STEP]
unfolding \<open>x = to_Gromov_completion xi\<close> \<open>y = to_Gromov_completion yi\<close>
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. extended_Gromov_product_at e (to_Gromov_completion xi) (to_Gromov_completion yi) = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> to_Gromov_completion xi \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> to_Gromov_completion yi}
[PROOF STEP]
by (auto simp add: *)
[PROOF STATE]
proof (state)
this:
extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
extended_Gromov_product_at e x y = Inf {liminf (\<lambda>n. ereal (Gromov_product_at e (u n) (v n))) |u v. (\<lambda>n. to_Gromov_completion (u n)) \<longlonglongrightarrow> x \<and> (\<lambda>n. to_Gromov_completion (v n)) \<longlonglongrightarrow> y}

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma loop_apx_least_fixpoint:
  "apx.is_least_fixpoint (\<lambda>x . y * x \<squnion> z) (\<mu> (\<lambda>x . y * x \<squnion> z) \<squnion> n(\<nu> (\<lambda>x . y * x \<squnion> z)) * L)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. order.is_least_fixpoint (\<sqsubseteq>) (\<lambda>x. y * x \<squnion> z) (\<mu> (\<lambda>x. y * x \<squnion> z) \<squnion> n (\<nu> (\<lambda>x. y * x \<squnion> z)) * L)
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. order.is_least_fixpoint (\<sqsubseteq>) (\<lambda>x. y * x \<squnion> z) (\<mu> (\<lambda>x. y * x \<squnion> z) \<squnion> n (\<nu> (\<lambda>x. y * x \<squnion> z)) * L)
[PROOF STEP]
have "kappa_mu_nu_L (\<lambda>x . y * x \<squnion> z)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. kappa_mu_nu_L (\<lambda>x. y * x \<squnion> z)
[PROOF STEP]
by (metis affine_apx_isotone loop_exists affine_has_greatest_fixpoint affine_has_least_fixpoint affine_isotone nu_below_mu_nu_L_def nu_below_mu_nu_L_kappa_mu_nu_L)
[PROOF STATE]
proof (state)
this:
kappa_mu_nu_L (\<lambda>x. y * x \<squnion> z)

goal (1 subgoal):
 1. order.is_least_fixpoint (\<sqsubseteq>) (\<lambda>x. y * x \<squnion> z) (\<mu> (\<lambda>x. y * x \<squnion> z) \<squnion> n (\<nu> (\<lambda>x. y * x \<squnion> z)) * L)
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
kappa_mu_nu_L (\<lambda>x. y * x \<squnion> z)

goal (1 subgoal):
 1. order.is_least_fixpoint (\<sqsubseteq>) (\<lambda>x. y * x \<squnion> z) (\<mu> (\<lambda>x. y * x \<squnion> z) \<squnion> n (\<nu> (\<lambda>x. y * x \<squnion> z)) * L)
[PROOF STEP]
using apx.least_fixpoint_char kappa_mu_nu_L_def
[PROOF STATE]
proof (prove)
using this:
kappa_mu_nu_L (\<lambda>x. y * x \<squnion> z)
order.is_least_fixpoint (\<sqsubseteq>) ?f ?x = (order.has_least_fixpoint (\<sqsubseteq>) ?f \<and> ?x = \<kappa> ?f)
kappa_mu_nu_L ?f \<equiv> order.has_least_fixpoint (\<sqsubseteq>) ?f \<and> \<kappa> ?f = \<mu> ?f \<squnion> n (\<nu> ?f) * L

goal (1 subgoal):
 1. order.is_least_fixpoint (\<sqsubseteq>) (\<lambda>x. y * x \<squnion> z) (\<mu> (\<lambda>x. y * x \<squnion> z) \<squnion> n (\<nu> (\<lambda>x. y * x \<squnion> z)) * L)
[PROOF STEP]
by force
[PROOF STATE]
proof (state)
this:
order.is_least_fixpoint (\<sqsubseteq>) (\<lambda>x. y * x \<squnion> z) (\<mu> (\<lambda>x. y * x \<squnion> z) \<squnion> n (\<nu> (\<lambda>x. y * x \<squnion> z)) * L)

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma canonical_separator_transitions_alt_def :
  assumes "q1 \<in> states M" and "q2 \<in> states M"
  shows "transitions (canonical_separator M q1 q2) =
        (shifted_transitions_for M q1 q2)
        \<union> (distinguishing_transitions_left_alt M q1 q2)
        \<union> (distinguishing_transitions_right_alt M q1 q2)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. FSM.transitions (canonical_separator M q1 q2) = shifted_transitions_for M q1 q2 \<union> distinguishing_transitions_left_alt M q1 q2 \<union> distinguishing_transitions_right_alt M q1 q2
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. FSM.transitions (canonical_separator M q1 q2) = shifted_transitions_for M q1 q2 \<union> distinguishing_transitions_left_alt M q1 q2 \<union> distinguishing_transitions_right_alt M q1 q2
[PROOF STEP]
have *: "(shift_Inl `
            {t \<in> FSM.transitions (Product_FSM.product (FSM.from_FSM M q1) (FSM.from_FSM M q2)).
             t_source t \<in> reachable_states (Product_FSM.product (FSM.from_FSM M q1) (FSM.from_FSM M q2))})
          = {(Inl (t_source t), t_input t, t_output t, Inl (t_target t)) |t.
             t \<in> FSM.transitions (Product_FSM.product (FSM.from_FSM M q1) (FSM.from_FSM M q2)) \<and>
             t_source t \<in> reachable_states (Product_FSM.product (FSM.from_FSM M q1) (FSM.from_FSM M q2))}"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. shift_Inl ` {t \<in> FSM.transitions (Product_FSM.product (from_FSM M q1) (from_FSM M q2)). t_source t \<in> reachable_states (Product_FSM.product (from_FSM M q1) (from_FSM M q2))} = {shift_Inl t |t. t \<in> FSM.transitions (Product_FSM.product (from_FSM M q1) (from_FSM M q2)) \<and> t_source t \<in> reachable_states (Product_FSM.product (from_FSM M q1) (from_FSM M q2))}
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
shift_Inl ` {t \<in> FSM.transitions (Product_FSM.product (from_FSM M q1) (from_FSM M q2)). t_source t \<in> reachable_states (Product_FSM.product (from_FSM M q1) (from_FSM M q2))} = {shift_Inl t |t. t \<in> FSM.transitions (Product_FSM.product (from_FSM M q1) (from_FSM M q2)) \<and> t_source t \<in> reachable_states (Product_FSM.product (from_FSM M q1) (from_FSM M q2))}

goal (1 subgoal):
 1. FSM.transitions (canonical_separator M q1 q2) = shifted_transitions_for M q1 q2 \<union> distinguishing_transitions_left_alt M q1 q2 \<union> distinguishing_transitions_right_alt M q1 q2
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. FSM.transitions (canonical_separator M q1 q2) = shifted_transitions_for M q1 q2 \<union> distinguishing_transitions_left_alt M q1 q2 \<union> distinguishing_transitions_right_alt M q1 q2
[PROOF STEP]
unfolding canonical_separator_simps[OF assms]
            shifted_transitions_def
            restrict_to_reachable_states_simps
            product_simps from_FSM_simps[OF assms(1)] from_FSM_simps[OF assms(2)]
            sup.idem

            distinguishing_transitions_alt_alt_def
            shifted_transitions_for_def
            *

            distinguishing_transitions_left_alt_def
            distinguishing_transitions_right_alt_def
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. shift_Inl ` FSM.transitions (Product_FSM.product (from_FSM M q1) (from_FSM M q2)) \<union> ({t. \<exists>q1' q2'. t_source t = Inl (q1', q2') \<and> (q1', q2') \<in> FSM.states M \<times> FSM.states M \<and> t_target t = Inr q1 \<and> (\<exists>t'\<in>FSM.transitions M. t_source t' = q1' \<and> t_input t' = t_input t \<and> t_output t' = t_output t) \<and> \<not> (\<exists>t'\<in>FSM.transitions M. t_source t' = q2' \<and> t_input t' = t_input t \<and> t_output t' = t_output t)} \<union> {t. \<exists>q1' q2'. t_source t = Inl (q1', q2') \<and> (q1', q2') \<in> FSM.states M \<times> FSM.states M \<and> t_target t = Inr q2 \<and> \<not> (\<exists>t'\<in>FSM.transitions M. t_source t' = q1' \<and> t_input t' = t_input t \<and> t_output t' = t_output t) \<and> (\<exists>t'\<in>FSM.transitions M. t_source t' = q2' \<and> t_input t' = t_input t \<and> t_output t' = t_output t)}) = {shift_Inl t |t. t \<in> FSM.transitions (Product_FSM.product (from_FSM M q1) (from_FSM M q2))} \<union> {t. \<exists>q1' q2'. t_source t = Inl (q1', q2') \<and> (q1', q2') \<in> FSM.states M \<times> FSM.states M \<and> t_target t = Inr q1 \<and> (\<exists>t'\<in>FSM.transitions M. t_source t' = q1' \<and> t_input t' = t_input t \<and> t_output t' = t_output t) \<and> \<not> (\<exists>t'\<in>FSM.transitions M. t_source t' = q2' \<and> t_input t' = t_input t \<and> t_output t' = t_output t)} \<union> {t. \<exists>q1' q2'. t_source t = Inl (q1', q2') \<and> (q1', q2') \<in> FSM.states M \<times> FSM.states M \<and> t_target t = Inr q2 \<and> \<not> (\<exists>t'\<in>FSM.transitions M. t_source t' = q1' \<and> t_input t' = t_input t \<and> t_output t' = t_output t) \<and> (\<exists>t'\<in>FSM.transitions M. t_source t' = q2' \<and> t_input t' = t_input t \<and> t_output t' = t_output t)}
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
FSM.transitions (canonical_separator M q1 q2) = shifted_transitions_for M q1 q2 \<union> distinguishing_transitions_left_alt M q1 q2 \<union> distinguishing_transitions_right_alt M q1 q2

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma int_nat_minus:"0 < (n::int) \<Longrightarrow> nat (n - 1) = (nat n) - 1"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. 0 < n \<Longrightarrow> nat (n - 1) = nat n - 1
[PROOF STEP]
by arith