Input:
lemma fconverseE[elim!]:
  assumes "x \<in>\<^sub>\<circ> r\<inverse>\<^sub>\<bullet>"
  obtains a b where "x = [b, a]\<^sub>\<circ>" and "[a, b]\<^sub>\<circ> \<in>\<^sub>\<circ> r"

Output:
using assms unfolding fconverse_def
by auto


Input:
lemma fpairsD[dest]:
  assumes "x \<in>\<^sub>\<circ> fpairs r"
  shows "x \<in>\<^sub>\<circ> r" and "\<exists>a b. x = [a, b]\<^sub>\<circ>"

Output:
using assms unfolding fpairs_def
by auto


Input: lemma fun_dual5: "(f = \<partial> \<circ> g \<circ> \<partial>) = (\<partial> \<circ> f \<circ> \<partial> = g)"

Output: by (metis comp_assoc fun_dual1 fun_dual2)


Input:
lemma Ord_vsubset_Vset_succ[V_cs_intros]:
  assumes "Ord \<alpha>" and "B \<subseteq>\<^sub>\<circ> Vset \<alpha>"
  shows "B \<subseteq>\<^sub>\<circ> Vset (succ \<alpha>)"

Output: by (intro vsubsetI) (auto simp: assms Vset_trans Ord_vsubset_in_Vset_succI)


Input:
lemma vsv_vimageI1:
  assumes "a \<in>\<^sub>\<circ> \<D>\<^sub>\<circ> r" and "a \<in>\<^sub>\<circ> A"
  shows "r\<lparr>a\<rparr> \<in>\<^sub>\<circ> r `\<^sub>\<circ> A"

Output:
using assms
by (simp add: vsv_vimage_eqI)


Input:
lemma vsv_vlrestriction_vinsert:
  assumes "a \<in>\<^sub>\<circ> \<D>\<^sub>\<circ> r"
  shows "r \<restriction>\<^sup>l\<^sub>\<circ> vinsert a A = vinsert \<langle>a, r\<lparr>a\<rparr>\<rangle> (r \<restriction>\<^sup>l\<^sub>\<circ> A)"

Output:
using assms
by (auto intro!: vsubset_antisym)


Input:
lemma dg_prod_vdiff_vunion_Obj_in_Obj:
  assumes "J \<subseteq>\<^sub>\<circ> I"
    and "b \<in>\<^sub>\<circ> (\<Prod>\<^sub>D\<^sub>Gk\<in>\<^sub>\<circ>I -\<^sub>\<circ> J. \<AA> k)\<lparr>Obj\<rparr>"
    and "c \<in>\<^sub>\<circ> (\<Prod>\<^sub>D\<^sub>Gj\<in>\<^sub>\<circ>J. \<AA> j)\<lparr>Obj\<rparr>"
  shows "b \<union>\<^sub>\<circ> c \<in>\<^sub>\<circ> (\<Prod>\<^sub>D\<^sub>Gi\<in>\<^sub>\<circ>I. \<AA> i)\<lparr>Obj\<rparr>"

Output: by ( vdiff_of_vunion rule: dg_prod_vunion_Obj_in_Obj assms: assms(2,3) subset: assms(1) )


Input:
lemma vimage_eq_imp_vcomp:
  assumes "r `\<^sub>\<circ> A = s `\<^sub>\<circ> B"
  shows "(t \<circ>\<^sub>\<circ> r) `\<^sub>\<circ> A = (t \<circ>\<^sub>\<circ> s) `\<^sub>\<circ> B"

Output:
using assms
by (metis vcomp_vimage)


Input:
lemma vifintersectionE2[elim]:
  assumes "a \<in>\<^sub>\<circ> (\<Inter>\<^sub>\<circ>i\<in>\<^sub>\<circ>I. f i)"
  obtains i where "i \<in>\<^sub>\<circ> I" and "a \<in>\<^sub>\<circ> f i"

Output:
using assms
by (elim vifintersectionE3) (meson assms VInterE2 app_vimageE)


Input:
lemma fconst_onE[elim!]:
  assumes "x \<in>\<^sub>\<circ> fconst_on A c"
  obtains a where "a \<in>\<^sub>\<circ> A" and "x = [a, c]\<^sub>\<circ>"

Output:
using assms unfolding fconst_on_def
by auto


Input:
lemma frestrictionI[intro!]:
  assumes "a \<in>\<^sub>\<circ> A" and "b \<in>\<^sub>\<circ> A" and "[a, b]\<^sub>\<circ> \<in>\<^sub>\<circ> r"
  shows "[a, b]\<^sub>\<circ> \<in>\<^sub>\<circ> r \<restriction>\<^sub>\<bullet> A"

Output:
using assms unfolding frestriction_def
by simp


Input:
lemma vsv_vimage_eqI[intro]:
  assumes "a \<in>\<^sub>\<circ> \<D>\<^sub>\<circ> r" and "r\<lparr>a\<rparr> = b" and "a \<in>\<^sub>\<circ> A"
  shows "b \<in>\<^sub>\<circ> r `\<^sub>\<circ> A"

Output:
using assms(2)[unfolded vsv_ex1_app2[OF assms(1)]] assms(3)
by auto


Input:
lemma fimageI1:
  assumes "x \<in>\<^sub>\<circ> \<R>\<^sub>\<bullet> (r \<restriction>\<^sup>l\<^sub>\<bullet> A)"
  shows "x \<in>\<^sub>\<circ> r `\<^sub>\<bullet> A"

Output:
using assms unfolding fimage_def
by simp


Input:
lemma vrat_mult_closed:
  assumes "x \<in>\<^sub>\<circ> \<rat>\<^sub>\<circ>" and "y \<in>\<^sub>\<circ> \<rat>\<^sub>\<circ>"
  shows "x *\<^sub>\<rat> y \<in>\<^sub>\<circ> \<rat>\<^sub>\<circ>"

Output:
proof- have "(x'::rat) * y' \<in> UNIV" for x' y'
by simp from this[untransferred, OF assms] show ?thesis .
qed


Input: lemma vrange_VLambda: "\<R>\<^sub>\<circ> (\<lambda>a\<in>\<^sub>\<circ>A. f a) = set (f ` elts A)"

Output: by (intro vsubset_antisym vsubsetI) auto


Input:
lemma vrat_assoc_law_multiplication:
  assumes "x \<in>\<^sub>\<circ> \<rat>\<^sub>\<circ>" and "y \<in>\<^sub>\<circ> \<rat>\<^sub>\<circ>" and "z \<in>\<^sub>\<circ> \<rat>\<^sub>\<circ>"
  shows "(x *\<^sub>\<rat> y) *\<^sub>\<rat> z = x *\<^sub>\<rat> (y *\<^sub>\<rat> z)"

Output:
proof- have "(x' * y') * z' = x' * (y' * z')" for x' y' z' :: rat
by simp from this[untransferred, OF assms] show ?thesis .
qed


Input: lemma vimage_VLambda_vrange: "(\<lambda>a\<in>\<^sub>\<circ>A. f a) `\<^sub>\<circ> B = \<R>\<^sub>\<circ> (\<lambda>a\<in>\<^sub>\<circ>A \<inter>\<^sub>\<circ> B. f a)"

Output:
unfolding vimage_def
by (simp add: vlrestriction_VLambda)


Input:
lemma vrestriction_atE2[elim]:
  assumes "x \<in>\<^sub>\<circ> r \<restriction>\<^sub>\<circ> A"
  obtains a b where "x = \<langle>a, b\<rangle>" and "a \<in>\<^sub>\<circ> A" and "b \<in>\<^sub>\<circ> A" and "r\<lparr>a\<rparr> = b"

Output:
using assms unfolding vrestriction_def
by clarsimp


Input:
lemma vint_mult_closed:
  assumes "x \<in>\<^sub>\<circ> \<int>\<^sub>\<circ>" and "y \<in>\<^sub>\<circ> \<int>\<^sub>\<circ>"
  shows "x *\<^sub>\<int> y \<in>\<^sub>\<circ> \<int>\<^sub>\<circ>"

Output:
proof- have "(x'::int) * y' \<in> UNIV" for x' y'
by simp from this[untransferred, OF assms] show ?thesis .
qed


Input:
lemma app_vimageE[elim]:
  assumes "b \<in>\<^sub>\<circ> r `\<^sub>\<circ> A"
  obtains a where "\<langle>a, b\<rangle> \<in>\<^sub>\<circ> r" and "a \<in>\<^sub>\<circ> A"

Output:
using assms unfolding vimage_def
by auto


Input:
lemma v11_vconverse_app_in_vdomain:
  assumes "y \<in>\<^sub>\<circ> \<R>\<^sub>\<circ> r"
  shows "r\<inverse>\<^sub>\<circ>\<lparr>y\<rparr> \<in>\<^sub>\<circ> \<D>\<^sub>\<circ> r"

Output:
using assms v11_vconverse unfolding vrange_vconverse[symmetric]
by (auto simp: v11_def)


Input:
lemma drop_suffix_hd_css_step'':
  assumes step: "\<Gamma>\<turnstile> (p#ps@cs,css,s) \<rightarrow> (cs',(pnorm@cs,pabr@cs)#css,t)"
  shows  "\<Gamma>\<turnstile> (p#ps,css,s) \<rightarrow> (cs',(pnorm,pabr)#css,t)"

Output:
using drop_suffix_hd_css_step' [OF step]
by auto


Input: lemma mset_subst_cls_list_subst_cls_mset: "mset (Cs \<cdot>cl \<sigma>) = (mset Cs) \<cdot>cm \<sigma>"

Output:
unfolding subst_cls_mset_def subst_cls_list_def
by auto


Input: lemma cs_length_g_one: assumes \<open>length (cs\<^bsup>\<pi>\<^esup> i) \<noteq> 1\<close> obtains k where  \<open>cs\<^bsup>\<pi>\<^esup> i = (cs\<^bsup>\<pi>\<^esup> k)@[\<pi> i]\<close> and \<open>i icd\<^bsup>\<pi>\<^esup>\<rightarrow> k\<close>

Output:
apply (cases \<open>i\<close> \<open>\<pi>\<close> rule: cs_cases)
using assms cs_not_nil
by auto


Input:
lemma preprocess'_Tableau_Poly_Mapping_Some': "(Poly_Mapping (preprocess' cs start)) p = Some v
  \<Longrightarrow> \<exists> h. poly h = p \<and> \<not> is_monom (poly h) \<and> qdelta_constraint_to_atom h v \<in> flat (set (Atoms (preprocess' cs start)))"

Output: by (induct cs start rule: preprocess'.induct, auto simp: Let_def split: option.splits if_splits)


Input:
lemma length_locss:
  "i < length cs
  \<Longrightarrow> length (locss P cs loc ! (length cs - Suc i)) =
  locLength P (fst(cs ! (length cs - Suc i)))
              (fst(snd(cs ! (length cs - Suc i))))
              (snd(snd(cs ! (length cs - Suc i))))"

Output:
apply (induct cs, auto)
apply (case_tac "i = length cs")
by (auto simp: nth_Cons')


Input: lemma size_jump2: "size (jump l cs) < size cs \<or> jump l cs = cs"

Output:
apply(induct cs)
apply simp
apply(case_tac a)
apply auto done


Input:
lemma fps_XDp_foldr_nth [simp]: "foldr (\<lambda>c r. fps_XDp c \<circ> r) cs (\<lambda>c. fps_XDp c a) c0 $ n =
    foldr (\<lambda>c r. (c + of_nat n) * r) cs (c0 + of_nat n) * a$n"

Output: by (induct cs arbitrary: c0) (simp_all add: algebra_simps)


Input:
lemma weakBisimCasePushRes:
  fixes x  :: name
  and   \<Psi>  :: 'b
  and   Cs :: "('c \<times> ('a, 'b, 'c) psi) list"

  assumes "x \<sharp> \<Psi>"
  and     "x \<sharp> (map fst Cs)"

  shows "\<Psi> \<rhd> \<lparr>\<nu>x\<rparr>(Cases Cs) \<approx> Cases(map (\<lambda>(\<phi>, P). (\<phi>, \<lparr>\<nu>x\<rparr>P)) Cs)"

Output:
using assms
by(metis bisimCasePushRes strongBisimWeakBisim)


Input:
lemma non_strict_constr_no_LTPP:
  assumes "nonstrict_constrs cs"
  shows "\<forall>x \<in> set cs. \<not>(\<exists>a b. LTPP a b = x)"

Output:
using assms nonstrict_constr.simps(9)
by blast


Input:
lemma SubobjsR_subclassRep:
  "Subobjs\<^sub>R P C Cs \<Longrightarrow> (C,last Cs) \<in> (subclsR P)\<^sup>*"

Output:
apply(erule Subobjs\<^sub>R.induct)
apply simp
apply(simp add: SubobjsR_nonempty) done


Input:
lemma same_level_path_aux_Append:
  "\<lbrakk>same_level_path_aux cs as; same_level_path_aux (upd_cs cs as) as'\<rbrakk>
  \<Longrightarrow> same_level_path_aux cs (as@as')"

Output: by(induct rule:slpa_induct,auto simp:intra_kind_def)


Input: lemma class_leq_refl[iff]: "class_ex cs c \<Longrightarrow> class_leq cs c c"

Output:
using wf
by (simp add: class_leq_def class_ex_def refl_on_def)


Input:
lemma min_gallery_least_length:
  assumes   "chamber C" "chamber D" "C\<noteq>D"
  defines   "Cs \<equiv> ARG_MIN length Cs. gallery (C#Cs@[D])"
  shows     "min_gallery (C#Cs@[D])"

Output:
unfolding Cs_def
using assms gallery_least_length
by (blast intro: min_galleryI_betw arg_min_nat_le)


Input: lemma remdups_clss_Nil_iff: "remdups_clss Cs = [] \<longleftrightarrow> Cs = []"

Output: by (cases Cs, simp, hypsubst, subst remdups_clss.simps(2), simp add: Let_def)


Input: lemma sort_eqv_trans: "sort_eqv cs x y \<Longrightarrow> sort_eqv cs y z \<Longrightarrow> sort_eqv cs x z"

Output:
using sort_eqv_def sort_leq_trans
by blast


Input:
lemma valid_path_aux_intra_path:
  "\<forall>a \<in> set as. intra_kind(kind a) \<Longrightarrow> valid_path_aux cs as"

Output: by(induct as,auto simp:intra_kind_def)


Input:
lemma presSwap_fromIMor[simp]:
"ipresCons h hA (fromMOD MOD) \<Longrightarrow> ipresSwap h (fromMOD MOD)
 \<Longrightarrow> presSwap (fromIMor h) MOD"

Output:
unfolding ipresSwap_def presSwap_def
by simp


Input:
lemma ipresIGFreshAll_termMOD[simp]:
"ipresIGFreshAll h hA termMOD MOD = ipresFreshAll h hA MOD"

Output:
unfolding ipresIGFreshAll_def ipresFreshAll_def
by simp


Input:
lemma fromIMor_termFSwSbMorph[simp]:
assumes "termFSwSbImorph h hA (fromMOD MOD)"
shows "termFSwSbMorph (fromIMor h) (fromIMorAbs hA) MOD"

Output:
using assms unfolding termFSwSbImorph_defs1
using assms unfolding termFSwSbImorph_def termFSwSbMorph_def
by simp


Input:
lemma errMOD_igWlsAbsDisj:
assumes "igWlsAbsDisj MOD"
shows "igWlsAbsDisj (errMOD MOD)"

Output:
using assms unfolding errMOD_def igWlsAbsDisj_def
apply clarify subgoal for _ _ _ _ A
by(cases A) fastforce+ .


Input:
lemma imp_igSubstInpIPresIGWlsInpSTR:
"igSubstIPresIGWlsSTR MOD \<Longrightarrow> igSubstInpIPresIGWlsInpSTR MOD"

Output: by(simp add: igSubstInpIPresIGWlsInpSTR_def igSubstIPresIGWlsSTR_def igSubstInp_def igWlsInp_def liftAll2_def lift_def sameDom_def split: option.splits) (smt option.distinct(1) option.exhaust)


Input:
lemma comp_ipresIGWlsAll:
assumes "ipresIGWlsAll h hA MOD MOD'" and "ipresIGWlsAll h' hA' MOD' MOD''"
shows "ipresIGWlsAll (h' o h) (hA' o hA) MOD MOD''"

Output:
using assms unfolding ipresIGWlsAll_def
using comp_ipresIGWls comp_ipresIGWlsAbs
by auto


Input:
lemma igFreshIGVar_fromMOD[simp]:
"gFreshGVar MOD \<Longrightarrow> igFreshIGVar (fromMOD MOD)"

Output:
unfolding igFreshIGVar_def gFreshGVar_def
by simp


Input:
lemma ipresCons_imp_ipresSubstAll:
assumes *: "ipresCons h hA MOD" and **: "igSubstCls MOD"
and "igConsIPresIGWls MOD" and "igFreshCls MOD"
shows "ipresSubstAll h hA MOD"

Output:
unfolding ipresSubstAll_def
using assms ipresCons_imp_ipresSubst ipresCons_imp_ipresSubstAbs
by auto


Input:
lemma igSubstAllIPresIGWlsAllSTR_imp_igSubstAllIPresIGWlsAll:
"igSubstAllIPresIGWlsAllSTR MOD \<Longrightarrow> igSubstAllIPresIGWlsAll MOD"

Output:
unfolding igSubstAllIPresIGWlsAllSTR_def igSubstAllIPresIGWlsAll_def
using igSubstIPresIGWlsSTR_imp_igSubstIPresIGWls igSubstAbsIPresIGWlsAbsSTR_imp_igSubstAbsIPresIGWlsAbs
by auto


Input:
theorem wlsFSwSb_recAll_unique_presCons:
assumes "wlsFSwSb MOD" and "presCons h hA MOD"
shows "(wls s X \<longrightarrow> h X = rec MOD X) \<and>
       (wlsAbs (us,s') A \<longrightarrow> hA A = recAbs MOD A)"

Output:
using assms wlsFSw_recAll_unique_presCons unfolding wlsFSwSb_def
by blast


Input:
lemma
  "(0::nat) mod 0 = 0"
  "(x::nat) mod 0 = x"
  "(0::nat) mod 1 = 0"
  "(1::nat) mod 1 = 0"
  "(3::nat) mod 1 = 0"
  "(x::nat) mod 1 = 0"
  "(0::nat) mod 3 = 0"
  "(1::nat) mod 3 = 1"
  "(3::nat) mod 3 = 0"
  "x mod 3 < 3"
  "(x mod 3 = x) = (x < 3)"

Output:
using [[z3_extensions]]
by smt+


Input:
lemma errMOD_igWlsAllDisj:
assumes "igWlsAllDisj MOD"
shows "igWlsAllDisj (errMOD MOD)"

Output:
using assms unfolding igWlsAllDisj_def
using errMOD_igWlsDisj errMOD_igWlsAbsDisj
by auto


Input:
lemma iwlsFSbSw_fromMOD[simp]:
"wlsFSbSw MOD \<Longrightarrow> iwlsFSbSw (fromMOD MOD)"

Output:
unfolding iwlsFSbSw_def wlsFSbSw_def
by simp


Input:
lemma sub_diff_mod_eq': "
  r \<le> t \<Longrightarrow> (k * m + t - (t - r) mod m) mod (m::nat) = r mod m"

Output:
apply (simp only: diff_mod_le[of t r m, THEN add_diff_assoc, symmetric])
apply (simp add: sub_diff_mod_eq) done


Input: lemma not_SN_onI[intro]: "f 0 \<in> X \<Longrightarrow> chain R f \<Longrightarrow> \<not> SN_on R X"

Output: by (unfold SN_on_def not_not, intro exI conjI)


Input:
lemma non_empty_cycle_root_loop_converse:
  assumes "non_empty_cycle_root r x"
    shows "r \<le> x\<^sup>+;r"

Output:
using assms less_eq_def non_empty_cycle_root_rtc_tc
by fastforce


Input: lemma "(0::real) < 1 + x\<^sup>2"

Output: by (sos "((R<1 + ((R<1 * (R<1 * [x]^2)) + ((A<=0 * R<1) * (R<1 * [1]^2)))))")


Input:
lemma oprod_Well_order:
assumes WELL: "Well_order r" and WELL': "Well_order r'"
shows "Well_order (r *o r')"

Output:
proof- have "Total r \<and> Total r'"
using WELL WELL'
by (auto simp add: order_on_defs) thus ?thesis
using assms unfolding well_order_on_def
using oprod_Linear_order oprod_wf_Id
by blast
qed


Input: lemma subset_AboveS_UnderS: "B \<le> Field r \<Longrightarrow> B \<le> AboveS r (UnderS r B)"

Output: by(auto simp add: AboveS_def UnderS_def)


Input: lemma per_add_exp: assumes "u \<le>p r\<^sup>\<omega>" and "m \<noteq> 0" shows "u \<le>p (r\<^sup>@m)\<^sup>\<omega>"

Output: using per_exp_pref[OF per_rootD, OF \<open>u \<le>p r\<^sup>\<omega>\<close>, of m] per_rootD'[OF \<open>u \<le>p r\<^sup>\<omega>\<close>, folded nonzero_pow_emp[OF \<open>m \<noteq> 0\<close>, of r]] unfolding period_root_def ..


Input:
lemma coprimeI:
    assumes "\<And>r. r dvd p \<Longrightarrow> r dvd q \<Longrightarrow> r dvd 1"
    shows "coprime p q"

Output:
using assms
by (auto simp: coprime_def')


Input:
lemma li_minus:
  assumes "locally_irrefl R A"
  shows "locally_irrefl R (A - B)"

Output:
using assms unfolding locally_irrefl_def
by (meson in_diffD)


Input:
lemma SN_on_Image_rtrancl_conv:
  "SN_on r A \<longleftrightarrow> SN_on r (r\<^sup>* `` A)" (is "?L \<longleftrightarrow> ?R")

Output:
proof assume ?L then show ?R
by (auto simp: SN_on_Image_rtrancl) next assume ?R then show ?L
by (auto simp: SN_on_def)
qed


Input: lemma oprod_Preorder: "\<lbrakk>Preorder r; Preorder r'; antisym r; antisym r'\<rbrakk> \<Longrightarrow> Preorder (r *o r')"

Output:
unfolding preorder_on_def
using oprod_Refl oprod_trans
by blast


Input:
lemma pj_invim_mono1:"\<lbrakk>Ring R; ideal R I; ideal (qring R I) J1;
      ideal (qring R I) J2; J1 \<subseteq> J2 \<rbrakk> \<Longrightarrow>
      (rInvim R (qring R I) (pj R I) J1) \<subseteq> (rInvim R (qring R I) (pj R I) J2)"

Output:
apply (rule subsetI)
apply (simp add:rInvim_def)
apply (simp add:subsetD) done


Input: lemma rrsmult_supp : "supp (r \<currency> f) \<subseteq> R"

Output:
using rightreg_scalar_multD2 suppD_contra
by force


Input:
lemma False_step_conc[iff]:
 "\<And>L R. (False#p,q) : step (conc L R) a =
       (\<exists>r. q = False#r \<and> (p,r) : step R a)"

Output:
apply (simp add:conc_def step_def)
apply blast done


Input: lemma r2f_ad_rel_hom: "\<F> (ad_rel R) = kad (\<F> R)"

Output: by (force simp add: kad_def ad_rel_def r2f_def fun_eq_iff)


Input:
lemma abs_trans[trans]:
  assumes A: "\<Up>R C \<le> B" and B: "\<Up>R' B \<le> A"
  shows "\<Up>R' (\<Up>R C) \<le> A"

Output:
using assms
by (fastforce simp: pw_le_iff refine_pw_simps)


Input:
lemma (in ring) carrier_is_subalgebra:
  assumes "K \<subseteq> carrier R" shows "subalgebra K (carrier R) R"

Output:
using assms subalgebra.intro[OF add.group_incl_imp_subgroup[of "carrier R"], of K] add.group_axioms unfolding subalgebra_axioms_def
by auto


Input: lemma (in domain) Units_mult_eq_Units [simp]: "Units (mult_of R) = Units R"

Output:
unfolding Units_def
using insert_Diff integral_iff
by auto


Input:
lemma toCard_pred_toCard:
  "\<lbrakk>|A| \<le>o r; Card_order r\<rbrakk> \<Longrightarrow> toCard_pred A r (toCard A r)"

Output:
unfolding toCard_def
using someI_ex[OF ex_toCard_pred] .


Input: lemma order_asym: "trans R \<Longrightarrow> asym R = irrefl R"

Output:
unfolding asym.simps irrefl_def trans_def
by meson


Input:
lemma runiq_wrt_ex1:
  "runiq R \<longleftrightarrow> (\<forall> a \<in> Domain R . \<exists>! b . (a, b) \<in> R)"

Output:
using runiq_basic
by (metis Domain.DomainI Domain.cases)


Input: lemma per_eq: "x \<le>p r\<^sup>\<omega> \<longleftrightarrow> (\<exists> k z. r\<^sup>@k\<cdot>z = x \<and> z \<le>p r) \<and> r \<noteq> \<epsilon>"

Output: using per_pref[unfolded pref_pow_conv] .


Input:
lemma rawpsubstT_atrm[simp,intro]:
assumes "r \<in> atrm" and "snd ` (set txs) \<subseteq> var" and "fst ` (set txs) \<subseteq> atrm"
shows "rawpsubstT r txs \<in> atrm"

Output:
using assms
by (induct txs arbitrary: r) auto


Input: lemma one_add_square_eq_0: "1 + (x)\<^sup>2 \<noteq> (0::real)"

Output: by (sos "((R<1 + (([~1] * A=0) + (R<1 * (R<1 * [x]^2)))))")


Input:
lemma good_ruleset_alt: "good_ruleset rs = (\<forall>r\<in>set rs. get_action r = Accept \<or> get_action r = Drop \<or>
                                                get_action r = Reject \<or> get_action r = Log  \<or> get_action r = Empty)"

Output:
unfolding good_ruleset_def
apply(rule Set.ball_cong)
apply(simp_all)
apply(rename_tac r)
by(case_tac "get_action r")(simp_all)


Input:
lemma divideR_right:
  fixes x y :: "'a::real_normed_vector"
  shows "r \<noteq> 0 \<Longrightarrow> y = x /\<^sub>R r \<longleftrightarrow> r *\<^sub>R y = x"

Output:
using scaleR_cancel_left[of r y "x /\<^sub>R r"]
by simp


Input:
lemma sup_refine[refine]:
  assumes "ai \<le>\<Down>R a"
  assumes "bi \<le>\<Down>R b"
  shows "sup ai bi \<le>\<Down>R (sup a b)"

Output:
using assms
by (auto simp: pw_le_iff refine_pw_simps)


Input: lemma order_less_trans: "\<lbrakk> order r; x \<sqsubset>\<^sub>r y; y \<sqsubset>\<^sub>r z \<rbrakk> \<Longrightarrow> x \<sqsubset>\<^sub>r z"

Output: by (unfold order_def lesssub_def) blast


Input:
lemma characteriseAx:
shows "r \<in> Ax \<Longrightarrow> r = ([],\<LM> ff \<RM> \<Rightarrow>* \<Empt>) \<or> (\<exists> i. r = ([], \<LM> At i \<RM> \<Rightarrow>* \<LM> At i \<RM>))"

Output:
apply (cases r)
by (rule Ax.cases) auto


Input:
lemma is_top_sorted_antimono:
  assumes "R\<subseteq>R'"
  assumes "is_top_sorted R' l"
  shows "is_top_sorted R l"

Output:
using assms unfolding is_top_sorted_alt
by (auto dest: rtrancl_mono_mp)


Input:
lemma D_inv: assumes "trans r" and "irrefl r" and "(r|\<tau>'| -s dl r \<sigma>,r|\<tau>| ) \<in> mul_eq r"
                                                and "(r|\<sigma>'| -s dl r \<tau>,r|\<sigma>| ) \<in> mul_eq r"
 shows "D r \<tau> \<sigma> \<sigma>' \<tau>'"

Output:
using assms unfolding D_def lemma3_2_2
using lemma2_6_6_a[OF assms(1)] union_commute
by metis


Input:
lemma connected_root_iff4:
  assumes "point r"
    shows "connected_root r x \<longleftrightarrow> 1;x = r\<^sup>T;x\<^sup>+"

Output: by (metis assms conv_contrav conv_invol conv_one star_conv star_slide_var connected_root_iff3)


Input: theorem per_pref: "x \<le>p r\<^sup>\<omega> \<longleftrightarrow> (\<exists> k. x \<le>p r\<^sup>@k) \<and> r \<noteq> \<epsilon>"

Output:
using per_pref_ex period_root_def pref_pow_ext' pref_prod_pref
by metis


Input:
lemma alpha_d_more_eqI:
  assumes "tr r = tr r'" "wait r = wait r'" "ref r = ref r'" "more r = more r'"
  shows "alpha_d.more r = alpha_d.more r'"

Output:
using assms
by (cases r, cases r') auto


Input:
lemma pred_resumption_antimono:
  assumes r: "pred_resumption A C r'"
  and le: "resumption_ord r r'"
  shows "pred_resumption A C r"

Output:
using r monotoneD[OF monotone_results le] monotoneD[OF monotone_outputs le]
by(auto simp add: pred_resumption_def)


Input:
lemma isLimOrd_succ:
assumes isLimOrd and "i \<in> Field r"
shows "succ i \<in> Field r"

Output:
using assms unfolding isLimOrd_def isSuccOrd_def
by (metis REFL in_notinI refl_on_domain succ_smallest)


Input: lemma eps_match: "eps test i r \<longleftrightarrow> match test r i i"

Output: by (induction r) (auto dest: antisym[OF match_le match_le])


Input:
lemma ltlr_expand_Release:
  "\<xi> \<Turnstile>\<^sub>r \<phi> R\<^sub>r \<psi> \<longleftrightarrow> (\<xi> \<Turnstile>\<^sub>r \<psi> and\<^sub>r (\<phi> or\<^sub>r (X\<^sub>r (\<phi> R\<^sub>r \<psi>))))"

Output: by (metis ltln_expand_Release ltlr_to_ltln.simps(5-7,9) ltlr_to_ltln_semantics)


Input:
lemma trans_llexord:
  "transp r \<Longrightarrow> transp (llexord r)"

Output: by(auto intro!: transpI elim: llexord_trans dest: transpD)


Input:
lemma pure_hn_refineI_no_asm:
  assumes "(c,a)\<in>R"
  shows "hn_refine emp (return c) emp (pure R) (RETURN a)"

Output:
unfolding hn_refine_def
using assms
by (sep_auto simp: pure_def)


Input:
lemma inverse_pow_pow:
  assumes "a \<in> carrier G"
  shows "inv (a [^] (r::nat)) = (inv a) [^] r"

Output:
proof - have "a [^] r \<in> carrier G"
using assms
by blast then show ?thesis
by (simp add: assms nat_pow_inv)
qed


Input:
theorem ACI_norm_final[simp]:
  "final \<guillemotleft>r\<guillemotright> = final r"

Output:
proof (induct r) case (Plus r1 r2) thus ?case
using toplevel_summands_final
by (auto simp: final_PLUS)
qed auto


Input: lemma lang_rexp_subst: "lang (rexp_subst f r) = subst_word f ` lang r"

Output: by (induction r) (simp_all add: image_Un)


Input: lemma hom_init: "hom_ab (init_a r) = init_b r"

Output:
unfolding init_a_def init_b_def hom_ab.simps
by (simp add: nonfinal_empty_mrexp)


Input:
lemma extended_Ax_prems_empty:
assumes "r \<in> Ax"
shows "fst (extendRule S r) = []"

Output:
using assms
apply (cases r)
by (rule Ax.cases) (auto simp add:extendRule_def)


Input:
lemma "(r 0 0 \<and> r 0 1 \<and> r 0 2 \<and> r 0 3) \<or>
       (r 1 0 \<and> r 1 1 \<and> r 1 2 \<and> r 1 3) \<or>
       (r 2 0 \<and> r 2 1 \<and> r 2 2 \<and> r 2 3) \<or>
       (r 3 0 \<and> r 3 1 \<and> r 3 2 \<and> r 3 3)"

Output: by (metis (full_types) rax)


Input:
lemma non_empty_cycle_root_msc_plus:
  assumes "non_empty_cycle_root r x"
    shows "x\<^sup>+;r = x\<^sup>T\<^sup>+;r"

Output:
using assms many_strongly_connected_iff_7 non_empty_cycle_root_msc
by fastforce


Input: lemma d_delta_lnexp_cf2_nonpos: "diff_delta_lnexp_cf2 x \<le> 0"

Output:
unfolding diff_delta_lnexp_cf2_def
by (sos "(((R<1 + ((R<1 * ((R<5/4 * [~3/40*x^2 + 1]^2) + (R<11/1280 * [x^2]^2))) + ((A<1 * R<1) * (R<1/64 * [1]^2))))) & ((R<1 + ((R<1 * ((R<5/4 * [~3/40*x^2 + 1]^2) + (R<11/1280 * [x^2]^2))) + ((A<1 * R<1) * (R<1/64 * [1]^2))))))")


Input: lemma lang_final: "final r = ([] \<in> lang n r)"

Output:
using concI[of "[]" _ "[]"]
by (induct r arbitrary: n) auto


Input: lemma in_rtrancl_insert: "x\<in>R\<^sup>* \<Longrightarrow> x\<in>(insert r R)\<^sup>*"

Output: by (metis in_mono rtrancl_mono subset_insertI)


Input: lemma RPDs_Star: "RPDs (MStar r) \<subseteq> {MStar r} \<union> MTimesL (MStar r) (RPDs r)"

Output:
unfolding RPDs_def
using RPDi_Star[OF order_refl, of _ r]
by (force simp: MTimesL_def)


Input: lemma simple_fw_alt: "simple_fw r p = simple_fw_alt r p"

Output: by(induction rule: simple_fw.induct) simp_all


Input:
lemma runit_commutes_with_R:
    assumes "ide f"
    shows "\<r>[R f] = R \<r>[f]"

Output:
unfolding runit_def
using assms PB.runit_commutes_with_R
by blast


Input: lemma pos_least: "shd (sdrop n rs) = r \<Longrightarrow> pos rs r \<le> n"

Output:
unfolding pos_def
by (metis (full_types) Least_le)


Input:
lemma msgs_mru_vote:
  assumes
  "\<mu> p \<in> get_msgs (send0 r) cfg (HOs r) (HOs r) p"
  shows "((msgs_to_lvs (\<mu> p)) |` HOs r p) = (mru_vote o cfg) |` HOs r p"

Output:
using assms
by(auto simp add: get_msgs_benign send0_def restrict_map_def msgs_to_lvs_def map_comp_def intro!: ext split: option.split)


Input: lemma strip_follow[simp]: "strip(follow m r) = strip r"

Output: by (induction r arbitrary: m) (auto split: if_splits)


Input:
lemma converse_Image:
  assumes runiq: "runiq R"
      and runiq_conv: "runiq (R^-1)"
  shows "(R^-1) `` R `` X \<subseteq> X"

Output:
using assms
by (metis converse_converse rightUniqueFunctionAfterInverse)


Input: lemma repL_geq:"repL w r \<Longrightarrow> r' \<ge> r \<Longrightarrow> repL w r'"

Output:
unfolding repL_def
using order_trans
by auto


Input:
lemma Card_order_Un1:
shows "Card_order r \<Longrightarrow> |Field r| \<le>o |(Field r) \<union> B| "

Output:
using card_of_Un1 card_of_Field_ordIso ordIso_symmetric ordIso_ordLeq_trans
by auto


Input: lemma Star_Star[simp]: "Star (Star r) = Star r"

Output: by (subst Star_unfoldL, coinduction arbitrary: r rule: language_coinduct_upto_regular) auto


Input:
lemma(in UP_cring) UP_car_memE:
  assumes "g \<in> carrier (UP R)"
  shows "\<And>x. g x \<in> carrier R"
        "\<And>x. x > (deg R g) \<Longrightarrow> g x = \<zero>"

Output:
using P_def assms UP_def[of R]
apply (simp add: mem_upD)
using assms UP_def[of R] up_def[of R]
by (smt R.ring_axioms UP_ring.deg_aboveD UP_ring.intro partial_object.select_convs(1) restrict_apply up_ring.simps(2))


Input: lemma pnorm_alt[symmetric]: "pnorm_alt r = pnorm r"

Output: by (induct r) (simp_all only: pnorm_alt.simps pnPlus_pnorm pnTimes_pnorm, auto simp: pnorm_def)


Input:
lemma mk_linear_orders_Linear_order:
  assumes "r \<in> mk_linear_orders C A"
  shows "Linear_order (linord_of_list r)"

Output:
using %invisible mk_linear_orders_distinct[OF assms(1)] linord_of_list_Linear_order
by fastforce


Input: lemma P2R_R2P[simp]: "P2R (R2P r) = r"

Output:
using Collect_mem_eq P2R_def R2P_P2R case_prod_curry
by metis


Input:
lemma trans_letter_less:
  assumes "trans r"
  shows "trans (letter_less r)"

Output:
using assms unfolding trans_def letter_less_def
by fast


Input:
lemma CR_onE:
  "CR_on r A \<Longrightarrow> a \<in> A \<Longrightarrow> ((b, c) \<in> join r \<Longrightarrow> P) \<Longrightarrow> ((a, b) \<notin> r\<^sup>* \<Longrightarrow> P) \<Longrightarrow> ((a, c) \<notin> r\<^sup>* \<Longrightarrow> P) \<Longrightarrow> P"

Output:
unfolding CR_defs
by blast


Input:
lemma run_stake:
      assumes "run r p"
      shows "path (stake k r) p"

Output:
using assms
by (metis run_shift_elim stake_sdrop)


Input: lemma order_refl [simp, intro]: "order r \<Longrightarrow> x \<sqsubseteq>\<^sub>r x"

Output: by (unfold order_def) (simp (no_asm_simp))


Input:
theorem (in domain) eval_cring_hom:
  assumes "subring K R" and "a \<in> carrier R"
  shows "ring_hom_cring (K[X]) R (\<lambda>p. (eval p) a)"

Output:
unfolding ring_hom_cring_def ring_hom_cring_axioms_def
using domain.axioms(1)[OF univ_poly_is_domain[OF assms(1)]] eval_is_hom[OF assms] cring_axioms
by auto


Input:
lemma \<R>\<^sub>1_weak_bisim:
  "weak_bisim (\<R>\<^sub>1 \<Gamma>') (\<R> \<Gamma>')"

Output:
unfolding weak_bisim_def
using \<R>\<^sub>1_elim \<R>_typed_step
by auto


Input:
lemma rtrancl_Image_eq:
  assumes "r = set r'" and "x = set x'"
  shows "r\<^sup>* `` x = set (rtrancl_list_impl r' x')"

Output:
using assms
by (auto simp: rtrancl_list_impl)


Input: lemma "(x::real) \<ge> 1 \<and> y \<ge> 1 \<longrightarrow> x * y \<ge> x + y - 1"

Output: by (sos "(((A<0 * R<1) + ((A<=0 * (A<=1 * R<1)) * (R<1 * [1]^2))))")


Input:
lemma antisym_order_consistent_self:
  "antisym r \<Longrightarrow> order_consistent r r"

Output: by(auto simp add: order_consistent_def dest: antisymD)


Input: lemma is_rbt_rec [forward]: "is_rbt (Node l c k v r) \<Longrightarrow> is_rbt l \<and> is_rbt r"

Output: @proof @case "c = R" @qed


Input:
lemma greatest_r_mono:
  assumes "Above r X \<subseteq> Above r' X"
  shows "greatest r X \<subseteq> greatest r' X"

Output:
using assms unfolding greatest_def Above_def
by (fast intro: FieldI1)


Input:
lemma Length_Extend[simp]:
  "Length (Extend k i \<AA> P) = max (Length \<AA>) (if P = {||} then 0 else Suc (fMax P))"

Output:
unfolding max_def
by (split if_splits, transfer) (force split: order.splits)


Input:
lemma abs_fresh_set_star:
  fixes X :: "name set"
  and   a :: name
  and   P :: "'a::fs_name"

  shows "(X \<sharp>* [a].P) = (X - {a}) \<sharp>* P"

Output: by(auto simp add: fresh_star_def abs_fresh)


Input: lemma cond_spmf_cong: "cond_spmf p A = cond_spmf p B" if "A \<inter> set_spmf p = B \<inter> set_spmf p"

Output:
apply(rule spmf_eqI)
using that
by(auto simp add: measure_spmf_zero_iff spmf_eq_0_set_spmf measure_spmf_cong[OF that])


Input:
lemma resOutputTauTrans[dest]:
  fixes x  :: name
  and   a  :: name
  and   b  :: name
  and   P  :: pi
  and   P' :: pi

  assumes "<\<nu>x>a{b}.P \<longmapsto>\<tau> \<prec> P'"

  shows False

Output:
using assms
by - (ind_cases "<\<nu>x>a{b}.P \<longmapsto>\<tau> \<prec> P'", auto simp add: residualInject pi.inject alpha')


Input:
lemma Seq_decomp_Throw[rule_format, OF _ refl, OF _ refl] :
"\<Gamma> \<turnstile> (p, s) \<rightarrow> (p', s') \<Longrightarrow>
 \<forall>p\<^sub>2 z. s = Normal z \<longrightarrow> p = Seq Throw p\<^sub>2 \<longrightarrow> s' = s \<and> p' = Throw"

Output:
apply(erule step_induct, simp_all)
apply clarsimp
apply(erule step.cases, simp_all) done


Input: lemma path_inv_Branching_Left: "path (Left#p) (Branching l r) \<longleftrightarrow> path p l"

Output:
using Left_def Right_def path.cases
by (induction p) auto


Input:
lemma weakBisimSubstParNil:
  fixes \<Psi> :: 'b
  and   P :: "('a, 'b, 'c) psi"

  shows "\<Psi> \<rhd> P \<parallel> \<zero> \<approx>\<^sub>s P"

Output: by(metis strongBisimSubstWeakBisimSubst bisimSubstParNil)


Input:
lemma prime_factorization_unique_nat:
  fixes f :: "nat \<Rightarrow> _"
  assumes S_eq: "S = {p. 0 < f p}"
    and "finite S"
    and S: "\<forall>p\<in>S. prime p" "n = (\<Prod>p\<in>S. p ^ f p)"
  shows "S = prime_factors n \<and> (\<forall>p. prime p \<longrightarrow> f p = multiplicity p n)"

Output:
using assms
by (intro prime_factorization_unique'') auto


Input: lemma action_loc_aux_compP [simp]: "action_loc_aux (compP f P) = action_loc_aux P"

Output: by(auto 4 4 elim!: action_loc_aux_cases)


Input: lemma infinity_evalUni_EqUni : "(\<exists>x. \<forall>y<x. aEvalUni (EqUni p) y) = (evalUni (substNegInfinityUni (EqUni p)) x)"

Output:
proof(cases p) case (fields a b c) show ?thesis
using infzeros[of _ a b c]
by(auto simp add: fields)
qed


Input:
lemma prime_elem_dvd_power:
  "prime_elem p \<Longrightarrow> p dvd x ^ n \<Longrightarrow> p dvd x"

Output: by (induction n) (auto dest: prime_elem_dvd_multD intro: dvd_trans[of _ 1])


Input: lemma poly_subst: "eval_poly \<alpha> (poly_subst \<sigma> p) = eval_poly (\<lambda> v. eval_poly \<alpha> (\<sigma> v)) p"

Output: by (induct p, simp add: zero_poly_def, auto simp: field_simps)


Input:
lemma inclosed_closed [intro]:
  assumes cinv: "opnet np p \<Turnstile> (otherwith ((=)) (net_tree_ips p) inoclosed, U \<rightarrow>) P"
    shows "oclosed (opnet np p) \<Turnstile> (\<lambda>_ _ _. True, U \<rightarrow>) P"

Output:
using assms unfolding oinvariant_def
by (clarsimp dest!: oclosed_oreachable_inclosed)


Input: lemma partition_on_mset_sum_size_eq: "partition_on_mset A P \<Longrightarrow> (\<Sum>x \<in># P. size x) = size A"

Output: by (metis partition_on_msetD1 size_big_union_sum)


Input:
lemma \<beta>_numbound0: assumes lp: "iszlfm p bs"
  shows "\<forall> b\<in> set (\<beta> p). numbound0 b"

Output:
using lp
by (induct p rule: \<beta>.induct,auto)


Input: lemma simpfm[simp]: "Ifm vs bs (simpfm p) = Ifm vs bs p"

Output: by (induct p arbitrary: bs rule: simpfm.induct) auto


Input:
lemma match_vars:
  assumes "\<turnstile> p \<rhd> t \<Rightarrow> \<theta>" and "x \<in> supp p"
  shows "x \<in> set (map fst \<theta>)"

Output:
using assms
by induct (auto simp add: supp_atm)


Input:
lemma l10_5:
  assumes "P' P Reflect A B" and
    "P'' P' Reflect A B"
  shows "P = P''"

Output: by (meson assms(1) assms(2) l10_2_uniqueness l10_4)


Input:
lemma UP_one_not_zero:
  "\<one>\<^bsub>P\<^esub> \<noteq> \<zero>\<^bsub>P\<^esub>"

Output:
proof assume "\<one>\<^bsub>P\<^esub> = \<zero>\<^bsub>P\<^esub>" hence "coeff P \<one>\<^bsub>P\<^esub> 0 = (coeff P \<zero>\<^bsub>P\<^esub> 0)"
by simp hence "\<one> = \<zero>"
by simp with R.one_not_zero show "False"
by contradiction
qed


Input:
lemma Some_OptionOverride [simp]:
   "(fst P) \<noteq> None \<Longrightarrow> OptionOverride P = the (fst P)"

Output:
apply (unfold OptionOverride_def)
apply auto done


Input:
lemma map_poly_of_real_Re: assumes "set (coeffs p) \<subseteq> \<real>"
  shows "map_poly of_real (map_poly Re p) = p"

Output: by (subst map_poly_map_poly, force+, rule map_poly_idI, insert assms, auto)


Input:
lemma af_trans_imp_wf:
  assumes "almost_full_on P A"
    and "transp_on P A"
  shows "wfp_on (strict P) A"

Output:
using assms
by (intro af_trans_extension_imp_wf)


Input:
lemma vwalk_join_hd':
  assumes "p \<noteq> []"
  shows "hd (p \<oplus> q) = hd p"

Output:
using assms
by (auto simp add: vwalk_join_def)


Input:
lemma (in comm_ring_hom) synthetic_div_hom:
  "synthetic_div (map_poly hom p) (hom x) = map_poly hom (synthetic_div p x)"

Output: by (induction p) (auto simp: map_poly_pCons_hom)


Input:
lemma preserves_import_circ:
  "preserves x (-p) \<Longrightarrow> -p * x\<^sup>\<circ> = -p * (-p * x)\<^sup>\<circ>"

Output:
using import_test preserves_def
by blast


Input:
lemma pickT_shift[simp]:
assumes "II \<in> UNpart cl P"
shows "II \<in> shift cl (pickT cl P II) ` (P (pickT cl P II))"

Output:
using assms pickT_pred_pickT unfolding pickT_pred_def
by auto


Input: lemma spmf_of_pmf_bind: "spmf_of_pmf (bind_pmf p f) = bind_pmf p (\<lambda>x. spmf_of_pmf (f x))"

Output: by(simp add: spmf_of_pmf_def map_bind_pmf)


Input:
lemma matchIdLeft:
  fixes a   :: name
  and   P   :: pi
  and   Rel :: "(pi \<times> pi) set"

  assumes "Id \<subseteq> Rel"

  shows "[a\<frown>a]P \<leadsto>[Rel] P"

Output:
using assms
by(force simp add: simulation_def dest: Match derivativeReflexive)


Input:
lemma induct_list012:
  "\<lbrakk>P []; \<And>x. P [x]; \<And>x y zs. \<lbrakk> P zs; P (y # zs) \<rbrakk> \<Longrightarrow> P (x # y # zs)\<rbrakk> \<Longrightarrow> P xs"

Output: by induction_schema (pat_completeness, lexicographic_order)


Input:
lemma univariate_mpoly_roots_finite:
fixes p::"'a::idom mpoly"
assumes "vars p \<subseteq> {v}" "p \<noteq> 0"
shows "finite {x. insertion (\<lambda>v. x) p = 0}"

Output:
using poly_roots_finite[of "mpoly_to_poly v p", unfolded poly_eq_insertion[OF \<open>vars p \<subseteq> {v}\<close>]]
using assms(1) assms(2) mpoly_to_poly_inverse poly_to_mpoly0
by fastforce


Input:
lemma subsetClosed'[simp]:
  fixes p    :: "name prm"
  and   xvec :: "name list"
  and   P    :: "'a::fs_name"

  shows "(set (p \<bullet> xvec) \<subseteq> supp (p \<bullet> P)) = (set xvec \<subseteq> supp P)"

Output: by(simp add: eqvts[THEN sym])


Input: lemma scount_finite: "ev (alw (not P)) \<omega> \<Longrightarrow> scount P \<omega> < \<infinity>"

Output:
using scount_eq_card[of P \<omega>]
by auto


Input: lemma SCrd[rule_format,simp]:"singleCombinators p\<longrightarrow> singleCombinators(remdups p)"

Output:
apply (induct p, simp_all) subgoal for a p
apply (case_tac a, simp_all) done done


Input: lemma perm_exits_Vs: "i \<in> Vs \<Longrightarrow> (p \<bullet> i) \<notin> Vs"

Output: by (metis Vs fresh_finite_set_at_base imageI fresh_star_def mem_permute_iff p)


Input:
lemma reflexive:
  fixes P :: pi

  shows "P \<approx> P"

Output:
proof - have "(P, P) \<in> Id"
by simp thus ?thesis
by(coinduct rule: weakBisimCoinduct) (auto intro: Weak_Early_Sim.reflexive)
qed


Input:
lemma sees_field_is_type:
  "\<lbrakk> P \<turnstile> C sees F:T (fm) in D; wf_prog wf_md P \<rbrakk> \<Longrightarrow> is_type P T"

Output: by(fastforce simp: sees_field_def elim: has_fields_types map_of_SomeD[OF map_of_remap_SomeD])


Input: lemma S_satisfies_eqvt: assumes "P \<turnstile>\<^sub>S \<phi>" shows "(p \<bullet> P) \<turnstile>\<^sub>S (p \<bullet> \<phi>)"

Output:
using assms
by (simp add: S_satisfies_def)


Input:
lemma match_list_None_conv:
  "match_list d P = None \<longleftrightarrow> matchers (set P) = {}"

Output:
using match_list_sound [of d P] and match_list_complete [of d P]
by (metis empty_iff not_None_eq)


Input: lemma fmdrop_eqvt: "p \<bullet> fmdrop x F = fmdrop (p \<bullet> x) (p \<bullet> F)"

Output: by transfer (auto simp: map_drop_def map_filter_def)


Input:
lemma fglr_aux1:
    assumes V: "(v',v)\<in>Id" and S: "(s',s)\<in>gstate_rel"
      and P: "\<And>a' p' D' pE' p D pE. ((a',p',D',pE'),(p,D,pE))\<in>gstate_rel
      \<Longrightarrow> f' a' p' D' pE' \<le>\<Down>R (f p D pE)"
    shows "(let (a',p',D',pE') = gcollapse v' s' in f' a' p' D' pE')
      \<le> \<Down>R (let (p,D,pE) = collapse v s in f p D pE)"

Output:
apply (auto split: prod.splits)
apply (rule P)
using gcollapse_refine[OF V S]
apply simp done


Input:
lemma
  "\<lbrakk> Q2 (val h p); (K ** T ** blub ** P ** points_to p v ** P ** J) h \<rbrakk>
   \<Longrightarrow> Q (val h p) (val h p)"

Output:
apply (sep_frule points_to)
apply simp oops


Input:
lemma powr_ln_powr_lower_bound:
  "a > 1 \<Longrightarrow> a \<le> x \<Longrightarrow> x \<le> b \<Longrightarrow>
     min (a powr p) (b powr p) * min (ln a powr p') (ln b powr p') \<le> x powr p * ln x powr p'"

Output: by (intro mult_mono powr_lower_bound) (auto intro: min.coboundedI1)


Input:
lemma external_actions_committed_compP [simp]:
  "external_actions_committed (compP f P) = external_actions_committed P"

Output: by(simp add: fun_eq_iff external_actions_committed_def)


Input:
lemma matrix_equation_main_step:
  fixes p:: "real poly"
  fixes qs:: "real poly list"
  fixes I:: "nat list"
  fixes signs:: "rat list list"
  assumes nonzero: "p\<noteq>0"
  assumes distinct_signs: "distinct signs"
  assumes all_info: "set (characterize_consistent_signs_at_roots_copr p qs) \<subseteq> set(signs)"
  assumes welldefined: "list_constr I (length qs)"
  assumes pairwise_rel_prime_1: "\<forall>q. ((List.member qs q) \<longrightarrow> (coprime p q))"
  shows "(vec_of_list (mtx_row signs I) \<bullet> (construct_lhs_vector p qs signs)) =
    construct_NofI p (retrieve_polys qs I)"

Output:
unfolding construct_NofI_prop[OF nonzero]
using matrix_equation_helper_step[OF assms]
by linarith


Input:
lemma check_prime_factors_subset_Cons [simp]:
  "check_prime_factors_subset (Suc 0) (p # ps) \<longleftrightarrow> check_prime_factors_subset (Suc 0) ps"
  "check_prime_factors_subset 1 (p # ps) \<longleftrightarrow> check_prime_factors_subset 1 ps"
  "p > 1 \<Longrightarrow> p dvd numeral n \<Longrightarrow> check_prime_factors_subset (numeral n) (p # ps) \<longleftrightarrow>
                           check_prime_factors_subset (numeral n div p) (p # ps)"
  "p \<le> 1 \<or> \<not>p dvd numeral n \<Longrightarrow> check_prime_factors_subset (numeral n) (p # ps) \<longleftrightarrow>
                           check_prime_factors_subset (numeral n) ps"

Output: by (subst check_prime_factors_subset.simps; force)+


Input:
lemma simActFreeCases[consumes 0, case_names Free]:
  fixes P   :: pi
  and   \<alpha>   :: freeRes
  and   C   :: "'a::fs_name"
  and   Rel :: "(pi \<times> pi) set"

  assumes Der: "\<exists>P'. (P \<Longrightarrow>\<^sub>l\<alpha> \<prec> P') \<and> (P', Q') \<in> Rel"

  shows "weakStepSimAct P (\<alpha> \<prec> Q') P Rel"

Output:
using assms
by(simp add: weakStepSimAct_def residual.inject)


Input:
lemma reflexive:
  fixes P :: pi

  shows "P \<sim>\<^sup>s P"

Output: by(force simp add: substClosed_def intro: Strong_Late_Bisim.reflexive)


Input:
lemma path_conforms_with_strategy_irrelevant:
  assumes "path_conforms_with_strategy p P \<sigma>" "v \<notin> lset P"
  shows "path_conforms_with_strategy p P (\<sigma>(v := w))"

Output:
using assms
apply (coinduction arbitrary: P)
by (drule path_conforms_with_strategy.cases) auto


Input:
lemma rewrite_sum_of_powers:
  assumes p: "(p::nat)>1"
  shows "\<Sum> ((^) p ` {0..n}) = (\<Sum> i = 0 .. n . p^i)" (is "?l = ?r")

Output: by (metis inj_on_def p power_inject_exp sum.reindex_cong)


Input: lemma head_head[simp]: "isnpolyh p n0 \<Longrightarrow> head (head p) = head p"

Output: by (induct p rule: head.induct) auto


Input: lemma match_list_append: "match_list \<gamma> (m1@m2) a p \<longleftrightarrow> (\<not> match_list \<gamma> m1 a p \<longrightarrow> match_list \<gamma> m2 a p)"

Output: by(induction m1) simp+


Input:
lemma RBT_Impl_rbt_all_simps [simp, code]:
  "RBT_Impl_rbt_all P rbt.Empty \<longleftrightarrow> True"
  "RBT_Impl_rbt_all P (Branch c l k v r) \<longleftrightarrow> P k v \<and> RBT_Impl_rbt_all P l \<and> RBT_Impl_rbt_all P r"

Output: by(auto simp add: RBT_Impl_rbt_all_def)


Input:
lemma pac_idealI1[intro]:
  \<open>p \<in> A \<Longrightarrow> p \<in> pac_ideal A\<close>

Output:
unfolding pac_ideal_def
by (auto intro: ideal.span_base)


Input:
lemma weight_sample_uniform_units:
  assumes "(p::nat) > 1"
  shows "weight_spmf (sample_uniform_units p) = 1"

Output:
using assms lossless_sample_uniform_units
by (simp add: lossless_weight_spmfD)


Input:
lemma sign_changes_cong':
  assumes "\<forall>p \<in> set ps. sgn (poly p x) = sgn (poly p y)"
  shows "sign_changes ps x = sign_changes ps y"

Output:
using assms
by (intro sign_changes_cong, simp_all)


Input:
lemma auto_weaken_pre_init_hf:
    assumes "\<And>x. PROTECT P x \<longrightarrow> P' x"
    assumes "(f,h) \<in> hfref P' R S"
    shows "(f,h) \<in> hfref P R S"

Output:
using assms
by (auto simp: hfref_def)


Input: lemma child_other: "d \<noteq> d' \<Longrightarrow> child p dir d ! d' = p ! d'"

Output:
unfolding child_def lv_def ix_def
by (cases "d' < length p", auto)


Input:
lemma new_omit_branch:
  assumes \<open>new p a branch\<close>
  shows \<open>new p a (omit_branch xs branch)\<close>

Output:
using assms omit_branch_mem_dual unfolding new_def
by fast


Input:
lemma poly_y_x_poly_lift:
  fixes p :: "'a :: comm_monoid_add poly"
  shows "poly_y_x (poly_lift p) = [:p:]"

Output:
apply(subst poly_y_x_fix_y_deg[of _ 0],force)
apply(subst(10) poly_as_sum_of_monoms[symmetric])
by (auto simp add: monom_sum monom_0 hom_distribs)


Input:
lemma inputBoundOutputTrans[dest]:
  fixes a  :: name
  and   x  :: name
  and   P  :: pi
  and   b  :: name
  and   y  :: name
  and   P' :: pi

  assumes "a<x>.P \<longmapsto>b<\<nu>y> \<prec> P'"

  shows False

Output:
using assms
by - (ind_cases "a<x>.P \<longmapsto>b<\<nu>y> \<prec> P'", auto simp add: residualInject)


Input:
lemma merge_simps [simp]:
  "merge qs [] = qs"
  "merge qs (p#ps) = update (fst p) (snd p) (merge qs ps)"

Output: by (simp_all add: merge_def split_def)


Input:
lemma filter_eq_Cons_iff:
  "(filter P ys = x#xs) =
  (\<exists>us vs. ys = us @ x # vs \<and> (\<forall>u\<in>set us. \<not> P u) \<and> P x \<and> xs = filter P vs)"

Output: by(auto dest:filter_eq_ConsD)


Input:
lemma last_smods_nzero:
  assumes "p\<noteq>0"
  shows "last (smods p q) \<noteq>0"

Output: by (metis assms last_in_set no_0_in_smods smods_nil_eq)


Input:
lemma WT1_not_contains_insync: "P,E \<turnstile>1 e :: T \<Longrightarrow> \<not> contains_insync e"
  and WTs1_not_contains_insyncs: "P,E \<turnstile>1 es [::] Ts \<Longrightarrow> \<not> contains_insyncs es"

Output: by(induct rule: WT1_WTs1.inducts) auto


Input:
lemma inputChainFresh:
  fixes x    :: name
  and   xvec :: "name list"
  and   N    :: "'a::fs_name"
  and   P    :: "('a, 'b::fs_name, 'c::fs_name) psi"

  shows "x \<sharp> (inputChain xvec N P) = (x \<in> set xvec \<or> (x \<sharp> N \<and> x \<sharp> P))"

Output: by (induct xvec) (simp_all add: abs_fresh)


Input:
lemma WhileInt [intro?]:
    "\<Gamma>,\<Theta>\<turnstile>\<^bsub>/F\<^esub> (P \<inter> b) c P,A
    \<Longrightarrow>
    \<Gamma>,\<Theta>\<turnstile>\<^bsub>/F\<^esub> P (whileAnno b {s. undefined} V c) (P \<inter> -b),A"

Output: by (unfold whileAnno_def) (rule HoarePartialDef.While [THEN conseqPrePost],auto)


Input: lemma Process_spec: "Abs_process((F P , D P)) = P"

Output: by(simp add: F_def FAILURES_def D_def DIVERGENCES_def Rep_process_inverse)


Input:
lemma singular_relboundary_alt:
   "singular_relboundary p X S c \<longleftrightarrow>
    (\<exists>d e. singular_chain (Suc p) X d \<and> singular_chain p (subtopology X S) e \<and>
           chain_boundary (Suc p) d = c + e)"

Output:
unfolding singular_relboundary_def mod_subset_def
by fastforce


Input:
lemma deg_leE:
  assumes "p \<in> carrier P"
  assumes "degree p < k"
  shows "p k = \<zero>"

Output:
using assms coeff_of_sum_diff_degree0 P_def coeff_simp deg_aboveD
by auto


Input:
lemma
"generalized_sfw [] p = None"
"generalized_sfw (a # as) p = (if (case a of (m,_) \<Rightarrow> simple_matches m p) then Some a else generalized_sfw as p)"

Output: by(fact generalized_sfw_simps)+


Input: lemma nonterminating_implies_div_free: "non_terminating P \<Longrightarrow> D P = {}"

Output:
unfolding non_terminating_is_right
by (metis NT_ND equals0I front_tickFree_charn process_charn tickFree_Cons tickFree_append)


Input:
lemma hyp2_S_z_non_zero:
  assumes "p \<in> hyp2 \<union> S"
  shows "z_non_zero p"

Output:
proof - from \<open>p \<in> hyp2 \<union> S\<close> have "conic_sgn p \<le> 0"
by (unfold K2_def S_def) auto hence "conic_sgn p \<noteq> 1"
by simp thus "z_non_zero p"
by (rule conic_sgn_not_1_z_non_zero)
qed


Input: lemma wf_bs_I: "wf_bs bs p \<Longrightarrow> Ipoly (bs @ bs') p = Ipoly bs p"

Output: by (induct p) (auto simp add: nth_append wf_bs_def)


Input:
lemma cs_rep_apply[simp]:
    assumes "p \<in> dom f"
    shows "fst (the (cs_rep (f, P) p)) = the (f p)"

Output:
using assms unfolding cs_rep_def
by auto


Input:
lemma croots: assumes "p \<noteq> 0" "degree p \<le> 2"
  shows "set (croots p) = {x. poly p x = 0}"

Output:
using assms unfolding croots_def
using roots0[of p] roots1[of p] croots2[of p]
by (auto split: if_splits)


Input:
lemma bpE:
  assumes "bp P"
  shows "pairwise disjnt P" "{} \<notin> P" "\<Union>P = U" "\<forall>B \<in> P. W(B) \<le> c"

Output:
using assms unfolding bp_def partition_on_def
by blast+


Input:
lemma tauTransitionChain:
  fixes P  :: pi
  and   P' :: pi

  assumes "P \<Longrightarrow>\<^sub>l\<^sup>^\<tau> \<prec> P'"

  shows "P \<Longrightarrow>\<^sub>\<tau> P'"

Output:
using assms
by(auto intro: Weak_Late_Step_Semantics.tauTransitionChain simp add: weakTransition_def residual.inject transition_def)


Input: lemma is_process3_S_pref: "\<lbrakk>is_process P; (t, {}) \<in> FAILURES P; s \<le> t\<rbrakk> \<Longrightarrow> (s, {}) \<in> FAILURES P"

Output: by(auto simp: le_list_def intro: is_process3 [rule_format])


Input:
lemma least_power_of_permutation:
  assumes "permutation p" shows "(p ^^ (least_power p a)) a = a" and "least_power p a > 0"

Output:
using permutation_is_nilpotent[OF assms] least_powerI
by (metis id_apply)+


Input: lemma iso_point_subset_block_iff: "p \<subseteq> \<V> \<Longrightarrow> bl \<in># \<B> \<Longrightarrow> p \<subseteq> bl \<longleftrightarrow> (\<pi> ` p) \<subseteq> (\<pi> ` bl)"

Output:
apply auto
using image_subset_iff iso_point_in_block_img_iff subset_iff
by metis


Input:
lemma LocalSecretsComposition_neg_loc_k:
assumes "kKS key \<notin> LocalSecrets P"
       and "exprChannel ch (kE key)"
       and "kKS key \<notin> specKeysSecrets P"
shows    "ch \<notin> loc P"

Output:
using assms
by (simp only: LocalSecretsDef, auto)


Input:
lemma (in PolynRg) pol_SOME_1:"p \<in> carrier R  \<Longrightarrow>
             cf_sol R S X p (SOME f. cf_sol R S X p f)"

Output:
apply (frule ex_cf_sol[of p])
apply (rule_tac P = "cf_sol R S X p" in someI_ex, assumption) done


Input: lemma gen_lossless_gpv_lift_spmf [iff]: "gen_lossless_gpv (lift_spmf p) \<longleftrightarrow> lossless_spmf p"

Output: by(auto dest: gen_lossless_gpvD intro: gen_lossless_gpvI)


Input:
lemma bounded_bdd_above[intro]:
  assumes bP: "bounded P"
  shows "bdd_above (range P)"

Output:
proof fix x assume "x \<in> range P" with bP show "x \<le> Inf {b. bounded_by b P}" unfolding bounded_def
by(auto intro:cInf_greatest)
qed


Input: lemma invoke_empty_reads [simp]: "\<forall>P \<in> S. reflp P \<and> transp P \<Longrightarrow> reads S (invoke [] ptr args) h h'"

Output:
apply(simp add: invoke_def reads_def preserved_def)
by (meson bind_returns_result_E error_returns_result)


Input: lemma ex1_iff_Collect_singleton: "P x \<Longrightarrow> (\<exists>!x. P x) \<longleftrightarrow> Collect P = {x}"

Output: by (subst ex1_imp_Collect_singleton[symmetric], auto)


Input:
lemma insert_eqvt:
  shows "p \<bullet> (insert x A) = insert (p \<bullet> x) (p \<bullet> A)"

Output: unfolding permute_set_eq_image image_insert ..


Input: lemma pmf_prob_compl: "pmf_prob p (-A) = 1 - pmf_prob p A"

Output:
using measure_pmf.prob_compl[of A p]
by (simp add: pmf_prob_def Compl_eq_Diff_UNIV)


Input:
lemma index_one_alt_bl_not_exist:
  assumes "\<Lambda> = 1" and " blv \<in># \<B>" and "p \<subseteq> blv" and "card p = 2"
  shows" \<And> bl. bl \<in># remove1_mset blv \<B> \<Longrightarrow> \<not> (p \<subseteq> bl) "

Output:
using index_one_empty_rm_blv
by (metis assms(1) assms(2) assms(3) assms(4) filter_mset_empty_conv)


Input:
lemma no_end_point_char_converse:
  assumes "point p"
    shows "x;p \<noteq> 0 \<longleftrightarrow> p \<le> x\<^sup>T;1"

Output:
using assms no_end_point_char
by force


Input:
lemma nodes_states:
      assumes "p \<in> nodes" "path r p"
      shows "set (states r p) \<subseteq> nodes"

Output:
using reachable_states assms
by blast


Input:
lemma is_process5_S:
"\<lbrakk>is_process P; (sa, X) \<in> FAILURES P; \<forall>c. c \<in> Y \<longrightarrow> (sa @ [c], {}) \<notin> FAILURES P\<rbrakk> \<Longrightarrow> (sa, X \<union> Y) \<in> FAILURES P"

Output: by(drule is_process5, metis)


Input: lemma shift1_isnpolyh: "isnpolyh p n0 \<Longrightarrow> p \<noteq> 0\<^sub>p \<Longrightarrow> isnpolyh (shift1 p) 0"

Output:
using isnpolyh_mono[where n="n0" and n'="0" and p="p"]
by (simp add: shift1_def)


Input: lemma proj_undefined[simp, intro]: "i \<notin> domain P \<Longrightarrow> P i = undefined"

Output:
using extensional_proj[of P] unfolding extensional_def
by auto


Input:
lemma ine_nonempty_exprChannelSet:
assumes "ine_exprChannelSet P ChSet E"
       and "ChSet \<noteq> {}"
shows    "ine P E "

Output:
using assms
by (simp add: ine_def ine_exprChannelSet_def, auto)


Input:
lemma l7_17_bis:
  assumes "A Midpoint P P'" and
    "B Midpoint P' P"
  shows "A = B"

Output: by (meson Tarski_neutral_dimensionless.l7_17 Tarski_neutral_dimensionless.l7_2 Tarski_neutral_dimensionless_axioms assms(1) assms(2))


Input:
lemma not_knows_conc_knows_elem_not_knows_tail:
assumes "\<not> knows P (a # e)"
       and "knows P [a]"
shows "\<not> knows P e"

Output:
using assms
by (metis knows_concat_3)


Input:
lemma singleActionChain:
  fixes P  :: pi
  and   \<alpha>  :: freeRes
  and   P' :: pi

  assumes "P \<longmapsto>\<alpha> \<prec> P'"

  shows "P \<Longrightarrow>\<^sub>l\<^sup>^(\<alpha> \<prec> P')"

Output:
using assms
by(auto intro: Weak_Late_Step_Semantics.singleActionChain simp add: weakTransition_def)


Input: lemma finite_llast_V [simp]: "lfinite P \<Longrightarrow> llast P \<in> V"

Output:
using P_not_None lfinite_lset lset_P_V
by blast


Input: lemma wf_nabla_aux: "(P \<subseteq> (converse R) `` P \<longrightarrow> P = {}) \<longleftrightarrow> (s2r P \<subseteq> relfdia R (s2r P) \<longrightarrow> s2r P = {})"

Output:
apply (standard, metis Domain_Id_on Domain_mono Id_on_empty fdia_rel_im1)
using fdia_rel_im1
by fastforce


Input:
lemma Bernstein_coeffs_01_smult:
  assumes "degree P \<le> p"
  shows "nth_default 0 (Bernstein_coeffs_01 p (smult a P)) i =
          a * nth_default 0 (Bernstein_coeffs_01 p P) i"

Output:
using assms
by (auto simp: nth_default_Bernstein_coeffs_01 reciprocal_smult pcompose_smult)


Input:
theorem
fixes
  p :: "(32, 'a) simple_packet_ext_scheme"
assumes
  "p_iiface p \<in> set ifs" and "p_l2type p = 0x800"
  "lr_of_tran rt fw ifs = Inr oft"
shows
  "OF_priority_match OF_match_fields_safe oft p = Action [Forward oif] \<longleftrightarrow> simple_linux_router_nol12 rt fw p = (Some (p\<lparr>p_oiface := oif\<rparr>))"
  "OF_priority_match OF_match_fields_safe oft p = Action [] \<longleftrightarrow> simple_linux_router_nol12 rt fw p = None"
  "OF_priority_match OF_match_fields_safe oft p \<noteq> NoAction" "OF_priority_match OF_match_fields_safe oft p \<noteq> Undefined"
  "OF_priority_match OF_match_fields_safe oft p = Action ls \<longrightarrow> length ls \<le> 1"
  "\<exists>ls. length ls \<le> 1 \<and> OF_priority_match OF_match_fields_safe oft p = Action ls"

Output:
using assms lr_of_tran_correct
by simp_all


Input:
lemma wqo_on_option_UNIV [intro]:
  "wqo_on P UNIV \<Longrightarrow> wqo_on (option_le P) UNIV"

Output:
using wqo_on_with_bot [of P UNIV]
by simp


Input:
lemma red_\<E>_eq_mexecd_\<E>:
  "\<lbrakk> wf_J_prog P; wf_start_state P C M vs \<rbrakk>
  \<Longrightarrow> J_\<E> P C M vs Running = JVMd_\<E> (J2JVM P) C M vs Running"

Output: by(simp only: red_Runs_eq_mexecd_Runs)


Input:
lemma example_how_to_use_properties_in_proofs:
  shows "\<forall> p . Policy.ifp p p"

Output:
using Policy_properties.ifp_reflexive
by auto


Input:
lemma lspace_bounded_measurable:
  fixes p::real
  assumes f: "f \<in> borel_measurable (lebesgue_on S)" and g: "g \<in> lspace (lebesgue_on S) p" and "p > 0"
    and le: " AE x in lebesgue_on S. norm (\<bar>f x\<bar> powr p) \<le> norm (\<bar>g x\<bar> powr p)"
  shows "f \<in> lspace (lebesgue_on S) p"

Output:
using assms
by (auto simp: lspace_ennreal_iff intro: Bochner_Integration.integrable_bound)


Input:
lemma Bernstein_coeffs_01_sum: assumes "degree P \<le> p"
  shows "P = (\<Sum>j = 0..p. smult (nth_default 0 (Bernstein_coeffs_01 p P) j)
             (Bernstein_Poly_01 j p))"

Output:
apply (subst nth_default_Bernstein_coeffs_01[OF assms])
apply (subst Bernstein_sum_01[OF assms])
by argo


Input:
lemma polyneg_norm:
fixes p::"'a::ring_1 poly"
shows "isnpoly p \<Longrightarrow> isnpoly (polyneg p)"

Output:
using polyneg_normh
by (simp add: isnpoly_def)


Input: lemma restrict_path[simp]: "path (restrict A) = path A"

Output:
proof (intro ext iffI) show "path A wr p" if "path (restrict A) wr p" for wr p
using that
by induct auto show "path (restrict A) wr p" if "path A wr p" for wr p
using that
by induct auto
qed


Input: lemma is_volatile_compP [simp]: "is_volatile (compP f P) = is_volatile P"

Output:
proof(rule ext) fix hT show "is_volatile (compP f P) hT = is_volatile P hT"
by(cases hT) simp_all
qed


Input:
lemma Proj_range_closed:
  assumes "is_Proj P"
  shows "closed (range (cblinfun_apply P))"

Output:
using assms
apply transfer
using closed_csubspace.closed is_projection_on_image
by blast


Input: lemma symmetric_mpoly_uminus_iff [simp]: "symmetric_mpoly A (-p) \<longleftrightarrow> symmetric_mpoly A p"

Output:
unfolding symmetric_mpoly_def
by simp


Input:
theorem sturm_R:
  shows "card {x. poly p x=0} =  changes_R_smods p (pderiv p)"

Output:
using sturm_tarski_R[of _ 1,unfolded taq_def]
by force


Input:
lemma ipurge_tr_rev_trace:
 "secure P I D \<Longrightarrow> xs \<in> traces P \<Longrightarrow> ipurge_tr_rev I D u xs \<in> traces P"

Output: by (subst ipurge_tr_rev_t_equiv [symmetric], rule ipurge_tr_rev_t_trace)


Input:
lemma ltakeWhile_simps [simp, code, nitpick_simp]:
  shows ltakeWhile_LNil: "ltakeWhile P LNil = LNil"
  and ltakeWhile_LCons: "ltakeWhile P (LCons x xs) = (if P x then LCons x (ltakeWhile P xs) else LNil)"

Output: by(auto simp add: ltakeWhile_def intro: llist.expand)


Input: lemma polyneg0: "isnpolyh p n \<Longrightarrow> (~\<^sub>p p) = 0\<^sub>p \<longleftrightarrow> p = 0\<^sub>p"

Output: by (induct p arbitrary: n rule: polyneg.induct) (auto simp add: Nneg_def)


Input: lemma nbhd_def2: "Der_1 \<D> \<Longrightarrow> Der_4e \<D> \<Longrightarrow> \<forall>A p. (nbhd A p) = (\<I> A p)"

Output:
unfolding nbhd_def
by (smt Int_Open MONO_def PC1 monI pI2 conn)


Input:
lemma pred_spmf_try [simp]:
  "pred_spmf P (try_spmf p q) = (pred_spmf P p \<and> (\<not> lossless_spmf p \<longrightarrow> pred_spmf P q))"

Output: by(auto simp add: pred_spmf_def)


Input:
lemma mono2mono_emeasure_spmf [THEN lfp.mono2mono]:
  shows monotone_emeasure_spmf:
  "monotone (ord_spmf (=)) (\<le>) (\<lambda>p. emeasure (measure_spmf p))"

Output: by(rule monotoneI le_funI ord_spmf_eqD_emeasure)+


Input:
lemma hfref_weaken_pre':
    assumes "\<And>x. \<lbrakk>P x; rdomp (fst R) x\<rbrakk> \<Longrightarrow> P' x"
    assumes "(f,h) \<in> hfref P' R S"
    shows "(f,h) \<in> hfref P R S"

Output:
apply (rule hfrefI)
apply (rule hn_refine_preI)
using assms
by (auto simp: hfref_def rdomp_def)


Input:
lemma disjCases4[consumes 1, case_names 1 2 3 4]:
  assumes AB: "A \<or> B \<or> C \<or> D"
  and AP: "A \<Longrightarrow> P"
  and BP: "B \<Longrightarrow> P"
  and CP: "C \<Longrightarrow> P"
  and DP: "D \<Longrightarrow> P"
  shows "P"

Output:
proof - from AB AP BP CP DP show ?thesis
by blast
qed


Input:
lemma mcont2mcont_nn_integral_spmf [THEN lfp.mcont2mcont, cont_intro]:
  shows mcont_nn_integral_spmf:
  "mcont lub_spmf (ord_spmf (=)) Sup (\<le>) (\<lambda>p :: 'a spmf. nn_integral (measure_spmf p) f)"

Output: by(rule mcontI)(simp_all add: cont_nn_integral_spmf)


Input:
lemma padic_add_comm0:
assumes "prime p"
shows  "(padic_add p x y)= (padic_add p y x)"

Output:
using assms unfolding padic_add_def
using padic_integers.residue_add_comm[of p]
by (simp add: padic_integers_def)


Input:
lemma irreducible\<^sub>d_as_irreducible:
  fixes p :: "int poly"
  shows "irreducible\<^sub>d p \<longleftrightarrow> irreducible (primitive_part p)"

Output:
using irreducible_primitive_connect[of "primitive_part p"]
by (cases "p = 0", auto simp: irreducible\<^sub>d_primitive_part)


Input:
lemma square_free_factorization_root:
  assumes sff: "square_free_factorization p (c,bs)"
    and p: "p \<noteq> (0 :: 'a poly)"
  shows "{x. poly p x = 0} = {x. \<exists> a i. (a,i) \<in> set bs \<and> poly a x = 0}"

Output:
using square_free_factorization_order_root[OF sff p] p unfolding order_root
by auto


Input:
lemma (in PolynRg) s_cf_deg:"\<lbrakk>p \<in> carrier R; p \<noteq> \<zero>\<rbrakk> \<Longrightarrow>
                  deg_n R S X p = fst (s_cf R S X p)"

Output:
apply (frule s_cf_expr[of p], assumption, (erule conjE)+)
apply (simp add:pol_deg_n[of p "s_cf R S X p" "fst (s_cf R S X p)"]) done


Input: lemma strong_del_point_finite:"finite_incidence_system (del_point p) (str_del_point_blocks p)"

Output:
using strong_del_point_incidence_wf del_point_def
by (intro_locales) (simp_all add: finite_incidence_system_axioms_def finite_sets)


Input:
lemma weak_transition_stepI [simp]:
    assumes "P \<Rightarrow>{\<alpha>} P'"
    shows "P \<Rightarrow>\<langle>\<alpha>\<rangle> P'"

Output:
using assms
by (cases "\<alpha> = \<tau>", simp_all add: observable_tau_transition)


Input:
lemma polynate_norm[simp]:
  fixes p :: "'a::field poly"
  shows "isnpoly (polynate p)"

Output: by (induct p rule: polynate.induct) (simp_all add: polyadd_norm polymul_norm polysub_norm polyneg_norm polypow_norm, simp_all add: isnpoly_def)


Input: lemma isconstant_polybound0: "isnpolyh p n0 \<Longrightarrow> isconstant p \<longleftrightarrow> polybound0 p"

Output: by (induct p arbitrary: n0 rule: isconstant.induct) (auto simp add: isnpolyh_polybound0)


Input:
lemma construct_NofI_R_relation:
  fixes p:: "real poly"
  fixes I1:: "real poly list"
  fixes I2:: "real poly list"
  shows "construct_NofI_R p I1 I2 =
    construct_NofI (sum_list (map power2 (p # I1))) I2"

Output:
unfolding construct_NofI_R_def construct_NofI_def
by metis


Input: theorem wt_J2JVM: "wf_J_prog P \<Longrightarrow> wf_jvm_prog (J2JVM P)"

Output:
unfolding J2JVM_def o_def
by(rule wt_compP2)(rule compP1_pres_wf)


Input: lemma prefix_conforms [simp]: "path_conforms_with_strategy p (ltake n P) \<sigma>"

Output:
using P_conforms path_conforms_with_strategy_prefix
by blast


Input:
lemma find_consistent_signs_at_roots_R:
  fixes p:: "real poly"
  fixes qs :: "real poly list"
  assumes "p \<noteq> 0"
  shows "set(find_consistent_signs_at_roots_R p qs) = set(characterize_consistent_signs_at_roots p qs)"

Output: by (metis assms find_consistent_signs_at_roots_0_R find_consistent_signs_at_roots_1_R length_greater_0_conv)


Input:
lemma path_nth_conv: "path E u p v \<longleftrightarrow> (let p'=p@[v] in
  u=p'!0 \<and>
  (\<forall>i<length p' - 1. (p'!i,p'!Suc i)\<in>E))"

Output:
apply (induct p arbitrary: v rule: rev_induct)
apply (auto simp: path_conc_conv path_cons_conv nth_append) done


Input:
lemma poly_cond_degree_0_imp_no_root:
  fixes x :: "'b :: {comm_ring_1,ring_char_0}"
  assumes pc: "poly_cond p" and deg: "degree p = 0" shows "ipoly p x \<noteq> 0"

Output:
proof from pc have "p \<noteq> 0"
by auto moreover assume "ipoly p x = 0" note poly_zero[OF this] ultimately show False
using deg
by auto
qed


Input: lemma assert_disch3 :" \<not> P \<sigma> \<Longrightarrow> \<not> (\<sigma> \<Turnstile> (assert\<^sub>S\<^sub>E P))"

Output: by(auto simp: bind_SE_def assert_SE_def valid_SE_def)


Input:
lemma absolute_liveness_eventually:
  shows "absolute_liveness P \<longleftrightarrow> (\<exists>\<sigma>. P \<sigma>) \<and> P = \<diamond>P"

Output:
unfolding absolute_liveness_def defs
by (metis cancel_comm_monoid_add_class.diff_cancel drop_eq_Nil order_refl shift.simps(1) stake_suffix_id suffix_shift suffix_zero)


Input: lemma headn_0[simp]: "isnpolyh p n \<Longrightarrow> m < n \<Longrightarrow> headn p m = p"

Output: by (induct p arbitrary: n rule: degreen.induct) auto


Input:
lemma okjectEqvt[eqvt]:
  fixes p :: "name prm"
  and   \<alpha> :: "('a::fs_name) action"

  shows "(p \<bullet> object \<alpha>) = object(p \<bullet> \<alpha>)"

Output: by(nominal_induct \<alpha> rule: action.strong_induct) auto


Input: lemma lm008: "injections X Y = totalRels X Y \<inter> injectionsUniverse"

Output:
using injections_def
by (simp add: Collect_conj_eq Int_assoc)


Input:
lemma limited_and_eq_id:
  "\<lbrakk> limited_and x z; y AND z = z \<rbrakk> \<Longrightarrow> x AND y = x"

Output:
unfolding limited_and_def
by (erule subst, fastforce simp: word_bw_lcs word_bw_assocs word_bw_comms)


Input:
lemma tuple5_mono [partial_function_mono]:
  assumes "\<And>y. mono_sum_bot (p1 y)"
    and "\<And>y. mono_sum_bot (p2 y)"
    and "\<And>y. mono_sum_bot (p3 y)"
    and "\<And>y. mono_sum_bot (p4 y)"
    and "\<And>y. mono_sum_bot (p5 y)"
  shows "mono_sum_bot (\<lambda>g. Xmlt.tuple5 t (\<lambda>y. p1 y g) (\<lambda> y. p2 y g) (\<lambda> y. p3 y g) (\<lambda> y. p4 y g) (\<lambda> y. p5 y g) f x)"

Output:
using assms
by (cases x, cases "list5elements (Xml.children x)") (auto intro!: partial_function_mono)


Input:
lemma rel_gpv_def':
  "rel_gpv A B gpv gpv' \<longleftrightarrow>
  (\<exists>gpv''. (\<forall>(x, y) \<in> results'_gpv gpv''. A x y) \<and> (\<forall>(x, y) \<in> outs'_gpv gpv''. B x y) \<and>
           map_gpv fst fst gpv'' = gpv \<and> map_gpv snd snd gpv'' = gpv')"

Output:
unfolding rel_gpv_def
by(auto simp add: BNF_Def.Grp_def)


Input: lemma aadd_two_pos:"\<lbrakk>0 \<le> (x::ant); 0 \<le> y\<rbrakk> \<Longrightarrow> 0 \<le> x + y"

Output:
apply (cut_tac Zero_in_aug_inf, cut_tac pos_in_aug_inf[of "x"], cut_tac pos_in_aug_inf[of "y"])
apply (cut_tac aadd_le_mono[of "0" "x" "y"], simp add:aadd_0_l, assumption+) done


Input: lemma lsl_rpc_galois: "(x \<sqinter> \<nu> z \<le> y) = (z \<le> rpc x (y::'a::bool_unital_quantale))"

Output:
unfolding rpc_def
by (metis adj_def inf_commute ls_galois shunt1)


Input: lemma omega_dom [simp]: "d (\<Omega> x y) = \<Omega> x y"

Output:
using Omega_def local.a_d_closed local.ads_d_def local.apd_d_def
by auto


Input:
lemma ereal_inverse_antimono_strict:
  fixes x y :: ereal
  shows "0 \<le> x \<Longrightarrow> x < y \<Longrightarrow> inverse y < inverse x"

Output: by (cases rule: ereal2_cases[of x y]) auto


Input:
lemma closed_diagonal:
  "closed {y. \<exists> x::('a::t2_space). y = (x,x)}"

Output:
proof - have "{y. \<exists> x::'a. y = (x,x)} = UNIV - {(x,y) | x y. x \<noteq> y}"
by auto then show ?thesis
using open_diagonal_complement closed_Diff
by auto
qed


Input: lemma dp_total2: "is_direct_product x y \<Longrightarrow> is_total y"

Output: by (metis is_direct_product_def inf_le2 is_total_def)


Input: lemma unique_choice: "\<forall>x. \<exists>!y. Q x y \<Longrightarrow> \<exists>!f. \<forall>x. Q x (f x)"

Output:
apply (auto intro!: choice ext)
by metis


Input:
theorem wls_fresh_psubst_I:
assumes "wls s X" and "wlsEnv rho"
and "rho zs z = None \<Longrightarrow> fresh zs z X" and
    "\<And> ys y Y. rho ys y = Some Y \<Longrightarrow> fresh ys y X \<or> fresh zs z Y"
shows "fresh zs z (X #[rho])"

Output:
using assms
by(simp add: fresh_psubst_I)


Input: lemma rconjby_uminus: "rconjby x (-y) = - rconjby x y"

Output:
using minus_unique[of "rconjby x y"] add_assoc4[of "rconjby x y" "-x" "-y" x]
by simp


Input:
lemma dotprod_is_0 [simp]:
  assumes "length x = length y"
  shows "x \<bullet> y = 0 \<longleftrightarrow> (\<forall>i<length y. x ! i = 0 \<or> y ! i = 0)"

Output:
using assms
by (metis dotprod_gt0_iff neq0_conv)


Input:
lemma ordinal_exp_assoc:
"(x ** y) ** z = x ** (y * z)"

Output:
apply (case_tac "x = 0", simp_all)
apply (rule_tac a=z in oLimit_induct, simp_all add: ordinal_exp_distrib) done


Input:
lemma code_fset_eq [code]:
  "HOL.equal X (fset_of_list Y) \<longleftrightarrow> size X = length (remdups Y) \<and> (\<forall>x |\<in>| X. List.member Y x)"

Output:
apply (simp only: HOL.equal_class.equal_eq fset_eq_alt)
apply (simp only: size)
using fmember
by fastforce


Input:
lemma antisym_conv:
  assumes "y \<le>\<^sub>a x"
  shows "x \<le>\<^sub>a y \<longleftrightarrow> x = y"

Output:
using assms
by (blast intro: antisym)


Input:
lemma middle:
  "dist x (middle x y) = (dist x y)/2"
  "dist (middle x y) y = (dist x y)/2"

Output:
unfolding middle_def
using middles[of x y]
by (metis (mono_tags, lifting) someI_ex)+


Input: lemma pr_id3_3': "pr_conv_3_to_1 (\<lambda> x y z. z) \<in> PrimRec1'"

Output:
proof - have "pr_conv_3_to_1 (\<lambda> x y z. z) = (\<lambda>x. c_snd x)"
by (simp add: pr_conv_3_to_1_def) thus ?thesis
by (simp add: PrimRec1'.snd)
qed


Input:
lemma Polygamma_real_mono:
  assumes "x > 0" "x \<le> (y::real)" "even n"
  shows   "Polygamma n x \<le> Polygamma n y"

Output:
using Polygamma_real_strict_mono[OF assms(1) _ assms(3), of y] assms(2)
by (cases "x = y") simp_all


Input:
lemma int_xor_ge0 [simp]:
  \<open>x XOR y \<ge> 0 \<longleftrightarrow> (x \<ge> 0 \<longleftrightarrow> y \<ge> 0)\<close> for x y :: int

Output: by (fact xor_nonnegative_int_iff)


Input:
lemma accum1_lemma [simp]:
  shows "rec_eval (rec_accum1 f) [x, y] = (\<Prod> z \<le> x. rec_eval f  [z, y])"

Output: by (induct x) (simp_all add: rec_accum1_def)


Input:
theorem wls_vsubstEnv_compose2:
assumes  "wlsEnv rho"
and "ys \<noteq> zs \<or> y \<notin> {z,z1}"
shows "((rho &[y1 // y]_ys) &[z1 // z]_zs) =
       ((rho &[z1 // z]_zs) &[(y1 @ys[z1 / z]_zs) // y]_ys)"

Output:
using assms
by(simp add: vsubstEnv_compose2)


Input:
lemma sup_inf_distrib2_1:
 "((y :: 'a :: lattice) \<sqinter> z) \<squnion> x = (y \<squnion> x) \<sqinter> (z \<squnion> x)"

Output: quickcheck[expect = counterexample] oops


Input:
lemma gen_upper_bound_increasing:
  fixes a :: real
  assumes "a \<le> x"
      and "\<And>y. a \<le> y \<Longrightarrow> y \<le> x \<Longrightarrow> ((\<lambda>x. fu x - f x) has_real_derivative g y) (at y)"
      and "\<And>y. a \<le> y \<Longrightarrow> y \<le> x \<Longrightarrow> g y \<ge> 0"
      and "fu a = f a"
    shows "f x \<le> fu x"

Output:
apply (rule gen_lower_bound_increasing [of a x f fu "\<lambda>u. - g u"])
using assms DERIV_minus [where f = "\<lambda>x. fu x - f x"]
apply auto done


Input:
lemma sup_eq_bot_iff [simp]:
  "(x :: 'a :: bounded_lattice_bot) \<squnion> y = \<bottom> \<longleftrightarrow> x = \<bottom> \<and> y = \<bottom>"

Output:
quickcheck[expect = no_counterexample]
by (simp add: eq_iff)


Input:
lemma circ_simulate_absorb:
  "y * x \<le> x \<Longrightarrow> y\<^sup>\<circ> * x \<le> x \<squnion> y\<^sup>\<circ> * bot"

Output: by (metis circ_simulate_left_plus_1 circ_zero mult_1_right)


Input: lemma max_tstp_idem: "max_tstp (max_tstp x y) y = max_tstp x y"

Output: by (cases x; cases y) auto


Input:
lemma esqrt_mono2 [mono_intros]:
  assumes "x \<le> y"
  shows "esqrt x \<le> esqrt y"

Output:
using esqrt_mono assms unfolding mono_def
by auto


Input:
lemma kat_2_equiv:
  "y * a(z) \<le> a(x) * y \<longleftrightarrow> d(x) * y * a(z) = bot"

Output:
apply (rule iffI)
apply (simp add: kat_2)
by (smt (verit, best) a_Z a_below_one a_complement_one case_split_left d_def mult_assoc mult_right_isotone mult_1_right bot_least)


Input: lemma The_select_first[simp]: "select_first x p y \<Longrightarrow> The (select_first x p) = y"

Output: by (intro the_equality select_first_unique)


Input:
lemma funpow_dist_0:
  assumes "x = y" shows "funpow_dist f x y = 0"

Output:
using assms unfolding funpow_dist_def
by (intro Least_eq_0) simp


Input: lemma is_pure_alt_def: "is_pure R \<longleftrightarrow> (\<exists>Ri. \<forall>x y. R x y = \<up>((y,x)\<in>Ri))"

Output:
unfolding is_pure_def
apply auto
apply (rename_tac P')
apply (rule_tac x="{(x,y). P' y x}" in exI)
apply auto done


Input:
lemma mk_mop_rl3:
    assumes "\<And>x y z. mf x y z \<equiv> ASSERT (P x y z) \<then> RETURN (f x y z)"
    shows "(RETURN ooo f, mf) \<in> Id \<rightarrow> Id \<rightarrow> Id \<rightarrow> \<langle>Id\<rangle>nres_rel"

Output:
unfolding assms[abs_def]
by (auto intro!: nres_relI simp: pw_le_iff refine_pw_simps)


Input: lemma facetrel_complement_vertex: "y\<lhd>x \<Longrightarrow> x = insert v y \<Longrightarrow> v\<notin>y"

Output:
using facetrel_def[of y x]
by fastforce


Input:
lemma hcomplex_approx_iff:
  "(x \<approx> y) = (hRe x \<approx> hRe y \<and> hIm x \<approx> hIm y)"

Output:
unfolding approx_def
by (simp add: hcomplex_Infinitesimal_iff)


Input:
lemma mult_L_sup_omega:
  "(x * L \<squnion> y)\<^sup>\<omega> = y\<^sup>\<omega> \<squnion> y\<^sup>\<star> * x * L"

Output: by (metis L_left_zero mult_bot_add_omega sup_commute mult_assoc)


Input:
lemma omega_sum_unfold_1:
  "(x \<squnion> y)\<^sup>\<omega> = x\<^sup>\<omega> \<squnion> x\<^sup>\<star> * y * (x \<squnion> y)\<^sup>\<omega>"

Output: by (metis mult_right_dist_sup omega_unfold mult_assoc wagner)


Input:
lemma complement_antitone:
  "x \<le> y \<Longrightarrow> -y \<le> -x"

Output: by (metis le_iff_sup maddux_3_3 sba2_export sup_monoid.add_commute)


Input: lemma real_sqrt_less_iff [simp]: "sqrt x < sqrt y \<longleftrightarrow> x < y"

Output:
unfolding sqrt_def
by (rule real_root_less_iff [OF pos2])


Input: lemma real_sqrt_sum_squares_eq_cancel2: "sqrt (x\<^sup>2 + y\<^sup>2) = y \<Longrightarrow> x = 0"

Output: by (drule arg_cong [where f = "\<lambda>x. x\<^sup>2"]) simp


Input: lemma Sigma_msetE[elim!]: "\<lbrakk>c \<in># Sigma_mset A B; \<And>x y. \<lbrakk>x \<in># A; y \<in># B x; c = (x, y)\<rbrakk> \<Longrightarrow> P\<rbrakk> \<Longrightarrow> P"

Output: by (unfold Sigma_mset_def) auto


Input:
lemma funpow_dist_0_eq:
  assumes "y \<in> orbit f x" shows "funpow_dist f x y = 0 \<longleftrightarrow> x = y"

Output:
using assms
by (auto simp: funpow_dist_0 dest: funpow_dist_prop)


Input:
lemma comp_one_vector:
  "one_vector x \<Longrightarrow> one_vector y \<Longrightarrow> one_vector (x * y)"

Output:
using mult_isotone mult_semi_associative order_lesseq_imp one_vector_def
by blast


Input:
lemma while_while_mult_sub:
  "x \<star> (1 \<star> y) \<le> (x \<star> 1) \<star> y"

Output: by (metis sup_commute while_sub_dist_3 while_while_sup)


Input:
lemma circ_mult_1:
  "(x * y)\<^sup>\<circ> = 1 \<squnion> x * (y * x)\<^sup>\<circ> * y"

Output: by (metis circ_left_unfold circ_slide_1 mult_assoc)


Input: lemma hadd: "x @+ y = x \<squnion> RepFun y (\<lambda>z. x @+ z)"

Output: by (metis def_hmemrec RepFun_ecut hadd_def order_refl)


Input:
lemma lres_mult_lres_lres:
  "x / (z * y) = (x / y) / z"

Output: by (metis conv_dist_comp double_compl lres_def mult_assoc)


Input: lemma add_lemma: "\<And> x y. rec_exec rec_add [x, y] =  x + y"

Output: by(induct_tac y, auto simp: rec_add_def rec_exec.simps)


Input:
lemma lub_belowI[intro, simp]:
  fixes x :: "'a :: Join_cpo"
  shows  "(\<And> y. y \<in> S \<Longrightarrow> y \<sqsubseteq> x) \<Longrightarrow> lub S \<sqsubseteq> x"

Output: by (metis exists_lub is_lub_thelub_ex is_ub_def)


Input:
lemma subst_simp_var2:
  assumes "x \<noteq> y"
  shows "(Var x)[y ::= M] = Var x"

Output:
unfolding subst_def
by( rule, metis substitutes.var2 assms, metis substitutes_function substitutes.var2 assms )


Input:
lemma center_on_geodesic [simp]:
  "center x y z \<in> {x--y}"
  "center x y z \<in> {x--z}"
  "center x y z \<in> {y--z}"
  "center x y z \<in> {y--x}"
  "center x y z \<in> {z--x}"
  "center x y z \<in> {z--y}"

Output:
using center_as_intersection
by (auto simp add: some_geodesic_commute)


Input:
lemma translexLess:
  shows "trans lexLess"

Output:
proof- { fix x :: "'a Trail" and y :: "'a Trail" and z :: "'a Trail" assume "(x, y) \<in> lexLess" and "(y, z) \<in> lexLess" hence "(x, z) \<in> lexLess"
using lexord_trans transDecisionLess unfolding lexLess_def
by simp } thus ?thesis unfolding trans_def
by blast
qed


Input:
lemma star_right_induct_mult_iff:
  "y * x \<le> y \<longleftrightarrow> y * x\<^sup>\<star> \<le> y"

Output:
using mult_right_isotone order_trans star.circ_increasing star_right_induct_mult
by blast


Input:
lemma merge_blindable_alt_def:
  "merge_blindable h m x y = (case (x, y) of
    (Unblinded x, Unblinded y) \<Rightarrow> map_option Unblinded (m x y)
  | (Blinded x, Unblinded y) \<Rightarrow> (if Content (h y) = x then Some (Unblinded y) else None)
  | (Unblinded y, Blinded x) \<Rightarrow> (if Content (h y) = x then Some (Unblinded y) else None)
  | (Blinded t, Blinded u) \<Rightarrow> (if t = u then Some (Blinded u) else None))"

Output: by(simp split: blindable\<^sub>m.split blindable\<^sub>h.split)


Input:
lemma uint16_mod_code [code abstract]:
  "Rep_uint16 (uint16_mod x y) =
  (if y = 0 then Rep_uint16 (undefined ((mod) :: uint16 \<Rightarrow> _) x (0 :: uint16)) else Rep_uint16 x mod Rep_uint16 y)"

Output:
unfolding uint16_mod_def
by transfer simp


Input:
theorem wls_freshAbs_psubstAbs_I:
assumes "wlsAbs (us,s) A" and "wlsEnv rho"
and "rho zs z = None \<Longrightarrow> freshAbs zs z A" and
    "\<And> ys y Y. rho ys y = Some Y \<Longrightarrow> freshAbs ys y A \<or> fresh zs z Y"
shows "freshAbs zs z (A $[rho])"

Output:
using assms
by(simp add: freshAbs_psubstAbs_I)


Input:
theorem wls_vsubst_trans:
assumes  "wls s X" and "fresh ys y1 X"
shows "((X #[y1 // y]_ys) #[y2 // y1]_ys) = (X #[y2 // y]_ys)"

Output:
using assms
by (simp add: vsubst_trans)


Input:
lemma in_Res_not_congruent:
  assumes res_g: "Complete_set_residues g"
  and x: "x \<in> g b" and y: "y \<in> g b" and x_not_y: "x\<noteq>y"
  shows "\<not> cong x y b"

Output:
using assms unfolding Complete_set_residues_def unfolding pairwise_def
by auto


Input: lemma vector_2: "is_vector y \<Longrightarrow> (x \<cdot> y\<^sup>\<smile>) ; z = x ; (y \<cdot> z)"

Output: by (metis inf.commute ra_2 is_vector_def)


Input:
lemma implies_inf_isotone:
  "x \<leadsto> y \<le> (x \<sqinter> z) \<leadsto> (y \<sqinter> z)"

Output: by (metis implies_curry implies_galois_increasing implies_isotone)


Input:
lemma  expl_cond_expect_const:
  assumes "Y w = Y y"
  shows "expl_cond_expect M Y X w = expl_cond_expect M Y X y"

Output:
unfolding expl_cond_expect_def img_dce_def
by (simp add: assms)


Input:
lemma econc_x_trans[trans]:
  "x \<le> \<Down>\<^sub>E E R y \<Longrightarrow> y \<le> z \<Longrightarrow> x \<le> \<Down>\<^sub>E E R z"

Output: by (force simp: pw_ele_iff refine_pw_simps)


Input: lemma p_linear: "(x::('e, 'a::linorder) Prio) \<le> y \<or> y \<le> x"

Output: by (unfold plesseq_def) (simp only: p_linear2)


Input:
lemma semilat_Def:
"semilat(A,r,f) \<equiv> order r \<and> closed A f \<and>
                 (\<forall>x\<in>A. \<forall>y\<in>A. x \<sqsubseteq>\<^sub>r x \<squnion>\<^sub>f y) \<and>
                 (\<forall>x\<in>A. \<forall>y\<in>A. y \<sqsubseteq>\<^sub>r x \<squnion>\<^sub>f y) \<and>
                 (\<forall>x\<in>A. \<forall>y\<in>A. \<forall>z\<in>A. x \<sqsubseteq>\<^sub>r z \<and> y \<sqsubseteq>\<^sub>r z \<longrightarrow> x \<squnion>\<^sub>f y \<sqsubseteq>\<^sub>r z)"

Output: by (unfold semilat_def) clarsimp


Input:
lemma sin_monotone_2pi:
  assumes "- (pi/2) \<le> y" and "y < x" and "x \<le> pi/2"
  shows "sin y < sin x"

Output:
unfolding sin_cos_eq
using assms
by (auto intro: cos_monotone_0_pi)


Input:
lemma ND0aux2[rule_format]: "DenyAllFromTo x y \<in> set b \<Longrightarrow>
                             y \<in> set (net_list_aux b)"

Output: by (metis aux5a net_list.simps set_remdups)


Input: lemma power_inductr_var: "y \<cdot> x \<le> y \<Longrightarrow> y \<cdot> x\<^bsup>n\<^esup> \<le> y"

Output: by (induct n, metis eq_refl mult_oner power.simps(1), metis mult.assoc mult_isor order_refl order_trans power.simps(2) power_commutes)


Input:
lemma has_white_path_toE[elim!]:
  "\<lbrakk> (x points_to y) s; white y s \<rbrakk> \<Longrightarrow> (x has_white_path_to y) s"

Output:
unfolding has_white_path_to_def
by (auto elim: rtranclp.intros(2))


Input:
lemma forest_down_closed:
  "x \<le> y \<Longrightarrow> forest y \<Longrightarrow> forest x"

Output:
using conv_isotone mult_isotone star_isotone
by fastforce


Input: lemma lprod_3_6: assumes y': "(y', y) \<in> R" shows "([x, z, y'], [x, y, z]) \<in> lprod R"

Output:
apply (rule lprod_list[where a="z" and b="z" and ah="[x]" and at="[y']" and bh="[x,y]" and bt="[]", simplified])
apply (simp add: y' lprod_2_4) done


Input:
lemma
  assumes x: "x \<in> A" and y: "y \<in> A"
  shows not_iff_asym: "\<not>x \<sqsubseteq> y \<longleftrightarrow> y \<sqsubset> x"
    and not_asym_iff[simp]: "\<not>x \<sqsubset> y \<longleftrightarrow> y \<sqsubseteq> x"

Output:
using comparable[OF x y]
by auto


Input: lemma nodes_connected_ind_sym: "F\<subseteq>E \<Longrightarrow> sym {(x, y) |x y. nodes_connected (ind F) x y}"

Output:
apply(frule ind_valid_graph) unfolding sym_def
using valid_graph.nodes_connected_sym
by fast


Input:
lemma prod_not_prime:
  assumes "prime (x::nat)"
    and "prime y"
    and "x > 2"
    and "y > 2"
  shows "\<not> prime ((x-1)*(y-1))"

Output: by (metis assms One_nat_def Suc_diff_1 nat_neq_iff numeral_2_eq_2 prime_gt_0_nat prime_product)


Input: lemma vector_to_cblinfun_add: \<open>vector_to_cblinfun (x + y) = vector_to_cblinfun x + vector_to_cblinfun y\<close>

Output:
apply transfer
by (simp add: scaleC_add_right)


Input:
lemma reflect_rtranclp:
  "(\<And>x y. S (f x) (f y) \<Longrightarrow> R x y) \<Longrightarrow>
   bij_on_trancl S f \<Longrightarrow>
   S\<^sup>*\<^sup>* (f x) (f y) \<Longrightarrow> R\<^sup>*\<^sup>* x y"

Output:
unfolding Nitpick.rtranclp_unfold
by (metis (full_types) injD reflect_tranclp)


Input: lemma subst_F_left_commute: "subst x (F x) (subst y (F y) t) = subst y (F y) (subst x (F x) t)"

Output: by (metis subst_tm_commute2 F_unfold subst_tm_id F_unfold atom_fresh_perm tm.fresh(2))


Input:
lemma ni_star_induct_iff:
  "ni(x * y) \<le> ni(y) \<longleftrightarrow> ni(x\<^sup>\<star> * y) \<le> ni(y)"

Output:
using ni_n_order n_star_induct_iff
by auto


Input:
lemma xml2to3elements_mono [partial_function_mono]:
  assumes p1: "\<And>y. mono_sum_bot (p1 y)"
              "\<And>y. mono_sum_bot (p2 y)"
              "\<And>y. mono_sum_bot (p3 y)"
  shows "mono_sum_bot (\<lambda>g. xml2to3elements t (\<lambda>y. p1 y g) (\<lambda>y. p2 y g) (\<lambda>y. p3 y g) f x)"

Output: by (cases x, auto intro!: partial_function_mono p1)


Input: theorem comm:  "x \<cdot> y = y \<cdot> x  \<longleftrightarrow>  (\<exists> t m k. x = t\<^sup>@k \<and> y = t\<^sup>@m)"

Output:
using comm_append_are_replicate[of x y, folded pow_is_concat_replicate] pow_comm
by auto


Input: lemma preal_add_assoc: "((x::preal) + y) + z = x + (y + z)"

Output:
apply (simp add: preal_add_def mem_add_set)
apply (force simp: add_set_def ac_simps) done


Input:
lemma hypreal_setle_less_trans: "S *<= x \<Longrightarrow> x < y \<Longrightarrow> S *<= y"
  for x y :: hypreal

Output: by (meson le_less_trans less_imp_le setle_def)


Input:
lemma orbit_perm_rem_eq:
  assumes "bij f" shows "orbit (perm_rem y f) x = (if x = y then {y} else orbit f x - {y})"

Output:
using assms
by (simp add: orbit_eq_singleton_iff orbit_perm_rem perm_rem_simps)


Input:
lemma hyperb_ineq_4_points' [mono_intros]:
  "Min {Gromov_product_at (e::'a) x y, Gromov_product_at e y z, Gromov_product_at e z t} \<le> Gromov_product_at e x t + 2 * deltaG(TYPE('a))"

Output:
using hyperb_ineq_4_points[of e x y z t]
by auto


Input:
lemma essentialI [intro?]:
  "\<And>B. \<lbrakk> path G x p y; y \<in> B; \<And>z. \<lbrakk> x \<noteq> y; z \<in> set p \<rbrakk> \<Longrightarrow> z = x \<or> z \<notin> S \<rbrakk> \<Longrightarrow> essential G B S x"

Output: by(auto simp add: essential_def)


Input: lemma subst_F_left_commute: "subst x (F x) (subst y (F y) t) = subst y (F y) (subst x (F x) t)"

Output: by (metis subst_tm_commute2 F_unfold subst_tm_id F_unfold atom_fresh_perm tm.fresh(2))


Input:
theorem freshEnv_updEnv_E4:
assumes "freshEnv ys y (rho [x \<leftarrow> X]_xs)"
and "zs \<noteq> xs \<or> z \<noteq> x" and "rho zs z = Some Z"
shows "fresh ys y Z"

Output:
using assms unfolding freshEnv_def liftAll_def
by (metis getEnv_updEnv1)


Input:
lemma bigo_sum1: "\<forall>x y. 0 \<le> h x y \<Longrightarrow>
    \<exists>c. \<forall>x y. \<bar>f x y\<bar> \<le> c * h x y \<Longrightarrow>
      (\<lambda>x. \<Sum>y \<in> A x. f x y) =o O(\<lambda>x. \<Sum>y \<in> A x. h x y)"

Output:
apply (rule bigo_sum_main)
apply force
apply clarsimp
apply (rule_tac x = c in exI)
apply force done


Input:
lemma circ_sup_sub_sup_one_2:
  "x\<^sup>\<circ> * (x \<squnion> y) \<le> x\<^sup>\<circ> * (1 \<squnion> y)"

Output: by (metis circ_sup_sub_sup_one_1 circ_transitive_equal mult_assoc mult_right_isotone)


Input:
lemma imperative_append: "VARS x y
 {x=X & y=Y}
 x := rev(x);
 WHILE x~=[]
 INV {rev(x)@y = X@Y}
 DO y := (hd x # y);
    x := tl x
 OD
 {y = X@Y}"

Output:
apply vcg_simp
apply(simp add: neq_Nil_conv)
apply auto done


Input: lemma fcompare_double_Eq2: "fcompare_double y z = ccode.Eq \<Longrightarrow> fcompare_double x y = c \<Longrightarrow> fcompare_double x z = c"

Output: by transfer (auto simp: fcompare_def split: if_splits)


Input:
lemma fmran'E[elim]:
  assumes "y \<in> fmran' m"
  obtains x where "fmlookup m x = Some y"

Output:
using assms
by (auto simp: fmlookup_ran'_iff)


Input:
lemma (in LCD) foldD_insert_aux:
  "\<lbrakk>x \<notin> A; x \<in> B; e \<in> D; A \<subseteq> B\<rbrakk>
    \<Longrightarrow> ((insert x A, v) \<in> foldSetD D f e) \<longleftrightarrow> (\<exists>y. (A, y) \<in> foldSetD D f e \<and> v = f x y)"

Output:
apply auto
by (metis Diff_insert_absorb f_closed finite_Diff foldSetD.insertI foldSetD_determ foldSetD_imp_finite insert_subset local.finite_imp_foldSetD local.foldSetD_closed)


Input: lemma is_inf_binary: "is_inf x y (\<Sqinter>{x, y})"

Output:
proof - have "is_Inf {x, y} (\<Sqinter>{x, y})" .. then show ?thesis
by (simp only: is_Inf_binary)
qed


Input:
lemma while_sup_below:
  "x \<squnion> y \<le> x \<star> (y \<star> 1)"

Output: by (metis le_supI le_supI1 while_left_dist_sup while_left_unfold while_one_increasing)


Input:
lemma left_diff_distrib: "(x - y) \<times>\<^sub>7 z = x \<times>\<^sub>7 z - y \<times>\<^sub>7 z"
  and  right_diff_distrib: "x \<times>\<^sub>7 (y - z) = x \<times>\<^sub>7 y - x \<times>\<^sub>7 z"

Output: by (simp_all add: cross7_simps)


Input:
lemma min_maxsimpchain_adj:
  "\<lbrakk> maxsimp x; maxsimp y; x\<sim>y; x\<noteq>y \<rbrakk> \<Longrightarrow> min_maxsimpchain [x,y]"

Output:
using maxsimpchain_def min_maxsimpchainI_betw[of x y "[]"]
by simp


Input:
lemma vdp_c0: "t \<in> point_ivl 7 \<longrightarrow> (x, y) \<in> point_ivl (1.4, 2.4) \<longrightarrow>
   t \<in> vdp.existence_ivl0 (x, y) \<and> vdp.flow0 (x, y) t \<in> {(1.870, 0.9887) .. (1.875, 1.001)}"

Output: by (tactic \<open>ode_bnds_tac @{thms vdp_fas_def} 30 35 9 14 [(0, 1, "0x000000")] (* "out_vdp_c0.out" *) "" @{context} 1\<close>)


Input:
lemma cdl_heap_add_assoc:
  "\<lbrakk>sep_state_disj x y; sep_state_disj y z; sep_state_disj x z\<rbrakk>
  \<Longrightarrow> cdl_heap_add (SepState (cdl_heap_add x y) (cdl_ghost_state_add x y)) z =
      cdl_heap_add x (SepState (cdl_heap_add y z) (cdl_ghost_state_add y z))"

Output:
apply (clarsimp simp: sep_state_disj_def)
apply (cut_tac cdl_heap_add_assoc')
apply fast
apply fastforce done


Input:
lemma t_fusion_assoc [simp]:
  "\<lbrakk> last x = first y; last y = first z \<rbrakk> \<Longrightarrow> t_fusion x (t_fusion y z) = t_fusion (t_fusion x y) z"

Output: by (cases x, cases y, cases z, simp add: t_fusion_def)


Input: lemma lookup_fresh: "x \<sharp> lookup e n y \<longleftrightarrow> y \<in> set e \<or> x \<noteq> atom y"

Output: by (induct arbitrary: n rule: lookup.induct) (auto simp: pure_fresh fresh_at_base)


Input:
lemma diamond_star_unfold_an:
  "|x\<^sup>\<star>>an(y) = an(y) \<squnion> |n(y) * x>|x\<^sup>\<star>>an(y)"

Output: by (metis an_n_def diamond_star_unfold_n n_an_def)


Input:
lemma Omega_mult:
  "(x * y)\<^sup>\<Omega> = 1 \<squnion> x * (y * x)\<^sup>\<Omega> * y"

Output: by (metis Omega_def comb1.circ_mult_1 omega_left_zero_equal omega_translate)


Input:
theorem wls_swapEnv_compose:
assumes "wlsEnv rho"
shows "((rho &[x \<and> y]_zs) &[x' \<and> y']_zs') =
       ((rho &[x' \<and> y']_zs') &[(x @zs[x' \<and> y']_zs') \<and> (y @zs[x' \<and> y']_zs')]_zs)"

Output:
using assms
by (intro swapEnv_compose) auto


Input: lemma edom_mono: "x \<sqsubseteq> y \<Longrightarrow> edom x \<subseteq> edom y"

Output:
unfolding edom_def
by auto (metis below_bottom_iff fun_belowD)


Input:
lemma rtrancl_len_E [elim]:
  assumes "(x, y) \<in> r\<^sup>*" obtains n where "(x, y) \<in> r^^n"

Output:
using rtrancl_imp_UN_relpow [OF assms]
by best


Input:
lemma (in weak_partial_order) weak_total_orderI:
  assumes total: "!!x y. \<lbrakk>x \<in> carrier L; y \<in> carrier L\<rbrakk> \<Longrightarrow> x \<sqsubseteq> y \<or> y \<sqsubseteq> x"
  shows "weak_total_order L"

Output: by unfold_locales (rule total)


Input:
lemma comp_commute_below_diversity:
  "x * y \<le> -1 \<longleftrightarrow> y * x \<le> -1"

Output: by (metis comp_right_one conv_dist_comp conv_one schroeder_3_p schroeder_4_p)


Input:
lemma while_sup_2:
  "(x \<squnion> y) \<star> z \<le> (x \<star> (y \<star> 1)) \<star> z"

Output:
using while_left_isotone while_sup_below
by auto


Input:
lemma has_vector_derivative_transform_within_open:
  assumes "(f has_vector_derivative f') (at x)"
    and "open S"
    and "x \<in> S"
    and "\<And>y. y\<in>S \<Longrightarrow> f y = g y"
  shows "(g has_vector_derivative f') (at x)"

Output:
using assms unfolding has_vector_derivative_def
by (rule has_derivative_transform_within_open)


Input:
lemma min_absorb2:
  assumes "y \<le>\<^sub>a x"
  shows "min x y = y"

Output:
using assms unfolding min_def
by (simp add: eq_iff)


Input: lemma subset_dual: "(\<partial> ` X = Y) \<longleftrightarrow> (X = \<partial>\<^sup>- ` Y)"

Output: by (metis dual_inj image_comp image_inv_f_f inv_o_cancel dual_inv2)


Input:
lemma showsp_real_alg_append [show_law_simps]:
  "showsp_real_alg p r (x @ y) = showsp_real_alg p r x @ y"

Output: by (intro show_lawD show_law_intros)


Input: lemma (in Semilat) ub2 [simp, intro?]: "\<lbrakk> x \<in> A; y \<in> A \<rbrakk> \<Longrightarrow> y \<sqsubseteq>\<^sub>r x \<squnion>\<^sub>f y"

Output:
using semilat
by (simp add: semilat_Def)


Input: lemma sqrt_nat[simp]: "set (sqrt_nat x) = { y. y * y = x}"

Output:
unfolding sqrt_nat_def
using root_nat[of 2 x]
by (simp add: power2_eq_square)


Input:
lemma sum_symmetric:
  assumes "y = y\<^sup>T"
    shows "sum (x\<^sup>T \<sqinter> y) = sum (x \<sqinter> y)"

Output: by (metis assms sum_conv conv_dist_inf)


Input: lemma c_drop_at_Suc1: "c_drop (Suc y) x = c_drop y (c_tl x)"

Output: apply(simp add: c_drop_at_Suc c_tl_c_drop) done


Input:
lemma matroid_ax_3_alt:
  assumes "I \<subseteq> X \<inter> Y"
  shows "rk (X \<union> Y) + rk I \<le> rk X + rk Y"

Output: by (metis add.commute add_le_cancel_right assms matroid_ax_2 matroid_ax_3 order_trans)


Input:
theorem (in pair_sigma_finite) Fubini:
  assumes f: "f \<in> borel_measurable (M1 \<Otimes>\<^sub>M M2)"
  shows "(\<integral>\<^sup>+ y. (\<integral>\<^sup>+ x. f (x, y) \<partial>M1) \<partial>M2) = (\<integral>\<^sup>+ x. (\<integral>\<^sup>+ y. f (x, y) \<partial>M2) \<partial>M1)"

Output: unfolding nn_integral_snd[OF assms] M2.nn_integral_fst[OF assms] ..


Input: lemma vinsert_compr: "vinsert y A = set {x. x = y \<or> x \<in>\<^sub>\<circ> A}"

Output:
unfolding vunion_def vinsert_def
by simp_all


Input: lemma vle2: "x \<unlhd> y \<Longrightarrow> x \<sqsubseteq> y"

Output: by (metis (full_types) TC_add' add.right_neutral le_TC_def vle_def nonzero_less_TC)


Input:
lemma itrm_brackets_Cons_SomeE:
  assumes "itrm_brackets (v#vs) x = Some x'"
  obtains y' where "itrm_brackets vs x = Some y'" and "itrm_bracket v y' = Some x'"

Output:
using assms unfolding itrm_brackets_def
by (elim foldr_option_Cons_SomeE)


Input:
lemma n_mult_omega_L_below:
  "n(y * x\<^sup>\<omega>) * L \<le> y * x\<^sup>\<star> \<squnion> y * n(x\<^sup>\<omega>) * L"

Output:
using sup_right_divisibility n_mult_omega_L_star
by blast


Input:
lemma sublens_pres_indep:
  "\<lbrakk> X \<subseteq>\<^sub>L Y; Y \<bowtie> Z \<rbrakk> \<Longrightarrow> X \<bowtie> Z"

Output:
apply (auto intro!:lens_indepI simp add: sublens_def lens_comp_def lens_indep_comm)
apply (simp add: lens_indep_sym) done


Input:
lemma
  fixes x y::real
  assumes "abs (x - y) \<le> e"
  obtains err where "x = y + err" "abs err \<le> e"

Output:
using assms
apply atomize_elim
apply (rule exI[where x="x - y"])
by (auto simp: abs_real_def)


Input:
lemma mult_right_dist_inf:
  "(x \<sqinter> y) * z = x * z \<sqinter> y * z"

Output: by (metis dual_dist_sup dual_dist_comp dual_involutive mult_right_dist_sup)


Input: lemma BVG_assign_other: "x\<noteq>y \<Longrightarrow> y\<notin>BVG(Assign x \<theta>)"

Output:
using repv_selectlike_other_converse[where x=x and y=y]
by simp


Input: lemma conjugate_conjr2[simp]: "conjugate (\<lambda>x. x \<rhd> y) = (\<lambda>x. y \<lhd> x)"

Output:
proof - have "conjugate (conjugate (\<lambda>x. y \<lhd> x)) = conjugate (\<lambda>x. x \<rhd> y)"
by simp thus ?thesis
by (metis conj_involution[OF residuated_conjl2])
qed


Input:
lemma fmrel_on_fset_refl_strong:
  assumes "\<And>x y. x |\<in>| S \<Longrightarrow> fmlookup m x = Some y \<Longrightarrow> P y y"
  shows "fmrel_on_fset S P m m"

Output:
unfolding fmrel_on_fset_fmrel_restrict fmrel_iff
using assms
by (simp add: option.rel_sel)


Input:
theorem Theorem_11:
  shows "\<exists>y\<in>match (TruePref.gfp_F ds). (x, y) \<in> Pd' (Xd x)"

Output:
using Theorem_11_fp_cop_F TruePref.Theorem_15_match
by simp


Input:
lemma
  "\<lparr>cx = x, cy = y\<rparr> = \<lparr>cx = x', cy = y'\<rparr> \<Longrightarrow> x = x' \<and> y = y'"

Output:
using [[smt_oracle, z3_extensions]]
by smt+


Input: lemma ShiftP_Zero: "{} \<turnstile> ShiftP Zero k d Zero"

Output:
proof - obtain x::name and x'::name and y::name and z::name where "atom x \<sharp> (x',y,z,k,d)" "atom x' \<sharp> (y,z,k,d)" "atom y \<sharp> (z,k,d)" "atom z \<sharp> (k,d)"
by (metis obtain_fresh) thus ?thesis
by (auto simp: ShiftP.simps [of x x' y z])
qed


Input:
lemma csquare_continuous:
  fixes e :: real
  shows "e > 0 \<Longrightarrow> \<exists>d. 0 < d \<and> (\<forall>y. cmod (y - x) < d \<longrightarrow> cmod (y * y - x * x) < e)"

Output:
using isCont_power[OF continuous_ident, of x, unfolded isCont_def LIM_eq, rule_format, of e 2]
by (force simp add: power2_eq_square)


Input:
lemma degree_max_aform:
  assumes "degree_aform_err x \<le> d"
  assumes "degree_aform_err y \<le> d"
  shows "degree_aform_err (max_aform_err p x y) \<le> d"

Output:
using assms
by (auto simp: max_aform_err_def Let_def Basis_list_real_def split: prod.splits intro!: order_trans[OF degree_aform_independent_from] order_trans[OF degree_aform_of_ivl])


Input:
lemma s_mul_ext_IdI:
  assumes "X \<noteq> {#}" and "M = X + Z" and "N = Y + Z"
    and "\<forall>y \<in> set_mset Y. \<exists>x \<in> set_mset X. (x, y) \<in> R"
  shows "(M, N) \<in> s_mul_ext Id R"

Output:
using assms mult2_alt_sI[of N Z Y M Z X Id "R\<inverse>"]
by (auto simp: s_mul_ext_def ac_simps)


Input: lemma general_product_idempotence: "(\<pi> z. z = x) = x"

Output:
proof - have "\<forall>y. O y x \<longleftrightarrow> (\<exists>z. (\<forall>y. y = x \<longrightarrow> P z y) \<and> O y z)"
by (meson overlap_eq part_reflexivity part_transitivity) thus "(\<pi> z. z = x) = x"
by (rule general_product_intro)
qed


Input:
lemma as_good_as_sameIff[iff]:
  "z \<in> as_good_as y carrier relation \<longleftrightarrow> z \<succeq> y \<and> y \<succeq> z"

Output: by (metis (no_types, lifting) as_good_as_def mem_Collect_eq not_outside)


Input:
lemma not_af:
  "\<not> af A P \<Longrightarrow> (\<exists>x y. x \<in> A \<and> y \<in> A \<and> \<not> P x y) \<and> (\<exists>x\<in>A. \<not> af A (\<lambda>y z. P y z \<or> P x y))"

Output:
unfolding af.simps [of A P]
by blast


Input:
lemma diamond_L_left_isotone:
  "x \<le> y \<Longrightarrow> \<parallel>x\<guillemotright>z \<le> \<parallel>y\<guillemotright>z"

Output:
using mult_left_isotone ni_def ni_isotone ndiamond_L_def
by auto


Input:
lemma pell_valuation_neg_pos:
  assumes "x < 0" "y > 0" "solution (x, y)"
  shows   "pell_valuation (x, y) \<in> {-1<..<0}"

Output:
using pell_valuation_pos_neg[of "-x" "-y"] assms
by simp


Input: lemma pure_tree_inject[simp]: "pure_tree x = pure_tree y \<longleftrightarrow> x = y"

Output:
proof assume "pure_tree x = pure_tree y" hence "root (pure_tree x) = root (pure_tree y)"
by simp thus "x = y"
by simp
qed simp


Input:
lemma alg_dvd_trans [trans]:
  fixes x y z :: "'a :: field_char_0"
  shows "x alg_dvd y \<Longrightarrow> y alg_dvd z \<Longrightarrow> x alg_dvd z"

Output:
using algebraic_int_times[of "y / x" "z / y"]
by (auto simp: alg_dvd_def)


Input:
lemma weakPsiCongResComm:
  fixes x :: name
  and   \<Psi> :: 'b
  and   y :: name
  and   P :: "('a, 'b, 'c) psi"

  assumes "x \<sharp> \<Psi>"
  and     "y \<sharp> \<Psi>"

  shows "\<Psi> \<rhd> \<lparr>\<nu>x\<rparr>(\<lparr>\<nu>y\<rparr>P) \<doteq> \<lparr>\<nu>y\<rparr>(\<lparr>\<nu>x\<rparr>P)"

Output:
using assms
by(metis bisimResComm strongBisimWeakPsiCong)


Input:
lemma pt_set_infinite_ineq:
  fixes X  :: "'x set"
  and   pi :: "'y prm"
  assumes pt: "pt TYPE('x) TYPE('y)"
  and     at: "at TYPE('y)"
  shows "infinite (pi\<bullet>X) = infinite X"

Output:
using pt at
by (simp add: pt_set_finite_ineq)


Input: lemma "Suc (Suc 1) * (x + Suc 1 * y) = 3 * x + 6 * y"

Output: apply (reflection Inum_eqs' only: "Suc (Suc 1) * (x + Suc 1 * y)") oops


Input:
lemma fractrel_iff_normalize_quot_eq:
  "fractrel x y \<longleftrightarrow> normalize_quot x = normalize_quot y \<and> snd x \<noteq> 0 \<and> snd y \<noteq> 0"

Output: by (cases x, cases y) (auto simp: fractrel_def normalize_quot_eq_iff)


Input:
lemma maxR_commute:
  shows "{x,y} \<subseteq> Field r \<Longrightarrow> maxR x y = maxR y x"

Output:
using r_Linear_order unfolding maxR_def
by (fastforce simp: order_on_defs antisym_def total_on_def)


Input: lemma eexp_inj[simp]: "eexp x = eexp y \<longleftrightarrow> x = y"

Output: by (cases x; cases y; simp)


Input:
lemma (in aGroup) ag_plus_zero:"\<lbrakk>x \<in> carrier A; y \<in> carrier A\<rbrakk> \<Longrightarrow>
                     (x = -\<^sub>a y)  = (x \<plusminus> y = \<zero>)"

Output:
apply (rule iffI)
apply (simp add:ag_l_inv1)
apply (simp add:ag_pOp_commute[of "x" "y"])
apply (rule ag_inv_unique[of "y" "x"], assumption+) done


Input: lemma mset_le_single_iff[iff]: "{#x#} \<le> {#y#} \<longleftrightarrow> x \<le> y" for x y :: "'a::order"

Output:
unfolding less_eq_multiset\<^sub>H\<^sub>O
by force


Input:
lemma domainCharacteristicFunction:
  "Domain (X <|| Y) = X \<union> Y"

Output:
using domainConstant paste_Domain sup_commute
by metis


Input: lemma rfb_set: "fb\<^sub>\<R> R Y = {x. \<forall>y. (x,y) \<in> R \<longrightarrow> y \<in> Y}"

Output:
unfolding rfb_def ffb_prop_var comp_def klift_def f2r_def r2f_def kop_def
by force


Input: lemma iteration_subdenest: "x\<^sup>\<infinity> \<cdot> y\<^sup>\<infinity> \<le> (x + y)\<^sup>\<infinity>"

Output: by (metis add_commute iteration_idem iteration_subdist local.mult_isol_var)


Input:
lemma G_eq_real_suminf:
  "convergence_G x y (1::real) \<Longrightarrow> G x y = ennreal (\<Sum>i. p x y i)"

Output:
unfolding G_eq_suminf
by (intro suminf_ennreal ennreal_suminf_neq_top p_nonneg) (auto simp: convergence_G_def p_def)


Input: lemma lprod_3_1: assumes "(x', x) \<in> R" shows "([y, z, x'], [x, y, z]) \<in> lprod R"

Output:
apply (rule lprod_list[where a="y" and b="y" and ah="[]" and at="[z,x']" and bh="[x]" and bt="[z]", simplified])
apply (auto simp add: lprod_2_1 assms) done


Input:
lemma cont_case_prodI:
  assumes "monotone (rel_prod orda ordb) (\<le>) (case_prod f)"
  and "\<And>x. cont lubb ordb Sup (\<le>) (\<lambda>y. f x y)"
  and "\<And>y. cont luba orda Sup (\<le>) (\<lambda>x. f x y)"
  and "class.preorder orda (mk_less orda)"
  and "class.preorder ordb (mk_less ordb)"
  shows "cont (prod_lub luba lubb) (rel_prod orda ordb) Sup (\<le>) (case_prod f)"

Output: by(rule cont_prodI)(simp_all add: assms)


Input: lemma if_pres_disj: "x \<in> disjunctive \<Longrightarrow> y \<in> disjunctive \<Longrightarrow> (If p then x else y) \<in> disjunctive"

Output:
apply (unfold if_assertion)
by (simp add: sup_pres_disj comp_pres_disj assertion_disjunctive)


Input:
lemma nested_bind [simp]:
  "do x <- do y <- f; return (g y) od; h x od =
   do y <- f; h (g y) od"

Output:
apply (clarsimp simp add: bind_def)
apply (rule ext)
apply (clarsimp simp add: Let_def split_def return_def) done


Input:
lemma loop_semantics:
  "\<kappa> (\<lambda>x . y * x \<squnion> z) = \<mu> (\<lambda>x . y * x \<squnion> z) \<squnion> n(\<nu> (\<lambda>x . y * x \<squnion> z)) * L"

Output:
using apx.least_fixpoint_char loop_apx_least_fixpoint
by auto


Input:
lemma
  assumes "\<forall>x\<in>{0::int..}. \<exists>y\<in>{0..}. \<exists>z\<in>{0..}. x + 3 * y = 5 * z"
  shows "\<forall>x::nat. \<exists>y z. x + 3 * y = 5 * z"

Output:
apply transfer
apply fact done


Input: lemma ordinal_le_div: "\<lbrakk>0 < y; y * z \<le> x\<rbrakk> \<Longrightarrow> (z::ordinal) \<le> x div y"

Output:
apply (auto simp add: div_ordinal_def)
apply (simp add: normal.le_oInv[OF normal_times]) done


Input: lemma real_sqrt_eq_iff [simp]: "sqrt x = sqrt y \<longleftrightarrow> x = y"

Output:
unfolding sqrt_def
by (rule real_root_eq_iff [OF pos2])