[STATEMENT]
lemma wfTerminationLess:
  fixes F0 :: Formula and decisionVars :: "Variable set"
  assumes "finite decisionVars" "wf learnL"
  shows "wf (terminationLess F0 decisionVars learnL)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. wf (terminationLess F0 decisionVars learnL)
[PROOF STEP]
unfolding wf_eq_minimal
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<forall>Q x. x \<in> Q \<longrightarrow> (\<exists>z\<in>Q. \<forall>y. (y, z) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> y \<notin> Q)
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<forall>Q x. x \<in> Q \<longrightarrow> (\<exists>z\<in>Q. \<forall>y. (y, z) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> y \<notin> Q)
[PROOF STEP]
show "\<forall>Q state. state \<in> Q \<longrightarrow> (\<exists> stateMin \<in> Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
proof-
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
{
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
fix Q::"State set"
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
fix state::State
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
assume "state \<in> Q"
[PROOF STATE]
proof (state)
this:
state \<in> Q

goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
have "wf (lexLessState F0 decisionVars)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. wf (lexLessState F0 decisionVars)
[PROOF STEP]
using wfLexLessState[of "decisionVars" "F0"]
[PROOF STATE]
proof (prove)
using this:
finite decisionVars \<Longrightarrow> wf (lexLessState F0 decisionVars)

goal (1 subgoal):
 1. wf (lexLessState F0 decisionVars)
[PROOF STEP]
using \<open>finite decisionVars\<close>
[PROOF STATE]
proof (prove)
using this:
finite decisionVars \<Longrightarrow> wf (lexLessState F0 decisionVars)
finite decisionVars

goal (1 subgoal):
 1. wf (lexLessState F0 decisionVars)
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
wf (lexLessState F0 decisionVars)

goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
with \<open>state \<in> Q\<close>
[PROOF STATE]
proof (chain)
picking this:
state \<in> Q
wf (lexLessState F0 decisionVars)
[PROOF STEP]
obtain state0
        where "state0 \<in> Q" "\<forall>state'. (state', state0) \<in> lexLessState F0 decisionVars \<longrightarrow> state' \<notin> Q"
[PROOF STATE]
proof (prove)
using this:
state \<in> Q
wf (lexLessState F0 decisionVars)

goal (1 subgoal):
 1. (\<And>state0. \<lbrakk>state0 \<in> Q; \<forall>state'. (state', state0) \<in> lexLessState F0 decisionVars \<longrightarrow> state' \<notin> Q\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
unfolding wf_eq_minimal
[PROOF STATE]
proof (prove)
using this:
state \<in> Q
\<forall>Q x. x \<in> Q \<longrightarrow> (\<exists>z\<in>Q. \<forall>y. (y, z) \<in> lexLessState F0 decisionVars \<longrightarrow> y \<notin> Q)

goal (1 subgoal):
 1. (\<And>state0. \<lbrakk>state0 \<in> Q; \<forall>state'. (state', state0) \<in> lexLessState F0 decisionVars \<longrightarrow> state' \<notin> Q\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
state0 \<in> Q
\<forall>state'. (state', state0) \<in> lexLessState F0 decisionVars \<longrightarrow> state' \<notin> Q

goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
let ?Q0 = "{state. state \<in> Q \<and> (getM state) = (getM state0)}"
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
from \<open>state0 \<in> Q\<close>
[PROOF STATE]
proof (chain)
picking this:
state0 \<in> Q
[PROOF STEP]
have "state0 \<in> ?Q0"
[PROOF STATE]
proof (prove)
using this:
state0 \<in> Q

goal (1 subgoal):
 1. state0 \<in> {state \<in> Q. getM state = getM state0}
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
state0 \<in> {state \<in> Q. getM state = getM state0}

goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
from \<open>wf learnL\<close>
[PROOF STATE]
proof (chain)
picking this:
wf learnL
[PROOF STEP]
have "wf (learnLessState learnL)"
[PROOF STATE]
proof (prove)
using this:
wf learnL

goal (1 subgoal):
 1. wf (learnLessState learnL)
[PROOF STEP]
using wfLearnLessState
[PROOF STATE]
proof (prove)
using this:
wf learnL
wf ?learnL \<Longrightarrow> wf (learnLessState ?learnL)

goal (1 subgoal):
 1. wf (learnLessState learnL)
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
wf (learnLessState learnL)

goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
with \<open>state0 \<in> ?Q0\<close>
[PROOF STATE]
proof (chain)
picking this:
state0 \<in> {state \<in> Q. getM state = getM state0}
wf (learnLessState learnL)
[PROOF STEP]
obtain state1
        where "state1 \<in> ?Q0" "\<forall>state'. (state', state1) \<in> learnLessState learnL \<longrightarrow> state' \<notin> ?Q0"
[PROOF STATE]
proof (prove)
using this:
state0 \<in> {state \<in> Q. getM state = getM state0}
wf (learnLessState learnL)

goal (1 subgoal):
 1. (\<And>state1. \<lbrakk>state1 \<in> {state \<in> Q. getM state = getM state0}; \<forall>state'. (state', state1) \<in> learnLessState learnL \<longrightarrow> state' \<notin> {state \<in> Q. getM state = getM state0}\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
unfolding wf_eq_minimal
[PROOF STATE]
proof (prove)
using this:
state0 \<in> {state \<in> Q. getM state = getM state0}
\<forall>Q x. x \<in> Q \<longrightarrow> (\<exists>z\<in>Q. \<forall>y. (y, z) \<in> learnLessState learnL \<longrightarrow> y \<notin> Q)

goal (1 subgoal):
 1. (\<And>state1. \<lbrakk>state1 \<in> {state \<in> Q. getM state = getM state0}; \<forall>state'. (state', state1) \<in> learnLessState learnL \<longrightarrow> state' \<notin> {state \<in> Q. getM state = getM state0}\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
apply (erule_tac x="?Q0" in allE)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>\<And>state1. \<lbrakk>state1 \<in> {state \<in> Q. getM state = getM state0}; \<forall>state'. (state', state1) \<in> learnLessState learnL \<longrightarrow> state' \<notin> {state \<in> Q. getM state = getM state0}\<rbrakk> \<Longrightarrow> thesis; state0 \<in> {state \<in> Q. getM state = getM state0}; \<forall>x. x \<in> {state \<in> Q. getM state = getM state0} \<longrightarrow> (\<exists>z\<in>{state \<in> Q. getM state = getM state0}. \<forall>y. (y, z) \<in> learnLessState learnL \<longrightarrow> y \<notin> {state \<in> Q. getM state = getM state0})\<rbrakk> \<Longrightarrow> thesis
[PROOF STEP]
apply (erule_tac x="state0" in allE)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>\<And>state1. \<lbrakk>state1 \<in> {state \<in> Q. getM state = getM state0}; \<forall>state'. (state', state1) \<in> learnLessState learnL \<longrightarrow> state' \<notin> {state \<in> Q. getM state = getM state0}\<rbrakk> \<Longrightarrow> thesis; state0 \<in> {state \<in> Q. getM state = getM state0}; state0 \<in> {state \<in> Q. getM state = getM state0} \<longrightarrow> (\<exists>z\<in>{state \<in> Q. getM state = getM state0}. \<forall>y. (y, z) \<in> learnLessState learnL \<longrightarrow> y \<notin> {state \<in> Q. getM state = getM state0})\<rbrakk> \<Longrightarrow> thesis
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
state1 \<in> {state \<in> Q. getM state = getM state0}
\<forall>state'. (state', state1) \<in> learnLessState learnL \<longrightarrow> state' \<notin> {state \<in> Q. getM state = getM state0}

goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
from \<open>state1 \<in> ?Q0\<close>
[PROOF STATE]
proof (chain)
picking this:
state1 \<in> {state \<in> Q. getM state = getM state0}
[PROOF STEP]
have "state1 \<in> Q" "getM state1 = getM state0"
[PROOF STATE]
proof (prove)
using this:
state1 \<in> {state \<in> Q. getM state = getM state0}

goal (1 subgoal):
 1. state1 \<in> Q &&& getM state1 = getM state0
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
state1 \<in> Q
getM state1 = getM state0

goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
let ?stateMin = state1
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
have "\<forall>state'. (state', ?stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<forall>state'. (state', state1) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q
[PROOF STEP]
proof
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>state'. (state', state1) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q
[PROOF STEP]
fix state'
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>state'. (state', state1) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q
[PROOF STEP]
show "(state', ?stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q
[PROOF STEP]
proof
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
assume "(state', ?stateMin) \<in> terminationLess F0 decisionVars learnL"
[PROOF STATE]
proof (state)
this:
(state', state1) \<in> terminationLess F0 decisionVars learnL

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
hence
            "(state', ?stateMin) \<in> lexLessState F0 decisionVars \<or>
            (state', ?stateMin) \<in> learnLessState learnL"
[PROOF STATE]
proof (prove)
using this:
(state', state1) \<in> terminationLess F0 decisionVars learnL

goal (1 subgoal):
 1. (state', state1) \<in> lexLessState F0 decisionVars \<or> (state', state1) \<in> learnLessState learnL
[PROOF STEP]
unfolding terminationLess_def
[PROOF STATE]
proof (prove)
using this:
(state', state1) \<in> {(stateA, stateB). (stateA, stateB) \<in> lexLessState F0 decisionVars \<or> (stateA, stateB) \<in> learnLessState learnL}

goal (1 subgoal):
 1. (state', state1) \<in> lexLessState F0 decisionVars \<or> (state', state1) \<in> learnLessState learnL
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
(state', state1) \<in> lexLessState F0 decisionVars \<or> (state', state1) \<in> learnLessState learnL

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
(state', state1) \<in> lexLessState F0 decisionVars \<or> (state', state1) \<in> learnLessState learnL

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
{
[PROOF STATE]
proof (state)
this:
(state', state1) \<in> lexLessState F0 decisionVars \<or> (state', state1) \<in> learnLessState learnL

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
assume "(state', ?stateMin) \<in> lexLessState F0 decisionVars"
[PROOF STATE]
proof (state)
this:
(state', state1) \<in> lexLessState F0 decisionVars

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
with \<open>getM state1 = getM state0\<close>
[PROOF STATE]
proof (chain)
picking this:
getM state1 = getM state0
(state', state1) \<in> lexLessState F0 decisionVars
[PROOF STEP]
have "(state', state0) \<in> lexLessState F0 decisionVars"
[PROOF STATE]
proof (prove)
using this:
getM state1 = getM state0
(state', state1) \<in> lexLessState F0 decisionVars

goal (1 subgoal):
 1. (state', state0) \<in> lexLessState F0 decisionVars
[PROOF STEP]
unfolding lexLessState_def
[PROOF STATE]
proof (prove)
using this:
getM state1 = getM state0
(state', state1) \<in> {(stateA, stateB). (getM stateA, getM stateB) \<in> lexLessRestricted (vars F0 \<union> decisionVars)}

goal (1 subgoal):
 1. (state', state0) \<in> {(stateA, stateB). (getM stateA, getM stateB) \<in> lexLessRestricted (vars F0 \<union> decisionVars)}
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
(state', state0) \<in> lexLessState F0 decisionVars

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
with \<open>\<forall>state'. (state', state0) \<in> lexLessState F0 decisionVars \<longrightarrow> state' \<notin> Q\<close>
[PROOF STATE]
proof (chain)
picking this:
\<forall>state'. (state', state0) \<in> lexLessState F0 decisionVars \<longrightarrow> state' \<notin> Q
(state', state0) \<in> lexLessState F0 decisionVars
[PROOF STEP]
have "state' \<notin> Q"
[PROOF STATE]
proof (prove)
using this:
\<forall>state'. (state', state0) \<in> lexLessState F0 decisionVars \<longrightarrow> state' \<notin> Q
(state', state0) \<in> lexLessState F0 decisionVars

goal (1 subgoal):
 1. state' \<notin> Q
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
state' \<notin> Q

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
}
[PROOF STATE]
proof (state)
this:
(state', state1) \<in> lexLessState F0 decisionVars \<Longrightarrow> state' \<notin> Q

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
(state', state1) \<in> lexLessState F0 decisionVars \<Longrightarrow> state' \<notin> Q

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
{
[PROOF STATE]
proof (state)
this:
(state', state1) \<in> lexLessState F0 decisionVars \<Longrightarrow> state' \<notin> Q

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
assume "(state', ?stateMin) \<in> learnLessState learnL"
[PROOF STATE]
proof (state)
this:
(state', state1) \<in> learnLessState learnL

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
with \<open>\<forall>state'. (state', state1) \<in> learnLessState learnL \<longrightarrow> state' \<notin> ?Q0\<close>
[PROOF STATE]
proof (chain)
picking this:
\<forall>state'. (state', state1) \<in> learnLessState learnL \<longrightarrow> state' \<notin> {state \<in> Q. getM state = getM state0}
(state', state1) \<in> learnLessState learnL
[PROOF STEP]
have "state' \<notin> ?Q0"
[PROOF STATE]
proof (prove)
using this:
\<forall>state'. (state', state1) \<in> learnLessState learnL \<longrightarrow> state' \<notin> {state \<in> Q. getM state = getM state0}
(state', state1) \<in> learnLessState learnL

goal (1 subgoal):
 1. state' \<notin> {state \<in> Q. getM state = getM state0}
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
state' \<notin> {state \<in> Q. getM state = getM state0}

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
from \<open>(state', state1) \<in> learnLessState learnL\<close> \<open>getM state1 = getM state0\<close>
[PROOF STATE]
proof (chain)
picking this:
(state', state1) \<in> learnLessState learnL
getM state1 = getM state0
[PROOF STEP]
have "getM state' = getM state0"
[PROOF STATE]
proof (prove)
using this:
(state', state1) \<in> learnLessState learnL
getM state1 = getM state0

goal (1 subgoal):
 1. getM state' = getM state0
[PROOF STEP]
unfolding learnLessState_def
[PROOF STATE]
proof (prove)
using this:
(state', state1) \<in> {(stateA, stateB). getM stateA = getM stateB \<and> (getF stateA, getF stateB) \<in> learnL}
getM state1 = getM state0

goal (1 subgoal):
 1. getM state' = getM state0
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
getM state' = getM state0

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
with \<open>state' \<notin> ?Q0\<close>
[PROOF STATE]
proof (chain)
picking this:
state' \<notin> {state \<in> Q. getM state = getM state0}
getM state' = getM state0
[PROOF STEP]
have "state' \<notin> Q"
[PROOF STATE]
proof (prove)
using this:
state' \<notin> {state \<in> Q. getM state = getM state0}
getM state' = getM state0

goal (1 subgoal):
 1. state' \<notin> Q
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
state' \<notin> Q

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
}
[PROOF STATE]
proof (state)
this:
(state', state1) \<in> learnLessState learnL \<Longrightarrow> state' \<notin> Q

goal (1 subgoal):
 1. (state', state1) \<in> terminationLess F0 decisionVars learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
ultimately
[PROOF STATE]
proof (chain)
picking this:
(state', state1) \<in> lexLessState F0 decisionVars \<or> (state', state1) \<in> learnLessState learnL
(state', state1) \<in> lexLessState F0 decisionVars \<Longrightarrow> state' \<notin> Q
(state', state1) \<in> learnLessState learnL \<Longrightarrow> state' \<notin> Q
[PROOF STEP]
show "state' \<notin> Q"
[PROOF STATE]
proof (prove)
using this:
(state', state1) \<in> lexLessState F0 decisionVars \<or> (state', state1) \<in> learnLessState learnL
(state', state1) \<in> lexLessState F0 decisionVars \<Longrightarrow> state' \<notin> Q
(state', state1) \<in> learnLessState learnL \<Longrightarrow> state' \<notin> Q

goal (1 subgoal):
 1. state' \<notin> Q
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
state' \<notin> Q

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
(state', state1) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
\<forall>state'. (state', state1) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q

goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
with \<open>?stateMin \<in> Q\<close>
[PROOF STATE]
proof (chain)
picking this:
state1 \<in> Q
\<forall>state'. (state', state1) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q
[PROOF STEP]
have "(\<exists> stateMin \<in> Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)"
[PROOF STATE]
proof (prove)
using this:
state1 \<in> Q
\<forall>state'. (state', state1) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q

goal (1 subgoal):
 1. \<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q

goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
}
[PROOF STATE]
proof (state)
this:
?state2 \<in> ?Q2 \<Longrightarrow> \<exists>stateMin\<in>?Q2. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> ?Q2

goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
?state2 \<in> ?Q2 \<Longrightarrow> \<exists>stateMin\<in>?Q2. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> ?Q2

goal (1 subgoal):
 1. \<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
\<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)

goal:
No subgoals!
[PROOF STEP]
qed
[PROOF STATE]
proof (state)
this:
\<forall>Q state. state \<in> Q \<longrightarrow> (\<exists>stateMin\<in>Q. \<forall>state'. (state', stateMin) \<in> terminationLess F0 decisionVars learnL \<longrightarrow> state' \<notin> Q)

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma (in \<Z>) dg_Rel_incl_Rel_is_arr'[dg_Rel_cs_intros]:
  assumes "A \<in>\<^sub>\<circ> Vset \<alpha>"
    and "B \<in>\<^sub>\<circ> Vset \<alpha>"
    and "A \<subseteq>\<^sub>\<circ> B"
    and "A' = A"
    and "B' = B"
  shows "incl_Rel A B : A' \<mapsto>\<^bsub>dg_Rel \<alpha>\<^esub> B'"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. incl_Rel A B : A' \<mapsto>\<^bsub>dg_Rel \<alpha>\<^esub> B'
[PROOF STEP]
using assms(1-3)
[PROOF STATE]
proof (prove)
using this:
A \<in>\<^sub>\<circ> Vset \<alpha>
B \<in>\<^sub>\<circ> Vset \<alpha>
A \<subseteq>\<^sub>\<circ> B

goal (1 subgoal):
 1. incl_Rel A B : A' \<mapsto>\<^bsub>dg_Rel \<alpha>\<^esub> B'
[PROOF STEP]
unfolding assms(4,5)
[PROOF STATE]
proof (prove)
using this:
A \<in>\<^sub>\<circ> Vset \<alpha>
B \<in>\<^sub>\<circ> Vset \<alpha>
A \<subseteq>\<^sub>\<circ> B

goal (1 subgoal):
 1. incl_Rel A B : A \<mapsto>\<^bsub>dg_Rel \<alpha>\<^esub> B
[PROOF STEP]
by (rule dg_Rel_incl_Rel_is_arr)


[STATEMENT]
lemma nodeToDigit_list: "digitToList (nodeToDigit nd) = nodeToList nd"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. digitToList (nodeToDigit nd) = nodeToList nd
[PROOF STEP]
by (cases nd,auto)


[STATEMENT]
lemma poly_compat2: "\<lbrakk>p1 >p p2; p2 \<ge>p p3\<rbrakk> \<Longrightarrow> p1 >p p3"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>p1 >p p2; p2 \<ge>p p3\<rbrakk> \<Longrightarrow> p1 >p p3
[PROOF STEP]
unfolding poly_ge_def poly_gt_def
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>\<forall>\<alpha>. pos_assign \<alpha> \<longrightarrow> eval_poly \<alpha> p1 \<succ> eval_poly \<alpha> p2; \<forall>\<alpha>. pos_assign \<alpha> \<longrightarrow> eval_poly \<alpha> p3 \<le> eval_poly \<alpha> p2\<rbrakk> \<Longrightarrow> \<forall>\<alpha>. pos_assign \<alpha> \<longrightarrow> eval_poly \<alpha> p1 \<succ> eval_poly \<alpha> p3
[PROOF STEP]
using compat2
[PROOF STATE]
proof (prove)
using this:
\<lbrakk>?x \<succ> ?y; ?z \<le> ?y\<rbrakk> \<Longrightarrow> ?x \<succ> ?z

goal (1 subgoal):
 1. \<lbrakk>\<forall>\<alpha>. pos_assign \<alpha> \<longrightarrow> eval_poly \<alpha> p1 \<succ> eval_poly \<alpha> p2; \<forall>\<alpha>. pos_assign \<alpha> \<longrightarrow> eval_poly \<alpha> p3 \<le> eval_poly \<alpha> p2\<rbrakk> \<Longrightarrow> \<forall>\<alpha>. pos_assign \<alpha> \<longrightarrow> eval_poly \<alpha> p1 \<succ> eval_poly \<alpha> p3
[PROOF STEP]
by blast


[STATEMENT]
lemma sym_simps [simp]:
    assumes "ide a" and "ide b"
    shows "arr \<s>[a, b]" and "dom \<s>[a, b] = a \<otimes> b" and "cod \<s>[a, b] = b \<otimes> a"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. arr \<s>[a, b] &&& local.dom \<s>[a, b] = a \<otimes> b &&& cod \<s>[a, b] = b \<otimes> a
[PROOF STEP]
using assms sym_in_hom
[PROOF STATE]
proof (prove)
using this:
ide a
ide b
\<lbrakk>ide ?a; ide ?b\<rbrakk> \<Longrightarrow> \<guillemotleft>\<s>[?a, ?b] : ?a \<otimes> ?b \<rightarrow> ?b \<otimes> ?a\<guillemotright>

goal (1 subgoal):
 1. arr \<s>[a, b] &&& local.dom \<s>[a, b] = a \<otimes> b &&& cod \<s>[a, b] = b \<otimes> a
[PROOF STEP]
by auto


[STATEMENT]
lemma parts_insert_subset: "insert X (parts H) \<subseteq> parts(insert X H)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. insert X (parts H) \<subseteq> parts (insert X H)
[PROOF STEP]
by (blast intro: parts_mono [THEN [2] rev_subsetD])


[STATEMENT]
lemma inv\<^sub>L_inf_sum:
  fixes X :: "'b :: banach \<Rightarrow>\<^sub>L _"
  assumes "norm X < 1"
  shows "inv\<^sub>L (id_blinfun - X) = (\<Sum>i. X ^^ i)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. inv\<^sub>L (id_blinfun - X) = (\<Sum>i. X ^^ i)
[PROOF STEP]
using Blinfun_Util.inv_norm_le[OF assms] assms
[PROOF STATE]
proof (prove)
using this:
id_blinfun - X o\<^sub>L (\<Sum>i. X ^^ i) = id_blinfun
(\<Sum>i. X ^^ i) o\<^sub>L id_blinfun - X = id_blinfun
norm X < 1

goal (1 subgoal):
 1. inv\<^sub>L (id_blinfun - X) = (\<Sum>i. X ^^ i)
[PROOF STEP]
by (auto simp: inv\<^sub>L_I[symmetric])


[STATEMENT]
lemma weight_spmf_eq_nn_integral_spmf: "weight_spmf p = \<integral>\<^sup>+ x. spmf p x \<partial>count_space UNIV"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. ennreal (weight_spmf p) = \<integral>\<^sup>+ x. ennreal (spmf p x) \<partial>count_space UNIV
[PROOF STEP]
by(simp add: measure_measure_spmf_conv_measure_pmf space_measure_spmf measure_pmf.emeasure_eq_measure[symmetric] nn_integral_pmf[symmetric] embed_measure_count_space[symmetric] inj_on_def nn_integral_embed_measure measurable_embed_measure1)


[STATEMENT]
lemma bind_nonempty':
  assumes "f \<in> measurable M (subprob_algebra N)" "x \<in> space M"
  shows "bind M f = join (distr M (subprob_algebra N) f)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. M \<bind> f = join (distr M (subprob_algebra N) f)
[PROOF STEP]
using assms
[PROOF STATE]
proof (prove)
using this:
f \<in> M \<rightarrow>\<^sub>M subprob_algebra N
x \<in> space M

goal (1 subgoal):
 1. M \<bind> f = join (distr M (subprob_algebra N) f)
[PROOF STEP]
apply (subst bind_nonempty, blast)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>f \<in> M \<rightarrow>\<^sub>M subprob_algebra N; x \<in> space M\<rbrakk> \<Longrightarrow> join (distr M (subprob_algebra (f (SOME x. x \<in> space M))) f) = join (distr M (subprob_algebra N) f)
[PROOF STEP]
apply (subst subprob_algebra_cong[OF sets_kernel[OF assms(1) someI_ex]], blast)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>f \<in> M \<rightarrow>\<^sub>M subprob_algebra N; x \<in> space M\<rbrakk> \<Longrightarrow> join (distr M (subprob_algebra N) f) = join (distr M (subprob_algebra N) f)
[PROOF STEP]
apply (simp add: subprob_algebra_cong[OF sets_kernel[OF assms]])
[PROOF STATE]
proof (prove)
goal:
No subgoals!
[PROOF STEP]
done


[STATEMENT]
lemma qbs_prob_integral_Markov_inequality_abs':
  assumes "qbs_prob_space_qbs s = X"
          "qbs_integrable s f"
      and "0 < c"
    shows "qbs_measure s {x \<in> qbs_space X. c \<le> \<bar>f x\<bar>} \<le> (1/c * qbs_prob_integral s (\<lambda>x. \<bar>f x\<bar>))"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. qbs_measure s {x \<in> qbs_space X. c \<le> \<bar>f x\<bar>} \<le> 1 / c * \<integral>\<^sub>Q x. \<bar>f x\<bar> \<partial>s
[PROOF STEP]
using qbs_prob_integral_Markov_inequality'[OF assms(1) qbs_integrable_abs[OF assms(2)] _ assms(3)]
[PROOF STATE]
proof (prove)
using this:
(\<And>x. x \<in> qbs_space (qbs_prob_space_qbs s) \<Longrightarrow> 0 \<le> \<bar>f x\<bar>) \<Longrightarrow> qbs_measure s {x \<in> qbs_space (qbs_prob_space_qbs s). c \<le> \<bar>f x\<bar>} \<le> 1 / c * \<integral>\<^sub>Q x. \<bar>f x\<bar> \<partial>s

goal (1 subgoal):
 1. qbs_measure s {x \<in> qbs_space X. c \<le> \<bar>f x\<bar>} \<le> 1 / c * \<integral>\<^sub>Q x. \<bar>f x\<bar> \<partial>s
[PROOF STEP]
by(simp add: assms(1))


[STATEMENT]
lemma sem_5bd2: "ob X Y \<and> X \<sqsubseteq> Z \<longrightarrow> ob Z ((Z \<sqinter> (\<sim>X)) \<squnion> Y)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. ob X Y \<and> X \<sqsubseteq> Z \<longrightarrow> ob Z ((Z \<sqinter> (\<sim>X)) \<squnion> Y)
[PROOF STEP]
using sem_5b sem_5d
[PROOF STATE]
proof (prove)
using this:
\<forall>X Y Z. (\<forall>x. (X \<sqinter> Y) x = (X \<sqinter> Z) x) \<longrightarrow> ob X Y = ob X Z
\<forall>X Y Z. Y \<sqsubseteq> X \<and> ob X Y \<and> X \<sqsubseteq> Z \<longrightarrow> ob Z ((Z \<sqinter> (\<sim>X)) \<squnion> Y)

goal (1 subgoal):
 1. ob X Y \<and> X \<sqsubseteq> Z \<longrightarrow> ob Z ((Z \<sqinter> (\<sim>X)) \<squnion> Y)
[PROOF STEP]
by (smt sem_5b1)


[STATEMENT]
lemma not_col_permutation_3:
  assumes "\<not> Col A B C"
  shows "\<not> Col C B A"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<not> Col C B A
[PROOF STEP]
using assms col_permutation_3
[PROOF STATE]
proof (prove)
using this:
\<not> Col A B C
Col ?A ?B ?C \<Longrightarrow> Col ?C ?B ?A

goal (1 subgoal):
 1. \<not> Col C B A
[PROOF STEP]
by blast


[STATEMENT]
lemma expands_to_imp_ln_powr_eq:
  assumes "(l expands_to L) bs" "eventually (\<lambda>x. l x \<le> f x) at_top"
          "trimmed_pos L" "basis_wf bs"
  shows   "eventually (\<lambda>x. ln (f x powr g x) = ln (f x) * g x) at_top"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<forall>\<^sub>F x in at_top. ln (f x powr g x) = ln (f x) * g x
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<forall>\<^sub>F x in at_top. ln (f x powr g x) = ln (f x) * g x
[PROOF STEP]
from expands_to_imp_eventually_pos[of bs l L] assms
[PROOF STATE]
proof (chain)
picking this:
\<lbrakk>basis_wf bs; (l expands_to L) bs; trimmed_pos L\<rbrakk> \<Longrightarrow> \<forall>\<^sub>F x in at_top. 0 < l x
(l expands_to L) bs
\<forall>\<^sub>F x in at_top. l x \<le> f x
trimmed_pos L
basis_wf bs
[PROOF STEP]
have "eventually (\<lambda>x. l x > 0) at_top"
[PROOF STATE]
proof (prove)
using this:
\<lbrakk>basis_wf bs; (l expands_to L) bs; trimmed_pos L\<rbrakk> \<Longrightarrow> \<forall>\<^sub>F x in at_top. 0 < l x
(l expands_to L) bs
\<forall>\<^sub>F x in at_top. l x \<le> f x
trimmed_pos L
basis_wf bs

goal (1 subgoal):
 1. \<forall>\<^sub>F x in at_top. 0 < l x
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
\<forall>\<^sub>F x in at_top. 0 < l x

goal (1 subgoal):
 1. \<forall>\<^sub>F x in at_top. ln (f x powr g x) = ln (f x) * g x
[PROOF STEP]
with assms(2)
[PROOF STATE]
proof (chain)
picking this:
\<forall>\<^sub>F x in at_top. l x \<le> f x
\<forall>\<^sub>F x in at_top. 0 < l x
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
\<forall>\<^sub>F x in at_top. l x \<le> f x
\<forall>\<^sub>F x in at_top. 0 < l x

goal (1 subgoal):
 1. \<forall>\<^sub>F x in at_top. ln (f x powr g x) = ln (f x) * g x
[PROOF STEP]
by eventually_elim (simp add: powr_def)
[PROOF STATE]
proof (state)
this:
\<forall>\<^sub>F x in at_top. ln (f x powr g x) = ln (f x) * g x

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma eqA_preserves_anga:
  assumes "QCongAAcute a" and
    (* "QCongA b" and*)
    "a = b"
  shows "QCongAAcute b"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. QCongAACute b
[PROOF STEP]
using assms(1) assms(2)
[PROOF STATE]
proof (prove)
using this:
QCongAACute a
a = b

goal (1 subgoal):
 1. QCongAACute b
[PROOF STEP]
by auto


[STATEMENT]
lemma null_sets_completion_subset:
  "B \<subseteq> A \<Longrightarrow> A \<in> null_sets (completion M) \<Longrightarrow> B \<in> null_sets (completion M)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>B \<subseteq> A; A \<in> null_sets (completion M)\<rbrakk> \<Longrightarrow> B \<in> null_sets (completion M)
[PROOF STEP]
unfolding null_sets_completion_iff2
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<lbrakk>B \<subseteq> A; Bex (null_sets M) ((\<subseteq>) A)\<rbrakk> \<Longrightarrow> Bex (null_sets M) ((\<subseteq>) B)
[PROOF STEP]
by auto


[STATEMENT]
lemma contr: "! x xs. inDed (x#x#xs) --> inDed (x#xs)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<forall>x xs. inDed (x # x # xs) \<longrightarrow> inDed (x # xs)
[PROOF STEP]
apply(simp add: inDed_def)
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<forall>x xs. x # x # xs \<in> deductions CutFreePC \<longrightarrow> x # xs \<in> deductions CutFreePC
[PROOF STEP]
apply(blast intro!: ContrI rulesInPCs)
[PROOF STATE]
proof (prove)
goal:
No subgoals!
[PROOF STEP]
done


[STATEMENT]
lemma map_var0_eq_BPS_iff[simp]:
  "map_var0 f g z = BPS X \<longleftrightarrow> (\<exists>Y. z = BPS Y \<and> map_bset (map_prod f g) Y = X)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (map_var0 f g z = BPS X) = (\<exists>Y. z = BPS Y \<and> map_bset (map_prod f g) Y = X)
[PROOF STEP]
by (cases z) auto


[STATEMENT]
lemma conservativeI3:
  assumes "qmpt M T"
          "\<And>A. A \<in> sets M \<Longrightarrow> (\<forall>n>0. (T^^n)-`A \<inter> A = {}) \<Longrightarrow> A \<in> null_sets M"
  shows "conservative M T"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. conservative M T
[PROOF STEP]
proof (rule conservativeI2[OF assms(1)])
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>A. \<lbrakk>A \<in> sets M; 0 < emeasure M A\<rbrakk> \<Longrightarrow> \<exists>n>0. (T ^^ n) -` A \<inter> A \<noteq> {}
[PROOF STEP]
fix A
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<And>A. \<lbrakk>A \<in> sets M; 0 < emeasure M A\<rbrakk> \<Longrightarrow> \<exists>n>0. (T ^^ n) -` A \<inter> A \<noteq> {}
[PROOF STEP]
assume "A \<in> sets M" "0 < emeasure M A"
[PROOF STATE]
proof (state)
this:
A \<in> sets M
0 < emeasure M A

goal (1 subgoal):
 1. \<And>A. \<lbrakk>A \<in> sets M; 0 < emeasure M A\<rbrakk> \<Longrightarrow> \<exists>n>0. (T ^^ n) -` A \<inter> A \<noteq> {}
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
A \<in> sets M
0 < emeasure M A
[PROOF STEP]
have "\<not>(A \<in> null_sets M)"
[PROOF STATE]
proof (prove)
using this:
A \<in> sets M
0 < emeasure M A

goal (1 subgoal):
 1. A \<notin> null_sets M
[PROOF STEP]
unfolding null_sets_def
[PROOF STATE]
proof (prove)
using this:
A \<in> sets M
0 < emeasure M A

goal (1 subgoal):
 1. A \<notin> {N \<in> sets M. emeasure M N = 0}
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
A \<notin> null_sets M

goal (1 subgoal):
 1. \<And>A. \<lbrakk>A \<in> sets M; 0 < emeasure M A\<rbrakk> \<Longrightarrow> \<exists>n>0. (T ^^ n) -` A \<inter> A \<noteq> {}
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
A \<notin> null_sets M
[PROOF STEP]
show "\<exists>n>0. (T ^^ n) -` A \<inter> A \<noteq> {}"
[PROOF STATE]
proof (prove)
using this:
A \<notin> null_sets M

goal (1 subgoal):
 1. \<exists>n>0. (T ^^ n) -` A \<inter> A \<noteq> {}
[PROOF STEP]
using assms(2)[OF \<open>A \<in> sets M\<close>]
[PROOF STATE]
proof (prove)
using this:
A \<notin> null_sets M
\<forall>n>0. (T ^^ n) -` A \<inter> A = {} \<Longrightarrow> A \<in> null_sets M

goal (1 subgoal):
 1. \<exists>n>0. (T ^^ n) -` A \<inter> A \<noteq> {}
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
\<exists>n>0. (T ^^ n) -` A \<inter> A \<noteq> {}

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma set_map_or[simp]:
  "set (map (\<lambda>v. A v \<^bold>\<or> B v) vs) = { A v \<^bold>\<or> B v | v. v \<in> set vs }"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. set (map (\<lambda>v. A v \<^bold>\<or> B v) vs) = {A v \<^bold>\<or> B v |v. v \<in> set vs}
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. set (map (\<lambda>v. A v \<^bold>\<or> B v) vs) = {A v \<^bold>\<or> B v |v. v \<in> set vs}
[PROOF STEP]
let ?l = "map (\<lambda>v. A v \<^bold>\<or> B v) vs"
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. set (map (\<lambda>v. A v \<^bold>\<or> B v) vs) = {A v \<^bold>\<or> B v |v. v \<in> set vs}
[PROOF STEP]
have "set ?l = (\<lambda>v. A v \<^bold>\<or> B v) ` set vs"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. set (map (\<lambda>v. A v \<^bold>\<or> B v) vs) = (\<lambda>v. A v \<^bold>\<or> B v) ` set vs
[PROOF STEP]
using set_map
[PROOF STATE]
proof (prove)
using this:
set (map ?f ?xs) = ?f ` set ?xs

goal (1 subgoal):
 1. set (map (\<lambda>v. A v \<^bold>\<or> B v) vs) = (\<lambda>v. A v \<^bold>\<or> B v) ` set vs
[PROOF STEP]
by force
[PROOF STATE]
proof (state)
this:
set (map (\<lambda>v. A v \<^bold>\<or> B v) vs) = (\<lambda>v. A v \<^bold>\<or> B v) ` set vs

goal (1 subgoal):
 1. set (map (\<lambda>v. A v \<^bold>\<or> B v) vs) = {A v \<^bold>\<or> B v |v. v \<in> set vs}
[PROOF STEP]
thus ?thesis
[PROOF STATE]
proof (prove)
using this:
set (map (\<lambda>v. A v \<^bold>\<or> B v) vs) = (\<lambda>v. A v \<^bold>\<or> B v) ` set vs

goal (1 subgoal):
 1. set (map (\<lambda>v. A v \<^bold>\<or> B v) vs) = {A v \<^bold>\<or> B v |v. v \<in> set vs}
[PROOF STEP]
using setcompr_eq_image
[PROOF STATE]
proof (prove)
using this:
set (map (\<lambda>v. A v \<^bold>\<or> B v) vs) = (\<lambda>v. A v \<^bold>\<or> B v) ` set vs
{?f x |x. ?P x} = ?f ` {x. ?P x}

goal (1 subgoal):
 1. set (map (\<lambda>v. A v \<^bold>\<or> B v) vs) = {A v \<^bold>\<or> B v |v. v \<in> set vs}
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
set (map (\<lambda>v. A v \<^bold>\<or> B v) vs) = {A v \<^bold>\<or> B v |v. v \<in> set vs}

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma fps_subdegree_mult_fps_X_power:
  assumes "f \<noteq> 0"
  shows   "subdegree (fps_X ^ n * f) = subdegree f + n"
  and     "subdegree (f * fps_X ^ n) = subdegree f + n"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. subdegree (fps_X ^ n * f) = subdegree f + n &&& subdegree (f * fps_X ^ n) = subdegree f + n
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (2 subgoals):
 1. subdegree (fps_X ^ n * f) = subdegree f + n
 2. subdegree (f * fps_X ^ n) = subdegree f + n
[PROOF STEP]
from assms
[PROOF STATE]
proof (chain)
picking this:
f \<noteq> 0
[PROOF STEP]
show "subdegree (fps_X ^ n * f) = subdegree f + n"
[PROOF STATE]
proof (prove)
using this:
f \<noteq> 0

goal (1 subgoal):
 1. subdegree (fps_X ^ n * f) = subdegree f + n
[PROOF STEP]
by (induct n)
       (simp_all add: algebra_simps fps_subdegree_mult_fps_X(1) fps_mult_fps_X_power_nonzero(1))
[PROOF STATE]
proof (state)
this:
subdegree (fps_X ^ n * f) = subdegree f + n

goal (1 subgoal):
 1. subdegree (f * fps_X ^ n) = subdegree f + n
[PROOF STEP]
thus "subdegree (f * fps_X ^ n) = subdegree f + n"
[PROOF STATE]
proof (prove)
using this:
subdegree (fps_X ^ n * f) = subdegree f + n

goal (1 subgoal):
 1. subdegree (f * fps_X ^ n) = subdegree f + n
[PROOF STEP]
by (simp add: fps_mult_fps_X_power_commute)
[PROOF STATE]
proof (state)
this:
subdegree (f * fps_X ^ n) = subdegree f + n

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma finite_adm_edges[simp, intro!]: "finite (adm_edges f l)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. finite (adm_edges f l)
[PROOF STEP]
apply (rule finite_subset[of _ "cfE_of f"])
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. adm_edges f l \<subseteq> cfE_of f
 2. finite (cfE_of f)
[PROOF STEP]
by (auto simp: adm_edges_def)


[STATEMENT]
lemma concat_union_fset [simp]:
  shows "concat_fset (xs |\<union>| ys) = concat_fset xs |\<union>| concat_fset ys"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. concat_fset (xs |\<union>| ys) = concat_fset xs |\<union>| concat_fset ys
[PROOF STEP]
by descending simp


[STATEMENT]
lemma length_insort_wrt [simp]: "length (insort_wrt R xs) = length xs"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. length (insort_wrt R xs) = length xs
[PROOF STEP]
by (induction xs) (simp_all add: insort_wrt_def)


[STATEMENT]
theorem sylow_conjugate:
  assumes P:"P \<in> subgroups_of_size (p ^ a)"
  assumes Q:"Q \<in> subgroups_of_size (p ^ a)"
  obtains g where "g \<in> carrier G" "Q = g <# (P #> inv g)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. (\<And>g. \<lbrakk>g \<in> carrier G; Q = g <# (P #> inv g)\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. (\<And>g. \<lbrakk>g \<in> carrier G; Q = g <# (P #> inv g)\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
from P
[PROOF STATE]
proof (chain)
picking this:
P \<in> subgroups_of_size (p ^ a)
[PROOF STEP]
have "card P = p ^ a"
[PROOF STATE]
proof (prove)
using this:
P \<in> subgroups_of_size (p ^ a)

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

goal (1 subgoal):
 1. card P = p ^ a
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
card P = p ^ a

goal (1 subgoal):
 1. (\<And>g. \<lbrakk>g \<in> carrier G; Q = g <# (P #> inv g)\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
from Q
[PROOF STATE]
proof (chain)
picking this:
Q \<in> subgroups_of_size (p ^ a)
[PROOF STEP]
have Qcard:"card Q = p ^ a"
[PROOF STATE]
proof (prove)
using this:
Q \<in> subgroups_of_size (p ^ a)

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

goal (1 subgoal):
 1. card Q = p ^ a
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
card Q = p ^ a

goal (1 subgoal):
 1. (\<And>g. \<lbrakk>g \<in> carrier G; Q = g <# (P #> inv g)\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
from Q P
[PROOF STATE]
proof (chain)
picking this:
Q \<in> subgroups_of_size (p ^ a)
P \<in> subgroups_of_size (p ^ a)
[PROOF STEP]
obtain g where g:"g \<in> carrier G" "Q \<subseteq> g <# (P #> inv g)"
[PROOF STATE]
proof (prove)
using this:
Q \<in> subgroups_of_size (p ^ a)
P \<in> subgroups_of_size (p ^ a)

goal (1 subgoal):
 1. (\<And>g. \<lbrakk>g \<in> carrier G; Q \<subseteq> g <# (P #> inv g)\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
by (rule ex_conj_sylow_group)
[PROOF STATE]
proof (state)
this:
g \<in> carrier G
Q \<subseteq> g <# (P #> inv g)

goal (1 subgoal):
 1. (\<And>g. \<lbrakk>g \<in> carrier G; Q = g <# (P #> inv g)\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
g \<in> carrier G
Q \<subseteq> g <# (P #> inv g)

goal (1 subgoal):
 1. (\<And>g. \<lbrakk>g \<in> carrier G; Q = g <# (P #> inv g)\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
with P finite_G
[PROOF STATE]
proof (chain)
picking this:
P \<in> subgroups_of_size (p ^ a)
finite (carrier G)
g \<in> carrier G
Q \<subseteq> g <# (P #> inv g)
[PROOF STEP]
have "conjugation_action (p ^ a) g P \<in> subgroups_of_size (p ^ a)"
[PROOF STATE]
proof (prove)
using this:
P \<in> subgroups_of_size (p ^ a)
finite (carrier G)
g \<in> carrier G
Q \<subseteq> g <# (P #> inv g)

goal (1 subgoal):
 1. conjugation_action (p ^ a) g P \<in> subgroups_of_size (p ^ a)
[PROOF STEP]
by (metis conjugation_is_size_invariant)
[PROOF STATE]
proof (state)
this:
conjugation_action (p ^ a) g P \<in> subgroups_of_size (p ^ a)

goal (1 subgoal):
 1. (\<And>g. \<lbrakk>g \<in> carrier G; Q = g <# (P #> inv g)\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
conjugation_action (p ^ a) g P \<in> subgroups_of_size (p ^ a)

goal (1 subgoal):
 1. (\<And>g. \<lbrakk>g \<in> carrier G; Q = g <# (P #> inv g)\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
from g P
[PROOF STATE]
proof (chain)
picking this:
g \<in> carrier G
Q \<subseteq> g <# (P #> inv g)
P \<in> subgroups_of_size (p ^ a)
[PROOF STEP]
have "conjugation_action (p ^ a) g P = g <# (P #> inv g)"
[PROOF STATE]
proof (prove)
using this:
g \<in> carrier G
Q \<subseteq> g <# (P #> inv g)
P \<in> subgroups_of_size (p ^ a)

goal (1 subgoal):
 1. conjugation_action (p ^ a) g P = g <# (P #> inv g)
[PROOF STEP]
unfolding conjugation_action_def
[PROOF STATE]
proof (prove)
using this:
g \<in> carrier G
Q \<subseteq> g <# (P #> inv g)
P \<in> subgroups_of_size (p ^ a)

goal (1 subgoal):
 1. (\<lambda>g\<in>carrier G. \<lambda>P\<in>subgroups_of_size (p ^ a). g <# (P #> inv g)) g P = g <# (P #> inv g)
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
conjugation_action (p ^ a) g P = g <# (P #> inv g)

goal (1 subgoal):
 1. (\<And>g. \<lbrakk>g \<in> carrier G; Q = g <# (P #> inv g)\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
ultimately
[PROOF STATE]
proof (chain)
picking this:
g \<in> carrier G
Q \<subseteq> g <# (P #> inv g)
conjugation_action (p ^ a) g P \<in> subgroups_of_size (p ^ a)
conjugation_action (p ^ a) g P = g <# (P #> inv g)
[PROOF STEP]
have conjSize:"g <# (P #> inv g) \<in> subgroups_of_size (p ^ a)"
[PROOF STATE]
proof (prove)
using this:
g \<in> carrier G
Q \<subseteq> g <# (P #> inv g)
conjugation_action (p ^ a) g P \<in> subgroups_of_size (p ^ a)
conjugation_action (p ^ a) g P = g <# (P #> inv g)

goal (1 subgoal):
 1. g <# (P #> inv g) \<in> subgroups_of_size (p ^ a)
[PROOF STEP]
unfolding conjugation_action_def
[PROOF STATE]
proof (prove)
using this:
g \<in> carrier G
Q \<subseteq> g <# (P #> inv g)
(\<lambda>g\<in>carrier G. \<lambda>P\<in>subgroups_of_size (p ^ a). g <# (P #> inv g)) g P \<in> subgroups_of_size (p ^ a)
(\<lambda>g\<in>carrier G. \<lambda>P\<in>subgroups_of_size (p ^ a). g <# (P #> inv g)) g P = g <# (P #> inv g)

goal (1 subgoal):
 1. g <# (P #> inv g) \<in> subgroups_of_size (p ^ a)
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
g <# (P #> inv g) \<in> subgroups_of_size (p ^ a)

goal (1 subgoal):
 1. (\<And>g. \<lbrakk>g \<in> carrier G; Q = g <# (P #> inv g)\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
with Qcard
[PROOF STATE]
proof (chain)
picking this:
card Q = p ^ a
g <# (P #> inv g) \<in> subgroups_of_size (p ^ a)
[PROOF STEP]
have  card:"card (g <# (P #> inv g)) = card Q"
[PROOF STATE]
proof (prove)
using this:
card Q = p ^ a
g <# (P #> inv g) \<in> subgroups_of_size (p ^ a)

goal (1 subgoal):
 1. card (g <# (P #> inv g)) = card Q
[PROOF STEP]
unfolding subgroups_of_size_def
[PROOF STATE]
proof (prove)
using this:
card Q = p ^ a
g <# (P #> inv g) \<in> {H. subgroup H G \<and> card H = p ^ a}

goal (1 subgoal):
 1. card (g <# (P #> inv g)) = card Q
[PROOF STEP]
by simp
[PROOF STATE]
proof (state)
this:
card (g <# (P #> inv g)) = card Q

goal (1 subgoal):
 1. (\<And>g. \<lbrakk>g \<in> carrier G; Q = g <# (P #> inv g)\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
from conjSize finite_G
[PROOF STATE]
proof (chain)
picking this:
g <# (P #> inv g) \<in> subgroups_of_size (p ^ a)
finite (carrier G)
[PROOF STEP]
have "finite (g <# (P #> inv g))"
[PROOF STATE]
proof (prove)
using this:
g <# (P #> inv g) \<in> subgroups_of_size (p ^ a)
finite (carrier G)

goal (1 subgoal):
 1. finite (g <# (P #> inv g))
[PROOF STEP]
by (metis (mono_tags) finite_subset mem_Collect_eq subgroup.subset subgroups_of_size_def)
[PROOF STATE]
proof (state)
this:
finite (g <# (P #> inv g))

goal (1 subgoal):
 1. (\<And>g. \<lbrakk>g \<in> carrier G; Q = g <# (P #> inv g)\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
with g card
[PROOF STATE]
proof (chain)
picking this:
g \<in> carrier G
Q \<subseteq> g <# (P #> inv g)
card (g <# (P #> inv g)) = card Q
finite (g <# (P #> inv g))
[PROOF STEP]
have "Q = g <# (P #> inv g)"
[PROOF STATE]
proof (prove)
using this:
g \<in> carrier G
Q \<subseteq> g <# (P #> inv g)
card (g <# (P #> inv g)) = card Q
finite (g <# (P #> inv g))

goal (1 subgoal):
 1. Q = g <# (P #> inv g)
[PROOF STEP]
by (metis card_subset_eq)
[PROOF STATE]
proof (state)
this:
Q = g <# (P #> inv g)

goal (1 subgoal):
 1. (\<And>g. \<lbrakk>g \<in> carrier G; Q = g <# (P #> inv g)\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
with g
[PROOF STATE]
proof (chain)
picking this:
g \<in> carrier G
Q \<subseteq> g <# (P #> inv g)
Q = g <# (P #> inv g)
[PROOF STEP]
show thesis
[PROOF STATE]
proof (prove)
using this:
g \<in> carrier G
Q \<subseteq> g <# (P #> inv g)
Q = g <# (P #> inv g)

goal (1 subgoal):
 1. thesis
[PROOF STEP]
by (metis that)
[PROOF STATE]
proof (state)
this:
thesis

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma bmod_Sup_fun2: "\<otimes> R f (\<Squnion>\<G>) x = \<Squnion>{\<otimes> R f (g::'a \<Rightarrow> 'b::proto_quantale) x |g. g \<in> \<G>}"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<otimes> R f (\<Squnion>\<G>) x = \<Squnion>{\<otimes> R f g x |g. g \<in> \<G>}
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. \<otimes> R f (\<Squnion>\<G>) x = \<Squnion>{\<otimes> R f g x |g. g \<in> \<G>}
[PROOF STEP]
have "\<otimes> R f (\<Squnion>{g. g \<in> \<G>}) x = \<Squnion>{f y \<cdot> \<Squnion>{g z |g. g \<in> \<G>} |y z. R x y z}"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<otimes> R f (\<Squnion>{g. g \<in> \<G>}) x = \<Squnion>{f y \<cdot> \<Squnion>{g z |g. g \<in> \<G>} |y z. R x y z}
[PROOF STEP]
by (simp add:  bmod_comp_def SUP_is_Sup)
[PROOF STATE]
proof (state)
this:
\<otimes> R f (\<Squnion>{g. g \<in> \<G>}) x = \<Squnion>{f y \<cdot> \<Squnion>{g z |g. g \<in> \<G>} |y z. R x y z}

goal (1 subgoal):
 1. \<otimes> R f (\<Squnion>\<G>) x = \<Squnion>{\<otimes> R f g x |g. g \<in> \<G>}
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
\<otimes> R f (\<Squnion>{g. g \<in> \<G>}) x = \<Squnion>{f y \<cdot> \<Squnion>{g z |g. g \<in> \<G>} |y z. R x y z}

goal (1 subgoal):
 1. \<otimes> R f (\<Squnion>\<G>) x = \<Squnion>{\<otimes> R f g x |g. g \<in> \<G>}
[PROOF STEP]
have "... = \<Squnion>{\<Squnion>{f y \<cdot> g z |g. g \<in> \<G>} |y z. R x y z}"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<Squnion>{f y \<cdot> \<Squnion>{g z |g. g \<in> \<G>} |y z. R x y z} = \<Squnion>{\<Squnion>{f y \<cdot> g z |g. g \<in> \<G>} |y z. R x y z}
[PROOF STEP]
by (simp add: Sup_distl bmod_auxr)
[PROOF STATE]
proof (state)
this:
\<Squnion>{f y \<cdot> \<Squnion>{g z |g. g \<in> \<G>} |y z. R x y z} = \<Squnion>{\<Squnion>{f y \<cdot> g z |g. g \<in> \<G>} |y z. R x y z}

goal (1 subgoal):
 1. \<otimes> R f (\<Squnion>\<G>) x = \<Squnion>{\<otimes> R f g x |g. g \<in> \<G>}
[PROOF STEP]
also
[PROOF STATE]
proof (state)
this:
\<Squnion>{f y \<cdot> \<Squnion>{g z |g. g \<in> \<G>} |y z. R x y z} = \<Squnion>{\<Squnion>{f y \<cdot> g z |g. g \<in> \<G>} |y z. R x y z}

goal (1 subgoal):
 1. \<otimes> R f (\<Squnion>\<G>) x = \<Squnion>{\<otimes> R f g x |g. g \<in> \<G>}
[PROOF STEP]
have "... =  \<Squnion>{\<Squnion>{f y \<cdot> g z |y z. R x y z} |g. g \<in> \<G>}"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. \<Squnion>{\<Squnion>{f y \<cdot> g z |g. g \<in> \<G>} |y z. R x y z} = \<Squnion>{\<Squnion>{f y \<cdot> g z |y z. R x y z} |g. g \<in> \<G>}
[PROOF STEP]
apply (rule antisym)
[PROOF STATE]
proof (prove)
goal (2 subgoals):
 1. \<Squnion>{\<Squnion>{f y \<cdot> g z |g. g \<in> \<G>} |y z. R x y z} \<le> \<Squnion>{\<Squnion>{f y \<cdot> g z |y z. R x y z} |g. g \<in> \<G>}
 2. \<Squnion>{\<Squnion>{f y \<cdot> g z |y z. R x y z} |g. g \<in> \<G>} \<le> \<Squnion>{\<Squnion>{f y \<cdot> g z |g. g \<in> \<G>} |y z. R x y z}
[PROOF STEP]
by ((rule Sup_least, safe)+, (rule Sup_upper2, force, rule Sup_upper, force))+
[PROOF STATE]
proof (state)
this:
\<Squnion>{\<Squnion>{f y \<cdot> g z |g. g \<in> \<G>} |y z. R x y z} = \<Squnion>{\<Squnion>{f y \<cdot> g z |y z. R x y z} |g. g \<in> \<G>}

goal (1 subgoal):
 1. \<otimes> R f (\<Squnion>\<G>) x = \<Squnion>{\<otimes> R f g x |g. g \<in> \<G>}
[PROOF STEP]
finally
[PROOF STATE]
proof (chain)
picking this:
\<otimes> R f (\<Squnion>{g. g \<in> \<G>}) x = \<Squnion>{\<Squnion>{f y \<cdot> g z |y z. R x y z} |g. g \<in> \<G>}
[PROOF STEP]
show ?thesis
[PROOF STATE]
proof (prove)
using this:
\<otimes> R f (\<Squnion>{g. g \<in> \<G>}) x = \<Squnion>{\<Squnion>{f y \<cdot> g z |y z. R x y z} |g. g \<in> \<G>}

goal (1 subgoal):
 1. \<otimes> R f (\<Squnion>\<G>) x = \<Squnion>{\<otimes> R f g x |g. g \<in> \<G>}
[PROOF STEP]
by (auto simp: bmod_comp_def)
[PROOF STATE]
proof (state)
this:
\<otimes> R f (\<Squnion>\<G>) x = \<Squnion>{\<otimes> R f g x |g. g \<in> \<G>}

goal:
No subgoals!
[PROOF STEP]
qed


[STATEMENT]
lemma construct_in_span:
  assumes B[simp]: "vs1.independent B"
  shows "construct B f v \<in> vs2.span (f ` B)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. construct B f v \<in> vs2.span (f ` B)
[PROOF STEP]
proof -
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. construct B f v \<in> vs2.span (f ` B)
[PROOF STEP]
interpret c: linear s1 s2 "construct B f"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. linear (*a) (*b) (construct B f)
[PROOF STEP]
by (rule linear_construct) fact
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. construct B f v \<in> vs2.span (f ` B)
[PROOF STEP]
let ?R = "vs1.representation B"
[PROOF STATE]
proof (state)
goal (1 subgoal):
 1. construct B f v \<in> vs2.span (f ` B)
[PROOF STEP]
have "v \<in> vs1.span ((vs1.extend_basis B - B) \<union> B)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. v \<in> vs1.span (vs1.extend_basis B - B \<union> B)
[PROOF STEP]
by (auto simp: Un_absorb2 vs1.extend_basis_superset)
[PROOF STATE]
proof (state)
this:
v \<in> vs1.span (vs1.extend_basis B - B \<union> B)

goal (1 subgoal):
 1. construct B f v \<in> vs2.span (f ` B)
[PROOF STEP]
then
[PROOF STATE]
proof (chain)
picking this:
v \<in> vs1.span (vs1.extend_basis B - B \<union> B)
[PROOF STEP]
obtain x y where "v = x + y" "x \<in> vs1.span (vs1.extend_basis B - B)" "y \<in> vs1.span B"
[PROOF STATE]
proof (prove)
using this:
v \<in> vs1.span (vs1.extend_basis B - B \<union> B)

goal (1 subgoal):
 1. (\<And>x y. \<lbrakk>v = x + y; x \<in> vs1.span (vs1.extend_basis B - B); y \<in> vs1.span B\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
unfolding vs1.span_Un
[PROOF STATE]
proof (prove)
using this:
v \<in> {x + y |x y. x \<in> vs1.span (vs1.extend_basis B - B) \<and> y \<in> vs1.span B}

goal (1 subgoal):
 1. (\<And>x y. \<lbrakk>v = x + y; x \<in> vs1.span (vs1.extend_basis B - B); y \<in> vs1.span B\<rbrakk> \<Longrightarrow> thesis) \<Longrightarrow> thesis
[PROOF STEP]
by auto
[PROOF STATE]
proof (state)
this:
v = x + y
x \<in> vs1.span (vs1.extend_basis B - B)
y \<in> vs1.span B

goal (1 subgoal):
 1. construct B f v \<in> vs2.span (f ` B)
[PROOF STEP]
moreover
[PROOF STATE]
proof (state)
this:
v = x + y
x \<in> vs1.span (vs1.extend_basis B - B)
y \<in> vs1.span B

goal (1 subgoal):
 1. construct B f v \<in> vs2.span (f ` B)
[PROOF STEP]
have "construct B f (\<Sum>b | ?R y b \<noteq> 0. ?R y b *a b) \<in> vs2.span (f ` B)"
[PROOF STATE]
proof (prove)
goal (1 subgoal):
 1. construct B f (\<Sum>b | vs1.representation B y b \<noteq> (0::'a). vs1.representation B y b *a b) \<in> vs2.span (f ` B)
[PROOF STEP]
by (auto simp add: c.sum c.scale construct_basis vs1.representation_ne_zero
      intro!: vs2.span_sum vs2.span_scale intro: vs2.span_base )
[PROOF STATE]
proof (state)
this:
construct B f (\<Sum>b | vs1.representation B y b \<noteq> (0::'a). vs1.representation B y b *a b) \<in> vs2.span (f ` B)

goal (1 subgoal):
 1. construct B f v \<in> vs2.span (f ` B)
[PROOF STEP]
ultimately
[PROOF STATE]
proof (chain)
picking this:
v = x + y
x \<in> vs1.span (vs1.extend_basis B - B)
y \<in> vs1.span B
construct B f (\<Sum>b | vs1.representation B y b \<noteq> (0::'a). vs1.representation B y b *a b) \<in> vs2.span (f ` B)
[PROOF STEP]
show "construct B f v \<in> vs2.span (f ` B)"
[PROOF STATE]
proof (prove)
using this:
v = x + y
x \<in> vs1.span (vs1.extend_basis B - B)
y \<in> vs1.span B
construct B f (\<Sum>b | vs1.representation B y b \<noteq> (0::'a). vs1.representation B y b *a b) \<in> vs2.span (f ` B)

goal (1 subgoal):
 1. construct B f v \<in> vs2.span (f ` B)
[PROOF STEP]
by (auto simp add: c.add construct_outside vs1.sum_nonzero_representation_eq)
[PROOF STATE]
proof (state)
this:
construct B f v \<in> vs2.span (f ` B)

goal:
No subgoals!
[PROOF STEP]
qed