[STATEMENT]
theorem (in snd_sylow) num_sylow_dvd_remainder:
  shows "card (subgroups_of_size (p ^ a)) dvd m"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. card (subgroups_of_size (p ^ a)) dvd m
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. card (subgroups_of_size (p ^ a)) dvd m
[PROOF STEP]
from finite_G
[PROOF STATE]
proof (chain)
picking this:
finite (carrier G)
[PROOF STEP]
interpret conj: group_action G "(conjugation_action (p ^ a))" "(subgroups_of_size (p ^ a))"
[PROOF STATE]
proof (prove)
using this:
finite (carrier G)

goal (1 subgoal):
 1. group_action G (conjugation_action (p ^ a)) (subgroups_of_size (p ^ a))
[PROOF STEP]
by (rule acts_on_subsets)
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. card (subgroups_of_size (p ^ a)) dvd m
[PROOF STEP]
obtain P where PG:"subgroup P G" and cardP:"card P = p ^ a"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<And>P. \<lbrakk>subgroup P G; card P = p ^ a\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
by (metis sylow_thm)
[PROOF STATE]
proof (state)
this:
subgroup P G
card P = p ^ a

goal (1 subgoal):
 1. card (subgroups_of_size (p ^ a)) dvd m
[PROOF STEP]
hence Psize:"P \<in> subgroups_of_size (p ^ a)"
[PROOF STATE]
proof (prove)
using this:
subgroup P G
card P = p ^ a

goal (1 subgoal):
 1. P \<in> subgroups_of_size (p ^ a)
[PROOF STEP]
unfolding subgroups_of_size_def
[PROOF STATE]
proof (prove)
using this:
subgroup P G
card P = p ^ a

goal (1 subgoal):
 1. P \<in> {H. subgroup H G \<and> card H = p ^ a}
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
P \<in> subgroups_of_size (p ^ a)

goal (1 subgoal):
 1. card (subgroups_of_size (p ^ a)) dvd m
[PROOF STEP]
with finite_G
[PROOF STATE]
proof (chain)
picking this:
finite (carrier G)
P \<in> subgroups_of_size (p ^ a)
[PROOF STEP]
have "order G = card (conj.orbit P) * card (conj.stabilizer P)"
[PROOF STATE]
proof (prove)
using this:
finite (carrier G)
P \<in> subgroups_of_size (p ^ a)

goal (1 subgoal):
 1. order G = card (conj.orbit P) * card (conj.stabilizer P)
[PROOF STEP]
by (metis Psize acts_on_subsets group_action.orbit_size)
[PROOF STATE]
proof (state)
this:
order G = card (conj.orbit P) * card (conj.stabilizer P)

goal (1 subgoal):
 1. card (subgroups_of_size (p ^ a)) dvd m
[PROOF STEP]
with order_G Psize
[PROOF STATE]
proof (chain)
picking this:
order G = p ^ a * m
P \<in> subgroups_of_size (p ^ a)
order G = card (conj.orbit P) * card (conj.stabilizer P)
[PROOF STEP]
have orderEq:"p ^ a * m = card (subgroups_of_size (p ^ a)) * card (conj.stabilizer P)"
[PROOF STATE]
proof (prove)
using this:
order G = p ^ a * m
P \<in> subgroups_of_size (p ^ a)
order G = card (conj.orbit P) * card (conj.stabilizer P)

goal (1 subgoal):
 1. p ^ a * m = card (subgroups_of_size (p ^ a)) * card (conj.stabilizer P)
[PROOF STEP]
by (metis num_eq_card_orbit)
[PROOF STATE]
proof (state)
this:
p ^ a * m = card (subgroups_of_size (p ^ a)) * card (conj.stabilizer P)

goal (1 subgoal):
 1. card (subgroups_of_size (p ^ a)) dvd m
[PROOF STEP]
define k where "k = card (rcosets\<^bsub>G\<lparr>carrier := conj.stabilizer P\<rparr>\<^esub> P)"
[PROOF STATE]
proof (state)
this:
k = card (rcosets\<^bsub>G\<lparr>carrier := conj.stabilizer P\<rparr>\<^esub> P)

goal (1 subgoal):
 1. card (subgroups_of_size (p ^ a)) dvd m
[PROOF STEP]
with Psize
[PROOF STATE]
proof (chain)
picking this:
P \<in> subgroups_of_size (p ^ a)
k = card (rcosets\<^bsub>G\<lparr>carrier := conj.stabilizer P\<rparr>\<^esub> P)
[PROOF STEP]
have "k * p ^ a = card (conj.stabilizer P)"
[PROOF STATE]
proof (prove)
using this:
P \<in> subgroups_of_size (p ^ a)
k = card (rcosets\<^bsub>G\<lparr>carrier := conj.stabilizer P\<rparr>\<^esub> P)

goal (1 subgoal):
 1. k * p ^ a = card (conj.stabilizer P)
[PROOF STEP]
by (metis num_sylow_normalizer)
[PROOF STATE]
proof (state)
this:
k * p ^ a = card (conj.stabilizer P)

goal (1 subgoal):
 1. card (subgroups_of_size (p ^ a)) dvd m
[PROOF STEP]
with orderEq
[PROOF STATE]
proof (chain)
picking this:
p ^ a * m = card (subgroups_of_size (p ^ a)) * card (conj.stabilizer P)
k * p ^ a = card (conj.stabilizer P)
[PROOF STEP]
have "p ^ a * m = card (subgroups_of_size (p ^ a)) * p ^ a * k"
[PROOF STATE]
proof (prove)
using this:
p ^ a * m = card (subgroups_of_size (p ^ a)) * card (conj.stabilizer P)
k * p ^ a = card (conj.stabilizer P)

goal (1 subgoal):
 1. p ^ a * m = card (subgroups_of_size (p ^ a)) * p ^ a * k
[PROOF STEP]
by (auto simp:mult.assoc mult.commute)
[PROOF STATE]
proof (state)
this:
p ^ a * m = card (subgroups_of_size (p ^ a)) * p ^ a * k

goal (1 subgoal):
 1. card (subgroups_of_size (p ^ a)) dvd m
[PROOF STEP]
hence "p ^ a * m = p ^ a * card (subgroups_of_size (p ^ a)) * k"
[PROOF STATE]
proof (prove)
using this:
p ^ a * m = card (subgroups_of_size (p ^ a)) * p ^ a * k

goal (1 subgoal):
 1. p ^ a * m = p ^ a * card (subgroups_of_size (p ^ a)) * k
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
p ^ a * m = p ^ a * card (subgroups_of_size (p ^ a)) * k

goal (1 subgoal):
 1. card (subgroups_of_size (p ^ a)) dvd m
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
p ^ a * m = p ^ a * card (subgroups_of_size (p ^ a)) * k
[PROOF STEP]
have "m = card (subgroups_of_size (p ^ a)) * k"
[PROOF STATE]
proof (prove)
using this:
p ^ a * m = p ^ a * card (subgroups_of_size (p ^ a)) * k

goal (1 subgoal):
 1. m = card (subgroups_of_size (p ^ a)) * k
[PROOF STEP]
using pa_not_zero
[PROOF STATE]
proof (prove)
using this:
p ^ a * m = p ^ a * card (subgroups_of_size (p ^ a)) * k
p ^ a \<noteq> 0

goal (1 subgoal):
 1. m = card (subgroups_of_size (p ^ a)) * k
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
m = card (subgroups_of_size (p ^ a)) * k

goal (1 subgoal):
 1. card (subgroups_of_size (p ^ a)) dvd m
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
m = card (subgroups_of_size (p ^ a)) * k
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
m = card (subgroups_of_size (p ^ a)) * k

goal (1 subgoal):
 1. card (subgroups_of_size (p ^ a)) dvd m
[PROOF STEP]
..
[PROOF STATE]
proof (state)
this:
card (subgroups_of_size (p ^ a)) dvd m

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma tendsto_principal_singleton[simp]:
  shows "(f \<longlongrightarrow> f x) (principal {x})"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (f \<longlongrightarrow> f x) (principal {x})
[PROOF STEP]
unfolding tendsto_def eventually_principal
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<forall>S. open S \<longrightarrow> f x \<in> S \<longrightarrow> (\<forall>x\<in>{x}. f x \<in> S)
[PROOF STEP]
by simp


[STATEMENT]
lemma primekeytrick:
  fixes A B :: nat
  assumes "(M * A) mod P = (M * B) mod P"
  assumes "M mod P \<noteq> 0" and "prime P"
  shows "A mod P = B mod P"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. A mod P = B mod P
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. A mod P = B mod P
[PROOF STEP]
from assms
[PROOF STATE]
proof (chain)
picking this:
M * A mod P = M * B mod P
M mod P \<noteq> 0
prime P
[PROOF STEP]
have "M > 0"
[PROOF STATE]
proof (prove)
using this:
M * A mod P = M * B mod P
M mod P \<noteq> 0
prime P

goal (1 subgoal):
 1. 0 < M
[PROOF STEP]
by (auto intro: ccontr)
[PROOF STATE]
proof (state)
this:
0 < M

goal (1 subgoal):
 1. A mod P = B mod P
[PROOF STEP]
from assms
[PROOF STATE]
proof (chain)
picking this:
M * A mod P = M * B mod P
M mod P \<noteq> 0
prime P
[PROOF STEP]
have *: "\<And>q. P dvd M * q \<Longrightarrow> P dvd q"
[PROOF STATE]
proof (prove)
using this:
M * A mod P = M * B mod P
M mod P \<noteq> 0
prime P

goal (1 subgoal):
 1. \<And>q. P dvd M * q \<Longrightarrow> P dvd q
[PROOF STEP]
using primekeyrewrite [of P M]
[PROOF STATE]
proof (prove)
using this:
M * A mod P = M * B mod P
M mod P \<noteq> 0
prime P
\<lbrakk>prime P; P dvd M * ?b; \<not> P dvd M\<rbrakk> \<Longrightarrow> P dvd ?b

goal (1 subgoal):
 1. \<And>q. P dvd M * q \<Longrightarrow> P dvd q
[PROOF STEP]
unfolding dvd_eq_mod_eq_0 [symmetric]
[PROOF STATE]
proof (prove)
using this:
M * A mod P = M * B mod P
\<not> P dvd M
prime P
\<lbrakk>prime P; P dvd M * ?b; \<not> P dvd M\<rbrakk> \<Longrightarrow> P dvd ?b

goal (1 subgoal):
 1. \<And>q. P dvd M * q \<Longrightarrow> P dvd q
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
P dvd M * ?q \<Longrightarrow> P dvd ?q

goal (1 subgoal):
 1. A mod P = B mod P
[PROOF STEP]
from equalmodstrick2 [OF assms(1)] \<open>M > 0\<close>
[PROOF STATE]
proof (chain)
picking this:
pdifference (M * A) (M * B) mod P = 0
0 < M
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
pdifference (M * A) (M * B) mod P = 0
0 < M

goal (1 subgoal):
 1. A mod P = B mod P
[PROOF STEP]
apply -
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>pdifference (M * A) (M * B) mod P = 0; 0 < M\<rbrakk> \<Longrightarrow> A mod P = B mod P
[PROOF STEP]
apply (rule equalmodstrick1)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>pdifference (M * A) (M * B) mod P = 0; 0 < M\<rbrakk> \<Longrightarrow> pdifference A B mod P = 0
[PROOF STEP]
apply (auto intro: * dvdI simp add: dvd_eq_mod_eq_0 [symmetric] diff_mult_distrib2 [symmetric])
[PROOF STATE]
proof (prove)
goal:
No subgoals!
[PROOF STEP]
done
[PROOF STATE]
proof (state)
this:
A mod P = B mod P

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma  bernoulli_stream_npref_prob:
  fixes x
  assumes "M = bernoulli_stream p"
  shows "emeasure M {w\<in> space M. (stake 0 w = stake 0 x)} = 1"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. emeasure M {w \<in> space M. stake 0 w = stake 0 x} = 1
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. emeasure M {w \<in> space M. stake 0 w = stake 0 x} = 1
[PROOF STEP]
define S where "S = {w\<in> space M. (stake 0 w = stake 0 x)}"
[PROOF STATE]
proof (state)
this:
S = {w \<in> space M. stake 0 w = stake 0 x}

goal (1 subgoal):
 1. emeasure M {w \<in> space M. stake 0 w = stake 0 x} = 1
[PROOF STEP]
have "S = space M"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. S = space M
[PROOF STEP]
unfolding S_def
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. {w \<in> space M. stake 0 w = stake 0 x} = space M
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
S = space M

goal (1 subgoal):
 1. emeasure M {w \<in> space M. stake 0 w = stake 0 x} = 1
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
S = space M

goal (1 subgoal):
 1. emeasure M {w \<in> space M. stake 0 w = stake 0 x} = 1
[PROOF STEP]
by (simp add: assms bernoulli_stream_def prob_space.emeasure_space_1
        prob_space.prob_space_stream_space prob_space_measure_pmf)
[PROOF STATE]
proof (state)
this:
emeasure M {w \<in> space M. stake 0 w = stake 0 x} = 1

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma disjointed_mono: "mono A \<Longrightarrow> disjointed A (Suc n) = A (Suc n) - A n"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. mono A \<Longrightarrow> disjointed A (Suc n) = A (Suc n) - A n
[PROOF STEP]
using mono_imp_UN_eq_last[of A]
[PROOF STATE]
proof (prove)
using this:
mono A \<Longrightarrow> \<Union> (A ` {..?n}) = A ?n

goal (1 subgoal):
 1. mono A \<Longrightarrow> disjointed A (Suc n) = A (Suc n) - A n
[PROOF STEP]
by (simp add: disjointed_def atLeastLessThanSuc_atLeastAtMost atLeast0AtMost)


[STATEMENT]
lemma fix_is_fix_of_limit:
  assumes fixpoint: "f I = I"
  shows "limit f I = I"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. limit f I = I
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. limit f I = I
[PROOF STEP]
have funpower: "\<And> n. funpower f n I = I"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<And>n. funpower f n I = I
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>n. funpower f n I = I
[PROOF STEP]
fix n :: nat
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>n. funpower f n I = I
[PROOF STEP]
from fixpoint
[PROOF STATE]
proof (chain)
picking this:
f I = I
[PROOF STEP]
show "funpower f n I = I"
[PROOF STATE]
proof (prove)
using this:
f I = I

goal (1 subgoal):
 1. funpower f n I = I
[PROOF STEP]
by (induct n, auto)
[PROOF STATE]
proof (state)
this:
funpower f n I = I

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
funpower f ?n I = I

goal (1 subgoal):
 1. limit f I = I
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. limit f I = I
[PROOF STEP]
by (simp add: limit_def funpower natUnion_def)
[PROOF STATE]
proof (state)
this:
limit f I = I

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma dot_left_diff_distrib:
  fixes u v x :: "real^'n"
  shows "(u - v) \<bullet> x = (u \<bullet> x) - (v \<bullet> x)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (u - v) \<bullet> x = u \<bullet> x - v \<bullet> x
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. (u - v) \<bullet> x = u \<bullet> x - v \<bullet> x
[PROOF STEP]
have "(u \<bullet> x) - (v \<bullet> x) = (\<Sum>i\<in>UNIV. u$i * x$i) - (\<Sum>i\<in>UNIV. v$i * x$i)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. u \<bullet> x - v \<bullet> x = (\<Sum>i\<in>UNIV. u $ i * x $ i) - (\<Sum>i\<in>UNIV. v $ i * x $ i)
[PROOF STEP]
unfolding inner_vec_def
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<Sum>i\<in>UNIV. u $ i \<bullet> x $ i) - (\<Sum>i\<in>UNIV. v $ i \<bullet> x $ i) = (\<Sum>i\<in>UNIV. u $ i * x $ i) - (\<Sum>i\<in>UNIV. v $ i * x $ i)
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
u \<bullet> x - v \<bullet> x = (\<Sum>i\<in>UNIV. u $ i * x $ i) - (\<Sum>i\<in>UNIV. v $ i * x $ i)

goal (1 subgoal):
 1. (u - v) \<bullet> x = u \<bullet> x - v \<bullet> x
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
u \<bullet> x - v \<bullet> x = (\<Sum>i\<in>UNIV. u $ i * x $ i) - (\<Sum>i\<in>UNIV. v $ i * x $ i)

goal (1 subgoal):
 1. (u - v) \<bullet> x = u \<bullet> x - v \<bullet> x
[PROOF STEP]
from sum_subtractf [of "\<lambda> i. u$i * x$i" "\<lambda> i. v$i * x$i"]
[PROOF STATE]
proof (chain)
picking this:
(\<Sum>xa\<in>?A. u $ xa * x $ xa - v $ xa * x $ xa) = (\<Sum>xa\<in>?A. u $ xa * x $ xa) - (\<Sum>xa\<in>?A. v $ xa * x $ xa)
[PROOF STEP]
have
    "\<dots> = (\<Sum>i\<in>UNIV. u$i * x$i - v$i * x$i)"
[PROOF STATE]
proof (prove)
using this:
(\<Sum>xa\<in>?A. u $ xa * x $ xa - v $ xa * x $ xa) = (\<Sum>xa\<in>?A. u $ xa * x $ xa) - (\<Sum>xa\<in>?A. v $ xa * x $ xa)

goal (1 subgoal):
 1. (\<Sum>i\<in>UNIV. u $ i * x $ i) - (\<Sum>i\<in>UNIV. v $ i * x $ i) = (\<Sum>i\<in>UNIV. u $ i * x $ i - v $ i * x $ i)
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
(\<Sum>i\<in>UNIV. u $ i * x $ i) - (\<Sum>i\<in>UNIV. v $ i * x $ i) = (\<Sum>i\<in>UNIV. u $ i * x $ i - v $ i * x $ i)

goal (1 subgoal):
 1. (u - v) \<bullet> x = u \<bullet> x - v \<bullet> x
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
(\<Sum>i\<in>UNIV. u $ i * x $ i) - (\<Sum>i\<in>UNIV. v $ i * x $ i) = (\<Sum>i\<in>UNIV. u $ i * x $ i - v $ i * x $ i)

goal (1 subgoal):
 1. (u - v) \<bullet> x = u \<bullet> x - v \<bullet> x
[PROOF STEP]
from left_diff_distrib [where 'a = real]
[PROOF STATE]
proof (chain)
picking this:
(?a - ?b) * ?c = ?a * ?c - ?b * ?c
[PROOF STEP]
have
    "\<dots> = (\<Sum>i\<in>UNIV. (u$i - v$i) * x$i)"
[PROOF STATE]
proof (prove)
using this:
(?a - ?b) * ?c = ?a * ?c - ?b * ?c

goal (1 subgoal):
 1. (\<Sum>i\<in>UNIV. u $ i * x $ i - v $ i * x $ i) = (\<Sum>i\<in>UNIV. (u $ i - v $ i) * x $ i)
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
(\<Sum>i\<in>UNIV. u $ i * x $ i - v $ i * x $ i) = (\<Sum>i\<in>UNIV. (u $ i - v $ i) * x $ i)

goal (1 subgoal):
 1. (u - v) \<bullet> x = u \<bullet> x - v \<bullet> x
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
(\<Sum>i\<in>UNIV. u $ i * x $ i - v $ i * x $ i) = (\<Sum>i\<in>UNIV. (u $ i - v $ i) * x $ i)

goal (1 subgoal):
 1. (u - v) \<bullet> x = u \<bullet> x - v \<bullet> x
[PROOF STEP]
have
    "\<dots> = (u - v) \<bullet> x"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<Sum>i\<in>UNIV. (u $ i - v $ i) * x $ i) = (u - v) \<bullet> x
[PROOF STEP]
unfolding inner_vec_def
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<Sum>i\<in>UNIV. (u $ i - v $ i) * x $ i) = (\<Sum>i\<in>UNIV. (u - v) $ i \<bullet> x $ i)
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
(\<Sum>i\<in>UNIV. (u $ i - v $ i) * x $ i) = (u - v) \<bullet> x

goal (1 subgoal):
 1. (u - v) \<bullet> x = u \<bullet> x - v \<bullet> x
[PROOF STEP]
finally
[PROOF STATE]
proof (chain)
picking this:
u \<bullet> x - v \<bullet> x = (u - v) \<bullet> x
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
u \<bullet> x - v \<bullet> x = (u - v) \<bullet> x

goal (1 subgoal):
 1. (u - v) \<bullet> x = u \<bullet> x - v \<bullet> x
[PROOF STEP]
..
[PROOF STATE]
proof (state)
this:
(u - v) \<bullet> x = u \<bullet> x - v \<bullet> x

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma coplanar_perm_8:
  assumes "Coplanar A B C D"
  shows "Coplanar B C A D"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. Coplanar B C A D
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. Coplanar B C A D
[PROOF STEP]
obtain X where P1: "(Col A B X \<and> Col C D X) \<or> (Col A C X \<and> Col B D X) \<or> (Col A D X \<and> Col B C X)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<And>X. Col A B X \<and> Col C D X \<or> Col A C X \<and> Col B D X \<or> Col A D X \<and> Col B C X \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
using Coplanar_def assms
[PROOF STATE]
proof (prove)
using this:
Coplanar ?A ?B ?C ?D \<equiv> \<exists>X. Col ?A ?B X \<and> Col ?C ?D X \<or> Col ?A ?C X \<and> Col ?B ?D X \<or> Col ?A ?D X \<and> Col ?B ?C X
Coplanar A B C D

goal (1 subgoal):
 1. (\<And>X. Col A B X \<and> Col C D X \<or> Col A C X \<and> Col B D X \<or> Col A D X \<and> Col B C X \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
Col A B X \<and> Col C D X \<or> Col A C X \<and> Col B D X \<or> Col A D X \<and> Col B C X

goal (1 subgoal):
 1. Coplanar B C A D
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
Col A B X \<and> Col C D X \<or> Col A C X \<and> Col B D X \<or> Col A D X \<and> Col B C X
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
Col A B X \<and> Col C D X \<or> Col A C X \<and> Col B D X \<or> Col A D X \<and> Col B C X

goal (1 subgoal):
 1. Coplanar B C A D
[PROOF STEP]
using Coplanar_def col_permutation_4
[PROOF STATE]
proof (prove)
using this:
Col A B X \<and> Col C D X \<or> Col A C X \<and> Col B D X \<or> Col A D X \<and> Col B C X
Coplanar ?A ?B ?C ?D \<equiv> \<exists>X. Col ?A ?B X \<and> Col ?C ?D X \<or> Col ?A ?C X \<and> Col ?B ?D X \<or> Col ?A ?D X \<and> Col ?B ?C X
Col ?A ?B ?C \<Longrightarrow> Col ?B ?A ?C

goal (1 subgoal):
 1. Coplanar B C A D
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
Coplanar B C A D

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma exists_path_subpath_to_frontier_closed:
    fixes S :: "'a::real_normed_vector set"
    assumes S: "closed S" and g: "path g" and g0: "pathstart g \<in> S" and g1: "pathfinish g \<notin> S"
    obtains h where "path h" "pathstart h = pathstart g" "path_image h \<subseteq> path_image g \<inter> S"
                    "pathfinish h \<in> frontier S"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<And>h. \<lbrakk>path h; pathstart h = pathstart g; path_image h \<subseteq> path_image g \<inter> S; pathfinish h \<in> frontier S\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. (\<And>h. \<lbrakk>path h; pathstart h = pathstart g; path_image h \<subseteq> path_image g \<inter> S; pathfinish h \<in> frontier S\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
obtain h where h: "path h" "pathstart h = pathstart g" "path_image h \<subseteq> path_image g"
                    "path_image h - {pathfinish h} \<subseteq> interior S"
                    "pathfinish h \<in> frontier S"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<And>h. \<lbrakk>path h; pathstart h = pathstart g; path_image h \<subseteq> path_image g; path_image h - {pathfinish h} \<subseteq> interior S; pathfinish h \<in> frontier S\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
using exists_path_subpath_to_frontier [OF g _ g1] closure_closed [OF S] g0
[PROOF STATE]
proof (prove)
using this:
\<lbrakk>pathstart g \<in> closure S; \<And>h. \<lbrakk>path h; pathstart h = pathstart g; path_image h \<subseteq> path_image g; path_image h - {pathfinish h} \<subseteq> interior S; pathfinish h \<in> frontier S\<rbrakk> \<Longrightarrow> ?thesis\<rbrakk> \<Longrightarrow> ?thesis
closure S = S
pathstart g \<in> S

goal (1 subgoal):
 1. (\<And>h. \<lbrakk>path h; pathstart h = pathstart g; path_image h \<subseteq> path_image g; path_image h - {pathfinish h} \<subseteq> interior S; pathfinish h \<in> frontier S\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
path h
pathstart h = pathstart g
path_image h \<subseteq> path_image g
path_image h - {pathfinish h} \<subseteq> interior S
pathfinish h \<in> frontier S

goal (1 subgoal):
 1. (\<And>h. \<lbrakk>path h; pathstart h = pathstart g; path_image h \<subseteq> path_image g \<inter> S; pathfinish h \<in> frontier S\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. thesis
[PROOF STEP]
proof
[PROOF STATE]
proof (state)
goal (4 subgoals):
 1. path ?h
 2. pathstart ?h = pathstart g
 3. path_image ?h \<subseteq> path_image g \<inter> S
 4. pathfinish ?h \<in> frontier S
[PROOF STEP]
show "path_image h \<subseteq> path_image g \<inter> S"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. path_image h \<subseteq> path_image g \<inter> S
[PROOF STEP]
using assms h interior_subset [of S]
[PROOF STATE]
proof (prove)
using this:
closed S
path g
pathstart g \<in> S
pathfinish g \<notin> S
path h
pathstart h = pathstart g
path_image h \<subseteq> path_image g
path_image h - {pathfinish h} \<subseteq> interior S
pathfinish h \<in> frontier S
interior S \<subseteq> S

goal (1 subgoal):
 1. path_image h \<subseteq> path_image g \<inter> S
[PROOF STEP]
by (auto simp: frontier_def)
[PROOF STATE]
proof (state)
this:
path_image h \<subseteq> path_image g \<inter> S

goal (3 subgoals):
 1. path h
 2. pathstart h = pathstart g
 3. pathfinish h \<in> frontier S
[PROOF STEP]
qed (use h in auto)
[PROOF STATE]
proof (state)
this:
thesis

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma ewp_neg_and_omega: "\<not> ewp x \<longleftrightarrow> x\<^sup>\<omega> = 0"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<not> ewp x) = (x\<^sup>\<omega> = (0::'a))
[PROOF STEP]
proof
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. \<not> ewp x \<Longrightarrow> x\<^sup>\<omega> = (0::'a)
 2. x\<^sup>\<omega> = (0::'a) \<Longrightarrow> \<not> ewp x
[PROOF STEP]
assume "\<not> ewp x"
[PROOF STATE]
proof (state)
this:
\<not> ewp x

goal (2 subgoals):
 1. \<not> ewp x \<Longrightarrow> x\<^sup>\<omega> = (0::'a)
 2. x\<^sup>\<omega> = (0::'a) \<Longrightarrow> \<not> ewp x
[PROOF STEP]
hence "\<forall> y. y \<le> x \<cdot> y \<longrightarrow> y = 0"
[PROOF STATE]
proof (prove)
using this:
\<not> ewp x

goal (1 subgoal):
 1. \<forall>y. y \<le> x \<cdot> y \<longrightarrow> y = (0::'a)
[PROOF STEP]
by (meson ewp_def)
[PROOF STATE]
proof (state)
this:
\<forall>y. y \<le> x \<cdot> y \<longrightarrow> y = (0::'a)

goal (2 subgoals):
 1. \<not> ewp x \<Longrightarrow> x\<^sup>\<omega> = (0::'a)
 2. x\<^sup>\<omega> = (0::'a) \<Longrightarrow> \<not> ewp x
[PROOF STEP]
thus "x\<^sup>\<omega> = 0"
[PROOF STATE]
proof (prove)
using this:
\<forall>y. y \<le> x \<cdot> y \<longrightarrow> y = (0::'a)

goal (1 subgoal):
 1. x\<^sup>\<omega> = (0::'a)
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
x\<^sup>\<omega> = (0::'a)

goal (1 subgoal):
 1. x\<^sup>\<omega> = (0::'a) \<Longrightarrow> \<not> ewp x
[PROOF STEP]
next
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. x\<^sup>\<omega> = (0::'a) \<Longrightarrow> \<not> ewp x
[PROOF STEP]
assume "x\<^sup>\<omega> = 0"
[PROOF STATE]
proof (state)
this:
x\<^sup>\<omega> = (0::'a)

goal (1 subgoal):
 1. x\<^sup>\<omega> = (0::'a) \<Longrightarrow> \<not> ewp x
[PROOF STEP]
hence "\<forall> y. y \<le> x \<cdot> y \<longrightarrow> y = 0"
[PROOF STATE]
proof (prove)
using this:
x\<^sup>\<omega> = (0::'a)

goal (1 subgoal):
 1. \<forall>y. y \<le> x \<cdot> y \<longrightarrow> y = (0::'a)
[PROOF STEP]
using local.join.le_bot local.omega_coinduct_var2
[PROOF STATE]
proof (prove)
using this:
x\<^sup>\<omega> = (0::'a)
?a \<le> (0::'a) \<Longrightarrow> ?a = (0::'a)
?y \<le> ?x \<cdot> ?y \<Longrightarrow> ?y \<le> ?x\<^sup>\<omega>

goal (1 subgoal):
 1. \<forall>y. y \<le> x \<cdot> y \<longrightarrow> y = (0::'a)
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
\<forall>y. y \<le> x \<cdot> y \<longrightarrow> y = (0::'a)

goal (1 subgoal):
 1. x\<^sup>\<omega> = (0::'a) \<Longrightarrow> \<not> ewp x
[PROOF STEP]
thus "\<not> ewp x"
[PROOF STATE]
proof (prove)
using this:
\<forall>y. y \<le> x \<cdot> y \<longrightarrow> y = (0::'a)

goal (1 subgoal):
 1. \<not> ewp x
[PROOF STEP]
by (meson ewp_def)
[PROOF STATE]
proof (state)
this:
\<not> ewp x

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma ACIcl_set_eq:
  fixes r s :: "'a rexp"
  assumes "r ~~ s"
  shows "set_rexp r = set_rexp s"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. set_rexp r = set_rexp s
[PROOF STEP]
using assms
[PROOF STATE]
proof (prove)
using this:
r ~~ s

goal (1 subgoal):
 1. set_rexp r = set_rexp s
[PROOF STEP]
by (induct rule: equivclp_induct) (auto dest: ACI_set_eq)


[STATEMENT]
lemma (in pre_digraph) digraph_isomorphism_subgraphI:
  assumes "digraph_isomorphism hom"
  assumes "subgraph H G"
  shows "pre_digraph.digraph_isomorphism H hom"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. pre_digraph.digraph_isomorphism H hom
[PROOF STEP]
using assms
[PROOF STATE]
proof (prove)
using this:
digraph_isomorphism hom
subgraph H G

goal (1 subgoal):
 1. pre_digraph.digraph_isomorphism H hom
[PROOF STEP]
by (auto simp: pre_digraph.digraph_isomorphism_def subgraph_def compatible_def intro: subset_inj_on)


[STATEMENT]
lemma ball_eball_mono: "ereal r \<le> r' \<Longrightarrow> ball z r \<le> eball z r'"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. ereal r \<le> r' \<Longrightarrow> ball z r \<subseteq> eball z r'
[PROOF STEP]
using eball_mono[of "ereal r" r']
[PROOF STATE]
proof (prove)
using this:
ereal r \<le> r' \<Longrightarrow> eball ?z (ereal r) \<subseteq> eball ?z r'

goal (1 subgoal):
 1. ereal r \<le> r' \<Longrightarrow> ball z r \<subseteq> eball z r'
[PROOF STEP]
by simp


[STATEMENT]
lemma smallD_nonneg_real:
  assumes "f \<in> lr F (g)" "eventually (\<lambda>x. f x \<ge> 0) F" "c > 0"
  shows   "eventually (\<lambda>x. R (f x) (c * \<bar>g x\<bar>)) F"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<forall>\<^sub>F x in F. R (f x) (c * \<bar>g x\<bar>)
[PROOF STEP]
using assms
[PROOF STATE]
proof (prove)
using this:
f \<in> lr F g
\<forall>\<^sub>F x in F. 0 \<le> f x
0 < c

goal (1 subgoal):
 1. \<forall>\<^sub>F x in F. R (f x) (c * \<bar>g x\<bar>)
[PROOF STEP]
by (auto simp: lr_def dest!: spec[of _ c] elim: eventually_elim2)


[STATEMENT]
lemma r01_binary_expression_eq_lr:
  "snd (snd (r01_binary_expansion'' r n)) = r01_binary_expression r n"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. snd (snd (r01_binary_expansion'' r n)) = r01_binary_expression r n
[PROOF STEP]
proof(induction n)
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. snd (snd (r01_binary_expansion'' r 0)) = r01_binary_expression r 0
 2. \<And>n. snd (snd (r01_binary_expansion'' r n)) = r01_binary_expression r n \<Longrightarrow> snd (snd (r01_binary_expansion'' r (Suc n))) = r01_binary_expression r (Suc n)
[PROOF STEP]
case 0
[PROOF STATE]
proof (state)
this:

goal (2 subgoals):
 1. snd (snd (r01_binary_expansion'' r 0)) = r01_binary_expression r 0
 2. \<And>n. snd (snd (r01_binary_expansion'' r n)) = r01_binary_expression r n \<Longrightarrow> snd (snd (r01_binary_expansion'' r (Suc n))) = r01_binary_expression r (Suc n)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
[PROOF STEP]
show ?case
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. snd (snd (r01_binary_expansion'' r 0)) = r01_binary_expression r 0
[PROOF STEP]
by(simp add: r01_binary_expression_def r01_binary_sum_def r01_binary_expansion'_def)
[PROOF STATE]
proof (state)
this:
snd (snd (r01_binary_expansion'' r 0)) = r01_binary_expression r 0

goal (1 subgoal):
 1. \<And>n. snd (snd (r01_binary_expansion'' r n)) = r01_binary_expression r n \<Longrightarrow> snd (snd (r01_binary_expansion'' r (Suc n))) = r01_binary_expression r (Suc n)
[PROOF STEP]
next
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>n. snd (snd (r01_binary_expansion'' r n)) = r01_binary_expression r n \<Longrightarrow> snd (snd (r01_binary_expansion'' r (Suc n))) = r01_binary_expression r (Suc n)
[PROOF STEP]
case 1:(Suc n')
[PROOF STATE]
proof (state)
this:
snd (snd (r01_binary_expansion'' r n')) = r01_binary_expression r n'

goal (1 subgoal):
 1. \<And>n. snd (snd (r01_binary_expansion'' r n)) = r01_binary_expression r n \<Longrightarrow> snd (snd (r01_binary_expansion'' r (Suc n))) = r01_binary_expression r (Suc n)
[PROOF STEP]
show ?case
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. snd (snd (r01_binary_expansion'' r (Suc n'))) = r01_binary_expression r (Suc n')
[PROOF STEP]
proof (cases "r01_binary_expansion'' r n'")
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>a b c. r01_binary_expansion'' r n' = (a, b, c) \<Longrightarrow> snd (snd (r01_binary_expansion'' r (Suc n'))) = r01_binary_expression r (Suc n')
[PROOF STEP]
case 2:(fields a ur lr)
[PROOF STATE]
proof (state)
this:
r01_binary_expansion'' r n' = (a, ur, lr)

goal (1 subgoal):
 1. \<And>a b c. r01_binary_expansion'' r n' = (a, b, c) \<Longrightarrow> snd (snd (r01_binary_expansion'' r (Suc n'))) = r01_binary_expression r (Suc n')
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
r01_binary_expansion'' r n' = (a, ur, lr)
[PROOF STEP]
have ih:"lr = (\<Sum>i = 0..n'. real (fst (r01_binary_expansion'' r i)) * (1 / 2) ^ i / 2)"
[PROOF STATE]
proof (prove)
using this:
r01_binary_expansion'' r n' = (a, ur, lr)

goal (1 subgoal):
 1. lr = (\<Sum>i = 0..n'. real (fst (r01_binary_expansion'' r i)) * (1 / 2) ^ i / 2)
[PROOF STEP]
using 1
[PROOF STATE]
proof (prove)
using this:
r01_binary_expansion'' r n' = (a, ur, lr)
snd (snd (r01_binary_expansion'' r n')) = r01_binary_expression r n'

goal (1 subgoal):
 1. lr = (\<Sum>i = 0..n'. real (fst (r01_binary_expansion'' r i)) * (1 / 2) ^ i / 2)
[PROOF STEP]
by(simp add: r01_binary_expression_def r01_binary_sum_def r01_binary_expansion'_def)
[PROOF STATE]
proof (state)
this:
lr = (\<Sum>i = 0..n'. real (fst (r01_binary_expansion'' r i)) * (1 / 2) ^ i / 2)

goal (1 subgoal):
 1. \<And>a b c. r01_binary_expansion'' r n' = (a, b, c) \<Longrightarrow> snd (snd (r01_binary_expansion'' r (Suc n'))) = r01_binary_expression r (Suc n')
[PROOF STEP]
have 3:"(ur + lr) / 2 = lr + (1/2)^(Suc (Suc n'))"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (ur + lr) / 2 = lr + (1 / 2) ^ Suc (Suc n')
[PROOF STEP]
using r01_binary_expansion_diff[of r n'] 2
[PROOF STATE]
proof (prove)
using this:
fst (snd (r01_binary_expansion'' r n')) - snd (snd (r01_binary_expansion'' r n')) = (1 / 2) ^ Suc n'
r01_binary_expansion'' r n' = (a, ur, lr)

goal (1 subgoal):
 1. (ur + lr) / 2 = lr + (1 / 2) ^ Suc (Suc n')
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
(ur + lr) / 2 = lr + (1 / 2) ^ Suc (Suc n')

goal (1 subgoal):
 1. \<And>a b c. r01_binary_expansion'' r n' = (a, b, c) \<Longrightarrow> snd (snd (r01_binary_expansion'' r (Suc n'))) = r01_binary_expression r (Suc n')
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. snd (snd (r01_binary_expansion'' r (Suc n'))) = r01_binary_expression r (Suc n')
[PROOF STEP]
by(simp add: r01_binary_expression_def r01_binary_sum_def r01_binary_expansion'_def 2 Let_def 3) fact
[PROOF STATE]
proof (state)
this:
snd (snd (r01_binary_expansion'' r (Suc n'))) = r01_binary_expression r (Suc n')

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
snd (snd (r01_binary_expansion'' r (Suc n'))) = r01_binary_expression r (Suc n')

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma fds_abs_converges_uminus:
  assumes "fds_abs_converges f s"
  shows   "fds_abs_converges (-f) s"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. fds_abs_converges (- f) s
[PROOF STEP]
using assms
[PROOF STATE]
proof (prove)
using this:
fds_abs_converges f s

goal (1 subgoal):
 1. fds_abs_converges (- f) s
[PROOF STEP]
by (simp add: fds_abs_converges_def)


[STATEMENT]
lemma face_cycle_succ_pred[simp]:
    shows "face_cycle_succ (face_cycle_pred a) = a"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. face_cycle_succ (face_cycle_pred a) = a
[PROOF STEP]
unfolding face_cycle_pred_def face_cycle_succ_def
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (edge_succ M \<circ> edge_rev M) ((edge_rev M \<circ> edge_pred M) a) = a
[PROOF STEP]
by simp


[STATEMENT]
lemma vec_inv[simp]:
  assumes v: "v : carrier_vec n"
      and v0: "(v::'a::conjugatable_ordered_field vec) \<noteq> 0\<^sub>v n"
  shows "vec_inv v \<bullet> v = 1"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. vec_inv v \<bullet> v = (1::'a)
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. vec_inv v \<bullet> v = (1::'a)
[PROOF STEP]
{
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. vec_inv v \<bullet> v = (1::'a)
[PROOF STEP]
assume "v \<bullet>c v = 0"
[PROOF STATE]
proof (state)
this:
v \<bullet>c v = (0::'a)

goal (1 subgoal):
 1. vec_inv v \<bullet> v = (1::'a)
[PROOF STEP]
hence "v = 0\<^sub>v n"
[PROOF STATE]
proof (prove)
using this:
v \<bullet>c v = (0::'a)

goal (1 subgoal):
 1. v = 0\<^sub>v n
[PROOF STEP]
using conjugate_square_eq_0_vec[OF v]
[PROOF STATE]
proof (prove)
using this:
v \<bullet>c v = (0::'a)
(v \<bullet>c v = (0::'a)) = (v = 0\<^sub>v n)

goal (1 subgoal):
 1. v = 0\<^sub>v n
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
v = 0\<^sub>v n

goal (1 subgoal):
 1. vec_inv v \<bullet> v = (1::'a)
[PROOF STEP]
hence False
[PROOF STATE]
proof (prove)
using this:
v = 0\<^sub>v n

goal (1 subgoal):
 1. False
[PROOF STEP]
using v0
[PROOF STATE]
proof (prove)
using this:
v = 0\<^sub>v n
v \<noteq> 0\<^sub>v n

goal (1 subgoal):
 1. False
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
False

goal (1 subgoal):
 1. vec_inv v \<bullet> v = (1::'a)
[PROOF STEP]
}
[PROOF STATE]
proof (state)
this:
v \<bullet>c v = (0::'a) \<Longrightarrow> False

goal (1 subgoal):
 1. vec_inv v \<bullet> v = (1::'a)
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
v \<bullet>c v = (0::'a) \<Longrightarrow> False

goal (1 subgoal):
 1. vec_inv v \<bullet> v = (1::'a)
[PROOF STEP]
have "conjugate v \<bullet> v = v \<bullet>c v"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. conjugate v \<bullet> v = v \<bullet>c v
[PROOF STEP]
apply (rule comm_scalar_prod)
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. conjugate v \<in> carrier_vec ?n
 2. v \<in> carrier_vec ?n
[PROOF STEP]
using v
[PROOF STATE]
proof (prove)
using this:
v \<in> carrier_vec n

goal (2 subgoals):
 1. conjugate v \<in> carrier_vec ?n
 2. v \<in> carrier_vec ?n
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
conjugate v \<bullet> v = v \<bullet>c v

goal (1 subgoal):
 1. vec_inv v \<bullet> v = (1::'a)
[PROOF STEP]
ultimately
[PROOF STATE]
proof (chain)
picking this:
v \<bullet>c v = (0::'a) \<Longrightarrow> False
conjugate v \<bullet> v = v \<bullet>c v
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
v \<bullet>c v = (0::'a) \<Longrightarrow> False
conjugate v \<bullet> v = v \<bullet>c v

goal (1 subgoal):
 1. vec_inv v \<bullet> v = (1::'a)
[PROOF STEP]
unfolding vec_inv_def
[PROOF STATE]
proof (prove)
using this:
v \<bullet>c v = (0::'a) \<Longrightarrow> False
conjugate v \<bullet> v = v \<bullet>c v

goal (1 subgoal):
 1. ((1::'a) / (v \<bullet>c v) \<cdot>\<^sub>v conjugate v) \<bullet> v = (1::'a)
[PROOF STEP]
apply (subst smult_scalar_prod_distrib)
[PROOF STATE]
proof (prove)
goal (3 subgoals):
 1. \<lbrakk>v \<bullet>c v = (0::'a) \<Longrightarrow> False; conjugate v \<bullet> v = v \<bullet>c v\<rbrakk> \<Longrightarrow> conjugate v \<in> carrier_vec ?n2
 2. \<lbrakk>v \<bullet>c v = (0::'a) \<Longrightarrow> False; conjugate v \<bullet> v = v \<bullet>c v\<rbrakk> \<Longrightarrow> v \<in> carrier_vec ?n2
 3. \<lbrakk>v \<bullet>c v = (0::'a) \<Longrightarrow> False; conjugate v \<bullet> v = v \<bullet>c v\<rbrakk> \<Longrightarrow> (1::'a) / (v \<bullet>c v) * (conjugate v \<bullet> v) = (1::'a)
[PROOF STEP]
using assms
[PROOF STATE]
proof (prove)
using this:
v \<in> carrier_vec n
v \<noteq> 0\<^sub>v n

goal (3 subgoals):
 1. \<lbrakk>v \<bullet>c v = (0::'a) \<Longrightarrow> False; conjugate v \<bullet> v = v \<bullet>c v\<rbrakk> \<Longrightarrow> conjugate v \<in> carrier_vec ?n2
 2. \<lbrakk>v \<bullet>c v = (0::'a) \<Longrightarrow> False; conjugate v \<bullet> v = v \<bullet>c v\<rbrakk> \<Longrightarrow> v \<in> carrier_vec ?n2
 3. \<lbrakk>v \<bullet>c v = (0::'a) \<Longrightarrow> False; conjugate v \<bullet> v = v \<bullet>c v\<rbrakk> \<Longrightarrow> (1::'a) / (v \<bullet>c v) * (conjugate v \<bullet> v) = (1::'a)
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
vec_inv v \<bullet> v = (1::'a)

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma leaf_out_degree_zero: "leaf v \<Longrightarrow> out_degree T v = 0"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. leaf v \<Longrightarrow> out_degree T v = 0
[PROOF STEP]
unfolding leaf_def out_degree_def
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. v \<in> verts T \<and> out_arcs T v = {} \<Longrightarrow> card (out_arcs T v) = 0
[PROOF STEP]
by auto


[STATEMENT]
lemma gen_llength_code [code]:
  "gen_llength n LNil = enat n"
  "gen_llength n (LCons x xs) = gen_llength (n + 1) xs"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. gen_llength n LNil = enat n &&& gen_llength n (LCons x xs) = gen_llength (n + 1) xs
[PROOF STEP]
by(simp_all add: gen_llength_def iadd_Suc eSuc_enat[symmetric] iadd_Suc_right)


[STATEMENT]
lemma coplanar_perm_14:
  assumes "Coplanar A B C D"
  shows "Coplanar C B A D"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. Coplanar C B A D
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. Coplanar C B A D
[PROOF STEP]
obtain X where P1: "(Col A B X \<and> Col C D X) \<or> (Col A C X \<and> Col B D X) \<or> (Col A D X \<and> Col B C X)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<And>X. Col A B X \<and> Col C D X \<or> Col A C X \<and> Col B D X \<or> Col A D X \<and> Col B C X \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
using Coplanar_def assms
[PROOF STATE]
proof (prove)
using this:
Coplanar ?A ?B ?C ?D \<equiv> \<exists>X. Col ?A ?B X \<and> Col ?C ?D X \<or> Col ?A ?C X \<and> Col ?B ?D X \<or> Col ?A ?D X \<and> Col ?B ?C X
Coplanar A B C D

goal (1 subgoal):
 1. (\<And>X. Col A B X \<and> Col C D X \<or> Col A C X \<and> Col B D X \<or> Col A D X \<and> Col B C X \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
Col A B X \<and> Col C D X \<or> Col A C X \<and> Col B D X \<or> Col A D X \<and> Col B C X

goal (1 subgoal):
 1. Coplanar C B A D
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
Col A B X \<and> Col C D X \<or> Col A C X \<and> Col B D X \<or> Col A D X \<and> Col B C X
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
Col A B X \<and> Col C D X \<or> Col A C X \<and> Col B D X \<or> Col A D X \<and> Col B C X

goal (1 subgoal):
 1. Coplanar C B A D
[PROOF STEP]
using Coplanar_def col_permutation_4
[PROOF STATE]
proof (prove)
using this:
Col A B X \<and> Col C D X \<or> Col A C X \<and> Col B D X \<or> Col A D X \<and> Col B C X
Coplanar ?A ?B ?C ?D \<equiv> \<exists>X. Col ?A ?B X \<and> Col ?C ?D X \<or> Col ?A ?C X \<and> Col ?B ?D X \<or> Col ?A ?D X \<and> Col ?B ?C X
Col ?A ?B ?C \<Longrightarrow> Col ?B ?A ?C

goal (1 subgoal):
 1. Coplanar C B A D
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
Coplanar C B A D

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma r_lchild_le_r: "well_shaped t \<Longrightarrow> r (lchild t) \<le> r t"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. well_shaped t \<Longrightarrow> r (lchild t) \<le> r t
[PROOF STEP]
proof (induct t)
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. well_shaped Leaf \<Longrightarrow> r (lchild Leaf) \<le> r Leaf
 2. \<And>x1 x2 x3 t1 t2. \<lbrakk>well_shaped t1 \<Longrightarrow> r (lchild t1) \<le> r t1; well_shaped t2 \<Longrightarrow> r (lchild t2) \<le> r t2; well_shaped (Node x1 x2 x3 t1 t2)\<rbrakk> \<Longrightarrow> r (lchild (Node x1 x2 x3 t1 t2)) \<le> r (Node x1 x2 x3 t1 t2)
[PROOF STEP]
case (Node i j a t1 t2)
[PROOF STATE]
proof (state)
this:
well_shaped t1 \<Longrightarrow> r (lchild t1) \<le> r t1
well_shaped t2 \<Longrightarrow> r (lchild t2) \<le> r t2
well_shaped (Node i j a t1 t2)

goal (2 subgoals):
 1. well_shaped Leaf \<Longrightarrow> r (lchild Leaf) \<le> r Leaf
 2. \<And>x1 x2 x3 t1 t2. \<lbrakk>well_shaped t1 \<Longrightarrow> r (lchild t1) \<le> r t1; well_shaped t2 \<Longrightarrow> r (lchild t2) \<le> r t2; well_shaped (Node x1 x2 x3 t1 t2)\<rbrakk> \<Longrightarrow> r (lchild (Node x1 x2 x3 t1 t2)) \<le> r (Node x1 x2 x3 t1 t2)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
well_shaped t1 \<Longrightarrow> r (lchild t1) \<le> r t1
well_shaped t2 \<Longrightarrow> r (lchild t2) \<le> r t2
well_shaped (Node i j a t1 t2)
[PROOF STEP]
show ?case
[PROOF STATE]
proof (prove)
using this:
well_shaped t1 \<Longrightarrow> r (lchild t1) \<le> r t1
well_shaped t2 \<Longrightarrow> r (lchild t2) \<le> r t2
well_shaped (Node i j a t1 t2)

goal (1 subgoal):
 1. r (lchild (Node i j a t1 t2)) \<le> r (Node i j a t1 t2)
[PROOF STEP]
by auto
      (metis Suc_eq_plus1_left order.trans le_add2 tree.exhaust_sel well_shaped.simps(2))
[PROOF STATE]
proof (state)
this:
r (lchild (Node i j a t1 t2)) \<le> r (Node i j a t1 t2)

goal (1 subgoal):
 1. well_shaped Leaf \<Longrightarrow> r (lchild Leaf) \<le> r Leaf
[PROOF STEP]
qed simp


[STATEMENT]
lemma Plus:
  fixes A :: "'b set" and B :: "'c set"
  assumes fin: "finite A" "finite B"
  shows "F g (A <+> B) = F (g \<circ> Inl) A \<^bold>* F (g \<circ> Inr) B"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. F g (A <+> B) = F (g \<circ> Inl) A \<^bold>* F (g \<circ> Inr) B
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. F g (A <+> B) = F (g \<circ> Inl) A \<^bold>* F (g \<circ> Inr) B
[PROOF STEP]
have "A <+> B = Inl ` A \<union> Inr ` B"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. A <+> B = Inl ` A \<union> Inr ` B
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
A <+> B = Inl ` A \<union> Inr ` B

goal (1 subgoal):
 1. F g (A <+> B) = F (g \<circ> Inl) A \<^bold>* F (g \<circ> Inr) B
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
A <+> B = Inl ` A \<union> Inr ` B

goal (1 subgoal):
 1. F g (A <+> B) = F (g \<circ> Inl) A \<^bold>* F (g \<circ> Inr) B
[PROOF STEP]
from fin
[PROOF STATE]
proof (chain)
picking this:
finite A
finite B
[PROOF STEP]
have "finite (Inl ` A)" "finite (Inr ` B)"
[PROOF STATE]
proof (prove)
using this:
finite A
finite B

goal (1 subgoal):
 1. finite (Inl ` A) &&& finite (Inr ` B)
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
finite (Inl ` A)
finite (Inr ` B)

goal (1 subgoal):
 1. F g (A <+> B) = F (g \<circ> Inl) A \<^bold>* F (g \<circ> Inr) B
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
finite (Inl ` A)
finite (Inr ` B)

goal (1 subgoal):
 1. F g (A <+> B) = F (g \<circ> Inl) A \<^bold>* F (g \<circ> Inr) B
[PROOF STEP]
have "Inl ` A \<inter> Inr ` B = {}"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. Inl ` A \<inter> Inr ` B = {}
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
Inl ` A \<inter> Inr ` B = {}

goal (1 subgoal):
 1. F g (A <+> B) = F (g \<circ> Inl) A \<^bold>* F (g \<circ> Inr) B
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
Inl ` A \<inter> Inr ` B = {}

goal (1 subgoal):
 1. F g (A <+> B) = F (g \<circ> Inl) A \<^bold>* F (g \<circ> Inr) B
[PROOF STEP]
have "inj_on Inl A" "inj_on Inr B"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. inj_on Inl A &&& inj_on Inr B
[PROOF STEP]
by (auto intro: inj_onI)
[PROOF STATE]
proof (state)
this:
inj_on Inl A
inj_on Inr B

goal (1 subgoal):
 1. F g (A <+> B) = F (g \<circ> Inl) A \<^bold>* F (g \<circ> Inr) B
[PROOF STEP]
ultimately
[PROOF STATE]
proof (chain)
picking this:
A <+> B = Inl ` A \<union> Inr ` B
finite (Inl ` A)
finite (Inr ` B)
Inl ` A \<inter> Inr ` B = {}
inj_on Inl A
inj_on Inr B
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
A <+> B = Inl ` A \<union> Inr ` B
finite (Inl ` A)
finite (Inr ` B)
Inl ` A \<inter> Inr ` B = {}
inj_on Inl A
inj_on Inr B

goal (1 subgoal):
 1. F g (A <+> B) = F (g \<circ> Inl) A \<^bold>* F (g \<circ> Inr) B
[PROOF STEP]
using fin
[PROOF STATE]
proof (prove)
using this:
A <+> B = Inl ` A \<union> Inr ` B
finite (Inl ` A)
finite (Inr ` B)
Inl ` A \<inter> Inr ` B = {}
inj_on Inl A
inj_on Inr B
finite A
finite B

goal (1 subgoal):
 1. F g (A <+> B) = F (g \<circ> Inl) A \<^bold>* F (g \<circ> Inr) B
[PROOF STEP]
by (simp add: union_disjoint reindex)
[PROOF STATE]
proof (state)
this:
F g (A <+> B) = F (g \<circ> Inl) A \<^bold>* F (g \<circ> Inr) B

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma map_project_conv_fold:
  "List.map_project f (set xs) =
   fold (\<lambda>x A. case f x of None \<Rightarrow> A | Some y \<Rightarrow> insert y A) xs {}"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. List.map_project f (set xs) = fold (\<lambda>x A. case f x of None \<Rightarrow> A | Some y \<Rightarrow> insert y A) xs {}
[PROOF STEP]
by(induct xs rule: rev_induct)(simp_all add: map_project_simps cong: option.case_cong)


[STATEMENT]
lemma AE_embed_measure:
  assumes inj: "inj f"
  shows "(AE x in embed_measure M f. P x) \<longleftrightarrow> (AE x in M. P (f x))"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. almost_everywhere (embed_measure M f) P = (AE x in M. P (f x))
[PROOF STEP]
using assms
[PROOF STATE]
proof (prove)
using this:
inj f

goal (1 subgoal):
 1. almost_everywhere (embed_measure M f) P = (AE x in M. P (f x))
[PROOF STEP]
by (intro AE_embed_measure') (auto intro!: inj_onI dest: injD)


[STATEMENT]
lemma c_sum_eq_arg: "c_sum x = x \<Longrightarrow> x \<le> 1"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. c_sum x = x \<Longrightarrow> x \<le> 1
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. c_sum x = x \<Longrightarrow> x \<le> 1
[PROOF STEP]
assume A1: "c_sum x = x"
[PROOF STATE]
proof (state)
this:
c_sum x = x

goal (1 subgoal):
 1. c_sum x = x \<Longrightarrow> x \<le> 1
[PROOF STEP]
have S1: "sf(c_sum x) + c_fst x = x"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. sf (c_sum x) + c_fst x = x
[PROOF STEP]
by (rule sf_c_sum_plus_c_fst)
[PROOF STATE]
proof (state)
this:
sf (c_sum x) + c_fst x = x

goal (1 subgoal):
 1. c_sum x = x \<Longrightarrow> x \<le> 1
[PROOF STEP]
from A1 S1
[PROOF STATE]
proof (chain)
picking this:
c_sum x = x
sf (c_sum x) + c_fst x = x
[PROOF STEP]
have S2: "sf x + c_fst x = x"
[PROOF STATE]
proof (prove)
using this:
c_sum x = x
sf (c_sum x) + c_fst x = x

goal (1 subgoal):
 1. sf x + c_fst x = x
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
sf x + c_fst x = x

goal (1 subgoal):
 1. c_sum x = x \<Longrightarrow> x \<le> 1
[PROOF STEP]
have S3: "x \<le> sf x"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. x \<le> sf x
[PROOF STEP]
by (rule arg_le_sf)
[PROOF STATE]
proof (state)
this:
x \<le> sf x

goal (1 subgoal):
 1. c_sum x = x \<Longrightarrow> x \<le> 1
[PROOF STEP]
from S2 S3
[PROOF STATE]
proof (chain)
picking this:
sf x + c_fst x = x
x \<le> sf x
[PROOF STEP]
have "sf(x)=x"
[PROOF STATE]
proof (prove)
using this:
sf x + c_fst x = x
x \<le> sf x

goal (1 subgoal):
 1. sf x = x
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
sf x = x

goal (1 subgoal):
 1. c_sum x = x \<Longrightarrow> x \<le> 1
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
sf x = x

goal (1 subgoal):
 1. x \<le> 1
[PROOF STEP]
by (rule sf_eq_arg)
[PROOF STATE]
proof (state)
this:
x \<le> 1

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma congruence_nonzero:
  assumes "H \<noteq> mat_zero" and "mat_det M \<noteq> 0"
  shows "congruence M H \<noteq> mat_zero"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. congruence M H \<noteq> mat_zero
[PROOF STEP]
using assms
[PROOF STATE]
proof (prove)
using this:
H \<noteq> mat_zero
mat_det M \<noteq> 0

goal (1 subgoal):
 1. congruence M H \<noteq> mat_zero
[PROOF STEP]
unfolding congruence_def
[PROOF STATE]
proof (prove)
using this:
H \<noteq> mat_zero
mat_det M \<noteq> 0

goal (1 subgoal):
 1. mat_adj M *\<^sub>m\<^sub>m H *\<^sub>m\<^sub>m M \<noteq> mat_zero
[PROOF STEP]
by (subst mult_mm_non_zero_r, subst mult_mm_non_zero_l) (auto simp add: mat_det_adj)


[STATEMENT]
lemma negligible_powerI [negligible_intros]:
  fixes k :: real
  assumes "\<bar>k\<bar> < 1"
  shows "negligible (\<lambda>n. k ^ n)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. negligible ((^) k)
[PROOF STEP]
proof(cases "k = 0")
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. k = 0 \<Longrightarrow> negligible ((^) k)
 2. k \<noteq> 0 \<Longrightarrow> negligible ((^) k)
[PROOF STEP]
case True
[PROOF STATE]
proof (state)
this:
k = 0

goal (2 subgoals):
 1. k = 0 \<Longrightarrow> negligible ((^) k)
 2. k \<noteq> 0 \<Longrightarrow> negligible ((^) k)
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. negligible ((^) k)
[PROOF STEP]
using negligible_K0
[PROOF STATE]
proof (prove)
using this:
negligible (\<lambda>_. 0)

goal (1 subgoal):
 1. negligible ((^) k)
[PROOF STEP]
by(rule negligible_mono)(auto intro: exI[where x=1] simp add: True eventually_at_top_linorder)
[PROOF STATE]
proof (state)
this:
negligible ((^) k)

goal (1 subgoal):
 1. k \<noteq> 0 \<Longrightarrow> negligible ((^) k)
[PROOF STEP]
next
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. k \<noteq> 0 \<Longrightarrow> negligible ((^) k)
[PROOF STEP]
case False
[PROOF STATE]
proof (state)
this:
k \<noteq> 0

goal (1 subgoal):
 1. k \<noteq> 0 \<Longrightarrow> negligible ((^) k)
[PROOF STEP]
hence "0 < \<bar>k\<bar>"
[PROOF STATE]
proof (prove)
using this:
k \<noteq> 0

goal (1 subgoal):
 1. 0 < \<bar>k\<bar>
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
0 < \<bar>k\<bar>

goal (1 subgoal):
 1. k \<noteq> 0 \<Longrightarrow> negligible ((^) k)
[PROOF STEP]
from assms
[PROOF STATE]
proof (chain)
picking this:
\<bar>k\<bar> < 1
[PROOF STEP]
have "negligible (\<lambda>x. \<bar>k\<bar> powr real x)"
[PROOF STATE]
proof (prove)
using this:
\<bar>k\<bar> < 1

goal (1 subgoal):
 1. negligible (\<lambda>x. \<bar>k\<bar> powr real x)
[PROOF STEP]
using negligible_powrI[of "\<bar>k\<bar>"]
[PROOF STATE]
proof (prove)
using this:
\<bar>k\<bar> < 1
\<lbrakk>0 \<le> \<bar>k\<bar>; \<bar>k\<bar> < 1\<rbrakk> \<Longrightarrow> negligible (\<lambda>x. \<bar>k\<bar> powr real x)

goal (1 subgoal):
 1. negligible (\<lambda>x. \<bar>k\<bar> powr real x)
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
negligible (\<lambda>x. \<bar>k\<bar> powr real x)

goal (1 subgoal):
 1. k \<noteq> 0 \<Longrightarrow> negligible ((^) k)
[PROOF STEP]
hence "negligible (\<lambda>x. \<bar>k\<bar> ^ x)"
[PROOF STATE]
proof (prove)
using this:
negligible (\<lambda>x. \<bar>k\<bar> powr real x)

goal (1 subgoal):
 1. negligible ((^) \<bar>k\<bar>)
[PROOF STEP]
using False
[PROOF STATE]
proof (prove)
using this:
negligible (\<lambda>x. \<bar>k\<bar> powr real x)
k \<noteq> 0

goal (1 subgoal):
 1. negligible ((^) \<bar>k\<bar>)
[PROOF STEP]
by(elim negligible_mono)(simp add: powr_realpow)
[PROOF STATE]
proof (state)
this:
negligible ((^) \<bar>k\<bar>)

goal (1 subgoal):
 1. k \<noteq> 0 \<Longrightarrow> negligible ((^) k)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
negligible ((^) \<bar>k\<bar>)
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
negligible ((^) \<bar>k\<bar>)

goal (1 subgoal):
 1. negligible ((^) k)
[PROOF STEP]
by(simp add: power_abs[symmetric])
[PROOF STATE]
proof (state)
this:
negligible ((^) k)

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
theorem AG_induct: "p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) = \<^bold>A\<^bold>G p"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) = \<^bold>A\<^bold>G p
[PROOF STEP]
proof
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>G p
 2. \<^bold>A\<^bold>G p \<subseteq> p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
show "p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>G p"  (is "?lhs \<subseteq> _")
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>G p
[PROOF STEP]
proof (rule AG_I)
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> p \<inter> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
show "?lhs \<subseteq> p \<inter> \<^bold>A\<^bold>X ?lhs"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> p \<inter> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
proof
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> p
 2. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
show "?lhs \<subseteq> p"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> p
[PROOF STEP]
..
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> p

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
show "?lhs \<subseteq> \<^bold>A\<^bold>X ?lhs"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
{
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
have "\<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> p \<rightarrow> \<^bold>A\<^bold>X p"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> p \<rightarrow> \<^bold>A\<^bold>X p
[PROOF STEP]
by (rule AG_fp_1)
[PROOF STATE]
proof (state)
this:
\<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> p \<rightarrow> \<^bold>A\<^bold>X p

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
\<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> p \<rightarrow> \<^bold>A\<^bold>X p

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
have "p \<inter> p \<rightarrow> \<^bold>A\<^bold>X p \<subseteq> \<^bold>A\<^bold>X p"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. p \<inter> p \<rightarrow> \<^bold>A\<^bold>X p \<subseteq> \<^bold>A\<^bold>X p
[PROOF STEP]
..
[PROOF STATE]
proof (state)
this:
p \<inter> p \<rightarrow> \<^bold>A\<^bold>X p \<subseteq> \<^bold>A\<^bold>X p

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
finally
[PROOF STATE]
proof (chain)
picking this:
(\<And>x y. x \<subseteq> y \<Longrightarrow> p \<inter> x \<subseteq> p \<inter> y) \<Longrightarrow> p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X p
[PROOF STEP]
have "?lhs \<subseteq> \<^bold>A\<^bold>X p"
[PROOF STATE]
proof (prove)
using this:
(\<And>x y. x \<subseteq> y \<Longrightarrow> p \<inter> x \<subseteq> p \<inter> y) \<Longrightarrow> p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X p

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X p
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X p

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
}
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X p

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X p

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
{
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X p

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
have "p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
..
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
have "\<dots> \<subseteq> \<^bold>A\<^bold>X \<dots>"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
by (rule AG_fp_2)
[PROOF STATE]
proof (state)
this:
\<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
finally
[PROOF STATE]
proof (chain)
picking this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
have "?lhs \<subseteq> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)"
[PROOF STATE]
proof (prove)
using this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
.
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
}
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
ultimately
[PROOF STATE]
proof (chain)
picking this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X p
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
have "?lhs \<subseteq> \<^bold>A\<^bold>X p \<inter> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)"
[PROOF STATE]
proof (prove)
using this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X p
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X p \<inter> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
..
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X p \<inter> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X p \<inter> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
have "\<dots> = \<^bold>A\<^bold>X ?lhs"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<^bold>A\<^bold>X p \<inter> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) = \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
by (simp only: AX_int)
[PROOF STATE]
proof (state)
this:
\<^bold>A\<^bold>X p \<inter> \<^bold>A\<^bold>X \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) = \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
finally
[PROOF STATE]
proof (chain)
picking this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))

goal (1 subgoal):
 1. p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))
[PROOF STEP]
.
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> p \<inter> \<^bold>A\<^bold>X (p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p))

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p) \<subseteq> \<^bold>A\<^bold>G p

goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
next
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
show "\<^bold>A\<^bold>G p \<subseteq> p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
proof
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. \<^bold>A\<^bold>G p \<subseteq> p
 2. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
show "\<^bold>A\<^bold>G p \<subseteq> p"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> p
[PROOF STEP]
by (rule AG_fp_1)
[PROOF STATE]
proof (state)
this:
\<^bold>A\<^bold>G p \<subseteq> p

goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
show "\<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
have "\<^bold>A\<^bold>G p = \<^bold>A\<^bold>G \<^bold>A\<^bold>G p"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<^bold>A\<^bold>G p = \<^bold>A\<^bold>G \<^bold>A\<^bold>G p
[PROOF STEP]
by (simp only: AG_AG)
[PROOF STATE]
proof (state)
this:
\<^bold>A\<^bold>G p = \<^bold>A\<^bold>G \<^bold>A\<^bold>G p

goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
\<^bold>A\<^bold>G p = \<^bold>A\<^bold>G \<^bold>A\<^bold>G p

goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
have "\<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>X p"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>X p
[PROOF STEP]
by (rule AG_AX)
[PROOF STATE]
proof (state)
this:
\<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>X p

goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
\<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>X p

goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
note AG_mono
[PROOF STATE]
proof (state)
this:
?p \<subseteq> ?q \<Longrightarrow> \<^bold>A\<^bold>G ?p \<subseteq> \<^bold>A\<^bold>G ?q

goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
?p \<subseteq> ?q \<Longrightarrow> \<^bold>A\<^bold>G ?p \<subseteq> \<^bold>A\<^bold>G ?q

goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
have "\<^bold>A\<^bold>X p \<subseteq> (p \<rightarrow> \<^bold>A\<^bold>X p)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<^bold>A\<^bold>X p \<subseteq> p \<rightarrow> \<^bold>A\<^bold>X p
[PROOF STEP]
..
[PROOF STATE]
proof (state)
this:
\<^bold>A\<^bold>X p \<subseteq> p \<rightarrow> \<^bold>A\<^bold>X p

goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
\<^bold>A\<^bold>X p \<subseteq> p \<rightarrow> \<^bold>A\<^bold>X p

goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
note AG_mono
[PROOF STATE]
proof (state)
this:
?p \<subseteq> ?q \<Longrightarrow> \<^bold>A\<^bold>G ?p \<subseteq> \<^bold>A\<^bold>G ?q

goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
finally
[PROOF STATE]
proof (chain)
picking this:
\<lbrakk>\<And>x y. x \<subseteq> y \<Longrightarrow> x \<subseteq> y; \<And>x y. x \<subseteq> y \<Longrightarrow> x \<subseteq> y\<rbrakk> \<Longrightarrow> \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
\<lbrakk>\<And>x y. x \<subseteq> y \<Longrightarrow> x \<subseteq> y; \<And>x y. x \<subseteq> y \<Longrightarrow> x \<subseteq> y\<rbrakk> \<Longrightarrow> \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)

goal (1 subgoal):
 1. \<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)
[PROOF STEP]
.
[PROOF STATE]
proof (state)
this:
\<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
\<^bold>A\<^bold>G p \<subseteq> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
\<^bold>A\<^bold>G p \<subseteq> p \<inter> \<^bold>A\<^bold>G (p \<rightarrow> \<^bold>A\<^bold>X p)

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma ENR_cball:
    fixes a :: "'a::euclidean_space"
    shows "ENR(cball a r)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. ENR (cball a r)
[PROOF STEP]
using ENR_convex_closed
[PROOF STATE]
proof (prove)
using this:
\<lbrakk>closed ?S; convex ?S\<rbrakk> \<Longrightarrow> ENR ?S

goal (1 subgoal):
 1. ENR (cball a r)
[PROOF STEP]
by blast


[STATEMENT]
lemma has_fps_expansion_imp_continuous:
  fixes F :: "'a::{real_normed_field,banach} fps"
  assumes "f has_fps_expansion F"
  shows   "continuous (at 0 within A) f"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. continuous (at (0::'a) within A) f
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. continuous (at (0::'a) within A) f
[PROOF STEP]
from assms
[PROOF STATE]
proof (chain)
picking this:
f has_fps_expansion F
[PROOF STEP]
have "isCont (eval_fps F) 0"
[PROOF STATE]
proof (prove)
using this:
f has_fps_expansion F

goal (1 subgoal):
 1. isCont (eval_fps F) (0::'a)
[PROOF STEP]
by (intro continuous_eval_fps) (auto simp: has_fps_expansion_def zero_ereal_def)
[PROOF STATE]
proof (state)
this:
isCont (eval_fps F) (0::'a)

goal (1 subgoal):
 1. continuous (at (0::'a) within A) f
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
isCont (eval_fps F) (0::'a)

goal (1 subgoal):
 1. continuous (at (0::'a) within A) f
[PROOF STEP]
have "?this \<longleftrightarrow> isCont f 0"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. isCont (eval_fps F) (0::'a) = isCont f (0::'a)
[PROOF STEP]
using assms
[PROOF STATE]
proof (prove)
using this:
f has_fps_expansion F

goal (1 subgoal):
 1. isCont (eval_fps F) (0::'a) = isCont f (0::'a)
[PROOF STEP]
by (intro isCont_cong) (auto simp: has_fps_expansion_def)
[PROOF STATE]
proof (state)
this:
isCont (eval_fps F) (0::'a) = isCont f (0::'a)

goal (1 subgoal):
 1. continuous (at (0::'a) within A) f
[PROOF STEP]
finally
[PROOF STATE]
proof (chain)
picking this:
isCont f (0::'a)
[PROOF STEP]
have "isCont f 0"
[PROOF STATE]
proof (prove)
using this:
isCont f (0::'a)

goal (1 subgoal):
 1. isCont f (0::'a)
[PROOF STEP]
.
[PROOF STATE]
proof (state)
this:
isCont f (0::'a)

goal (1 subgoal):
 1. continuous (at (0::'a) within A) f
[PROOF STEP]
thus "continuous (at 0 within A) f"
[PROOF STATE]
proof (prove)
using this:
isCont f (0::'a)

goal (1 subgoal):
 1. continuous (at (0::'a) within A) f
[PROOF STEP]
by (simp add: continuous_at_imp_continuous_within)
[PROOF STATE]
proof (state)
this:
continuous (at (0::'a) within A) f

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
theorem E1: "\<turnstile> \<diamond>(F \<or> G) = (\<diamond>F \<or> \<diamond>G)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<turnstile> \<diamond>(F \<or> G) = (\<diamond>F \<or> \<diamond>G)
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<turnstile> \<diamond>(F \<or> G) = (\<diamond>F \<or> \<diamond>G)
[PROOF STEP]
have "\<turnstile> \<box>\<not>(F \<or> G) = \<box>(\<not>F \<and> \<not>G)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<turnstile> \<box>\<not> (F \<or> G) = \<box>(\<not> F \<and> \<not> G)
[PROOF STEP]
by (rule MM1) auto
[PROOF STATE]
proof (state)
this:
\<turnstile> \<box>\<not> (F \<or> G) = \<box>(\<not> F \<and> \<not> G)

goal (1 subgoal):
 1. \<turnstile> \<diamond>(F \<or> G) = (\<diamond>F \<or> \<diamond>G)
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
\<turnstile> \<box>\<not> (F \<or> G) = \<box>(\<not> F \<and> \<not> G)

goal (1 subgoal):
 1. \<turnstile> \<diamond>(F \<or> G) = (\<diamond>F \<or> \<diamond>G)
[PROOF STEP]
unfolding eventually_def STL5[int_rewrite]
[PROOF STATE]
proof (prove)
using this:
\<turnstile> \<box>\<not> (F \<or> G) = (\<box>\<not> F \<and> \<box>\<not> G)

goal (1 subgoal):
 1. \<turnstile> \<not> \<box>\<not> (F \<or> G) = (\<not> \<box>\<not> F \<or> \<not> \<box>\<not> G)
[PROOF STEP]
by force
[PROOF STATE]
proof (state)
this:
\<turnstile> \<diamond>(F \<or> G) = (\<diamond>F \<or> \<diamond>G)

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma content_ff_map_poly_to_fract: "content_ff (map_poly to_fract (p :: 'a :: ufd poly)) \<in> range to_fract"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. content_ff (map_poly to_fract p) \<in> range to_fract
[PROOF STEP]
by (rule content_ff_to_fract, subst coeffs_map_poly, auto)


[STATEMENT]
lemma suma_assoc_2:
  assumes "SAMS A B C D E F" and
    "SAMS D E F G H I" and
    "A B C D E F SumA A' B' C'" and
    "D E F G H I SumA D' E' F'" and
    "A B C D' E' F' SumA K L M"
  shows "A' B' C' G H I SumA K L M"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. A' B' C' G H I SumA K L M
[PROOF STEP]
by (meson assms(1) assms(2) assms(3) assms(4) assms(5) sams_sym suma_assoc_1 suma_sym)


[STATEMENT]
lemma HNatInfinite_iff: "HNatInfinite = {N. \<forall>n \<in> Nats. n < N}"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. HNatInfinite = {N. \<forall>n\<in>\<nat>. n < N}
[PROOF STEP]
using HNatInfinite_def Nats_less_HNatInfinite
[PROOF STATE]
proof (prove)
using this:
HNatInfinite = {n. n \<notin> \<nat>}
\<lbrakk>?x \<in> \<nat>; ?y \<in> HNatInfinite\<rbrakk> \<Longrightarrow> ?x < ?y

goal (1 subgoal):
 1. HNatInfinite = {N. \<forall>n\<in>\<nat>. n < N}
[PROOF STEP]
by auto


[STATEMENT]
lemma vector_mult_component [simp]: "(x * y)$i = x$i * y$i"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (x * y) $ i = x $ i * y $ i
[PROOF STEP]
by vector


[STATEMENT]
lemma iT_Plus_iTrigger_conv: "(P t1. t1 \<T> t2 (I \<oplus> k). Q t2) = (P (t1 + k). t1 \<T> t2 I. Q (t2 + k))"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (P t1. t1 \<T> t2 I \<oplus> k. Q t2) = (P (t1 + k). t1 \<T> t2 I. Q (t2 + k))
[PROOF STEP]
by (simp add: iTrigger_iWeakSince_conv iT_Plus_iWeakSince_conv)


[STATEMENT]
lemma action_agree_valid_in_snapshot:
  assumes "(a \<in> PROB)" "(agree (fst a) s)" "(agree (snd a) s)"
  shows "(a \<in> snapshot PROB s)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. a \<in> snapshot PROB s
[PROOF STEP]
unfolding snapshot_def
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. a \<in> {a |a. a \<in> PROB \<and> agree (fst a) s \<and> agree (snd a) s}
[PROOF STEP]
using assms
[PROOF STATE]
proof (prove)
using this:
a \<in> PROB
agree (fst a) s
agree (snd a) s

goal (1 subgoal):
 1. a \<in> {a |a. a \<in> PROB \<and> agree (fst a) s \<and> agree (snd a) s}
[PROOF STEP]
by blast


[STATEMENT]
lemma random_permutation_of_set:
  assumes "finite A" "A \<noteq> {}"
  shows   "pmf_of_set (permutations_of_set A) =
             do {
               x \<leftarrow> pmf_of_set A;
               xs \<leftarrow> pmf_of_set (permutations_of_set (A - {x}));
               return_pmf (x#xs)
             }" (is "?lhs = ?rhs")
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. pmf_of_set (permutations_of_set A) = pmf_of_set A \<bind> (\<lambda>x. pmf_of_set (permutations_of_set (A - {x})) \<bind> (\<lambda>xs. return_pmf (x # xs)))
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. pmf_of_set (permutations_of_set A) = pmf_of_set A \<bind> (\<lambda>x. pmf_of_set (permutations_of_set (A - {x})) \<bind> (\<lambda>xs. return_pmf (x # xs)))
[PROOF STEP]
from assms
[PROOF STATE]
proof (chain)
picking this:
finite A
A \<noteq> {}
[PROOF STEP]
have "permutations_of_set A = (\<Union>x\<in>A. (#) x ` permutations_of_set (A - {x}))"
[PROOF STATE]
proof (prove)
using this:
finite A
A \<noteq> {}

goal (1 subgoal):
 1. permutations_of_set A = (\<Union>x\<in>A. (#) x ` permutations_of_set (A - {x}))
[PROOF STEP]
by (simp add: permutations_of_set_nonempty)
[PROOF STATE]
proof (state)
this:
permutations_of_set A = (\<Union>x\<in>A. (#) x ` permutations_of_set (A - {x}))

goal (1 subgoal):
 1. pmf_of_set (permutations_of_set A) = pmf_of_set A \<bind> (\<lambda>x. pmf_of_set (permutations_of_set (A - {x})) \<bind> (\<lambda>xs. return_pmf (x # xs)))
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
permutations_of_set A = (\<Union>x\<in>A. (#) x ` permutations_of_set (A - {x}))

goal (1 subgoal):
 1. pmf_of_set (permutations_of_set A) = pmf_of_set A \<bind> (\<lambda>x. pmf_of_set (permutations_of_set (A - {x})) \<bind> (\<lambda>xs. return_pmf (x # xs)))
[PROOF STEP]
from assms
[PROOF STATE]
proof (chain)
picking this:
finite A
A \<noteq> {}
[PROOF STEP]
have "pmf_of_set \<dots> = ?rhs"
[PROOF STATE]
proof (prove)
using this:
finite A
A \<noteq> {}

goal (1 subgoal):
 1. pmf_of_set (\<Union>x\<in>A. (#) x ` permutations_of_set (A - {x})) = pmf_of_set A \<bind> (\<lambda>x. pmf_of_set (permutations_of_set (A - {x})) \<bind> (\<lambda>xs. return_pmf (x # xs)))
[PROOF STEP]
by (subst pmf_of_set_UN[where n = "fact (card A - 1)"])
       (auto simp: card_image disjoint_family_on_def map_pmf_def [symmetric] map_pmf_of_set_inj)
[PROOF STATE]
proof (state)
this:
pmf_of_set (\<Union>x\<in>A. (#) x ` permutations_of_set (A - {x})) = pmf_of_set A \<bind> (\<lambda>x. pmf_of_set (permutations_of_set (A - {x})) \<bind> (\<lambda>xs. return_pmf (x # xs)))

goal (1 subgoal):
 1. pmf_of_set (permutations_of_set A) = pmf_of_set A \<bind> (\<lambda>x. pmf_of_set (permutations_of_set (A - {x})) \<bind> (\<lambda>xs. return_pmf (x # xs)))
[PROOF STEP]
finally
[PROOF STATE]
proof (chain)
picking this:
pmf_of_set (permutations_of_set A) = pmf_of_set A \<bind> (\<lambda>x. pmf_of_set (permutations_of_set (A - {x})) \<bind> (\<lambda>xs. return_pmf (x # xs)))
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
pmf_of_set (permutations_of_set A) = pmf_of_set A \<bind> (\<lambda>x. pmf_of_set (permutations_of_set (A - {x})) \<bind> (\<lambda>xs. return_pmf (x # xs)))

goal (1 subgoal):
 1. pmf_of_set (permutations_of_set A) = pmf_of_set A \<bind> (\<lambda>x. pmf_of_set (permutations_of_set (A - {x})) \<bind> (\<lambda>xs. return_pmf (x # xs)))
[PROOF STEP]
.
[PROOF STATE]
proof (state)
this:
pmf_of_set (permutations_of_set A) = pmf_of_set A \<bind> (\<lambda>x. pmf_of_set (permutations_of_set (A - {x})) \<bind> (\<lambda>xs. return_pmf (x # xs)))

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma (in prob_space) uniform_distributed_variance:
  fixes a b :: real
  assumes D: "distributed M lborel X (\<lambda>x. indicator {a .. b} x / measure lborel {a .. b})"
  shows "variance X = (b - a)\<^sup>2 / 12"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. expectation (\<lambda>x. (X x - expectation X)\<^sup>2) = (b - a)\<^sup>2 / 12
[PROOF STEP]
proof (subst distributed_variance)
[PROOF STATE]
proof (state)
goal (3 subgoals):
 1. distributed M lborel X (\<lambda>x. ennreal (?f x))
 2. \<And>x. 0 \<le> ?f x
 3. LBINT x. x\<^sup>2 * ?f (x + expectation X) = (b - a)\<^sup>2 / 12
[PROOF STEP]
have [arith]: "a < b"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. a < b
[PROOF STEP]
using uniform_distributed_bounds[OF D]
[PROOF STATE]
proof (prove)
using this:
a < b

goal (1 subgoal):
 1. a < b
[PROOF STEP]
.
[PROOF STATE]
proof (state)
this:
a < b

goal (3 subgoals):
 1. distributed M lborel X (\<lambda>x. ennreal (?f x))
 2. \<And>x. 0 \<le> ?f x
 3. LBINT x. x\<^sup>2 * ?f (x + expectation X) = (b - a)\<^sup>2 / 12
[PROOF STEP]
let ?\<mu> = "expectation X"
[PROOF STATE]
proof (state)
goal (3 subgoals):
 1. distributed M lborel X (\<lambda>x. ennreal (?f x))
 2. \<And>x. 0 \<le> ?f x
 3. LBINT x. x\<^sup>2 * ?f (x + expectation X) = (b - a)\<^sup>2 / 12
[PROOF STEP]
let ?D = "\<lambda>x. indicator {a..b} (x + ?\<mu>) / measure lborel {a..b}"
[PROOF STATE]
proof (state)
goal (3 subgoals):
 1. distributed M lborel X (\<lambda>x. ennreal (?f x))
 2. \<And>x. 0 \<le> ?f x
 3. LBINT x. x\<^sup>2 * ?f (x + expectation X) = (b - a)\<^sup>2 / 12
[PROOF STEP]
have "(\<integral>x. x\<^sup>2 * (?D x) \<partial>lborel) = (\<integral>x. x\<^sup>2 * (indicator {a - ?\<mu> .. b - ?\<mu>} x) / measure lborel {a .. b} \<partial>lborel)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. LBINT x. x\<^sup>2 * (indicat_real {a..b} (x + expectation X) / content {a..b}) = LBINT x. x\<^sup>2 * indicat_real {a - expectation X..b - expectation X} x / content {a..b}
[PROOF STEP]
by (intro Bochner_Integration.integral_cong) (auto split: split_indicator)
[PROOF STATE]
proof (state)
this:
LBINT x. x\<^sup>2 * (indicat_real {a..b} (x + expectation X) / content {a..b}) = LBINT x. x\<^sup>2 * indicat_real {a - expectation X..b - expectation X} x / content {a..b}

goal (3 subgoals):
 1. distributed M lborel X (\<lambda>x. ennreal (?f x))
 2. \<And>x. 0 \<le> ?f x
 3. LBINT x. x\<^sup>2 * ?f (x + expectation X) = (b - a)\<^sup>2 / 12
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
LBINT x. x\<^sup>2 * (indicat_real {a..b} (x + expectation X) / content {a..b}) = LBINT x. x\<^sup>2 * indicat_real {a - expectation X..b - expectation X} x / content {a..b}

goal (3 subgoals):
 1. distributed M lborel X (\<lambda>x. ennreal (?f x))
 2. \<And>x. 0 \<le> ?f x
 3. LBINT x. x\<^sup>2 * ?f (x + expectation X) = (b - a)\<^sup>2 / 12
[PROOF STEP]
have "\<dots> = (b - a)\<^sup>2 / 12"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. LBINT x. x\<^sup>2 * indicat_real {a - expectation X..b - expectation X} x / content {a..b} = (b - a)\<^sup>2 / 12
[PROOF STEP]
by (simp add: integral_power uniform_distributed_expectation[OF D])
       (simp add: eval_nat_numeral field_simps )
[PROOF STATE]
proof (state)
this:
LBINT x. x\<^sup>2 * indicat_real {a - expectation X..b - expectation X} x / content {a..b} = (b - a)\<^sup>2 / 12

goal (3 subgoals):
 1. distributed M lborel X (\<lambda>x. ennreal (?f x))
 2. \<And>x. 0 \<le> ?f x
 3. LBINT x. x\<^sup>2 * ?f (x + expectation X) = (b - a)\<^sup>2 / 12
[PROOF STEP]
finally
[PROOF STATE]
proof (chain)
picking this:
LBINT x. x\<^sup>2 * (indicat_real {a..b} (x + expectation X) / content {a..b}) = (b - a)\<^sup>2 / 12
[PROOF STEP]
show "(\<integral>x. x\<^sup>2 * ?D x \<partial>lborel) = (b - a)\<^sup>2 / 12"
[PROOF STATE]
proof (prove)
using this:
LBINT x. x\<^sup>2 * (indicat_real {a..b} (x + expectation X) / content {a..b}) = (b - a)\<^sup>2 / 12

goal (1 subgoal):
 1. LBINT x. x\<^sup>2 * (indicat_real {a..b} (x + expectation X) / content {a..b}) = (b - a)\<^sup>2 / 12
[PROOF STEP]
.
[PROOF STATE]
proof (state)
this:
LBINT x. x\<^sup>2 * (indicat_real {a..b} (x + expectation X) / content {a..b}) = (b - a)\<^sup>2 / 12

goal (2 subgoals):
 1. distributed M lborel X (\<lambda>x. ennreal (indicat_real {a..b} x / content {a..b}))
 2. \<And>x. 0 \<le> indicat_real {a..b} x / content {a..b}
[PROOF STEP]
qed (auto intro: D simp del: content_real_if)


[STATEMENT]
lemma det30_scaled_minus3[simp]: "det3 0 a (e *\<^sub>R a - b) = 0 \<longleftrightarrow> det3 0 a b = 0"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (det3 0 a (e *\<^sub>R a - b) = 0) = (det3 0 a b = 0)
[PROOF STEP]
using det30_plus_scaled3[of a "-b" e]
[PROOF STATE]
proof (prove)
using this:
(det3 0 a (- b + e *\<^sub>R a) = 0) = (det3 0 a (- b) = 0)

goal (1 subgoal):
 1. (det3 0 a (e *\<^sub>R a - b) = 0) = (det3 0 a b = 0)
[PROOF STEP]
by (simp add: algebra_simps)


[STATEMENT]
lemma quantale_hom_radj:
  fixes f :: "'a::quantale_with_dual \<Rightarrow> 'b::quantale_with_dual"
  shows "f \<in> quantale_homset \<Longrightarrow> f \<stileturn> radj f"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. f \<in> quantale_homset \<Longrightarrow> f \<stileturn> radj f
[PROOF STEP]
unfolding quantale_homset_iff
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. comp_pres f \<and> Sup_pres f \<Longrightarrow> f \<stileturn> radj f
[PROOF STEP]
by (simp add: Sup_pres_ladj_aux)


[STATEMENT]
lemma eq_rowI: assumes rows: "\<And> i. i < dim_row B \<Longrightarrow> row A i = row B i"
  and dims: "dim_row A = dim_row B" "dim_col A = dim_col B"
  shows "A = B"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. A = B
[PROOF STEP]
proof (rule eq_matI[OF _ dims])
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>i j. \<lbrakk>i < dim_row B; j < dim_col B\<rbrakk> \<Longrightarrow> A $$ (i, j) = B $$ (i, j)
[PROOF STEP]
fix i j
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>i j. \<lbrakk>i < dim_row B; j < dim_col B\<rbrakk> \<Longrightarrow> A $$ (i, j) = B $$ (i, j)
[PROOF STEP]
assume i: "i < dim_row B" and j: "j < dim_col B"
[PROOF STATE]
proof (state)
this:
i < dim_row B
j < dim_col B

goal (1 subgoal):
 1. \<And>i j. \<lbrakk>i < dim_row B; j < dim_col B\<rbrakk> \<Longrightarrow> A $$ (i, j) = B $$ (i, j)
[PROOF STEP]
from rows[OF i]
[PROOF STATE]
proof (chain)
picking this:
row A i = row B i
[PROOF STEP]
have id: "row A i $ j = row B i $ j"
[PROOF STATE]
proof (prove)
using this:
row A i = row B i

goal (1 subgoal):
 1. row A i $ j = row B i $ j
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
row A i $ j = row B i $ j

goal (1 subgoal):
 1. \<And>i j. \<lbrakk>i < dim_row B; j < dim_col B\<rbrakk> \<Longrightarrow> A $$ (i, j) = B $$ (i, j)
[PROOF STEP]
show "A $$ (i, j) = B $$ (i, j)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. A $$ (i, j) = B $$ (i, j)
[PROOF STEP]
using index_row(1)[OF i j, folded id] index_row(1)[of i A j] i j dims
[PROOF STATE]
proof (prove)
using this:
row A i $ j = B $$ (i, j)
\<lbrakk>i < dim_row A; j < dim_col A\<rbrakk> \<Longrightarrow> row A i $ j = A $$ (i, j)
i < dim_row B
j < dim_col B
dim_row A = dim_row B
dim_col A = dim_col B

goal (1 subgoal):
 1. A $$ (i, j) = B $$ (i, j)
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
A $$ (i, j) = B $$ (i, j)

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma distribute_alpha_over_sum:
  shows "(\<Sum>i\<in>set_pmf T. a * pmf p i * f i) = a * (\<Sum>i\<in>set_pmf T. pmf p i * f i)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<Sum>i\<in>set_pmf T. a * pmf p i * f i) = a * (\<Sum>i\<in>set_pmf T. pmf p i * f i)
[PROOF STEP]
by (metis (mono_tags, lifting) semiring_normalization_rules(18) sum.cong sum_distrib_left)


[STATEMENT]
lemma f_aggregate_append_mod: "
  length xs mod k = 0 \<Longrightarrow>
  f_aggregate (xs @ ys) k ag =
  f_aggregate xs k ag @ f_aggregate ys k ag"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. length xs mod k = 0 \<Longrightarrow> f_aggregate (xs @ ys) k ag = f_aggregate xs k ag @ f_aggregate ys k ag
[PROOF STEP]
by (simp add: f_aggregate_def list_slice_append_mod)


[STATEMENT]
lemma closedin_connected_component: "closedin (top_of_set s) (connected_component_set s x)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. closedin (top_of_set s) (connected_component_set s x)
[PROOF STEP]
proof (cases "connected_component_set s x = {}")
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. connected_component_set s x = {} \<Longrightarrow> closedin (top_of_set s) (connected_component_set s x)
 2. connected_component_set s x \<noteq> {} \<Longrightarrow> closedin (top_of_set s) (connected_component_set s x)
[PROOF STEP]
case True
[PROOF STATE]
proof (state)
this:
connected_component_set s x = {}

goal (2 subgoals):
 1. connected_component_set s x = {} \<Longrightarrow> closedin (top_of_set s) (connected_component_set s x)
 2. connected_component_set s x \<noteq> {} \<Longrightarrow> closedin (top_of_set s) (connected_component_set s x)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
connected_component_set s x = {}
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
connected_component_set s x = {}

goal (1 subgoal):
 1. closedin (top_of_set s) (connected_component_set s x)
[PROOF STEP]
by (metis closedin_empty)
[PROOF STATE]
proof (state)
this:
closedin (top_of_set s) (connected_component_set s x)

goal (1 subgoal):
 1. connected_component_set s x \<noteq> {} \<Longrightarrow> closedin (top_of_set s) (connected_component_set s x)
[PROOF STEP]
next
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. connected_component_set s x \<noteq> {} \<Longrightarrow> closedin (top_of_set s) (connected_component_set s x)
[PROOF STEP]
case False
[PROOF STATE]
proof (state)
this:
connected_component_set s x \<noteq> {}

goal (1 subgoal):
 1. connected_component_set s x \<noteq> {} \<Longrightarrow> closedin (top_of_set s) (connected_component_set s x)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
connected_component_set s x \<noteq> {}
[PROOF STEP]
obtain y where y: "connected_component s x y"
[PROOF STATE]
proof (prove)
using this:
connected_component_set s x \<noteq> {}

goal (1 subgoal):
 1. (\<And>y. connected_component s x y \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
by blast
[PROOF STATE]
proof (state)
this:
connected_component s x y

goal (1 subgoal):
 1. connected_component_set s x \<noteq> {} \<Longrightarrow> closedin (top_of_set s) (connected_component_set s x)
[PROOF STEP]
have *: "connected_component_set s x \<subseteq> s \<inter> closure (connected_component_set s x)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. connected_component_set s x \<subseteq> s \<inter> closure (connected_component_set s x)
[PROOF STEP]
by (auto simp: closure_def connected_component_in)
[PROOF STATE]
proof (state)
this:
connected_component_set s x \<subseteq> s \<inter> closure (connected_component_set s x)

goal (1 subgoal):
 1. connected_component_set s x \<noteq> {} \<Longrightarrow> closedin (top_of_set s) (connected_component_set s x)
[PROOF STEP]
have "connected_component s x y \<Longrightarrow> s \<inter> closure (connected_component_set s x) \<subseteq> connected_component_set s x"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. connected_component s x y \<Longrightarrow> s \<inter> closure (connected_component_set s x) \<subseteq> connected_component_set s x
[PROOF STEP]
apply (rule connected_component_maximal, simp)
[PROOF STATE]
proof (prove)
goal (3 subgoals):
 1. connected_component s x y \<Longrightarrow> x \<in> s \<and> x \<in> closure (connected_component_set s x)
 2. connected_component s x y \<Longrightarrow> connected (s \<inter> closure (connected_component_set s x))
 3. connected_component s x y \<Longrightarrow> s \<inter> closure (connected_component_set s x) \<subseteq> s
[PROOF STEP]
using closure_subset connected_component_in
[PROOF STATE]
proof (prove)
using this:
?S \<subseteq> closure ?S
connected_component ?S ?x ?y \<Longrightarrow> ?x \<in> ?S \<and> ?y \<in> ?S

goal (3 subgoals):
 1. connected_component s x y \<Longrightarrow> x \<in> s \<and> x \<in> closure (connected_component_set s x)
 2. connected_component s x y \<Longrightarrow> connected (s \<inter> closure (connected_component_set s x))
 3. connected_component s x y \<Longrightarrow> s \<inter> closure (connected_component_set s x) \<subseteq> s
[PROOF STEP]
apply fastforce
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. connected_component s x y \<Longrightarrow> connected (s \<inter> closure (connected_component_set s x))
 2. connected_component s x y \<Longrightarrow> s \<inter> closure (connected_component_set s x) \<subseteq> s
[PROOF STEP]
using * connected_intermediate_closure
[PROOF STATE]
proof (prove)
using this:
connected_component_set s x \<subseteq> s \<inter> closure (connected_component_set s x)
\<lbrakk>connected ?s; ?s \<subseteq> ?t; ?t \<subseteq> closure ?s\<rbrakk> \<Longrightarrow> connected ?t

goal (2 subgoals):
 1. connected_component s x y \<Longrightarrow> connected (s \<inter> closure (connected_component_set s x))
 2. connected_component s x y \<Longrightarrow> s \<inter> closure (connected_component_set s x) \<subseteq> s
[PROOF STEP]
apply blast+
[PROOF STATE]
proof (prove)
goal:
No subgoals!
[PROOF STEP]
done
[PROOF STATE]
proof (state)
this:
connected_component s x y \<Longrightarrow> s \<inter> closure (connected_component_set s x) \<subseteq> connected_component_set s x

goal (1 subgoal):
 1. connected_component_set s x \<noteq> {} \<Longrightarrow> closedin (top_of_set s) (connected_component_set s x)
[PROOF STEP]
with y *
[PROOF STATE]
proof (chain)
picking this:
connected_component s x y
connected_component_set s x \<subseteq> s \<inter> closure (connected_component_set s x)
connected_component s x y \<Longrightarrow> s \<inter> closure (connected_component_set s x) \<subseteq> connected_component_set s x
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
connected_component s x y
connected_component_set s x \<subseteq> s \<inter> closure (connected_component_set s x)
connected_component s x y \<Longrightarrow> s \<inter> closure (connected_component_set s x) \<subseteq> connected_component_set s x

goal (1 subgoal):
 1. closedin (top_of_set s) (connected_component_set s x)
[PROOF STEP]
by (auto simp: closedin_closed)
[PROOF STATE]
proof (state)
this:
closedin (top_of_set s) (connected_component_set s x)

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma of_nat_push_bit:
  \<open>of_nat (push_bit m n) = push_bit m (of_nat n)\<close>
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. of_nat (push_bit m n) = push_bit m (of_nat n)
[PROOF STEP]
by (simp add: push_bit_eq_mult Bit_Operations.push_bit_eq_mult)


[STATEMENT]
lemma d_mult_greatest_lower_bound:
  "d(x) \<le> d(y) * d(z) \<longleftrightarrow> d(x) \<le> d(y) \<and> d(x) \<le> d(z)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (d x \<le> d y * d z) = (d x \<le> d y \<and> d x \<le> d z)
[PROOF STEP]
by (metis d_commutative d_idempotent d_mult_left_lower_bound mult_isotone order_trans)


[STATEMENT]
lemma point_mult_closed: "on_curve a b p \<Longrightarrow> on_curve a b (point_mult a n p)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. on_curve a b p \<Longrightarrow> on_curve a b (point_mult a n p)
[PROOF STEP]
by (induct n) (simp_all add: add_closed)


[STATEMENT]
lemma singleton:"|i| = 1 \<longrightarrow> (\<exists>n. Rep_nat_int i = {n})"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. |i| = 1 \<longrightarrow> (\<exists>n. Rep_nat_int i = {n})
[PROOF STEP]
using card_1_singletonE card'.rep_eq
[PROOF STATE]
proof (prove)
using this:
\<lbrakk>card ?A = 1; \<And>x. ?A = {x} \<Longrightarrow> ?thesis\<rbrakk> \<Longrightarrow> ?thesis
|?x| = card (Rep_nat_int ?x)

goal (1 subgoal):
 1. |i| = 1 \<longrightarrow> (\<exists>n. Rep_nat_int i = {n})
[PROOF STEP]
by fastforce