# HG changeset patch # User wenzelm # Date 1451641740 -3600 # Node ID 5d208fd2507d07bb9f64ff0e40c61bf3f1b3b3b9 # Parent 9de1eb745aebd614e12354e0c5e24c019bd30d99 isabelle update_cartouches -c -t; diff -r 9de1eb745aeb -r 5d208fd2507d src/CCL/CCL.thy --- a/src/CCL/CCL.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/CCL/CCL.thy Fri Jan 01 10:49:00 2016 +0100 @@ -303,7 +303,7 @@ and [dest!] = ccl_injDs -subsection \Facts from gfp Definition of @{text "[="} and @{text "="}\ +subsection \Facts from gfp Definition of \[=\ and \=\\ lemma XHlemma1: "\A=B; a:B \ P\ \ a:A \ P" by simp @@ -422,7 +422,7 @@ lemmas npo_rls = npo_pair_lam npo_lam_pair npo_rls1 -subsection \Coinduction for @{text "[="}\ +subsection \Coinduction for \[=\\ lemma po_coinduct: "\ : R; R <= POgen(R)\ \ t [= u" apply (rule PO_def [THEN def_coinduct, THEN PO_iff [THEN iffD2]]) diff -r 9de1eb745aeb -r 5d208fd2507d src/CCL/Gfp.thy --- a/src/CCL/Gfp.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/CCL/Gfp.thy Fri Jan 01 10:49:00 2016 +0100 @@ -10,7 +10,7 @@ begin definition - gfp :: "['a set\'a set] \ 'a set" where -- "greatest fixed point" + gfp :: "['a set\'a set] \ 'a set" where \ "greatest fixed point" "gfp(f) == Union({u. u <= f(u)})" (* gfp(f) is the least upper bound of {u. u <= f(u)} *) @@ -90,7 +90,7 @@ done -subsection \Definition forms of @{text "gfp_Tarski"}, to control unfolding\ +subsection \Definition forms of \gfp_Tarski\, to control unfolding\ lemma def_gfp_Tarski: "\h == gfp(f); mono(f)\ \ h = f(h)" apply unfold diff -r 9de1eb745aeb -r 5d208fd2507d src/CCL/Hered.thy --- a/src/CCL/Hered.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/CCL/Hered.thy Fri Jan 01 10:49:00 2016 +0100 @@ -10,8 +10,8 @@ begin text \ - Note that this is based on an untyped equality and so @{text "lam - x. b(x)"} is only hereditarily terminating if @{text "ALL x. b(x)"} + Note that this is based on an untyped equality and so \lam + x. b(x)\ is only hereditarily terminating if \ALL x. b(x)\ is. Not so useful for functions! \ diff -r 9de1eb745aeb -r 5d208fd2507d src/CCL/Lfp.thy --- a/src/CCL/Lfp.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/CCL/Lfp.thy Fri Jan 01 10:49:00 2016 +0100 @@ -10,7 +10,7 @@ begin definition - lfp :: "['a set\'a set] \ 'a set" where -- "least fixed point" + lfp :: "['a set\'a set] \ 'a set" where \ "least fixed point" "lfp(f) == Inter({u. f(u) <= u})" (* lfp(f) is the greatest lower bound of {u. f(u) <= u} *) diff -r 9de1eb745aeb -r 5d208fd2507d src/CCL/Set.thy --- a/src/CCL/Set.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/CCL/Set.thy Fri Jan 01 10:49:00 2016 +0100 @@ -411,7 +411,7 @@ by (blast intro: equalityI elim: equalityE) -subsection \Simple properties of @{text "Compl"} -- complement of a set\ +subsection \Simple properties of \Compl\ -- complement of a set\ lemma Compl_disjoint: "A Int Compl(A) = {x. False}" by (blast intro: equalityI) diff -r 9de1eb745aeb -r 5d208fd2507d src/CCL/Term.thy --- a/src/CCL/Term.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/CCL/Term.thy Fri Jan 01 10:49:00 2016 +0100 @@ -291,7 +291,7 @@ \ -subsection \Rules for pre-order @{text "[="}\ +subsection \Rules for pre-order \[=\\ lemma term_porews: "inl(a) [= inl(a') \ a [= a'" diff -r 9de1eb745aeb -r 5d208fd2507d src/CCL/Trancl.thy --- a/src/CCL/Trancl.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/CCL/Trancl.thy Fri Jan 01 10:49:00 2016 +0100 @@ -25,7 +25,7 @@ where "r^+ == r O rtrancl(r)" -subsection \Natural deduction for @{text "trans(r)"}\ +subsection \Natural deduction for \trans(r)\\ lemma transI: "(\x y z. \:r; :r\ \ :r) \ trans(r)" unfolding trans_def by blast diff -r 9de1eb745aeb -r 5d208fd2507d src/CCL/Type.thy --- a/src/CCL/Type.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/CCL/Type.thy Fri Jan 01 10:49:00 2016 +0100 @@ -364,8 +364,7 @@ done -subsection \Lemmas and tactics for using the rule @{text - "coinduct3"} on @{text "[="} and @{text "="}\ +subsection \Lemmas and tactics for using the rule \coinduct3\ on \[=\ and \=\\ lemma lfpI: "\mono(f); a : f(lfp(f))\ \ a : lfp(f)" apply (erule lfp_Tarski [THEN ssubst]) diff -r 9de1eb745aeb -r 5d208fd2507d src/Cube/Example.thy --- a/src/Cube/Example.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/Cube/Example.thy Fri Jan 01 10:49:00 2016 +0100 @@ -149,7 +149,7 @@ schematic_goal (in LP2) "A:* P:A\A\* \ ?p: (\a:A. \b:A. P\a\b\P\b\a\\P:*.P) \ \a:A. P\a\a\\P:*.P" - -- \Antisymmetry implies irreflexivity:\ + \ \Antisymmetry implies irreflexivity:\ apply (strip_asms rules) apply (rule lam_ss) apply (depth_solve1 rules) @@ -206,7 +206,7 @@ schematic_goal (in LP2) "A:* a:A b:A \ ?p: (\P:A\*.P\a\P\b) \ (\P:A\*.P\b\P\a)" - -- \Symmetry of Leibnitz equality\ + \ \Symmetry of Leibnitz equality\ apply (strip_asms rules) apply (rule lam_ss) apply (depth_solve1 rules) diff -r 9de1eb745aeb -r 5d208fd2507d src/FOL/FOL.thy --- a/src/FOL/FOL.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOL/FOL.thy Fri Jan 01 10:49:00 2016 +0100 @@ -26,7 +26,7 @@ by (erule FalseE [THEN classical]) -subsubsection \Classical introduction rules for @{text "\"} and @{text "\"}\ +subsubsection \Classical introduction rules for \\\ and \\\\ lemma disjCI: "(\ Q \ P) \ P \ Q" apply (rule classical) @@ -34,7 +34,7 @@ apply (erule notE disjI2)+ done -text \Introduction rule involving only @{text "\"}\ +text \Introduction rule involving only \\\\ lemma ex_classical: assumes r: "\ (\x. P(x)) \ P(a)" shows "\x. P(x)" @@ -42,7 +42,7 @@ apply (rule exI, erule r) done -text \Version of above, simplifying @{text "\\"} to @{text "\\"}.\ +text \Version of above, simplifying \\\\ to \\\\.\ lemma exCI: assumes r: "\x. \ P(x) \ P(a)" shows "\x. P(x)" @@ -79,7 +79,7 @@ subsection \Special elimination rules\ -text \Classical implies (@{text "\"}) elimination.\ +text \Classical implies (\\\) elimination.\ lemma impCE: assumes major: "P \ Q" and r1: "\ P \ R" @@ -92,8 +92,7 @@ done text \ - This version of @{text "\"} elimination works on @{text Q} before @{text - P}. It works best for those cases in which P holds ``almost everywhere''. + This version of \\\ elimination works on \Q\ before \P\. It works best for those cases in which P holds ``almost everywhere''. Can't install as default: would break old proofs. \ lemma impCE': @@ -124,8 +123,8 @@ subsubsection \Tactics for implication and contradiction\ text \ - Classical @{text "\"} elimination. Proof substitutes @{text "P = Q"} in - @{text "\ P \ \ Q"} and @{text "P \ Q"}. + Classical \\\ elimination. Proof substitutes \P = Q\ in + \\ P \ \ Q\ and \P \ Q\. \ lemma iffCE: assumes major: "P \ Q" @@ -218,7 +217,7 @@ lemma ex1_functional: "\\! z. P(a,z); P(a,b); P(a,c)\ \ b = c" by blast -text \Elimination of @{text True} from assumptions:\ +text \Elimination of \True\ from assumptions:\ lemma True_implies_equals: "(True \ PROP P) \ PROP P" proof assume "True \ PROP P" @@ -248,7 +247,7 @@ subsection \Classical simplification rules\ text \ - Avoids duplication of subgoals after @{text expand_if}, when the true and + Avoids duplication of subgoals after \expand_if\, when the true and false cases boil down to the same thing. \ @@ -259,8 +258,8 @@ subsubsection \Miniscoping: pushing quantifiers in\ text \ - We do NOT distribute of @{text "\"} over @{text "\"}, or dually that of - @{text "\"} over @{text "\"}. + We do NOT distribute of \\\ over \\\, or dually that of + \\\ over \\\. Baaz and Leitsch, On Skolemization and Proof Complexity (1994) show that this step can increase proof length! @@ -314,8 +313,8 @@ lemmas meta_simps = - triv_forall_equality -- \prunes params\ - True_implies_equals -- \prune asms @{text True}\ + triv_forall_equality \ \prunes params\ + True_implies_equals \ \prune asms \True\\ lemmas IFOL_simps = refl [THEN P_iff_T] conj_simps disj_simps not_simps diff -r 9de1eb745aeb -r 5d208fd2507d src/FOL/IFOL.thy --- a/src/FOL/IFOL.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOL/IFOL.thy Fri Jan 01 10:49:00 2016 +0100 @@ -89,7 +89,7 @@ definition Ex1 :: "('a \ o) \ o" (binder "\!" 10) where ex1_def: "\!x. P(x) \ \x. P(x) \ (\y. P(y) \ y = x)" -axiomatization where -- \Reflection, admissible\ +axiomatization where \ \Reflection, admissible\ eq_reflection: "(x = y) \ (x \ y)" and iff_reflection: "(P \ Q) \ (P \ Q)" @@ -119,7 +119,7 @@ unfolding True_def by (rule impI) -subsubsection \Sequent-style elimination rules for @{text "\"} @{text "\"} and @{text "\"}\ +subsubsection \Sequent-style elimination rules for \\\ \\\ and \\\\ lemma conjE: assumes major: "P \ Q" @@ -159,7 +159,7 @@ done -subsubsection \Negation rules, which translate between @{text "\ P"} and @{text "P \ False"}\ +subsubsection \Negation rules, which translate between \\ P\ and \P \ False\\ lemma notI: "(P \ False) \ \ P" unfolding not_def by (erule impI) @@ -170,7 +170,7 @@ lemma rev_notE: "\P; \ P\ \ R" by (erule notE) -text \This is useful with the special implication rules for each kind of @{text P}.\ +text \This is useful with the special implication rules for each kind of \P\.\ lemma not_to_imp: assumes "\ P" and r: "P \ False \ Q" @@ -181,9 +181,8 @@ done text \ - For substitution into an assumption @{text P}, reduce @{text Q} to @{text - "P \ Q"}, substitute into this implication, then apply @{text impI} to - move @{text P} back into the assumptions. + For substitution into an assumption \P\, reduce \Q\ to \P \ Q\, substitute into this implication, then apply \impI\ to + move \P\ back into the assumptions. \ lemma rev_mp: "\P; P \ Q\ \ Q" by (erule mp) @@ -201,8 +200,8 @@ subsubsection \Modus Ponens Tactics\ text \ - Finds @{text "P \ Q"} and P in the assumptions, replaces implication by - @{text Q}. + Finds \P \ Q\ and P in the assumptions, replaces implication by + \Q\. \ ML \ fun mp_tac ctxt i = @@ -232,7 +231,7 @@ done -subsubsection \Destruct rules for @{text "\"} similar to Modus Ponens\ +subsubsection \Destruct rules for \\\ similar to Modus Ponens\ lemma iffD1: "\P \ Q; P\ \ Q" apply (unfold iff_def) @@ -301,10 +300,9 @@ done -subsubsection \@{text "\"} congruence rules for simplification\ +subsubsection \\\\ congruence rules for simplification\ -text \Use @{text iffE} on a premise. For @{text conj_cong}, @{text - imp_cong}, @{text all_cong}, @{text ex_cong}.\ +text \Use \iffE\ on a premise. For \conj_cong\, \imp_cong\, \all_cong\, \ex_cong\.\ ML \ fun iff_tac ctxt prems i = resolve_tac ctxt (prems RL @{thms iffE}) i THEN @@ -415,7 +413,7 @@ apply (erule (1) subst) done -text \A special case of @{text ex1E} that would otherwise need quantifier +text \A special case of \ex1E\ that would otherwise need quantifier expansion.\ lemma ex1_equalsE: "\\!x. P(x); P(a); P(b)\ \ a = b" apply (erule ex1E) @@ -457,7 +455,7 @@ apply assumption+ done -text \Dual of @{text box_equals}: for proving equalities backwards.\ +text \Dual of \box_equals\: for proving equalities backwards.\ lemma simp_equals: "\a = c; b = d; c = d\ \ a = b" apply (rule trans) apply (rule trans) @@ -499,8 +497,8 @@ subsection \Simplifications of assumed implications\ text \ - Roy Dyckhoff has proved that @{text conj_impE}, @{text disj_impE}, and - @{text imp_impE} used with @{ML mp_tac} (restricted to atomic formulae) is + Roy Dyckhoff has proved that \conj_impE\, \disj_impE\, and + \imp_impE\ used with @{ML mp_tac} (restricted to atomic formulae) is COMPLETE for intuitionistic propositional logic. See R. Dyckhoff, Contraction-free sequent calculi for intuitionistic logic @@ -547,7 +545,7 @@ apply (assumption | rule iffI impI major [THEN mp] r1 r2 r3)+ done -text \What if @{text "(\x. \ \ P(x)) \ \ \ (\x. P(x))"} is an assumption? +text \What if \(\x. \ \ P(x)) \ \ \ (\x. P(x))\ is an assumption? UNSAFE.\ lemma all_impE: assumes major: "(\x. P(x)) \ S" @@ -558,8 +556,8 @@ done text \ - Unsafe: @{text "\x. P(x)) \ S"} is equivalent - to @{text "\x. P(x) \ S"}.\ + Unsafe: \\x. P(x)) \ S\ is equivalent + to \\x. P(x) \ S\.\ lemma ex_impE: assumes major: "(\x. P(x)) \ S" and r: "P(x) \ S \ R" @@ -829,7 +827,7 @@ "(P \ False) \ \ P" by iprover+ -text \The @{text "x = t"} versions are needed for the simplification +text \The \x = t\ versions are needed for the simplification procedures.\ lemma quant_simps: "\P. (\x. P) \ P" diff -r 9de1eb745aeb -r 5d208fd2507d src/FOL/ex/Classical.thy --- a/src/FOL/ex/Classical.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOL/ex/Classical.thy Fri Jan 01 10:49:00 2016 +0100 @@ -321,9 +321,9 @@ by blast text \ - Other proofs: Can use @{text auto}, which cheats by using rewriting! - @{text Deepen_tac} alone requires 253 secs. Or - @{text \by (mini_tac 1 THEN Deepen_tac 5 1)\}. + Other proofs: Can use \auto\, which cheats by using rewriting! + \Deepen_tac\ alone requires 253 secs. Or + \by (mini_tac 1 THEN Deepen_tac 5 1)\. \ text\44\ @@ -366,7 +366,7 @@ apply safe apply (rule_tac x = a in allE, assumption) apply (rule_tac x = b in allE, assumption) - apply fast -- \blast's treatment of equality can't do it\ + apply fast \ \blast's treatment of equality can't do it\ done text\50. (What has this to do with equality?)\ @@ -399,7 +399,7 @@ (\x. hates(agatha,x) \ hates(butler,x)) \ (\x. \ hates(x,agatha) \ \ hates(x,butler) \ \ hates(x,charles)) \ killed(?who,agatha)" - by fast -- \MUCH faster than blast\ + by fast \ \MUCH faster than blast\ text\56\ @@ -468,7 +468,7 @@ ((C(y) \ Q(w,y,y)) \ OO(w,b) \ P(v,y) \ OO(v,b))))) \ \ (\x. A(x) \ (\y. C(y) \ (\z. D(x,y,z))))" by (blast 12) - -- \Needed because the search for depths below 12 is very slow.\ + \ \Needed because the search for depths below 12 is very slow.\ text \ diff -r 9de1eb745aeb -r 5d208fd2507d src/FOL/ex/If.thy --- a/src/FOL/ex/If.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOL/ex/If.thy Fri Jan 01 10:49:00 2016 +0100 @@ -26,7 +26,7 @@ apply (rule ifI) oops -text\Trying again from the beginning in order to use @{text blast}\ +text\Trying again from the beginning in order to use \blast\\ declare ifI [intro!] declare ifE [elim!] @@ -45,7 +45,7 @@ text \An invalid formula. High-level rules permit a simpler diagnosis.\ lemma "if(if(P,Q,R), A, B) \ if(P, if(Q,A,B), if(R,B,A))" apply auto - -- \The next step will fail unless subgoals remain\ + \ \The next step will fail unless subgoals remain\ apply (tactic all_tac) oops @@ -53,7 +53,7 @@ lemma "if(if(P,Q,R), A, B) \ if(P, if(Q,A,B), if(R,B,A))" unfolding if_def apply auto - -- \The next step will fail unless subgoals remain\ + \ \The next step will fail unless subgoals remain\ apply (tactic all_tac) oops diff -r 9de1eb745aeb -r 5d208fd2507d src/FOL/ex/Intro.thy --- a/src/FOL/ex/Intro.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOL/ex/Intro.thy Fri Jan 01 10:49:00 2016 +0100 @@ -30,7 +30,7 @@ apply assumption+ done -text \Correct version, delaying use of @{text spec} until last.\ +text \Correct version, delaying use of \spec\ until last.\ lemma "(\x y. P(x,y)) \ (\z w. P(w,z))" apply (rule impI) apply (rule allI) @@ -41,7 +41,7 @@ done -subsubsection \Demonstration of @{text "fast"}\ +subsubsection \Demonstration of \fast\\ lemma "(\y. \x. J(y,x) \ \ J(x,x)) \ \ (\x. \y. \z. J(z,y) \ \ J(z,x))" apply fast diff -r 9de1eb745aeb -r 5d208fd2507d src/FOL/ex/Intuitionistic.thy --- a/src/FOL/ex/Intuitionistic.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOL/ex/Intuitionistic.thy Fri Jan 01 10:49:00 2016 +0100 @@ -82,12 +82,12 @@ The attempt to prove them terminates quickly!\ lemma "((P \ Q) \ P) \ P" apply (tactic \IntPr.fast_tac @{context} 1\)? -apply (rule asm_rl) --\Checks that subgoals remain: proof failed.\ +apply (rule asm_rl) \\Checks that subgoals remain: proof failed.\ oops lemma "(P \ Q \ R) \ (P \ R) \ (Q \ R)" apply (tactic \IntPr.fast_tac @{context} 1\)? -apply (rule asm_rl) --\Checks that subgoals remain: proof failed.\ +apply (rule asm_rl) \\Checks that subgoals remain: proof failed.\ oops @@ -121,7 +121,7 @@ lemma "(\x. \y. \z. p(x) \ q(y) \ r(z)) \ (\z. \y. \x. p(x) \ q(y) \ r(z))" - by (tactic \IntPr.best_dup_tac @{context} 1\) --\SLOW\ + by (tactic \IntPr.best_dup_tac @{context} 1\) \\SLOW\ text\Problem 3.1\ lemma "\ (\x. \y. mem(y,x) \ \ mem(x,x))" @@ -136,11 +136,11 @@ subsection \Intuitionistic FOL: propositional problems based on Pelletier.\ -text\@{text "\\"}1\ +text\\\\\1\ lemma "\ \ ((P \ Q) \ (\ Q \ \ P))" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}2\ +text\\\\\2\ lemma "\ \ (\ \ P \ P)" by (tactic \IntPr.fast_tac @{context} 1\) @@ -148,23 +148,23 @@ lemma "\ (P \ Q) \ (Q \ P)" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}4\ +text\\\\\4\ lemma "\ \ ((\ P \ Q) \ (\ Q \ P))" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}5\ +text\\\\\5\ lemma "\ \ ((P \ Q \ P \ R) \ P \ (Q \ R))" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}6\ +text\\\\\6\ lemma "\ \ (P \ \ P)" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}7\ +text\\\\\7\ lemma "\ \ (P \ \ \ \ P)" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}8. Peirce's law\ +text\\\\\8. Peirce's law\ lemma "\ \ (((P \ Q) \ P) \ P)" by (tactic \IntPr.fast_tac @{context} 1\) @@ -182,7 +182,7 @@ lemma "P \ P" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}12. Dijkstra's law\ +text\\\\\12. Dijkstra's law\ lemma "\ \ (((P \ Q) \ R) \ (P \ (Q \ R)))" by (tactic \IntPr.fast_tac @{context} 1\) @@ -193,19 +193,19 @@ lemma "P \ (Q \ R) \ (P \ Q) \ (P \ R)" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}14\ +text\\\\\14\ lemma "\ \ ((P \ Q) \ ((Q \ \ P) \ (\ Q \ P)))" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}15\ +text\\\\\15\ lemma "\ \ ((P \ Q) \ (\ P \ Q))" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}16\ +text\\\\\16\ lemma "\ \ ((P \ Q) \ (Q \ P))" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}17\ +text\\\\\17\ lemma "\ \ (((P \ (Q \ R)) \ S) \ ((\ P \ Q \ S) \ (\ P \ \ R \ S)))" by (tactic \IntPr.fast_tac @{context} 1\) @@ -239,28 +239,28 @@ lemma "((\x. P(x)) \ Q) \ (\x. P(x) \ Q)" apply (tactic \IntPr.fast_tac @{context} 1\)? - apply (rule asm_rl) --\Checks that subgoals remain: proof failed.\ + apply (rule asm_rl) \\Checks that subgoals remain: proof failed.\ oops lemma "(P \ (\x. Q(x))) \ (\x. P \ Q(x))" apply (tactic \IntPr.fast_tac @{context} 1\)? - apply (rule asm_rl) --\Checks that subgoals remain: proof failed.\ + apply (rule asm_rl) \\Checks that subgoals remain: proof failed.\ oops lemma "(\x. P(x) \ Q) \ ((\x. P(x)) \ Q)" apply (tactic \IntPr.fast_tac @{context} 1\)? - apply (rule asm_rl) --\Checks that subgoals remain: proof failed.\ + apply (rule asm_rl) \\Checks that subgoals remain: proof failed.\ oops lemma "(\x. \ \ P(x)) \ \ \ (\x. P(x))" apply (tactic \IntPr.fast_tac @{context} 1\)? - apply (rule asm_rl) --\Checks that subgoals remain: proof failed.\ + apply (rule asm_rl) \\Checks that subgoals remain: proof failed.\ oops text \Classically but not intuitionistically valid. Proved by a bug in 1986!\ lemma "\x. Q(x) \ (\x. Q(x))" apply (tactic \IntPr.fast_tac @{context} 1\)? - apply (rule asm_rl) --\Checks that subgoals remain: proof failed.\ + apply (rule asm_rl) \\Checks that subgoals remain: proof failed.\ oops @@ -271,13 +271,13 @@ require quantifier duplication -- not currently available. \ -text\@{text "\\"}18\ +text\\\\\18\ lemma "\ \ (\y. \x. P(y) \ P(x))" - oops -- \NOT PROVED\ + oops \ \NOT PROVED\ -text\@{text "\\"}19\ +text\\\\\19\ lemma "\ \ (\x. \y z. (P(y) \ Q(z)) \ (P(x) \ Q(x)))" - oops -- \NOT PROVED\ + oops \ \NOT PROVED\ text\20\ lemma @@ -287,13 +287,13 @@ text\21\ lemma "(\x. P \ Q(x)) \ (\x. Q(x) \ P) \ \ \ (\x. P \ Q(x))" - oops -- \NOT PROVED; needs quantifier duplication\ + oops \ \NOT PROVED; needs quantifier duplication\ text\22\ lemma "(\x. P \ Q(x)) \ (P \ (\x. Q(x)))" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}23\ +text\\\\\23\ lemma "\ \ ((\x. P \ Q(x)) \ (P \ (\x. Q(x))))" by (tactic \IntPr.fast_tac @{context} 1\) @@ -303,8 +303,8 @@ (\ (\x. P(x)) \ (\x. Q(x))) \ (\x. Q(x) \ R(x) \ S(x)) \ \ \ (\x. P(x) \ R(x))" text \ - Not clear why @{text fast_tac}, @{text best_tac}, @{text ASTAR} and - @{text ITER_DEEPEN} all take forever. + Not clear why \fast_tac\, \best_tac\, \ASTAR\ and + \ITER_DEEPEN\ all take forever. \ apply (tactic \IntPr.safe_tac @{context}\) apply (erule impE) @@ -321,12 +321,12 @@ \ (\x. Q(x) \ P(x))" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}26\ +text\\\\\26\ lemma "(\ \ (\x. p(x)) \ \ \ (\x. q(x))) \ (\x. \y. p(x) \ q(y) \ (r(x) \ s(y))) \ ((\x. p(x) \ r(x)) \ (\x. q(x) \ s(x)))" - oops --\NOT PROVED\ + oops \\NOT PROVED\ text\27\ lemma @@ -337,7 +337,7 @@ \ (\x. M(x) \ \ L(x))" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}28. AMENDED\ +text\\\\\28. AMENDED\ lemma "(\x. P(x) \ (\x. Q(x))) \ (\ \ (\x. Q(x) \ R(x)) \ (\x. Q(x) \ S(x))) \ @@ -352,7 +352,7 @@ (\x y. P(x) \ Q(y) \ R(x) \ S(y)))" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}30\ +text\\\\\30\ lemma "(\x. (P(x) \ Q(x)) \ \ R(x)) \ (\x. (Q(x) \ \ S(x)) \ P(x) \ R(x)) @@ -375,7 +375,7 @@ \ (\x. P(x) \ M(x) \ L(x))" by (tactic \IntPr.fast_tac @{context} 1\) -text\@{text "\\"}33\ +text\\\\\33\ lemma "(\x. \ \ (P(a) \ (P(x) \ P(b)) \ P(c))) \ (\x. \ \ ((\ P(a) \ P(x) \ P(c)) \ (\ P(a) \ \ P(b) \ P(c))))" @@ -398,7 +398,7 @@ (\x z. \ P(x,z) \ (\y. Q(y,z))) \ (\ \ (\x y. Q(x,y)) \ (\x. R(x,x))) \ \ \ (\x. \y. R(x,y))" - oops --\NOT PROVED\ + oops \\NOT PROVED\ text\39\ lemma "\ (\x. \y. F(y,x) \ \ F(y,y))" diff -r 9de1eb745aeb -r 5d208fd2507d src/FOL/ex/Locale_Test/Locale_Test1.thy --- a/src/FOL/ex/Locale_Test/Locale_Test1.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOL/ex/Locale_Test/Locale_Test1.thy Fri Jan 01 10:49:00 2016 +0100 @@ -86,7 +86,7 @@ locale pert_hom = d1: perturbation f d1 + d2: perturbation f d2 for f d1 d2 print_locale! pert_hom thm pert_hom_def -text \Alternative expression, obtaining nicer names in @{text "semi f"}.\ +text \Alternative expression, obtaining nicer names in \semi f\.\ locale pert_hom' = semi f + d1: perturbation f d1 + d2: perturbation f d2 for f d1 d2 print_locale! pert_hom' thm pert_hom'_def @@ -731,12 +731,12 @@ proof - show "dgrp(prod)" by unfold_locales from this interpret d: dgrp . - -- Unit + \ Unit have "dgrp.one(prod) = glob_one(prod)" by (rule d.one_def) also have "... = glob_one(prod) ** one" by (simp add: rone) also have "... = one" by (simp add: glob_lone) finally show "dgrp.one(prod) = one" . - -- Inverse + \ Inverse then have "dgrp.inv(prod, x) ** x = inv(x) ** x" by (simp add: glob_linv d.linv linv) then show "dgrp.inv(prod, x) = inv(x)" by (simp add: rcancel) qed diff -r 9de1eb745aeb -r 5d208fd2507d src/FOL/ex/Nat_Class.thy --- a/src/FOL/ex/Nat_Class.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOL/ex/Nat_Class.thy Fri Jan 01 10:49:00 2016 +0100 @@ -7,11 +7,11 @@ begin text \ - This is an abstract version of theory @{text Nat}. Instead of - axiomatizing a single type @{text nat} we define the class of all + This is an abstract version of theory \Nat\. Instead of + axiomatizing a single type \nat\ we define the class of all these types (up to isomorphism). - Note: The @{text rec} operator had to be made \emph{monomorphic}, + Note: The \rec\ operator had to be made \emph{monomorphic}, because class axioms may not contain more than one type variable. \ diff -r 9de1eb745aeb -r 5d208fd2507d src/FOL/ex/Prolog.thy --- a/src/FOL/ex/Prolog.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOL/ex/Prolog.thy Fri Jan 01 10:49:00 2016 +0100 @@ -56,7 +56,7 @@ done schematic_goal "rev(?x, a:b:c:Nil)" -apply (rule rules)+ -- \does not solve it directly!\ +apply (rule rules)+ \ \does not solve it directly!\ back back done diff -r 9de1eb745aeb -r 5d208fd2507d src/FOL/ex/Propositional_Cla.thy --- a/src/FOL/ex/Propositional_Cla.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOL/ex/Propositional_Cla.thy Fri Jan 01 10:49:00 2016 +0100 @@ -9,7 +9,7 @@ imports FOL begin -text \commutative laws of @{text "\"} and @{text "\"}\ +text \commutative laws of \\\ and \\\\ lemma "P \ Q \ Q \ P" by (tactic "IntPr.fast_tac @{context} 1") @@ -18,7 +18,7 @@ by fast -text \associative laws of @{text "\"} and @{text "\"}\ +text \associative laws of \\\ and \\\\ lemma "(P \ Q) \ R \ P \ (Q \ R)" by fast @@ -26,7 +26,7 @@ by fast -text \distributive laws of @{text "\"} and @{text "\"}\ +text \distributive laws of \\\ and \\\\ lemma "(P \ Q) \ R \ (P \ R) \ (Q \ R)" by fast @@ -60,16 +60,16 @@ text \Propositions-as-types\ --- \The combinator K\ +\ \The combinator K\ lemma "P \ (Q \ P)" by fast --- \The combinator S\ +\ \The combinator S\ lemma "(P \ Q \ R) \ (P \ Q) \ (P \ R)" by fast --- \Converse is classical\ +\ \Converse is classical\ lemma "(P \ Q) \ (P \ R) \ (P \ Q \ R)" by fast diff -r 9de1eb745aeb -r 5d208fd2507d src/FOL/ex/Propositional_Int.thy --- a/src/FOL/ex/Propositional_Int.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOL/ex/Propositional_Int.thy Fri Jan 01 10:49:00 2016 +0100 @@ -9,7 +9,7 @@ imports IFOL begin -text \commutative laws of @{text "\"} and @{text "\"}\ +text \commutative laws of \\\ and \\\\ lemma "P \ Q \ Q \ P" by (tactic "IntPr.fast_tac @{context} 1") @@ -18,7 +18,7 @@ by (tactic "IntPr.fast_tac @{context} 1") -text \associative laws of @{text "\"} and @{text "\"}\ +text \associative laws of \\\ and \\\\ lemma "(P \ Q) \ R \ P \ (Q \ R)" by (tactic "IntPr.fast_tac @{context} 1") @@ -26,7 +26,7 @@ by (tactic "IntPr.fast_tac @{context} 1") -text \distributive laws of @{text "\"} and @{text "\"}\ +text \distributive laws of \\\ and \\\\ lemma "(P \ Q) \ R \ (P \ R) \ (Q \ R)" by (tactic "IntPr.fast_tac @{context} 1") @@ -60,16 +60,16 @@ text \Propositions-as-types\ --- \The combinator K\ +\ \The combinator K\ lemma "P \ (Q \ P)" by (tactic "IntPr.fast_tac @{context} 1") --- \The combinator S\ +\ \The combinator S\ lemma "(P \ Q \ R) \ (P \ Q) \ (P \ R)" by (tactic "IntPr.fast_tac @{context} 1") --- \Converse is classical\ +\ \Converse is classical\ lemma "(P \ Q) \ (P \ R) \ (P \ Q \ R)" by (tactic "IntPr.fast_tac @{context} 1") diff -r 9de1eb745aeb -r 5d208fd2507d src/FOL/ex/Quantifiers_Cla.thy --- a/src/FOL/ex/Quantifiers_Cla.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOL/ex/Quantifiers_Cla.thy Fri Jan 01 10:49:00 2016 +0100 @@ -33,14 +33,14 @@ lemma "(\x. P(x) \ Q(x)) \ (\x. P(x)) \ (\x. Q(x))" by fast --- \Converse is false.\ +\ \Converse is false.\ lemma "(\x. P(x) \ Q(x)) \ (\x. P(x)) \ (\x. Q(x))" by fast text \Basic test of quantifier reasoning.\ --- \TRUE\ +\ \TRUE\ lemma "(\y. \x. Q(x,y)) \ (\x. \y. Q(x,y))" by fast @@ -72,7 +72,7 @@ lemma "(\x. P(x) \ Q(x)) \ (\x. P(x)) \ (\x. Q(x))" by fast -text \An example of why @{text exI} should be delayed as long as possible.\ +text \An example of why \exI\ should be delayed as long as possible.\ lemma "(P \ (\x. Q(x))) \ P \ (\x. Q(x))" by fast diff -r 9de1eb745aeb -r 5d208fd2507d src/FOL/ex/Quantifiers_Int.thy --- a/src/FOL/ex/Quantifiers_Int.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOL/ex/Quantifiers_Int.thy Fri Jan 01 10:49:00 2016 +0100 @@ -16,7 +16,7 @@ by (tactic "IntPr.fast_tac @{context} 1") --- \Converse is false\ +\ \Converse is false\ lemma "(\x. P(x)) \ (\x. Q(x)) \ (\x. P(x) \ Q(x))" by (tactic "IntPr.fast_tac @{context} 1") @@ -33,14 +33,14 @@ lemma "(\x. P(x) \ Q(x)) \ (\x. P(x)) \ (\x. Q(x))" by (tactic "IntPr.fast_tac @{context} 1") --- \Converse is false\ +\ \Converse is false\ lemma "(\x. P(x) \ Q(x)) \ (\x. P(x)) \ (\x. Q(x))" by (tactic "IntPr.fast_tac @{context} 1") text \Basic test of quantifier reasoning\ --- \TRUE\ +\ \TRUE\ lemma "(\y. \x. Q(x,y)) \ (\x. \y. Q(x,y))" by (tactic "IntPr.fast_tac @{context} 1") @@ -72,7 +72,7 @@ lemma "(\x. P(x) \ Q(x)) \ (\x. P(x)) \ (\x. Q(x))" by (tactic "IntPr.fast_tac @{context} 1") --- \An example of why exI should be delayed as long as possible\ +\ \An example of why exI should be delayed as long as possible\ lemma "(P \ (\x. Q(x))) \ P \ (\x. Q(x))" by (tactic "IntPr.fast_tac @{context} 1") @@ -85,7 +85,7 @@ text \Some slow ones\ --- \Principia Mathematica *11.53\ +\ \Principia Mathematica *11.53\ lemma "(\x y. P(x) \ Q(y)) \ ((\x. P(x)) \ (\y. Q(y)))" by (tactic "IntPr.fast_tac @{context} 1") diff -r 9de1eb745aeb -r 5d208fd2507d src/FOLP/ex/Intro.thy --- a/src/FOLP/ex/Intro.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOLP/ex/Intro.thy Fri Jan 01 10:49:00 2016 +0100 @@ -41,7 +41,7 @@ done -subsubsection \Demonstration of @{text "fast"}\ +subsubsection \Demonstration of \fast\\ schematic_goal "?p : (EX y. ALL x. J(y,x) <-> ~J(x,x)) --> ~ (ALL x. EX y. ALL z. J(z,y) <-> ~ J(z,x))" diff -r 9de1eb745aeb -r 5d208fd2507d src/FOLP/ex/Intuitionistic.thy --- a/src/FOLP/ex/Intuitionistic.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/FOLP/ex/Intuitionistic.thy Fri Jan 01 10:49:00 2016 +0100 @@ -138,7 +138,7 @@ text "Problem ~~17" schematic_goal "?p : ~~(((P & (Q-->R))-->S) <-> ((~P | Q | S) & (~P | ~R | S)))" - by (tactic \IntPr.fast_tac @{context} 1\) -- slow + by (tactic \IntPr.fast_tac @{context} 1\) \ slow subsection \Examples with quantifiers\ @@ -261,7 +261,7 @@ (ALL x. S(x) & R(x) --> L(x)) & (ALL x. M(x) --> R(x)) --> (ALL x. P(x) & M(x) --> L(x))" - by (tactic "IntPr.best_tac @{context} 1") -- slow + by (tactic "IntPr.best_tac @{context} 1") \ slow text "Problem 39" schematic_goal "?p : ~ (EX x. ALL y. F(y,x) <-> ~F(y,y))" @@ -270,7 +270,7 @@ text "Problem 40. AMENDED" schematic_goal "?p : (EX y. ALL x. F(x,y) <-> F(x,x)) --> ~(ALL x. EX y. ALL z. F(z,y) <-> ~ F(z,x))" - by (tactic "IntPr.best_tac @{context} 1") -- slow + by (tactic "IntPr.best_tac @{context} 1") \ slow text "Problem 44" schematic_goal "?p : (ALL x. f(x) --> @@ -287,7 +287,7 @@ schematic_goal "?p : (EX z w. ALL x y. P(x,y) <-> (x=z & y=w)) --> (EX z. ALL x. EX w. (ALL y. P(x,y) <-> y=w) <-> x=z)" - by (tactic "IntPr.best_tac @{context} 1") -- \60 seconds\ + by (tactic "IntPr.best_tac @{context} 1") \ \60 seconds\ text "Problem 56" schematic_goal "?p : (ALL x. (EX y. P(y) & x=f(y)) --> P(x)) <-> (ALL x. P(x) --> P(f(x)))" diff -r 9de1eb745aeb -r 5d208fd2507d src/Tools/Adhoc_Overloading.thy --- a/src/Tools/Adhoc_Overloading.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/Tools/Adhoc_Overloading.thy Fri Jan 01 10:49:00 2016 +0100 @@ -2,7 +2,7 @@ Author: Christian Sternagel, University of Innsbruck *) -section {* Adhoc overloading of constants based on their types *} +section \Adhoc overloading of constants based on their types\ theory Adhoc_Overloading imports Pure diff -r 9de1eb745aeb -r 5d208fd2507d src/Tools/Code_Generator.thy --- a/src/Tools/Code_Generator.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/Tools/Code_Generator.thy Fri Jan 01 10:49:00 2016 +0100 @@ -2,7 +2,7 @@ Author: Florian Haftmann, TU Muenchen *) -section {* Loading the code generator and related modules *} +section \Loading the code generator and related modules\ theory Code_Generator imports Pure diff -r 9de1eb745aeb -r 5d208fd2507d src/Tools/Spec_Check/Examples.thy --- a/src/Tools/Spec_Check/Examples.thy Thu Dec 31 21:46:31 2015 +0100 +++ b/src/Tools/Spec_Check/Examples.thy Fri Jan 01 10:49:00 2016 +0100 @@ -2,82 +2,82 @@ imports Spec_Check begin -section {* List examples *} +section \List examples\ -ML_command {* +ML_command \ check_property "ALL xs. rev xs = xs"; -*} +\ -ML_command {* +ML_command \ check_property "ALL xs. rev (rev xs) = xs"; -*} +\ -section {* AList Specification *} +section \AList Specification\ -ML_command {* +ML_command \ (* map_entry applies the function to the element *) check_property "ALL k f xs. AList.lookup (op =) (AList.map_entry (op =) k f xs) k = Option.map f (AList.lookup (op =) xs k)"; -*} +\ -ML_command {* +ML_command \ (* update always results in an entry *) check_property "ALL k v xs. AList.defined (op =) (AList.update (op =) (k, v) xs) k"; -*} +\ -ML_command {* +ML_command \ (* update always writes the value *) check_property "ALL k v xs. AList.lookup (op =) (AList.update (op =) (k, v) xs) k = SOME v"; -*} +\ -ML_command {* +ML_command \ (* default always results in an entry *) check_property "ALL k v xs. AList.defined (op =) (AList.default (op =) (k, v) xs) k"; -*} +\ -ML_command {* +ML_command \ (* delete always removes the entry *) check_property "ALL k xs. not (AList.defined (op =) (AList.delete (op =) k xs) k)"; -*} +\ -ML_command {* +ML_command \ (* default writes the entry iff it didn't exist *) check_property "ALL k v xs. (AList.lookup (op =) (AList.default (op =) (k, v) xs) k = (if AList.defined (op =) xs k then AList.lookup (op =) xs k else SOME v))"; -*} +\ -section {* Examples on Types and Terms *} +section \Examples on Types and Terms\ -ML_command {* +ML_command \ check_property "ALL f g t. map_types (g o f) t = (map_types f o map_types g) t"; -*} +\ -ML_command {* +ML_command \ check_property "ALL f g t. map_types (f o g) t = (map_types f o map_types g) t"; -*} +\ -text {* One would think this holds: *} +text \One would think this holds:\ -ML_command {* +ML_command \ check_property "ALL t ts. strip_comb (list_comb (t, ts)) = (t, ts)" -*} +\ -text {* But it only holds with this precondition: *} +text \But it only holds with this precondition:\ -ML_command {* +ML_command \ check_property "ALL t ts. case t of _ $ _ => true | _ => strip_comb (list_comb (t, ts)) = (t, ts)" -*} +\ -section {* Some surprises *} +section \Some surprises\ -ML_command {* +ML_command \ check_property "ALL Ts t. type_of1 (Ts, t) = fastype_of1 (Ts, t)" -*} +\ -ML_command {* +ML_command \ val thy = @{theory}; check_property "ALL t u. if Pattern.matches thy (t, u) then Term.could_unify (t, u) else true" -*} +\ end