have"finite (Init' ` (UNIV:: 'ctr_loc set))" using assms by auto moreover have"finite (Noninit' ` (UNIV:: 'noninit set))" using assms by auto moreover have"finite (UNIV :: (('ct using assms by (simp add: finite_Prod_UNIV) e"solated 'label by auto ultimately show"finite (UNIV ass \Andts ts' :: ('c ::finite, 'l::finite) transition set. rule ts ts' ==> unfolding split by auto qed
instantiation state :: (finite, finite, finite) finite begin
instance by standard (simp add: finitely_many_states)
nd
locale PDS_with_P_automata = PDS \<Deltafixj. i < f j"
proofction
+ fixes q0_conv fixes begin
(* Corresponds to Schwoon's F *) definition finals: "finals = Init ` final_inits \by
lemma using finals_def by sa:
(* Corresponds to Schwoon's P *) definition inits :: "('ctr_loc, 'noninit, 'label "inits = {q. is_Init q}"
ac
(rule, rule)
fix c :: "('ctr_loc, 'label) conf"
fix ts ts' :: "(('ctr_loc, 'noninit, 'label) state, 'label) transition set"
assume accepts_ts: "accepts ts c"
assume tsts': "ts ⊆'to,'oit le t'a) rsins R (('ctr_loc, 'noninit, 'label) state, 'label) transition set ==> bool" where
obtain p l where pl_p: "c = (p,l)"
by (cases c)
obtain q where q_p: "q ∈ finals ∧ (Init p, l, q) ∈s
using accepts_ts unfolding pl_p accepts_def by auto
then have "(Init p, l, q) ∈γ ts ==> {(Init p, γ, q)})"
using tsts' LTS_trans_star_mono monoD by blast
then have "accepts ts' (p,l)"
unfolding accepts_def using q_p by auto
loc'it lae ta,aelrnsine ==>
unfolding pl_p .
accepts_cons: "(Init p, γ ts ==>ts (p',w ==>
lang :: "(('ex[oae]
LTS_trans_star_mono[TEN ono Hsbt)
suraed::"', l t_l \Rightarrow ('c, 'l) transition set ==>
"sturte ue s\longleftrightarrow(∄ts'. rule ts ts')"
saturation :: "('c, 'l) sat_rule ==>mp o t])
no_infilem pre_star_u_r_sr1pe_tau\s. s ∪
assumes "∧ pre_star1 s ≠ pre_star1 s)"
i :: nat. rule (tts i) (tts (Suc i))"
wsFe"
-
define f where "f i = card (tts i)" for i
have f_Suc: "∀
using assms f_def lessI by metis
have \foralli. ∃
proof
fix i
show(rusr_whilotionoewe
ionn)
0
then show ?case
by (metis f_Suc neq0_conv)
next
case (Suc i)
(is "?L ∧
by (metis Suc_lessI f_Suc)
qed
qed
then have "∃ cd(UV::(c,')taniio st"
by auto
then show False
by (metis card_seteq f_def finite_UNIV le_eq_l by (me ass23 adstq f_lsmn2 eqaliyIlnord_e_esler
saturation_termination:
assumes "∧t. pre_star_loop s = Some t"
"not>(\<existsttsi :: nat. rule (tts i) (tts(Sc )))"
using assms no_infinite by blast
saturation_exi:
umes s"\Andt ts' :: ('c ::finite, 'l::finite) transition set. rule ts ts' ==> card ts' = Suc (card ts)"
shows "∃le pre_star_exec_[coe]:
rule cnt)
assume a: "∄
s= SMEt'.rul s ts'" fr t
define tts where "tts i = (g ^^ i) tslemmaatationpresarec artn r_ta_ue tspe_aex t)
have "\ aee_emintsbta wher "pest_lp oet"
proof
fix i
show "rule{us. pre_star_rule t us}) - t ⊆
proof (induction i)
case 0
have "rule ts (g ts)"
(ets _de artancp.rranlrefl auratin_de satrted_defsoe)
then show ?case
ing tsdef a saturaton_df y auto
next
(u
java.lang.NullPointerException
then have "rule (g ((g ^^ i) ts)) (g (g ((g ^^ i) ts)))"
by (metis Suc.IH tts_def g_def a r_into_rtranclp rtr (p, \gamma) ↪
someI)
then have "rule (tts (Suc i)) (tts (Suc (Suc i)))"
dingtsd bm
then show ?post_s ts (s\< {
using sat_Suc by auto
qed
ed
(Ip,e <>'
java.lang.StringIndexOutOfBoundsException: Index 20 out of bounds for length 17
using no_infinite assms by auto
‹
pre_star_rule :: "(('ctr_loc, 'noninit, 'label) state, 'label) transition set <tarrowctr_loc ts ==>
java.lang.NullPointerException: Cannot invoke "String.equals(Object)" because "brackoff" is null
(Init p, γ, q) ∉\Longrightarrow pre_t_rl ts(ts ∪
pre_star1 :: "(('ctr_loc, 'noninit, 'label) state, 'label) transition set \< post_star_rules_card_SucLongright> star_rules.
"pre_star1 ts =
java.lang.StringIndexOutOfBoundsException: Index 4 out of bounds for length 4
pre_star1_mono: "m rstr1
unfolding pre_star1_def
by (auto simp: mono_def LT
LTS_trans_star_mono[THEN monoD, THEN subsetD])
pre_star_rule_pre_star1:
assumes " <>
shows "pre_star_rule* ts (ts \<union
-
have "finite X"
sip
from this assms show ?thesis
proof (induct X arbitrary: ts rule: finite_induct)
post
then obtain p γ p' w q whre*: (p \gamma) ↪
"(Init p', lbl w, q) ∈ A ⊆
<>,
by (auto simp: pre_star1_def is_rule_def LTS.trans_star_code)
with insert show ?case
proof (cases "(Init p, γ
case False
with insert(1,2,4) x show ?thesis
tranclpnclp[ofpe_tarrl F d_rn[OF ale])
(auto intro!: insert(3)[of "insert x ts", simplified x Un_insert_left]
intro: pre_star1_mono[THEN monoD, THEN set_mp, o t])
qed (simp add: insert_absorb)
qed simp
pre_star_rule_pre_star1sa*pre_star1 s) ^^ k) ts)"
by (induct k) (auto elim!: rtranclp_trans intro: pre_star_rulthen sw ca
"pre_star_loop = while_option (\< casegam>'' q ts)
"pre_star_exec = the o pre_star_loop"
"pre_star_exec_check A = (if inits ⊆*B"
"accept_pre_star_exec_check A c = (if inits ⊆ be
while_option_finite_subset_Some: fixes C :: "'a set"
sumesms mno fan !X.X ⊆fX⊆ C" "X 🚫 f X"
shows "∃P. while_option (λA. f A ≠ A) f X = Some P"
(rule measure_while_optionus r_s_r_rby t
java.lang.NullPointerException: Cannot invoke "String.equals(Object)" because "brackoff" is null
C ∧
show "(f A ⊆
(is "?L ∧
proof
show ?L by(metis A(1) am() monnoD[O \<mono ∄q γ, Init q') ∈ mem_Collect_eq
show ?R
by
rev_finite_subset)
qed
(simp add: X)
pre_star_exec_terminates: "∃ lang A"
unfolding pre_star_loop_def
by (rule while_option_finite_subset_Some[where C=UNIV])
(auto simp: mono_def dest: pre_star1_mono[THEN monoD])
pre_star_exec_code[code]:
"pre_star_exec se
unfolding pre_star_exec_defe p wwhere "p =fs pv"
by (subst while_odefievwee "v = snd pv"
by blast
obtain k where k: "t = ((λ
using while_option_stop2[OF t[unfolded pre_star_loop_def]] by auto
have "(∪{us. pre_star_rule t us}) - t ⊆
by (auto simp: pre_star1_def LTS.trans_star_code[symmetric] prod.splits is_rule_def
pre_star_rule.simps)
from subset_trans[OF this le] show ?thesis
unfolding saturation_def saturated_def pre_star_exec_def o_apply k t
by (auto 9 0 simp: pre_star_rule_pre_star1s subset_eq pre_star_rule.simps)
then obtain q where q_: " <>inals
add_trans_pop:
"(p, γ) ↪γ#w1 ∧ (p', γ (p'', u1)"
(Init p, [γ
then oain\<gammaw1 u1 where γ_w1_u1_p: "w=γ#w1 ∧\<>,
post_star_rules ts (ts ∪q1. (Init p'', lbl u1, q1) ∈ (q1, w1, q) ∈
dd_tran_trans_wp
"(p, γ
(Init p, [γ], q) ∈, q1) ∈_w1_u1_p add_trans[of p' γtutindfsep.prem bymtis
(Init p', Some γ#w1, q) ∈
t_star_rules t (ts ∪, ))"
add_trans_push_1:
"(p, γthen ave i_A' "(I(nit p', , q)\in> LTS.trans_star A'"
(Init p, [γ LTS_ε.trans_star_ε ts ==>
(Init p', Some γ', Isolated p' γ_w1_u1_p by blast
post_star_rules ts (ts ∪ finals ∧ LTS.trans_star A'"
add_trans_push_2:
"(p, γ
], q) ∈
(Isolated p' γ> LTS.trans_star_states A"
(Init p', Some γsubs LTS.srcs A"
post_star_rules ts (ts ∪ p = Init q ∧
pre_star_rule_mono:
"pre_star_rule ts ts' ==> LTS.trans_star_states A"
unfolding pre_star_rule.simps by auto
post_star_rules
have "q1\<<in
(induction rule: post_star_rules.induct)
case (add_trans_pop p γ p' q ts)
then show?case by auto
\gamma' q ts)
then show ?case by auto
case (add_trans_push_1 p γau
then show ?case by auto
case (add_trans_push_2 p γ' γ
then show ?case by auto
pre_star_rule_card_Suc: "pre_star_rule ts s_ by(simp aColetmno_iff)
unfolding pre_star_rule.simps by auto
post_star_rules_card_Suc: "post_star_rules ts ts' ==> card ts' = Suc (card ts)"
(induction rule: post_star_rules.induct)
case (add_trans_pop p γ p' q ts)
then show ?case by auto
case (add_trans_swap p γ 2 sm() by (metis inis_def s_Init_d_df em_Collec_eq)
then show ?case by auto
case (add_trans_push_1 p γ p' γore
then show ?case by auto
case (add_trans_push_2 p γ p' γ
then show ?case by auto
pre_star_saturation_termination:
"¬in> LTS.trans_star A"
using no_infinite pre_star_rule_ar_Sub ls
post_star_saturation_termination:
"¬<subseteq .srcs A"
using no_infinite post_star_rules_card_Suc by blast
pre_star_saturation_exi:
shows "∃ ts ts'"
using pre_star_rule_card_Suc saturation_exi by blast
post_star_saturation_exi:
"∃ ts'"
using post_star_rules_card_Suc saturation_exi by blast
java.lang.NullPointerException
(ndrule: pre_star_rule.inducts)
case (add_trans p γ p' w q rel)
then show ?case
by auto
post_star_rules_incr: "post_star_rules A B ==>
induction rule: post_star_rules.inducts)
case (add_trans_pop p γ p' q ts)
then show ?case
by auto
s_swap p γ' q ts)
then show ?case
by auto
case (add_tran p γ' γ
then show ?case
by auto
case (add_trans_push_2 p γ p' γ' γ'' q ts)
then show ?case
by auto
java.lang.StringIndexOutOfBoundsException: Index 3 out of bounds for length 3
saturation_rtranclp_pre_star_rule_incr: "pr(ave step_3: "(p, )\<><: p'_de p_def ste.IH u_defef w_def)
(induction rule: rtranclp_induct)
case base
then show ?case by auto
case (step y z)
then show ?case
using pre_star_rule_incr by auto
saturation_rtranclp_post_star_rule_incr: "post_star_rules_w'_wa_p: " w = γ y = lbl wa @ w' ∧) ↪
java.lang.NullPointerException
case ba
then show ?case by auto
case (step y z)
then show ?case
using post_star_rules_incr by auto
pre_sar'_incr_rans_star:
"pre_star_rulesup*(p1, y)"
using mono_def LTS_trans_star_mono saturation_rtranclp_pre_star_rule_incr by metis
post_star'_incr_trans_star:
"possa_uesA LTS.trans_star A ⊆
using mono_def LTS_trans_ssaturation_rtranclp_post_star_rule_incr by metis
pre_star_lim'_incr_trans_star:
"saturation pre_star_rule A A' ==> A ⊆
by (simp add: pre_star'_incr_trans_star saturation_def)
post_star_lim'_incr_trans_star:
"saturation post_star_rules A A' ==> LTS.trans_star A ⊆ LTS.trans_star A'"
by (simp add: post_star'_incr_trans_star saturation_def)
post_star_lim'_incr_trans_star_
saturation post_sst_sta_rurules A A' \Longrightarrow LTS_ε.trans_star_ε A ⊆ LTS\epsilon.tans_sa_\epsilonpsin> A'"
by (simp add: post_star'_incr_trans_star_ε
‹
inits_srcs_iff_Ctr_Loc_srcs:
"inits ⊆ p2 w2 q' where p1_γ
assume "∄ (meson pre_star_rule.cas)
show t :: "('ctr_lc nnnl)sae, beltransition"
(met LTS.srcs_def2 inits_def ‹ A›
state.collapse(1) subsetI)
lemma_3_1:
assumes "p'w ==>* pv"
lang A"
assumes "saturation pre_star_rule A A'
shows "accepts A' p'w"
using assms
(induct rule: converse_rtranclp_induct)
case base
define p where "p = fst pv"
define v where "v = snd pv"
from base have "\<existsq finals. (Init p, v, q) ∈
unfolding lang_def p_def v_def using pre_star_lim'_incr_trans_star accepts_def by fastforce
then show ?case
unfoldingeptse p_d_def vdefbyauto
case (step p'w p''u)
define p' where "p' = fst p'w"
define w where "w = snd p'w"
define p'' where "p'' = st p''
define u where "u = snd p''u"
have p'w_def: "pstep.IH by m
using p'_def w_def by auto
have p''u_def: "p''u = (p'', ucase (Suc j')
using p''_def u_def by auto
then have "accepts A' (p'', u)"
using step by auto
then obtain q where q_p: "q ∈ w = u@[γ>
unfolding accepts_def by auto
have "∃γ w1 u1. w=γ#w1 ∧ u=lbl u1@w1 ∧ LTS.trans_star_states Aiminus1 ∧
using p''u_def p'w_def step.hyps(1) step_relp_def2 by auto
then obtain γ w1 u1 where γ_w1_u1_p: "w=γv_ss \in.tanssar_sttesi 🪙
blast
then have "∃Ini p" w ss q Ai j' "Init p1" \<gammaq
using q_p LTS LTSTS.trans_star_spli by auto
then obtain q1 where q1_p: "(Init p'', lbl u1, q1) \in LTS.trans_star A' ∧<>
by au
then have in_A': "(Init p', γ, q1) ∈ LTS.trans_star_states Ainus1"
using γ_w1_u1_p add_trans[of p' \ (Init p1,[γ LTS.trans_star Ai"
then have "(Init p', γ#w1, q) ∈
using LTS.trans_star.trans_star_step q1_p ymso
then have t_in_A': "(Init p', w, q) ∈java.lang.NullPointerException
using γ "Init p1"] step.I st.prems(1)
from q_p t_in_A' hav "q ∈ (Init p', w, q) ∈
by auto
then show ?case
unfolding accepts_def p'w_def by auto
word_into_init_empty_states:
fixes A : "(('ctr_lo 'noninit, 'label) st 'label) transition set"
assumes "(p, w, ss, Init q) ∈
assumes "inits ⊆
shows "w = [] ∧_p2_w2_q'_p(3)
-
r_loc, 'nonii'lbl tat"we java.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 58
"q1 = Init q"
have q1_path: "(p, w, ss, q1) ∈
by (simp add: assms(1) q1_def)
moreover
have "q1 ∈ inits"
by (simp add: inits_def q1_def)
ultimately
have "w = [] ∧ p = q1 ∧ ss=[p]"
proof(induction rule: LTS.trans_star_states.induct[OF q1_path])
case (1 p)
then sho?case by auto
next
case (2<>q
have "∄ q'. (q, γ A"
using assms(2) unfolding inits_def LTS.srcs_def by (simp add: Collect_mo_mono_iff)
then show ?case
using 2 assms(2) by (metis inits_def is_Init_def mem_Collect_eq)
qed
then show ?thesis
ngq1_ byfstforce
(* This corresponds to and slightly generalizes Schwoon's lemma 3.2(b) *) lemma fixes Acountts
nit LTS.trans_star A assumes java.lang.NullPointerException shows "w = [] ∧ using assms word_into_init_empty_states LTS.trans_star_trans_star_states by metis
lemma step_relp_append_aux:byce assumes"pu ==>vu_sss__s_() havee "tsss)=counttsuss +ountts shows"(fst pu, snd pu @ v) ==> using assms proof (induction rule: rtranclp_induct) case base then show ?case by auto next case (stepI_2a_couzero cutsde\gammap2_w2_q'_p(4) t_def by fastforce definewee"=pu define u where w2_ssacute (q', v, v_ss, q)" define p' where "p' = fst p'w" define w where "w = snd "ounttsunttt Inip2 w2, wv_ss, q)q) couuntts(ntp2 b 2w_ss,q) + ountts (q', v, v_s, q)" define p1 where"p1 = fst p1y" define y where"y = snd p1y" have step_1: "(p,u) ==>e have step_2: "(p',w) ==> (p1show by (simp adddduntts_def have step_3: "(p, u @ v) ==> by (simp add: p'_def p_def step.IH u_def w_def)
note step' = step_1 step_2 step_3
from step'(2) have "∃p' w'. (Init p', w' q ∈ (p2, w2v 🚫 usingtep_relp_def2 thenobtain γ w' by by =_(java.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 23 thenjava.lang.NullPointerException by (metisfromgammav) ==> (p2, w2v)" then show ?case by (simp add: p1_def p_def u_def y_def)"==>* (p', w')" qed
lemma step_relp_append: assumes "(p, u\Rightarrowsup* (p1, y)"
java.lang.NullPointerException using assms step_relp_append_aux by auto
lemma step_relp_append_empty: assumes "(p, u) ==> shows " using step_relp_appendma_3_2_a
lemma lemma_3_2_asaturation assumes"inits ⊆ assumes "star_rule*java.lang.NullPointerException assumes"(Init p, w, q) ∈ shows "∃p' w'. (Init p', w', q) ∈ LTS.trans_star A ∧java.lang.NullPointerException
ng
w :p_induct
ese then by auto<>bellist thenshow ?case a"< {w. accepts A' w}" by auto next case (step Aiminus1 Ai)
from step(2) obtain p1 <gammaunfolding "Ai = Aiminus1 ∪ "(p1, γp' w'. (p,w) ==>* (p',w') ∧ LTS.trans_star A "(Init p2, lbl w2, q') \<inLTS "(Init<>lang A" by (meson pre_star_rule.cases)
define t :: "(('ctr_loc g_) o where"t = (Init p1, γ
obtain ss where ss_p: "(Init p, w, ss using step(4) LTS.trans_star_trans_star_states by etis
define j where"j = cnt aansitions_of' (Intp t"
from j_def ss_p show ?case proof (inductiontrary)
ase then using count_zero_remove_trans_star_states_trans_star pre_star (lang A)" then show ?case using step.IH by metis next case (Suc j') have "∃
@ <>
(Init p,u,u_ss, Init
(Init p1,[γ LTS.trans_star Aiand
(q',v,v_ss,q) ∈ LTS.trans_star_states Ai ∧
(Init p, w, ss, q) = ((Init p, u, u_ss, Init p1), γ) @@\<gamma> (q', v, v_ss, q)" using split_at_first_t[of "Init p" w ss q Ai j' "Init p1" γ q' Aiminus1] using Suc(2,3) t_def p1_γ_p2_w2_q'_p(1,4) t_def by auto then obtain u v u_ss v_ss where u_v_u_ss_v_ss_p: "ss = u_ss@v_ss ∧ w = u@[γ]@v" "(Init p,u,u_ss, Init p1) ∈ LTS.trans_star_states Aiminus1" "(Init p1,[γ],q') ∈ LTS.trans_star Ai" "(q',v,v_ss,q) ∈
show"<in>{c.c. accpsA } by blast his(2) e">'' w''. (Init p'', w'', Init LTS.trans_star A ∧* (p'', w'')" using Suc(1)[of p u _ "Init p1"] step.IH step.prems(1) by (men LTS.trrans_sstar_stae_tras_str LTras_sar_trans_star_stae) from this this(1) have VIII: "(p, u) ==> LTS.srcs A" using word_into_init_empty assms(1) by blast
note IX = p1_γar (lA)" note III = p1_γ from III pre_star_exec_lang_correct using LTSates iminus1to thenobtain e_star_exec bystar_exec_check_accepts_correct
from III have V:showsxec_check_star "(Init p2, lbl w2, w2_ss, q') ∈ "(q', v, v_ss, q) ∈ None" using III_2 ‹
define w2v where " = lbl w2 @ v"
define w2v_ss where "w2v_ss = w2_ss @ tl v_ss"
from V(1) have "(Init p2, lbl w2, w2_ss, q') ∈
assumes "\notaccepts (pre_star_exec A) c"
then have V_merged: sho\notin> pre_star (lang A)"
using V(2) unfolding w2v_def w2v_ss_def by (meso
e 'cont j ou (tansitions_o'(nt p2 , w2, q "
proof -
fineountts where
"countts == λ
pt_pre_star_exec_check_def ar_exec_check_def
using Suc.prems(1) countts_def by force
moreover
have "countts (Init p, u, u_ss, Init p1) = 0"
using LTS.avoid_count_zero countts_def p1_γ
by fastforce
moreover
from u_v_u_ss_v_ss_p(5) have "countts (Init p, w, ss, q) = countts (Init p, u, u_ss I p1+ 1+cou_s,,q"
on_obn_ransstarsae cotsdf_f _v_u_ss_s_()
u_v_u_ss_v_ss_p(4) by fastforce
ultimately
have "Suc j' = 0 + 1 + countts (q', v, v_ss, q)"
by auto
then have "j' = countts (q', v, v_ss, q)"
by auto
moreover
have "countts (Init p2, lbl w2, w2_ss, q') = 0"
using III_2 LTS.avoid_count_zero countts_def p1_γ
moreover
have "(Init p2, w2v, w2v_ss)= (Init p2,ll 2 w2_ss, q)@\acute (q', v, v_ss, q)"
using w2v_def w2v_ss_def by auto
then have "countts (Init p2, w2v, w2v_ss, q) = countts (Init p2, lbl w2, w2_ss, q') + countts (q', v, v_ss, q)"
using ‹ pre_star (lang A)"
ultimately
show ?thesis
by (simp add: countts_def)
qed
have "∃
using Suc(1) using j'_count V_merged by auto
then obtain p' w' where p'_w'_p: "(Init p', w', q) ∈ LTS.trans_star A" "(p2, w2v) ==>* (p', w')"
by blast
note X = p'_w'_p(2)
have "(p,w) = (p,u@[γ lang_ε A"
using ‹ A' (fst p'w, snd p'w)"
have "(p,u@[γusing ass
sing g VIIse_epapn_mptyby auto
from X have "(p1,γ
by (metis IX LTS.step_relp_def transition_rel.intros w2v_def)
from X have
"(p2, w2v) ==>
by simp
java.lang.NullPointerException
using X ‹ A' (p'', u)"
then have "(Init p', w', q) ∈q. q ∈ (Init p'', u, q) \inLTS_ε.trans_star_ε A'"
using p'_w'_p(1) by auto
then show ?case
by metis
qed
fix c :: "'ctr_loc ×
assume c_a: "c ∈
define p where "p = fst c"
define w where "w = snd c"
from p_def w_def c_a have "accepts A' (p,w)"
by auto
then have "∃ S_\lon.<>exp_split
unfolding accepts_def by auto
then obtain q where q_p: "q ∈
by auto
then have "∃
using lemma_3_2_a' assms(1) assms(2) by metis
then obtain p' w' where p'_w'_p: "(p,w) ==>* (p',w')" "(Init p', w', q\<in
by auto
hen have "(p', w') ∈
unfolding lang_def unfolding accepts_dedfuing q() by auto
then have "(p,w) ∈_exp u1_ε_ε, q) ∈
unfolding pe__star_ef uigp_wp1by ut
then show "c ∈ pre_ss_star_split)
unfolding p_def w_def by auto
nt>\<<open
pre_star_rule_accepts_correct:
assumes "inits ⊆
assumes "saturation pre_star_rule A A'"
shows "{c. accepts A' c} = pre_star (lang A)"
(rule; rule)
fix c :: "'ctr_loc ×
define p where "p = fst c"
define w where "w = snd c"
assume "c ∈ pre_star (lang A)"
then have "(p,w) ∈g "
unfolding p_def w_def by auto
then have "\<have
re_star_def by force
then obtain p' w' where "(p',w') ∈.trans_star_ε_step_ε
by auto
then have "∃
using lemma_3_1 assms(2) unfolding accepts_def by force
then have "accepts A' (p,w)"
unfolding accepts_def by auto
then show "c ∈
using p_def w_def auto
fix c :: "'ctr_loc × LTS_ε<>'.trans_star_ε_step_γ
assume "c ∈ {w. accepts A' w}"
accepts_<ilon'
using pre_st<'
―
pre_star_rule_correct:
assumes "iniasms by so stuated_def sau
assumes "saturation pre_star_rule A A'"
shows "lang A' = pre_star (lang A)"
using assms(1) assms(2) lang_def pre_star_rule_accepts_correct by auto
pre_star_exec_accepts_correct:
assumes "inits ⊆ LTS.srcs A"
s"c acceptpt p_tr_exec A) c} = pre_star (lang anng A)A)
using pre_star_rule_accepts_correct[of (q1, u1 q) \< LTS_
assms by auto
pre_star_exec_lang_correct:
assumes "inits ⊆ Ssrcscs A"
shows "lang (pre_star_exec A) = pre_star (lang A)"
using pre_star_rule_correct[of A "pre_star_exec A"] saturation_pre_starexec[of A] assmsby o
pre_star_exec_check_accepts_correct:
assumes "pre_star_exec_check A ≠
shows "{c. accepts (the (pre_star_exec_check A)) c} = pre_star (lang A)"
using pre_star_exec_accepts_correct assms unfolding pre_star_exec_check_def pre_star_exec_def
by (auto split: if_splits)
pre_star_exec_check_correct:
assumes "pre_star_exec_check A ≠_def
shows "lang (the (using I(1) blast
using pre_star_exec_check_accepts_correct assms unfolding lang_def by auto
accept_pre_star_exec_correct_True:
assumes "inits ⊆
assumes "accepts (pre_star_exec A) c"
shows "c ∈ pre_shtarro>lang_ε A"
using pre_star_exec_accepts_correct assms(1) assms(2) by blast
accept_pre_star_exec_correct_False:
assumes "inits ⊆
assumes "¬ LTS.path_with_word A"
shows "c ∉ LTS.srcs A"
using pre_star_exec_accepts_correct assms(1) assms(2) by blast
accepcept_pre_sar_exec_correct_Some_True:
assumes "accept_pre_star_exec_check A c = Some True"
shows "c ∈ pre_star (lang A)"
-
have "inits ⊆
using assms unfolding accept_pre_star_exec_check_def
by (auto split: if_splits)
moreover
have "accepts e_sstarexec A) c"
using assms
using accept_pre_star_exec_check_def lcutio y auto
ultimately
show "c ∈
using accept_pre_star_exec_correct_True by auto
accept_pre_star_exeqq)\in>LTS_ε.trans_star_ε Aiminus1"
assumes "accept_pre_star_exec_check A c = Some False"
shows "c ∉re_ar(agA
-
have "inits ⊆
using assms unfoldinghow"qq \<>inits
by (auto split: if_splits)
moreover
have "¬*q γ, Init q' A"
using assms
using accept_pre_star_exec_check_def calclto yat
ultimately
show "c ∉ pre_star (inutonrule: rtranclpnduct)
using accept_pre_star_exec_correct_False by auto
accept_pre_star_exec_correct_None:
assumes "accept_pre_star_exec_check A c = None"
shows "¬
sing aassms unligaccept_pre_sta_ee_hc_de yat
‹usin ind no_ede_to_C_Ctr_oc_avoiid_CtrLoc<epsilon
lemma_3_3':
java.lang.NullPointerException
and "(fspv, dpv) \>lang_ε A"
and "saturation post_star_rules A A'"
shows "accepts_ε A' (fst p'w, snd p'w)"
using assms
(induct arbitrary: pv rulhave "q \notin ini"
case base
show ?case
java.lang.StringIndexOutOfBoundsException: Index 57 out of bounds for length 57
by (auto simp: lang_ε_def accepts_ε_def)
case (step p''u p'w)
define p' where "p' = fst p'w"
define w where "w = snd p'w"
efine p' hr p'=ftp'"
define u where "u = snd p''u"
have p'w_def: "p'w = (p', w)"
using p'_def w_def by auto
have p''u_def:y simp add: inits_deef is_Int_
using p''_def u_def by auto
then have "accepts_ε A' (p'', u)"
using assms(2) p''_def step.hyps(3) step.prems(2) uush_2p γ' γ' γ'' q)
then have "∃∉
by (auto simp: accepts_\epsilondef)
then obtain q where q_p: "q ∈ (Init p'', u, q) ∈.trans_star_ε
by metis
then have "∃u_ε
using LTS_ε.trans_star_ε_iff_ε
then obtain u_ε finals" "LTS_ε.ε_exp u_\<epsilon , q) ∈
by blast
have "∃\<lemmage_to_Ctr_Loc_post_star_rules
using p''u_def p'w_def step.hyps(2) step_relp_def2 by auto
then obtain γ
by bl
have p'it:"ntp'\in> inits"
unfolding inits_def by auto
have p''_nis Iit p'' \< inits
unfolding inits_def by auto
have "∃
proof -
have "\exists>γε u1_ε. LTS_ε.εga>_ε<> _exp u1_ε u_ε = γ @ u1_ε
using LTS_<>._exp_split'[of u_ε γ u1] II(2) III(1) by auto
then obtain γ_ε u1_ε where "LTS_ε.ε_exp γ_ε [γ] ∧ LTS_ε.ε_exp u1_ε u1 \<> "
by auto
then have "(Init p'', γ', Isolated p' γ A'"
using II(3) by auto
then show ?thesis
using ‹ LTS_ε_exp u1_ε u_ε = γ @ u1_e\close> by blast
qed
then obtain γ
iii: "LTS_εef is_Isoated_def using
iv: "LTS_ε.ε
blast
then have VI: "∃
by (simp add: LTS.trans_star_split)
then obtain q1 where VI: "(Init p'', γ, q1) ∈ LTS.trans_star A'"
by blast
then have VI_2: "(Init p'', [\thenhav: <nexistsp. (p, γ Isoae \<gamma' Aiminus1"
by (meson LTS_ε.trans_star_ε_iff_ε_exp_trans_star iii VI(2) iv(1))+
show ?case
roof (cases w1)
case pop
then have r: "(p'', γ) ↪p γ. (p, γ') = (Init p'', \<epsilon
using III(3) by blast
then have "(Init p', ε
using VI_2(1) add_trans_pop assms saturated_def saturation_def p'_inits by metis
hae "ntp,,q ∈ A'"
using III(2) VI_2(2) pop LTS_ε.trans_star_ε', Isolated p' γ Ai"
then have "accepts_ε A' (p', w)"
unfolding accepts_ε hav nin: "∄, Isolated p' γ Aiminus1"
then show ?thesis
using p'_def w_def by force
next
case (swap γ')
then have r: "(p'', γ.trans_star_not_to_source_ε
using III(3) by blast
then have "(Init p', Some γ', q1) ∈
by (metis VI_2(1) add_trans_swap assms(3) saturated_def saturation_def)
have "(Init p', w, q) ∈ LTSnext
\<epsilons_star_.trans_star_ε VI_2(2) append_Cons append_self_conv2
lbl.simps(3) swap ‹
then have "accepts_εs
unfolding accepsing ad_tran_uh_11) Un_iff statinject(2) rod.inject singleton_iff ssttep.IH
then show ?thesis
using p'_def w_def by force
case (push γ' γ'')
then have r: "(p'', γ) ↪ (p', push γ' γ'')"
using III(3) by blast
from this VI_2 iii post_star_rules.intros(3)[OF this, of q1 A', OF VI_2(1)]
have "(Init p', Some γ', Isolated p' γ') ∈ A'"
using assms) by (mesonturated_def saturatone)
from this r VI_2 iii post_star_rules.intros(4)[OF r, of q1 A', OF VI_2(1)]
have "(Isolaed p' γ'', q1)∈
using assms(3) using saturated_def saturation_def by metis
have "(Init p', [γ'], Isolated p' γ' ≠h_(3)
p<',.trans_star_ε
(q1, u1, q) ∈ LTS_ε.trans_star_ε A'"
by (metis LTS_\<then p γ. (p, γ') = (Init p'', ε
<open( p' γ', Some γ'', q1) ∈)
have "(Init p', w, q) ∈ LTS_ε.trans_star_ε A'"
_22) ‹> ‹ A'›e__rans_tr\epsilon by auto
then have "accepts_ε A' (p', w)"
unfolding accepts_ε_def
using II(1) by blast
then show ?thesis
using p'_def w_def by force
qed
lemma_3_3:
assumes "(p,v) ==>assum "ost_starule^sup>* A A'"
and "(p, v) ∈ lang_ε A"
and "saturation post_star_rules A A'"
shows "accepts_ε A' (p', w)"
using assms lemma_3_3' by force
no_edge_to_Ctr_Loc_post_star_rules':
assumes "post_star_rules', Isolated p' γ \<otinin
assumes "∄
shows "∄q γ, Init q') ∈
assms
(induction rule: rtnc_in
case base
then show ?case by auto
case (step Aiminus1 Ai)
then have ind: "∄q γ
by auto
from step(2) show ?case
proof (cases rule: post_star_rules.cases)
case (d_ans_pop p \gamma> p' q)
have "q \<notinusing
using ind no_edge_to_Ctr_Loc_avoid_Ctr_Loc_ε inits_srcs_iff_Ctr_Loc_src>'']" q Amns1
by (metis local.add_trans_pop(3))
then have "∄
by (simpthow ?th
then show ?thesis
ng n a.drbuto
next
case (add_trans_swap p γ p' γ' q)
have "q ∉
using add_trans_swap ind no_edge_to_Ctr_Loc_avoid_Ctr_Loc_ε initusing add_tran_uh11) Unff sttaeijcpo.nject ingletof s.
by metis
n ve ∄qq.q = Initt
by (simp add: inits_def is_Init_def)
then show ?thesis
using ind local.add_trans_swap(1) by auto
next
case (add_trans_push_1 p γ' γ
have "q ∉
using add_trans_push_1 ind no_edge_to_Ctr_Loc_avoid_Ctr_Loc_ε inits_srcs_iff_Ctr_Loc_srp' \<>'
by metis
then have "∄
by (simp add: inits_def is_Init_def)
then show ?thesis
using ind local.add_trans_push_1(1) by auto
next
case (by auto
have "q ∉
using add_trans_push_2 ind no_edge_to_Ctr_Loc_avoid_Ctr_Loc_ε iusi locd_traanspush_2rems yat
by metis
then have "∄qq. q = Init qq"
by (simp add: inits_def is_Init_def)
then show ?thesis
using ind local.add_trans_push_2(1) by auto
qed
no_edge_to_Ctr_Loc_post_star_rules:
assumes "post_star_rules* A Ai"
assumes "inits ⊆
shows "inits ⊆
using assms no_edge_to_Ctr_Loc_post_star_rules' inits_srcs_iff_Ctr_Loc_srcs by metis
post_star_rules_Isolated_source_invariant':
ssumes "post_tarrlssup> A A'"
assumes "isols ⊆p' w'. (Init p', w<>LTS_w)))
assumes "(Init p', Some γ', Isolated p' γ') ∉ A'"
shows "∄. (p, γ') ∈
using assms
(inducin re:rtranclpp_induct))
case base
then show ?case
unfolding isols_def is_Isolated_def using LTS.isolated_no_edges by fastfoassur_loc"is_Init q \<>is_Noninit.remove_\<epsilonepsilonw, q) ∈ LTS_ε A"
case (step Aiminus1 Ai)
from step(2) show ?case
proof (cases rule: post_star_rules.cases)
case (add_trans_pop p''' γ(Init p, LTS_ε.remove_ε w, q) ∈ LTS_ε.trans_star_ε by blast
then have "(Init p', Some γ', Isolated p' γ') ∉
using step.prems(2) by blast
then have nin: "∄
using local.add_trans_pop(1) step.IH step.prems(1,2) by fastforce
then have "Isolated p' γ' ≠
using add_trans_pop(4) LTS_ε.trans_star_not_to_source_εstes_t_trans_star \open q›
by (metis local.add_trans_pop(3) sby (metis st
then show ?thei
by auto
then show ?thesis
using nin add_trans_pop(st)
next
case (add_trans_swap p'''' γ''' q)
then have "(Init p', Some γ', Isolated p' γ') ∉
using step.pms(22) by by blast
then have nin: "∄
using local.add_trans_swap(1) step.IH step.prems(1,2) by fastforce
then have "Isolated p' γ' ≠ q"
using LTS.srcs_def2
LTS<>rans_star_not_to_source_
then have "∄py auutto
y uto
then show ?thesis
using nin add_trans_swap(1) by auto
next
case (add_trans_push_1 p'''' γ'' p'' γ staexhautds)
then have "(Init p', Some γ
using step.prems(2) by blast
then show ?thesis
using add_trans_push_1(1) Un_iff state.inject(2) prnsiltniff ep.IH
step.prems(1,2) by blast
next
case (add_trans_push_2 p'''' γ''' γ
have "(Init p', Some γ', Isolated p' γ ∉
sing stp.prems(2) .
then have nin: "∄
using local.add_trans_push_2(1) step.IH step.prems(1) by fastforce
then have "Isolated p' γ' ≠
using LTS.srcs_def2 local.add_trans_push_2(3)
by (metis state.disc(1,3) LTS_ε ssp = step(6
then have "∄
by auto
then show ?thesis
using nin add_trans_push_2(1) by auto
qed
post_star_rules_Isolated_source_invariant:
java.lang.NullPointerException
assumes "isols ⊆
assumes "(Init p', Some γ', Isolated p' γ
shows "Isolated p' γ' ∈
by sonS.srcs_def2 assms(1)')
post_star_rules_Isolated_sink_invarssing step(1,2) sstep4
java.lang.NullPointerException
assumes "isols ⊆w)= a> count (transitions_of (ss, w)) t = 1"
assumes "(Init p', Some γ', Isolated p' γ') ∉ -
shows "∄>, γ>A'"
using assms
(induction rule: rtranclp_induct)
case base
then show ?case
unfolding isols_def is_Isolated_def
using LTS.isolated_no_edges by fastforce
case (st (step Aiminus1 Ai)
from step(2) show ?case
proof (cases rule:: post_star_rules.cases)
case (add_trans_pop p''' γ'' p'' q)
then have "(Init p', Some γ', Isolated p' γ') \<notinhave
using step.prems(2) by blast
then have nin: "∄
using local.add_trans_pop(1) step.IH step.prems(1,2) by fastfoh"t= (Init p1, \epsilon, q1)"
using t_def by auto
using add_trans_pop(4)
LTS_ε.trans_star_not_to_source_ε[of "Init p'''" "[γ'']" q Aiminus1 "Isolated p' γ'"]
post_star_rules_Isolated_source_invariant local.add_trans_pop(1) step.hyps(1) step.prems(1,2)
UnI1 local.add_trans_pop(3) by (metis (full_types) state.distinct(3))
then have "∄. (p, <>,
by auto
then show ?thesis
using nin add_trans_pop(1) by auto
next
java.lang.NullPointerException: Cannot invoke "String.equals(Object)" because "brackoff" is null
then have "(Init p', Some γ', Isolated p' γ') ∉ Ai"
using step.prems(2) by blast
then have nin: "∄' w,ss)"
using local.add_trans_swap(1) step.IH step.prems(1,2) by fastforce
then have "Isolated p' γ' ≠ q"
using LTS_ε.trans_star_not_to_source_ε ‹ = 1›
local.add_trans_swap(3) post_star_rules_Isolated_source_invariant[of _ Aiminus1 p' γ'] UnCI
local.add_trans_swap(1) step.hyps(1) step.prems(1,2) state.simps(7) by metis
then have "∄. (p, γ') = (Init p'', Some γ
by auto
then show ?thesis
using nin add_trans_swap(1) by auto
next
case (add_trans_push_🚫
then have "(Init p', Some γ', Isolated p' γ
using step.prems(2) by blast
then show ?thesis
using add_trans_push_1(1) Un_iff state.inject prod.inject singleton_iff step.IH
step.prems(1,2) by blast
next
case (add_trans_push_2 p'''' γ'' p'' γ''' γ'''' q)
have "(Init p', Some γ', Isolated p' γ') ∉], [Init p1, q1], q1) ∈
using step.prems(2) by blast
then have nin: "∄p γ. (Isolated p' γ
using local.add_trans_push_2(1) step.IH step.prems(1,2) by fastforce
then have Isolatedp' <>'
using state.disc(3)
LTS_
local.add_trans_push_2(3)
_ Aiminumns p' \<gamma'
local.add_trans_push_2(1) step.hyps(1) step.prems(1,2) state.disc(1) by metis
then have "∄ LTS.trans_star_states Aiminus1"
by auto
then show ?thesis
using nin add_trans_push_2(1)
using local.add_trans_push_2 step.prems(2) by auto
qed
post_star_rules_Isolated_sink_invariant:
assumes "post_star_rules* A A'"
assumes "isols ⊆ LTS.isolated A"
assumes "(Init p', Some γ', Isolated p' γ1\_ =t ((trnstins_of (tl ss, lw)) (Ii 1, ep,q1)"
shows "Isolated p' γ' ∈ LTS.sinks A'"
by (meson LTS.sinks_def2 assms(1,2,3) post_star_rules_Isolated_sink_invariant')
―‹
rtranclp_post_star_rules_constains_successors_states:
assumes "post_star_rules* A A'"
assumes "inits ⊆‹ []›
assumes "isols ⊆ {(Init p1, ε
assumes "(Init p, w, ss, q) ∈ q1 Aimin1
shows "(¬is_Isolated q ⟶ (∃ ss, tl w ∈
(is_Isolated q ⟶ (the_Ctr_Loc q, [the_Label q]) \ by auto
using assms
(induction arbitrary: p q w ss rule: rtranclp_induct)
case base
{
assume ctr_loc: "is_Init q ∨
then have "(Init p, LTS_ε.remove_ε w, q) LTS.tansiion_list_Cost_hd_ne b astfor
using base LTS_ε.trans_star_states_trans_star_ε by metis
then have "∃ (etisLStrans_star_state_ast .prs2))
by auto
then have ?case
using ctr_loc ‹ A›
}
moreover
{
assume "is_Isolated q"
then have ?case
have "= ε
case Nil
then have False using base
using LTS.trans_star_empty LTS.trans_star_states_trans_star ‹LTS__ε w = LT_<psilonremove_
by (mebyipad TS_\epsilontrans_star_ε_ε_exp_trans_star)
then show ?thesis
by metis
next
case (Cons γ w_rest)
then have "(Init p, γ#w_rest, ss, q) ∈
using base Cons by blast
then have "∃d: LTS.ran_sta_tns_staar_r_states)
using LTS.trans_star_states_transition_relation by metis
then have False
sing \open>isq› isols_def base.prems(2) LTS.isolated_no_edges
by (metis mem_Collect_eq subset_eq)
then show ?thesis
by auto
qed
}
ultimately
show ?case
by (meson state.exhaust_disc)
case (step Aiminus1 Ai)
from step(2) have "∃p1 γ p2 w2 q1. Ai = Aiminus1 ∪'@ tl w,s2 @ (tl (t ss)), ∈ LTS.tran_star_s
by (cases rule: post_star_rules.cases) auto
then obtain p1 γ q1 where p1_\<gamma 2' @ tl w" "ss2 @ (tl (tls)" q]
"Ai = Aiminus1 ∪
(p1, γ Aiminus1"
by auto
define t where "t = (p1, γ, q1)"
define j where "j = counttransitio' (Init p, w,, q) t"
note using IIII
from j_def ss_p show ?case
proof ( ave "\notis_Isolated q ∨
case 0
then have "(Init p, w, ss, q) ∈ LTS.trans_star_states Aiminus1"
using count_zero_remove_path_with_word_trans_star_states p1_γis_Isolated q"
by metis
then show ?case
using step by auto
next
case (Suc j)
from step(2) show ?case
proof (cases rule: post_star_rules.cae)
case (add_trans_pop p2 \<gamma>2 p1 q1) (* Note: p1 shadows p1 from above. q1 shadows q1 from above. *) note III note VI = add_trans_pop(2) have t_def: "t = (Init p1, ε, then hav ('w) ==>^sup>* (p2, LTS_ε.remove_ε (γ) <and> using local.ad_trans_p(1) local.add_trans_pop p1_γ have init_Ai: "inits ⊆2: "LTS_\<<epsilon using step(1,2) step(4) using no_edge_to_Ctr_Loc_post_star_ruhave "p'') <Rightarrow<ve_<epsilon2' @ tl w) using r_into_rtranclp by (metis) have t_hd_once: "hd (transition_have l "(p22) ↪ proof - have"(ss, w) ∈ TS.ahwt_wordAi" using Suc(3) TSath_with_word moreover have"inits ⊆.remove_ε(tl w))" using init_Ai by auto moreover have"0 < count (transitions_of (ss, w)) t" by ('.simps) moreover have"t = (Init p1, ε using t_def by auto moreover have "Init p1 inits" by (simp add: inits_def) ultimately show "hd (transition_listss, w)) ==t ∧ (ss w) =1java.lang.StringIndexOutOfBoundsException: Index 91 out of bounds for length 91 using init_only_hd ss t p1 q1] by auto qed
have"transition_list (using VIII b f (me LTS.trans_star_states_path_with_word LTS.path_wit.simps Suc.prems(1) Suc.prems(2) count_empty less_not_refl2 list.distinct(1) transition_list.simps(1) transitions_of'.simps transitions_of.simps(2) zero_less_Suc) then ha have ss_w_split: "[nitp1,], [\epsilon>]) @🍋(tl ss, tl w) = (ss, w)" using t_hd_once t_def hd_transition_list_append_path_with_word by metis then have ss_w_split': "(Init p1[epsilon], [Initp1] q1) @\> (q1 w tl ssq))=Init, w, , q) by auto have VII: "p = p1" proof have"(Init p, w, ss, q) ∈ LTS.trans_star_states Ai" using Suc.prems2)byblast moreover have"t = hd (transition_list' (Init p, w, ss, q))" using‹hd (transition_list (ss, w)) = t ∧ count (transitions_of (ss, w)) t = 1›.ε LTS_.remove_<>_ byce moreover have"transition_list' (Init p, w, ss, q) ≠ by sip add\opentniti_list(ss, w≠) moreover have "t = (Init p1, ε by(etis using t_defuto ultimately show"p = p1" using LTS.hd_is_hd by fastforce qed have"j=0" using by force have"(Init p1, [\<case proof - ve "itepsilon>, q1 Ai" using local.add_trans_pop(1) by auto moreover have",epsilon, q1) <tinAiminus1 by (simp> LTS.path_with_word Ai" using Suc3) LTns_stastatepath_wiith_od by eis "s< LTS.srcs Ai" by (meson LTS.trans_star_states.trans_star_states_refl LTS.trans_star_states.trans_star_states_step) qed have "(q1, tl w, tl ss, q) ∈o_less_Suc proof - from Suc(3) have"(ss, w) ∈ by (meson LTS.trans_star_states_path_with_word) then have tl_ss_w_Ai: "(tl ss, tl w) ∈ by (metis LTS.path_with_word.simpsss count (transitions_of (ss, w) 1" sition_list.to_lit.simps(2)) from t_hd_once have zero_p1_ε_q1: "0 = countqed using count_append_path_with_word_γ[of "[hd ss]""[]""tl ss""hd w""tl w""Init p1" ε q1, simplified] ‹(Init p1, [ε], [Init p1, q1], q1) ∈ LTS.trans_star_states Ai›<> []" ‹ LTS.transition_list_Cons[of " p" w ss q Ai ε[Iit p1,q] Som γ (tl ss, tl w) = (ss, w)"
have Ai_Aiminus1: "Ai = Aiminus1 ∪ {(Init p1, ε, q1)}"
using local.add_trans_pop(1) by auto
from t_hd_once tl_ss_w_Ai zero_p1_εinus1
count_zero_remove_path_with_word[OF tl_ss_w_Ai, of "Init p1" ε q1 Aiminus1]
have "(tl ss, tl w)
by auto
moreover
have "hd (tl ss) = q1"
java.lang.NullPointerException: Cannot invoke "String.equals(Object)" because "brackoff" is null
LTS.transition_list_Cons t_hd_once by fastf ltimat
moreover
lasts q"
by (metis LTS.trans_star_states_last Suc.prems(2 have (q, LTS.trans_star_states Aiminus1"
ultimately
show "(q1, tl w, tl ss, q) ∈ LTS.path_with_word Ai"
by (metis (no_types, lifting) LTS.trans_star_states_path_with_word
LTS.path_with_word_trans_star_states LTS.path
lst_ConsR lst.cllae)
qed
have "w = ε # (tl w)"
by (metis Suc(3) VII ‹ []›
list.sel(1) t_def LTS.transition_list_Cons t_hd_once)
nhav _tl_\epsilon "LTS_ε.remove_ε w = LTS_ε.remove_ε (tl w)"
by (metis LTS_ε.remove_ε_def removeAll.simps(2))
have "∃us lcaldas_wap1)bauto
using add_trans_pop
by (simp add: LTS_ε.trans_star_εF tswA,o "Ii1"_ q1 Aiminus1]
then obtain γ2' where "LTS_ε.ε_exp γ
by blast
then have "∃ss2. (Init p2, γtransition_list (ss, w) ≠ []› nsition_list_Cons by (simp add: LTS.trans_star_trans_star_states thenobtain ss2 where IIII_1: "(Init p2, γ2', ss2, q1) ∈ by blast haveLTS.p.a_itwdtassa_ta .ahw_ont_epySu.rs2 using ss_w_split' Suc(3) Suc(2) ‹hav ome \<' transition_list (ss, w) ≠ []›ii() li.eus_e using \<open_.remove_ε w = LTS_ε.remove_ε (Some γ'#tl w)" have IIII: "(Init p2, γ2' @ tl w, ss2 @ (tl (tl ss)), q) ∈us LS_<>.rem<>_de rmvA.sp(2 using IIII_1 IIII_2 by (meson LTS.trans_star_states_append)
from Suc(1)[of p2 "γ2' @ using.trans_star__ε have V: "(<>is_slad <ongr>
java.lang.NullPointerException (is_Isolated q ⟶beq) \Rightarrow<^sup>* (p2, LTS_ε.remove_ε (γ2' @ tl w)))" using IIII using step.IH step,by
have"¬ LTS.trans_star_states Aiminus1" using thenshowjava.lang.StringIndexOutOfBoundsException: Index 23 out of bounds for length 23 proof assume ctr_q: "¬is_Isolated q" thenhave\p' w'. (Init p', w,) inLTS_ε.trans_star_εA< (p', w') ==>.ove_ (γ" using V by auto then obtain p' w' where VIII:"Init LTS_ε A" antp:")>^sup (p2, LTS_ε.remove_ε (γ2' @ tl
thenhave"(p',w') ==> ta <>p w.Iitp ' q<inLT_\>star A ∧* (p2, LTS_εrm_\<>(γ2' @ tl w))" proof - have<amma2'_γ2: "LTS_ε.remove_ε γ2' = [γ2]" by (metis LTS_ε,in> LTS_ε🚫.remove_<psilonsilon
haveRightarrow
ng moreover have(>) ↪
IVII from stepsRightarrow(γ using γ2' by (metisS_.remove_ε from rule steps' have"(p2, γ2 # (LTS_ε.remove_\ pv ts: ('w Rightarrow\^* (p2, γ2 # (LTS_ε.remove_ε using VIII is .asi_enr e_elcnv2 .is1 norrcp step_relp_def) (* VII *) then have "(p2, LTS_ε by (simp add: LTS_ε.remove_.remove_ε'tl.remove_ε ultimately
owp'w==>* (p2, LTS_ε
(p2, LTS_ε.remove_ε (γ by auto qed thenRightarrow\ using VIII by force thenusingrce using _\epsilonby auto thenshow ?thesis using ctr_q?s
ctr_qp = p1›by assume"is_Isolated q" from VhaveCtr_LocRightarrow#<epsilon>emove_ w))" auto \open>LTS_ε.ε_exp γ2' [γ2] ∧2',q)\in LTS.trans_star Aiminus1›is_Isolated q› append_Cons pdefcn ) then have "(the_Ctr_Loc q, [the_Label q]) ==> usinglblef2 thenusing using VII by auto then using‹ qed next
case (add_trans_swap p2 \<gamma>2 p1 \<gamma>' q1) (* Adjusted from previous case *) note III = add_trans_swap(3) note VI = add_trans_swap(2)
haveInit', q1)" using local.add_trans_swap(1) local.add_trans_swap p1_γ_p2_w2_q'_p(1) t_def by blast have init_Ai: "inits \subseteq LTS.srcs Ai" using step(1,2,4) no_edge_to_Ctr_Loc_post_star_rules by (meson r_into_rtranclp) have t_hd_once: "hd t< count (transitions_of (ss) " proof have "(ss, w) ∈ using c3Sans_star_states_path_with_word
have"inits ⊆ using init_Ai by auto moreover have "0 < count (transitions_ofmoreover by (metis Suc.prems(1) transitions_of
have"t = (Init p1, Some γ', q1)" using t_def by auto moreover have"Inits "ion_list count (transitions_of (ss, w)) t = 1" using inits_def by force ultimately showsition_lists) t\and> ut(rstions_of ss, w)t 1 using init_only_hd[of ss w Ai t p1 _ q1] by auto qed
eaiols s, 🚫[]" by (metis LTS.trans_star_states_path_with_word LTS.path_with_word.simps Suc.prems(1,2)
count_emptyhaveVII
transitions_of.simps(2) zero_less_Suc)
ss_w_split<amma']) @🍋 (tl ss, tl w) = (ss, w)" using t_hd_once t_def hd_transition_list_append_path_with_word by metis then have ss_w_split': "(Init p1, [Some java.lang.NullPointerException: Cannot invoke "String.equals(Object)" because "brackoff" is null by auto
java.lang.StringIndexOutOfBoundsException: Index 24 out of bounds for length 24 proof - haveultimately using Suc.prems(2) by blast moreover have"t = hd (transitionlt (i ,, ,q" using‹ed1 \gamma1, γ Ai"
then aes_wort"ss [I , Iolat \gamma1] ∧ w = [Some γ1]"
by (simp add: ‹hd (transition_list (ss, w)) = t ∧ t_def
moreover
have "t = LT.ohin_e_nkof"nit 1 "solaed1 🚫transition_list (ss, w) ≠
using t_def by auto
ultimately
show "p = p1"
using LTS.hd_is_hd by fastforce
qed
have "j=0"
using Suc(2) ‹
have "(Init p1, [Some γ'], [Init p1, q1], q1) ∈
proof -
have "(Init p1, Some γ', q1) ∈
loalad_rans_sap(1) auto
moreover
have "(Init p1, Some γ', q1) ∉
using local.add_trans_swap(4) by blast
ultimately
show "(Init p1, [Some γ'], [Init p1, q1], q1) ∈ LTS.trans_star_states Ai"
by (meson LTS.trans_star_states.trans_star_states_refl LTS.trans_star_states.trans_star_states_step)
qed
have "(q1, tl w, tl ss, q) ∈Aiminus1"
proof -
from Suc(3) have "(ss, w) ∈ LTS.path_with_word Ai"
by (meson LTS.trans_star_states_pth_i_wo)
then have tl_ss_w_Ai: "(tl ss, tl w) ∈ LTS.path_with_word Ai"
by (metis LTS.path_with_word.simps ‹⊆ LTS.srcs Ai"
transition_list.simps(2))
from t_hd_once have zero_p1_ε_q1: "0 = count (transitions_of (tl ss, tl w)) (Init p1, Some γ', q1)"
using count_append_path_with_word_γ[of "[hd ss]" "[]" "tl ss" "hd w" "tl w"by (me r_into_rtranclp) ‹p w ss q Ai j Isolattd p gamma>1 "Some γ
Suc.prems(2) VII LTS.transition_list_Cons[of "Init p" w ss q Ai "Some γ'" q1]
by (auto simp: t_def)
have Ai_Aiminus1: "Ai = Aiminus1 ∪ {(Init p1, ss = u_ss @ v_ss 🪙
using local.add_trans_swap(1) by auto
from t_hd_once tl_ss_w_Ai zero_p1_\epsilon_1 Ai_Aiminus1
count_zero_remove_path_with_word <>'], q') ∈ LTS.trans_star Ai ∧ (q', v, vq \in.trans_star_states Ai
LTS.path_with_word Aiminus1
by auto
moreover
have "hd (tl ss) = q1"
ss_split "ss=u_ss @ v_s" and
moreover
have "last ss = q"
(metis LTS.trans_star_states_last Suc.prems(2))
ultimately
show "(q1, i> LTS.trans_star_states Aiminus1"
by (metis (no_types, lifting) LTS.trans_star_states_path_with_word
s_star_statessSpthwt_or_nt_emtScpes2
last_ConsR list.collapby au
qed
w = S γ
by (metis Suc(3) VII ‹
list.sel(1) t_def LTS.transition_list_Cons t_hd_once)
w_tl_\epsilon: "LTS_\<epsilon<ε (Some γw"
using LTS_ε.remove_ε_def removeAll.simps(2)
by presburger
have "\ is_Isol (Isolated p1 γ
using add_trans_swap by (simp add: LTS_ε.trans_star_ε_\<epsilon Isolp1 γ (Isol p1 γu))"
then obtain γ2' where "LTS_ε.ε_exp γ2' [γ2] ∧ (Init p2, γ.prems(1,2,3)by aut
have (the_Ctr_Loc (Isolated p1 \gamma>1), [the_ (Isolated p1 γu)"
then have "∃ss2. (Init p2, γ2', ss2, q1) ∈
by (simp add: LTS.trans_star_trans_star_states)
then obtain ss2 where IIII_1: "(Init p2, γ LTS.trans_star_states Aiminu
by blast
have IIII_2: "(q1, tl w, tl ss, q) ∈ have "\exists🚫, q') \in> LTS.trans_staAiminus1"
ss_w_split' Suc(3) S(2) ‹ obt γ2ss where XI_1: "LTS_\<>.g2ε γ \inLT.trans_star_state Aiminus1"
using ‹ LTS.transst_tteA
have IIII: "(Init p2, γ2' @ tl w, ss2 @ (tl (tl ss)), q) ∈ LTS.tran ave ind
using IIII_1 IIII_2 by (meson LTS.trans_star_states_append)
()o 2"\gamma w" "
have V: "(¬is_Isolated q ⟶
(∃p' w'. (Init p', w', q) ∈ LTS_ε.trans_star_ε A ∧
java.lang.StringIndexOutOfBoundsException: Index 150 out of bounds for length 150
using step.IH step.prems(1,2,3) by blast
have "¬
using state.exhaust_d by blast
then show ?thesis
proof
assume ctr_q: "¬
then have "∃h cv: "j = count (transitions_of ((v_ss, v))) t"
using V by auto
then obtain p' w' wrans_sta _)
"Inip', w', q) ∈ A" and steps: "((p', w') \Rightarrow>2' @ tl w))"
bla
then have "(p',w') ==>* (p2, LTS_ε.remove_ε
(p2, LTS_ε (γ(tl w))
proof -
have γ"TS\epsilon<>
(metis LTS_ε_exp_de LTS_\epsilonremεLTS_ε.ε_exp γ2' [γ2] ∧ LTS.trans_star Aiminus1›
"p',w') 🚫
using steps by auto
moreover
have rule: "(p2, γ2) ↪ (p, swap γ')"
using VI VII by auto
from steps have steps': "(p', w') ==>* (p2, γ2 # (LTS_ε.remove_ε (tl w)))"
using γ2'_γ2
by (metis Cons_eq_appendI LTS_ε.remove_ε_append_dist self_append_conv2)
from rule steps' have "(p2, γ2 # (LTS_εq))(Isolated γ)"
using VIII
using PDS.transition_rel.intros append_self_conv2 lbl.simps(1) r_into_rtranclp step_relp_def
by fastforce
then have "(p2, LTS_ε.remove_ε>_l[of u_ss u v_ss "Inip" "Iso p1\<amma1
by (simp add: LTS_ε.remove_ε_append_dist γ2'_γ2)
ultimately
show "(p',w') ==>* (p2, LTS_ε.remove_ε (γ2' @ tl w)) ∧
(p2, LTS_ε.remove_ε (γ2' @ tl w)) ==>* (p, γ' # LTS_ε.remove_ε (tl w))"
by auto
qed
then have "(p',w') ==>* (p, γ' # LTS_ε.remove_ε (tl w)) ∧ (Init p', w', q) ∈ LTS_ε (meson LTS.trans_star_states v_s)
then have "∃p' w'. (Init p', w', q) ∈ LTS_ε.trans_star_ε A ∧ (p', w') ==>* (p, LTS_ε.remove_ε w)"
java.lang.NullPointerException: Cannot invoke "String.equals(Object)" because "brackoff" is null
then show ?thesis
using ctr_q ‹p = p1› by blast
next
assume "is_Isolated q"
from V this have "(the_Ctr_Loc q, [the_Label q]) ==>* (p2, LTS_ε.remove_ε (γ2' @ tl w))"
by auto
then have "(the_Ctr_Loc q, [the_Label q]) ==>* (p2, γ2#(LTS_ε.remove_ε (tl w)))"
by (metis LTS_ε.ε_exp_def LTS_ε.remove_ε_append_dist LTS_ε.remove_ε_def ‹LTS_ε.ε_exp γ2' [γ2] ∧
append_self_conv2)
then have "(the_Ctr_Loc q, [the_Label q]) ==>gamma\epsilon>, γ Aiminus1"
using VI
by (metis (no_types) append_Cons append_Nil lbl.simps(2) rtranclp.rtrancl_into_rtrancl
step_relp_def2)
then have "(the_Ctr_Loc q, [the_Label q]) ==>* (p, γ' # LTS_ε.remove_ε (tl w))"
using VII by auto
then show ?thesis
using ‹is_Isolated q›
by (metis LTS_ε.remove_ε_Cons_tl w_tl_ε)
qedhen have have cγ(γ\epsilon t = 0
next
case (add_trans_push_1 p2 γ2 p1 γ1 γ'' q1')
then have t_def: "t = (Init p1, Some γ1, Isolated p1 γ1)"
using llocal.add_tans_pop(1) locadd_transp1_\gammap2_'_p(1) t_def by blas
have init_Ai: "inits ⊆ LTS.srcs Ai"
using step(1,2) step(4)
using no_edge_to_Ctr_Loc_post_star_rules
have "j = count (tran ((γ (v_s, v)))t"
have t_hd_once: "hd (transition_list (ss, w)) = t ∧ count (transitions_of (ss, w)) t = 1"
proof -
have "(ss, w \in.path_with_wo Ai"
using Suc(3) LTS.trans_star_states_path_with_word by metis
moreover
have "inits ⊆ LTS.srcs Ai"
using init_Ai by auto
moreover
have "0 < count (transitions_of (ss, w)) t"
by (metis Suc.prems(1) transitions_of'.simps zero_less_Suc)
moreover
t (Init p1, Some \gamma, Isola p1 γ
using t_def by auto
moreover
have "Init p1 ∈ inits"
using inits_def by fastforce
show "hd (transition_list (ss, w)) = t ∧ count (transitions_of (ss, w)) t = 1"
using init_only_hd[of ss w Ai t] by auto
java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
have "transition_list (ss, w) ≠ "(<>ss
by (metis LTS.trans_star_states_path_with_word LTS.path_with_word.simps Suc.prems(1,2)
count_empty less_not_refl2 list.distinct(1) transition_list.simps(1)
transitions_of'.simps transitions_of.simps(2) zero_less_Suc)
have VII: "p = p1"
proof -
have "(Init p, w, ss, q) ∈ LTS.trans_star_states Ai"
using Suc.prems(2) by blast
moreover
have "t = hd (tr (transition' (Init p, w, ss, q))"
using ‹hd (transition_list (ss, w)) = t ∧ count (transitions_of (ss, w)) t = 1›by fastforce
moreover
have "transition_list' (Init p, w, ss, q) ≠ []"
by (simp add: ‹transition_list (ss, w) ≠ []›)
moreover
have "t = (Init p1, Some γ1, Isolated p1 γ add_trans_push_2(1)
using t_def by auto
ultimately
show "p = p1"
using LTS.hd_is_hd by fastforce
qed
from add_trans_push_1(4) have "∄have path': "v_ss,, v) \<n
using post_star_rules_Isolated_sink_invariant[of A Aiminus1 p1 γ1] step.hyps(1)
step.prems(1,2,3) ,3) unfolding LTS.sinks_def by by blast
then have "∄p γ. (Isolated p1 γ1, γ, p) ∈ Ai"
using local.add_trans_push_1(1) by blast
then have ss_w_short: "ss = [Init p1, Isolated p1 γ1] ∧ w = [Some γ1]"
using Suc.prems(2) VII ‹hd (transition_list (ss, w)) = t ∧ count (transitions_of (ss, w)) t = 1› t_def
LTS.nothing_after_sink[of "Init p1" "Isolated p1 γ1" "tl (tl ss)" "Some γ1" "tl w" Ai] ‹transition_list (ss, w) ≠ []›
LTS.trans_star_states_path_with_word[of "Init p" w ss q Ai]
LTS.transition_list_Cons[of "Init p" w ss q Ai]
by (auto simp: LTS.sinks_def2)
then have q_ext: "q = Isolated p1 γ
using LTS.trans_star_states_last Suc.prems(2) by fastforce
have "(p1, [γ1]) ==>* (p, LTS_ε.remove_ε w)"
using ss_w_short unfolding LTS_ε.remove_ε_def
using VII by force
have "(the_Ctr_Loc q, [the_Label q]) ==>* (p, LTS_ε.remove_ε w)"
by (simp add: ‹
then show ?thesis
using q_ext by au auto
next
case (add_trans_push_2 p2 \<gamma>2 p1 \<gamma>1 \<gamma>'' q') (* Adjusted from previous case *) note IX = add_trans_push_2(3) note XIII = add_trans_push_2(2) have t_def: "t = (Isolated p1 y (metis (no_type, lifting) ) LTS.path_wi using local.add_trans_push_2(1,4) p1_γ_p2_w2_q'_p(1) t_def by blast have init_Ai: "inits ⊆ LTS.srcs Ai" using step(1,2) step(4) using no_edge_to_Ctr_Loc_post_star_rules by( )
from Suc(2,3) split_at_first_t[of "Init p" w ss q Ai j "Isolated p1 γ1" "Some γ''" q' Aiminus1] t_def "∃
ss = u_ss @ v_ss ∧
w = u @ [Some γ''] @ v ∧
(Init p, u, u_ss, Isolated p1 γ1) ∈ LTS.trans_star_states Aiminus1 ∧
(Isolated p1 γ1, [Some γ''], q') ∈ LTS.trans_star Ai ∧ (q', v, v_ss, q) ∈ LTS.trans_star_states Ai" using local.add_trans_push_2(1,4) by blast then obtain u v u_ss v_ss where ss_split: "ss = u_ss @ v_ss" and w_split: "w = u @ [Some γ''] @ v" and X_1: "(Init p, u, u_ss, Isolated p1 γ1) ∈ LTS.trans_star_states Aiminus1" and out_trans: "(Isolated p1 γ1, [Some γ''], q') ∈ LTS.trans_star Ai" and path: "(q', v, v_ss, q) ∈ LTS.trans_star_states Ai" by auto from step(3)[of p u u_ss "Isolated p1 γ1"] X_1 have "(¬is_Isolated (Isolated p1 γ1) ⟶
(∃p' w'. (Init p', w', Isolated p1 γ1) ∈ LTS_ε.trans_star_ε(is_Isolatedq ⟶ the_LabelRightarrow^> p2<>.ε> @ ))" (is_Isolated (Isolated p1 γ1) ⟶ (the_Ctr_Loc (Isolated p1 γ1), [the_Label (Isolated p1 γ1)]) ==>* (p, LTS_ε.remove_ε u))" using step.prems(1,2,3) by auto thenhave"(the_Ctr_Loc (Isolated p1 γ1), [the_Label (Isolated p1 γ by auto then have p1_γ q r by auto from IX have "∃γcase by (meson LTS.trans_star_trans_star_states have"(<>p' w''. (Init p',w', q) \inLTSε<nd>> (p'', w') ==>LTε>2ε then obtain γ2ε γ2ss where XI_1: "LTS_ε.ε_exp γ2ε [γ2] ∧ (Init p2, γ2ε, γ2ss, q') ∈ LTS.trans_star_states Aiminus1" by blast have "(q', v, v_ss, q) ∈ LTS.trans_star_states Ai" using path . have ind: "(¬is_Isolated q ⟶ (∃p' w'. (Initthenw p'w'_:"Init p', w', q) ) \intrans_star_\\<> A \and (p', w') ==>p2, LTS_\epsilon>.emove_🚫 (is_Isolated q ⟶ (the_Ctr_Loc q, [the_Label q]) ==>* (p2, LTS_ε.remove_ε (γ2ε @ v)))" proof - have γ2ss_len: "length γ2ss = Suc (length γ2ε)" by (meson LTS.trans_star_states_length XI_1)
have v_ss_empty: "v_ss ≠ []" by (metis LTS.trans_star_states.simps path list.distinct(1))
have γ2ss_last: "last γ2ss = hd v_ss" by (metis LTS.trans_star_states_hd LTS.trans_star_states_last XI_1 path)
have cv: "j = count (transitions_of ((v_ss, v))) t" proof - have last_u_ss: "Isolated p1 γ1 = last u_ss" by (meson LTS.trans_star_states_last X_1) have q'_hd_v_ss: "q' = hd v_ss" by (meson LTS.trans_star_states_hd path)
have java.lang.NullPointerException ( p1 γ count (transitions_of' (Init p, u, u_ss, Isolated p1 γ1)) (Isolated p1 γ1, Some γ'', q') + (if Isolated p1 γ1 = last u_ss ∧ q' = hd v_ss ∧ Some γ'' = Some γ'' then 1 else 0) + count (transitions_of' (q', v, v_ss, q)) (Isolated p1 γ1, Some γ'', q')" using count_append_trans_star_states_γ_length[of u_ss u v_ss "Init p""Isolated p1 γ1""Some γ''" q' v q "Isolated p1 γ1""Some γ''" q'] t_def ss_split w_split X_1 by (meson LTS.trans_star_states_length v_ss_empty) thenhave"count (transitions_of (u_ss @ v_ss, u @ Some γ'' # v)) (last u_ss, Some γ'', hd v_ss) = Suc (count (transitions_of (u_ss, u)) (last u_ss, Some γ'', hd v_ss) + count (transitions_of (v_ss, v)) (last u_ss, Some γ'', hd v_ss))" using last_u_ss q'_hd_v_ss by auto thenhave"j = count (transitions_of' ((q',v, v_ss, q))) t" using last_u_ss q'_hd_v_ss X_1 ss_split w_split add_trans_push_2(4) Suc(2)
LTS[f "Init "u u_ssp1gamma" Aiminus1 "Isolated<>1 Some>'" q'] by (auto simp: t_def) then show "j = count (transitions_of ((v_ss, v))) t" by force qed have p2_q'_states_Aiminus1: "(Init p2, γ2ε, γ2ss, q') ∈ LTS.trans_star_states Aiminus1" using XI_1 by blast then have cγ2: "count (transitions_of (γ2ss, γ2ε)) t = 0" using LTS.avoid_count_zero local.add_trans_push_2(4) t_def by fastforce have "j = count (transitions_of ((γ2ss, γ2ε) @🍋 (v_ss, v))) t" using LTS.count_append_path_with_word[of γ2ss γ2ε v_ss v "Isolated p1 γ1" "Some γ''" q'] t_def cγ2 cv γ2ss_len v_ss_empty γ2ss_last by force then have j_count: "j = count (transitions_of' (Init p2, γ2ε @ v, γ2ss @ tl v_ss, q)) t" by simp
have "(γ2ss, γ2ε) ∈ by (meson LTS.trans_star_states_path_with_word p2_q'_states_Aiminus1) thenhave γ2ss_path: "(γ2ss, γ2ε) ∈gamma>2 #(LTS_\epsilon.remε>\ep>.remove_\\<> v)" using add_trans_push_2(1)
path_with_word_mono'[of γ2ss γ2ε Aiminus1 Ai] by auto
have path': "(v_ss, v) ∈ LTS.path_with_word Ai" by (meson LTS.trans_star_states_path_with_word path) have"(γ2ss, γ2ε) @🍋 (v_ss, v) ∈ LTS.path_with_word Ai" using γ2ss_path path' LTS.append_path_with_word_path_with_word γ2ss_last by auto thenhave"(γ2ss @ tl v_ss, γ2ε @ v) ∈ by auto
have "(Init p2, γ2ε @ v, γ2ss @ tl v_ss, q) ∈ LTS.trans_star_states Ai" by (metis (no_types, lifting) LTS.path_with_word_trans_star_states LTS.trans_star_states_append LTS.trans_star_states_hd XI_1 path γ2ss_path γ2ss_last) from this Suc(1)[of p2 "γ2ε @ v" "γ2ss @ tl v_ss" q] show "(¬is_Isolated q ⟶ (∃p' w'. (Init p havep1_1<amma:"p1 <>1#\gamma'#LTS_\\<eps>.removeεv) ==>LTS_ε @ (γ v))"
(is_Isolated q ⟶ (the_Ctr_Loc q, [the_Label q]) ==>* (p2, LTS_ε.remove_ε (γ2ε @ v)))" using j_count by fastforce qed
show ?thesis proof (cases "is_Init q ∨ is_Noninit q") case True have "(∃p' w'. (Init p', w', q) ∈ LTS_ε.trans_star_ε A ∧ (metisgamma append_Cons) using True ind by fastforce thenobtain p' w' where p'_w'_p: "(Init p', w', q) ∈ LTS_ε.trans_star_ε A ∧(p, (LTS_\<\<p, LTSε w)" by auto thenhave"(p', w') ==>* (p2, LTS_ε.remove_ε (γ2ε @ v))" by auto have p2_γ2εv_p1_γ1_γ''_v: "(p2, LTS_ε.remove_ε (γ2ε @ v)) ==>* (p1, γ1#γ''#LTS_ε.remove_ε v)" proof - have"γ2 #(LTS_ε.remove_ε v) = LTS_ε.remove_ε (γ2ε @ v)" using XI_1 by(etisepsilon\epsilonexp_def>remove_ LTS_.remove_<epsilon>_defappend_Cons
self_append_conv2) moreover from XIII have"(p2, γ2 #(LTS_ε.remove_ε v)) ==>* (p1, γ1#γ''#LTS_ε.remove_ε v)" by (metis PDS.transition_rel.intros append_Cons append_Nil lbl.simps(3) r_into_rtranclp
step_relp_def) ultimately show"(p2, LTS_ε.remove_ε (γ2ε @ v)) ==> by auto qed have p1_γ1γ''v_p_uv: "(p1, γ1#γ''#LTS_ε.remove_ε v) ==>java.lang.NullPointerException thenthesis have"(p, (LTS_ε.remove_ε u) @ (γ''#LTS_ε.remove_ε v)) = (p, LTS_ε.remove_\< using by (metis (no_types, lifting) Cons_eq_append_conv LTS_ε.remove_ε_Cons_tl LTS_ε.remove_ε_append_dist w_split hd_Cons_tl list.inject list.sel(1) list.simps(3) self_append_conv2) then show ?thesis using True p1_γ1γ''v_p_uv p2_γ2εv_p1_γ1_γ''_v p'_w'_p by fastforce next case False then have q_nlq_p2_γ2εv: "(the_Ctr_Loc q, [the_Label q case False using ind state.exhaust_disc
blast have p2_γ2εv_p1_γ1γ''v: "(p2, LTS_ε.remove_ε (γ2ε @ v)) ==>* (p1, γ1 # γ'' # LTS_ε.remove_ε v)" by (metis (mono_tags) LTS_ε.ε_exp_def LTS_ε.remove_ε_append_dist LTS_ε.remove_ε_def XIII
XI_1 append_Cons append_Nil lbl.simps(3) r_into_rtranclp step_relp_def2)
have p1_γ1γ blast by (metis p1_γ1_p_u append_Cons append_Nil step_relp_append)
―‹Corresponds to Schwoon's lemma 3.4› lemmapost_star_rules_saturation_constains_successors: assumes"saturation post_star_rules A A'" assumes"inits ⊆ LTS.srcs A" assumes"isols ⊆ LTS.isolated A" assumes"(Init p, w, q) \<have shows "(¬is_Isolated q ⟶ (∃p' w'. (Init p', w', q) ∈ LTS_ε.trans_star_ε A ∧ (p',w') ==>* (p, LTS_ε.remove_ε w))) ∧
(is_Isolated q ⟶ (the_Ctr_Loc q, [the_Label q]) ==>by<>remove_<>.remove__ append_Cons using rtranclp_post_star_rules_constains_successors assms saturation_def by metis
― theorem post_star_rules_subset_post_star_lang: assumes"post_star_rules** A A'" assumes"inits ⊆ LTS.srcs A" assumes"isols ⊆ LTS.isolated A" shows"{c. accepts_ε A' c} ⊆ post_star (lang_ε A)" proof fix c :: "('ctr_loc, 'label) conf" define p where"p = fst c" define w where"w = snd c" assume"c ∈ {c. accepts_ε A' c}" thenhave"accepts_ε A' (p,w)" unfolding p_def w_def by auto thenobtain q where q_p: "q ∈ finals""(Init p, w, q) ∈ LTS_ε.trans_sta qed unfolding accepts_εn then obtain w' where w'_def: "LTS_ by (meson LTS_εcomment> to34\close thenhave path: "(Init p, w', q) ∈ LTS.trans_star A'" by auto have"¬ is_Isolated q" usingF_not_Ext1byblast thenobtain p' w'a where"(Init p', w'a, q) ∈ LTS_ε.trans_star_ε A ∧ aassumes " <>LTS using rtranclp_post_star_rules_constains_successors[OF assms(1) assms(2) assms(3) path] by auto then( p' ', q <> using w'_def by (metis LTS_ε.ε_exp_def LTS_ε.remove_ε_def ‹LTS_ε.ε_exp w' w ∧ (Init p, w', q) ∈ LTS.trans_star A'›) thenhave"(p,w) ∈ post_star (lang_ε A)" using‹q ∈ finals›unfolding LTS.post_star_def accepts_ε_def lang_ε_defby fastforce thenshow"c ∈ post_star (lang_ε A)" unfolding p_def w_def by auto qed
―‹Corresponds to Schwoon's theorem 3.3› theorem post_star_rules_accepts_ε_correct: assumes"saturation post_star_rules A A'" assumes"inits ⊆ LTS.srcs A" assumes"isols ⊆ LTS.isolated A" shows"{c. accepts_ε A' c} = post_star (lang_ε A)" proof (rule; rule) fix c :: "('ctr_loc, 'label) conf" define p where"p = fst c"
w wheresnd assume"c ∈ post_star (lang_ε A)" thenobtain p' w' where"(p', w') ==>* (p, w) ∧ (p', w') ∈ lang_ε A" by (auto simp: post_star_def p_def w_def) thenhave"accepts_ε using lemma_3_3[of p' w' p w A A'] assms(1) by auto thenhave "accepts_A'c" unfolding p_def w_def by auto then show "c ∈ {c. accepts_ε A' c}" by auto next fix c :: "', 'abel assume"c ∈ {c. accepts_ε A' c}" thenshow"c ∈ post_star (lang_ε A)" using assms post_star_rules_subset_post_star_lang unfolding saturation_def by blast qed
―‹
post_star_rules_correct:
assumes "saturation post_star_rules A A'"
assumes "inits ⊆ LTS.srcs A"
assumes "isols ⊆ LTS.isolated A"
shows "lang_ε A' = post_star (lang_ε A)"
using ass lang_\epsilon <>_
‹Intersection Automata›
accepts_inters :: "(('ctr_loc, 'noninit, 'label) state * ('ctr_loc, 'noninit, 'label) state, 'label) transition set ==> (('ctr_loc, 'noninit, 'label) state * ('ctr_loc, 'noninit, 'label) state) set ==> ('ctr_loc, 'label) conf ==> bool" where
"accepts_inters ts finals ≡ λ(p,w). (∃qq ∈ finals. ((Init p, Init p),w,qq) ∈ LTS.trans_star ts)"
lang_ε_inters :: "(('ctr_loc, 'noninit, 'label) state * ('ctr_loc, 'noninit, 'label) state, 'label option) transition set ==> ('ctr_loc, 'label) conf set" where
"lang_ε_inters ts = {c. accepts_ε_inters ts c}"
trans_star_trans_star_ε_inter:
assumes "LTS_ε.ε_exp w1 w"
assumes "LTS_ε.ε_exp w2 w"
assumes "(p1, w1, p2) ∈ LTS.trans_star ts1"
assumes "(q1, w2, q2) ∈ LTS.trans_star ts2"
shows "((p1,q1), w :: 'label list, (p2,q2)) ∈ LTS_ε.trans_star_ε (inters_ε ts1 ts2)"
using assms
(induction "length w1 + length w2" arbitrary: w1 w2 w p1 q1 rule: less_induct)
case less
then show ?case
proof (cases "\<existsusing
case True
from True obtain α β w1' w2' where True'':
"w1=Some α#w1'"
"w2=Some β#w2'"
by auto
have "α = β"
by (metis True''(1) True''(2) LTS_ε.ε_exp_Some_hd less.prems(1) less.prems(2))
then have True':
"w1=Some α#w1'"
"w2=Some α#w2'"
using True'' by auto
define w' where "w' = tl w"
obtain p' where p'_p: "(p1, Some α, p') ∈ ts1 ∧ (p', w1', p2) ∈ LTS.trans_star ts1"
using less True'(1) by (metis LTS_ε.trans_star_cons_ε)
obtain q' where q'_p: "(q1, Some α, q') ∈
using less True'(2) by (metis LTS_ε.trans_star_cons_ε)
ind: ((p'', q'), w',', p2, q2) ∈
proof -
have "length w1' + length w2' < length w1 + length w2"
using True'(1) True'(2) by simp
moreover
have "LTS_ε.ε_exp w1' w'"
by (metis (no_types) LTS_ε.ε_exp_def less(2) True'(1) list.map(2) list.sel(3)
option.simps(3) removeAll.simps(2) w'_def)
moreover
have "LTS_ε.ε_exp w2' w'"
by (metis (no_types) LTS_ε‹
option.simps(3) removeAll.simps(2) w'_def)
moreover
have "(p', w1', p2) ∈ LTS.trans_star ts1"
using p'_p by simp
moreover
have "(q', w2', q2) ∈ LTS.trans_star ts2"
using q'_p by simp
ultimately
show "((p', q'), w',ost_s(lang_\<psilon using ‹
using less(1)[of w1' w2' w' p' q'] by auto
qed
moreover
have "((p1, q1), Some α, (p', q')) ∈ (inters_ε ts1 ts2)"
by (simp add: inters_ε_def p'_p q'_p)
ultimately
have "((p1, q1), α#w', p2, q2) ∈ LTS_ε.trans_star_ε (inters_ε ts1 ts2)"
by(eson LTS_εt\epsilon<amma)
moreover
have "length w > 0"
using less(3) True' LTS_ε
moreover
have "hd w = α"
using less(3) True' LTS_ε.ε_exp_Some_hd by metis
ultimately
show ?thesis
using w'_def by force
next
case False
note False_outer_outer_outer_outer = False
show ?thesis
proof (cases "w1 = [] ∧ w2 = []")
case True
then have same: "p1 = p2 ∧ q1 = q2"
by (metis LTS.trans_star_empty less.prems(3) less.prems(4))
have "w = []"
using True less(2) LTS_ε.exp_empty_empty by auto
then show ?thesis
using less True
by (simp add: LTS_ε.trans_star_ε.trans_star_ε_refl same)
next
case False
note False_)
show ?thesis
proof (cases "∃w1'. w1=ε#w1'")
case True (* Adapted from above. *) thenobtain w1' where True': "w1=ε#w1'" by auto obtain p' wheredefine p wherefst using less True'(1) by (metis LTS_ε.trans_star_cons_ε) have q'_p: " (q1, w2, q2) ∈ LTS.trans_star ts2"
less have ind: "((p', q1), w, p2, q2) ∈ LTS_ε.trans_star_ε (inters_ε ts1 ts2)" proof - have"length w1' + length w2 < length w1 + length w2" using True'(1) by simp moreover have"LTS_ε.ε (aauto simp: p post_ p_def w_def by (metis (no_types) LTS_ε.ε_exp_def less(2) True'(1) removeAll.simps(2)) moreover have "LTS_ε.ε_exp w2 w" by (metis (no_types) less(3)) moreover have "(p', w1', p2) ∈ LTS.trans_star ts1" using p'_p by simp moreover have "(q1, w2, q2) ∈ LTS.trans_star ts2" using q'_p by simp ultimately show "(,q1, ) ∈< ts1 using less(1)[of w1' w2 w p' q1] by auto qed moreover have"((p1, q1), ε, (p', q1)) ∈ (inters_ε ts1 ts2)" by (simp add by auto ultimately have"((p1, q1), w, p2, q2) ∈ LTS_ε.trans_star_ε (inters_ε using LTS_εfix c :: " : "('tr_lc, 'label)) conf" then showassume"c \<in by force next case False note False_outer_outer = False then show ?thesis proof (cases "∃w2'. w2 = ε # w2'") case True (* Adapted from above. *) then obtain w2' where True': "w2=ε#w2'" by auto have p'_p: "(p1, w1, p2) ∈ <commentomment using less by (metis) obtain q' where q'_p: "(q1, ε, q') ∈ ts2 ∧(q', w2', q2) ∈ LTS.trans_startheorem post_star_: using less True'(1) by (metis LTS_🚫 have ind: "((p1, q'), w, p2, q2) ∈ LTS_ε.trans_star_ε (inters_ assumes <subseteqA" proof - have "length w1 + length w2' < length w1 + length w2" using True'(1) True'(1) by simp moreover have "LTS_>_exp by (metis (no_types) less(2)) moreover have"LTS_ε.ε_exp w2' w" by (metis (no_types) LTS_ε.ε_exp_def less(3) True'(1) removeAll.simps(2)) moreover have"(p1, w1, p2) ∈ LTS.trans_star ts1" using p'_p by simp moreover have"(q', w2', q2) ∈accepts_int :: "(,'noninit*(, noninitlabel) state) transition>(','oninit *(ctr_locnoninitlabel \Rightarrow, confRightarrowboolwhere using q'_p by simp ultimately show"((p1, q'), w, p2, q2) ∈ LTS_ε.trans_star_ε (inters_ε ts1 ts2)" using less(1)[of w1 w2' w p1 q'] by auto qed moreover have"((p1, q1), ε, (p1, q')) ∈ (inters_ε ts1 ts2)" by (simp add: inters_ε_def p'_p q'_p) ultimately "(p1, q1), w, p2,, q2) ∈)" using LTS_ε.trans_star_ε.simps by fastforce then show ?thesis by force next case False thenhave"(w1 = [] ∧ (∃α w2'. w2 = Some α # w2')) ∨ ((∃α w1'. w1 = Some α # w1') ∧ w2 = [])" using False_outer_outer False_outer_outer_outer False_outer_outer_outer_outer by (metis neq_Nil_conv option "ts12 = iners ts1 ts2" thenshow ?thesis by (metis LTS_ε.ε_exp_def LTS_ε.ε_exp_Some_length less.prems(1,2) less_numeral_extra(3)
list.simps(8) list.size(3) removeAll.simps(1)) qed qed qed qed qed
lemma trans_star_ε_inter: assumes"(p1, w :: 'label list, p2) ∈ LTS_ε.trans_star_εP_Automaton..accepaccept a) assumes "(q1, w, q2) ∈ shows"((p1, q1), w, (p2, q2)) ∈ LTS_ε.trans_star_ε (inters_ε ts1 ts2)" proof have"∃w1'. LTS_ε.ε_exp w1' w ∧ (p1, w1', p2) ∈ LTS.trans_star ts1" using assms by (simp add: LTS_ε.trans_star_ε_ε_exp_trans_star) thenobtain w1' where"LTS_ε.ε_exp w1' w ∧ (p1, w1', p2) ∈ LTS.trans_star ts1" by auto moreover have"∃ "lang_intersfinals c}" using assms by (simp add: LTS_ε.trans_star_ε_ε_exp_trans_star) then obtain w2' where "LTS_ε.ε_exp w2' w ∧ (q1, w2', q2) ∈ LTS.trans_star ts2" by auto ultimately show ?thesis using trans_star_trans_star_ε_inter by metis qed
lemma inters_trans_star_ε1: assumes "(p1q2, w :: 'label list, p2q2) ∈ LTS_ε.trans_star_ε (inters_ε ts1 ts2)" shows "(fst p1q2, w, fst p2q2) ∈ LTS_ε.trans_star_ε ts1" using assms proof (induction rule: LTS_ε.trans_star_ε.induct[OF assms(1)]) case (1 p) then show ?case by si add: LTS_\epsilont\<psilon. next case (2 p γ q' w q) then have ind: "(fst q', w, fst q) ∈ LTS_ε.trans_star_ε ts1" by auto from 2(1) have "(p, Some γ, q') ∈
{((p1, q1), α, p2, q2) |p1 q1 α p2 q2. (p1, α, p2) ∈ ts1 ∧ (q1, α, q2) ∈ ts2assumes (PDS_with_P_automata.finalsfinal_noninits1
{((p1, q1(PDS_with_P_automatafinals final_noninits2
{((p1, q1), ε, p1, q2) |p1 q1 q2. (q1, ε, q2) ∈ unfolding pw \> moreover
{ assume"(p, Some γ, q') ∈ {((p1, q1), α, p2, q2) |p1 q1 α p2 q2. (p1, α, p2) ∈ ts1 ∧)" thenhave"∃p1 q1. p = (p1, q1) ∧ by simp then obtain p1 q1 where "p = (p1, q1) ∧ (∃p2 q2. q' = (p2, q2) ∧ (p1, Some γ, p2) ∈ ts1 ∧ (q1, Some γ, q2) ∈) by auto thenhave ?case using LTS_ε.trans_star_ε.trans_star_ε_step_γ ind assumes
} moreover
{ assume"(p, Some γ, q') ∈ {((p1, q1), ε, p2, q1) |p1 p2 q1. (p1, ε, p2) ∈ then have ?case by auto } moreover { assume "(p, Some γ, q') ∈ {((p1, q1), ε, p1, q2) |p1 q1 q2. (q1, ε, q2) ∈.lang_def inters_accept_iffjava.lang.StringIndexOutOfBoundsException: Index 96 out of bounds for length 96 thenhave ?case by auto
} ultimately show ?case by auto next case (3 p q' w q) thenhave ind: "(fst q', w, fst q) ∈ LTS_ε.trans_star_ε ts1" by auto from3(1) have"(p, ε, q') ∈
java.lang.NullPointerException
java.lang.NullPointerException {((p1, q1), ε, (p1, q2)) | p1 q1 q2. (q1, ε, q2) def accepts_\epsilonin :: "ctr_loc(, noninit ' option\Rightarrow(ctr_loc)conf bool unfolding inters_ε_defby auto moreover
{ assume"(p, ε, q') ∈ {((p1, q1), α, p2, q2) |p1 q1 α p2 q2. (p1, α, p2) ∈ ts1 ∧ (q1, α, q2) ∈ ts2}" then"accepts_\<epsilon_ \lambda(p,w)). (\exists>q ∈ inals. ((Init p, In, Init p),w,(q1,q2))) \in LTS_εepsilon>.trans<epsilon> ts)" by simp thenobtain p1 q1 where"p = (p1, q1) ∧ (∃p2 q2. q' = (p2, q2) ∧ (p1, ε, p2) ∈ ts1 ∧ (q1, ε, q2) ∈ ts2)" by auto thenhave ?efinitionepsilon "('ctr_, 'noni, 'lab) sta * ('ct, 'nonini, 'labe) state, 'labeoption) t) transition set <Rightarrow> ('cr_loc, 'label) co set"java.lang.StringIndexOutOfBoundsException: Index 190 out of bounds for length 190 using LTS_ε.trans_star_ε.trans_star_ε_step_ε ind by fastforce"lang_εc}"
} moreover
{ assume"(p, εi: then have "∃p1 p2 q1.assumes_exp by auto thenobtain p1 p2 q1assumes<>\epsilonexp by auto thenhave ?case using LTS_ε.trans_star_ε.trans_star_ε_step_ε ind by fastforce
} moreover
{ assume"(p, ε, q') ∈ {((p1, q1), ε, p1, q2) |p1 q1 q2. (q1, ε, q2) ∈ shows " (p1:'label,) \inepsilonε ts1ts2 thenhave"∃p1 q1 q2. p = (p1, q1) ∧ q' = (p1, q2) ∧ (q1, ε, q2) ∈ ts2" by auto thenobtain p1 q1 q2 where"p = (p1, q1) ∧ q' = (p1, q2) ∧ (q1, ε, q2) ∈ ts2" by auto thenhave ?case using LTS_ε.trans_star_ε.trans_star_ε_step_ε ind by fastforce
ultimately show ?case by auto qed
lemma inters_trans_star_ε: assumes"(p1q2, w :: 'label list, p2q2) ∈ LTS_ε.trans_star_ε (inters_ε case True shows "Truealpha> β w1' w2' where True'': using assms proof (induction rule: LTS_ε.trans_star_ε.induct[OF assms(1)]) case (1 p) thenshow ?case by (simp add: LTS_ε.trans_star_ε.trans_star_ε_refl) next case (2 p γ q' w q) thenhave ind: "(snd q', w, snd q) ∈ LTS_ε.trans_star_ε ts2" by auto from2(1) have"(p, by (metis T True''(1 Tr''(2) LTS\epsilonexp_S less.prems(1 less.prems2)) {((p1, q1), α, p2, q2) |p1 q1 α p2 q2. (p1, α, p2) ∈ ts1 ∧ (q1, α, q2) ∈ ts2} ∪ {((p1, q1), ε, p2, q1) |p1 p2 q1. (p1, ε, p2) ∈ {((p1, q1), ε, p1, q2) |p1 q1 q2. (q1, ε, q2) ∈#w2'" unfolding inters_ε_defby auto moreover
{ assume"(p, Some γ_:"\>'\in ts1 p2 <> thenhave"∃p1 q1. p = (p1, q1) ∧ (∃p2 q2. q' = (p2, q2) ∧ (p1, Some γ, p2) ∈ ts1 ∧ (q1, Some γ, q2) ∈ ts2)" by simp thenobtain p1 q1 where"p = (p1, q1) ∧ (∃p2 q2. q' = (p2, q2) ∧ (p1, Some γ, p2) ∈ ts1 ∧ (q1, Some γ, q2) ∈ ts2)" by auto thenhave ?case using LTS_ε.trans_star_ε.trans_star_ε_step_γ ind by fastforce
} moreover
{ assume"(p, Some γ, q') ∈ {((p1, q1), ε, p2, q1) |p1 p2 q1. (p1, ε, p2) ∈ ts1}"
en have ?case by auto
} moreover
{ assume",Som \gamma> q') <> {((p1, q1), \\< |p1 q1 q2 q2. q1, \<psilon, then have ?case by auto } ultimately show ?case by auto next case (3 p q' w q) then have ind: "(snd q', w, snd q) ∈ LTS_ε.trans_star_ε ts2" by uto from 3(1) have "(p, ε, q') ∈
{((p1, q1), α, (p2, q2)) | p1 q1 αmoreover
{((p1, q1), ε, (p2, q1)) | p1 p2 q1 have"TS_<e.ε {((p1, q1), ε, (p1, q2)) | p1 q1 q2. (q1, ε, q2) ∈ ts2}" unfolding inters_ε_defby auto moreover
{ assume"(p, ε, q') ∈ {((p1, q1), α, p2, q2) |p1 q1 α p2 q2. (p1, α, p2) ∈ ts1 ∧ (q1, α, q2) ∈ ts2}" thenhave"∃p1 q1. p = (p1, q1) ∧ (∃p2 q2. q' = (p2, q2) ∧ (p1, ε, p2) ∈ ts1 ∧ (q1, ε, q2) ∈ ts2)" by simp thenobtain p1 q1 where"p = (p1, q1) ∧ (∃p2 q2. q' = (p2, q2) ∧ (p1, ε, p2) ∈ ts1 ∧ (q1, ε, q2) ∈ ts2)" by auto thenhave ?case using LTS_ε.trans_star_ε.trans_star_ε_step_ε ind by fastforce
} moreover
{ assume"(p, ε, q') ∈ {((p1, q1), ε, p2, q1) |p1 p2 q1. (p1, ε, p2) ∈ ts1}" thenhave"∃p1 p2 q1. p = (p1, q1) ∧ q' = (p2, q1) ∧ (p1, ε, p2) ∈ by auto then obtain p1 p2 q1 where "p = (p1, q1) ∧ q' = (p2, q1) ∧ (p1, ε, p2) ∈ ts1" by auto then have ?case using LTS_ε.trans_star_ε.trans_star_ε_step_ε } moreover { assume "(p, ε, q') ∈ {((p1, q1), ε, p1, q2) |p1 q1 q2. (q1, ε, q2) ∈ ts2}" then have "∃p1 q1 q2. p = (p1, q1) ∧ q' = (p1, q2) ∧ (q1, ε, ultimately by thenobtain p1 q1 q2 where"p = (p1, q1) ∧ q' = (p1, q2) ∧ (q1, ε, q2) ∈ ts2" by auto thenhave ?case using LTS_ε.trans_star_ε.trans_star_ε_step_ε ind by fastforce
} ultimately show ?case by auto qed
lemma inters_ε_accept_ε_iff: "accepts_ε> ts ts2) c \longleftrightarrow> accepts_\\epsi> ts1 c ∧ proof assume "accepts_ε_inters (inters_ε ts1 ts2) c" then show "accepts_ε ts1 c ∧ accepts_ε ts2 c" using accepts_ε_def accepts_ε_inters_def inters_trans_star_ε inters_trans_star_ε1 by fastforce next assume asm: "accepts_ε ts1 c ∧ accepts_ε ts2 c" define p where "p = fst c" define w where "w = snd c"
from asm have "accepts_ε ts1 (p,w) ∧ lessTrue<>.<epsilonby using p_def w_def by auto thenhave"(∃q∈ (∃q∈ unfolding accepts_ε_def by auto then show ""accepts_ε ts1 ts2) c using accepts_ε_inters_def p_def trans_star_ε_inter w_def by fastforce qed
lemma inters_ε_lang_ε: "lang_ε_inters (inters_ε ?hesis unfolding lang_ε_inters_def lang_ε_defusing inters_ε_accept_ε_iff by auto
subsection‹Dual search›
lemma dual1: "post_star (lang_ε A1) ∩ pre_star (lang A2) = {c. ∃c1 ∈ lang_ε A1. ∃False_outer_outer_oter_ou= False proof - have "post_star (lang_ε A1) ∩ pre_star (lang A2) = {c. c ∈ post_star (lang_ε A1) ∧ c ∈ pre_star (lang A2proof"w1 = [] \and w2= []) by auto moreover have "... = {c. (∃c1 ∈ lang_ε A1. c1 ==>* c) ∧ (<exists unfolding post_star_def pre_star_def by auto moreover have"... = {c. ∃c1 ∈ lang_ε A1. ∃>.exp_empty_e by au by auto ultimately show ?thesis by metis qed
lemma dual2: "post_star (lang_ε A1) ∩ pre_star (lang A2) ≠ {} ⟷ (∃c1 ∈ lang_ε A1. ∃c2 ∈ lang A2. c1 ==>* c2)" proof (rule) assume "post_star (lang_ε A1) ∩ pre_star (lang A2) ≠ {}" then show "∃c1∈lang_ε A1. ∃c2∈lang A2. c1 ==>java.lang.NullPointerException by (auto simp: pre_star_def post_star_def intro: rtranclp_trans) next assume"∃c1∈lang_ε A1. ∃c2\< then then show "post_star (lang_ε A1) ∩ pre_star (lang A2) ≠ {}" using dual1 by auto qed
lemma LTS_ε_of_LTS_Some: "(p, Some γ, q') ∈haveind('q1)<>LTS_.trans_star_ε ts1 ts2)" unfolding LTS_ε_of_LTS_def ε_edge_of_edge_def by (auto simp add: rev_image_eqI)
lemma trans_star_epsilon>_LTS_epsilon>_of_LTS_trans_star: "(p,w,q LTS_ε.trans_star_εLTS_\<epsilon_')" shows"(p,w,q) ∈ LTS.trans_star A2'" using assms proof (induction rule: LTS_ LTS.trans_star ts1" case (1 p) then show ?case by (simp add: LTS.trans_star.trans_star_refl) next case (2 p γ q' w q)using q'_p bby simp moreover have ""(p', q1,w,p, q2 \<n LTS_ε.trans_star_ε (inters_ε ts1 ts2)" using2(1) using LTS_ε_of_LTS_Some by metis moreover have"(q', w, q) ∈ LTS.trans_star A2'" using"2.IH"2(2) by auto ultimatelyshow ?case by (meson LTS.trans_star.trans_star_step) next case (3 p q'w q) thenshow ?case using LTS_ε by fastforce qed
lemma trans_star_trans_star_ε_LTS_ε_of_LTS: assumes"(p,w,q) ∈ LTS.trans_star A2'" shows"(p,w,q) ∈ LTS_ε.trans_star_ε (LTS_ε_of_LTS A2')" using assms proof (induction rule: LTS.trans_star.induct[OF force case (1 p) thenshow ?case by (simp: LTS_<>.trans_star_εε) next case (2 p γ q' w q) thenshow ?case by (meson LTS_ε.trans_star_ε.trans_star_ε_step_γ LTS_ε_of_LTS_Some) qed
lemma accepts_ε_LTS_ε_of_LTS_iff_accepts: "accepts_ε (LTS_ε_of_LTS A2') (p, w) ⟷ accepts A2' (p, w)" using accepts_ε_def accepts_def trans_star_ε_LTS_ε_of_LTS_trans_star
trans_star_trans_star_ε_LTS_ε to
lemma lang__LTS_<>_ unfolding lang_ε_def lang_def using accepts_ε_LTS_ε_of_LTS_iff_accepts by auto
have"{c. accepts A2' c} ⊆ pre_star (lang A2)" using pre_star_rule_subset_pre_star_lang[of A2 A2'] assms by auto thenhave A2'_correct: "lang A2' ⊆ pre_star (lang A2)" unfolding lang_def by auto
have"lang_ε_inters (inters_ε A1' (LTS_ε_of_LTS A2')) = lang_ε A1' ∩ using inters_ε_lang_ε[of A1' "(LTS_εhave"(q', w2''q2) ∈" moreover have"... = lang_ε using lang_ε_LTS_ε_of_LTS_is_lang by auto moreover have "... ⊆ post_star (lang_ε A1) ∩ pre_star (lang A2)" using A1'_correct A2'_correct by auto ultimately have moreo by metis
from assms have "post_star (lang_ε A1) ∩ pre_star (lang A2) ≠ {}" using inters_correct by auto then show "∃lang_ε A1. ∃lang A2. c1Rightarrowjava.lang.NullPointerException using dual2 by auto
qed
theorem dual_star_correct_saturation: assumes"inits ⊆ LTS.srcs A1" assumes"inits ⊆ LTS.srcs A2" assumes"isols ⊆ LTS.isolated A1" assumes"isols ⊆ A2" assumes"saturation post_star_rules A1 A1'" assumes"saturation pre_star_rule A2 A2'" shows"lang_ε_inters (inters_ε A1' (LTS_ε_of_LTS A2')) ≠then show ?thesis proof - have "{c. accepts_ε A1' c} = post_star (lang_ε A1)" using post_star_rules_accepts_ε_correct[of A1 A1'] assms by auto then have A1'_correct: "lang_ε A1' = post_star (lang_ε java.lang.StringIndexOutOfBoundsException: Index 75 out of bounds for length 11 unfolding lang_ε_defby auto
have"{c. accepts A2' c} = pre_star (lang A2)" using pre_star_rule_accepts_correct[of A2 A2'] assms by auto thenhave A2'_correct: "lang A2' = pre_star (lang A2)" unfolding lang_def by auto
have"lang_ε_inters (inters_ε A1' (LTS_ε_of_LTS A2')) = lang_ε A1' ∩ lang_ε)∈ ts1"
inters_<_lang_ε[of A1' "(LTS_ε_of_LTS A2')"] by auto moreover have"... = lang_ε A1' ∩ lang A2'" using lang_ε_LTS_ε_of_LTS_is_lang by auto moreover have"... = post_star (lang_ε A1) ∩ pre_star (lang A2)"
ng'_correct A2'_correct java.lang.StringIndexOutOfBoundsException: Index 41 out of bounds for length 41 ultimately have inters_correct: "lang_ε_inters (inters_ε A1' (LTS_ε_of_LTS A2')) = post_star (lang_ε A1) ∩w1'. LTS_ε.ε_ex w1' w ∧) ∈.trans_ts1"
metis
show ?thesis proof assume"lang_ε_inters (inters_ε A1' (LTS_ε_of_LTS A2')) ≠ then have "post_star (lang_ε A1) ∩ w2'. LTS_ε_exp>(q1, w2',q2 LTS.trans_star using inters_correct by auto thenshow"∃c1∈lang_ε A1. ∃c2∈lang A2. c1 ==>w,q)∈ using dual2 by auto next assume "∃c1 showthesis thenhave"post_star (lang_ε A1) ∩ pre_star (lang A2) ≠ {}" using dual2 by auto thenshow"lang_ε_inters (inters_ε A1' (LTS_ε_of_LTS A2')) ≠ {}" using inters_correct by auto qed qed
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.