diff options
author | Karl Berry <karl@freefriends.org> | 2019-02-17 23:02:19 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2019-02-17 23:02:19 +0000 |
commit | 9337ead45078f53688180eb292f26766703110d9 (patch) | |
tree | a1927cdffdcf1016b3d884f39e48558b9f2c8438 /Master/texmf-dist/tex/latex/rec-thy | |
parent | 8c3bfc326ff7064c4b80a6b4c7fc2053aa4672cc (diff) |
rec-thy (17feb19)
git-svn-id: svn://tug.org/texlive/trunk@50047 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/rec-thy')
-rw-r--r-- | Master/texmf-dist/tex/latex/rec-thy/rec-thy.sty | 583 |
1 files changed, 373 insertions, 210 deletions
diff --git a/Master/texmf-dist/tex/latex/rec-thy/rec-thy.sty b/Master/texmf-dist/tex/latex/rec-thy/rec-thy.sty index e984b3f17e8..4f69ee5fe32 100644 --- a/Master/texmf-dist/tex/latex/rec-thy/rec-thy.sty +++ b/Master/texmf-dist/tex/latex/rec-thy/rec-thy.sty @@ -1,5 +1,5 @@ \NeedsTeXFormat{LaTeX2e} -\ProvidesPackage{rec-thy}[2017/12/31 v2.3 Provides commands for writing up recursion theory papers] +\ProvidesPackage{rec-thy}[2019/02/17 v3.01 Provides commands for writing up recursion theory papers] \makeatletter % \newcommand*{\@curpack}{\@currname} %rec-thy.sty \newcommand*{\@packinfo}[1]{\PackageInfo{rec-thy}{#1}} @@ -100,7 +100,10 @@ \newif\ifrecthy@nosubfun \recthy@nosubfunfalse \newif\ifrecthy@nopfcases \@ifclassloaded{beamer}{\recthy@nopfcasestrue}{\recthy@nopfcasesfalse} \newif\ifrecthy@noprioritytrees \recthy@noprioritytreesfalse +\newif\ifrecthy@nosuppprioritytrees \recthy@nosuppprioritytreestrue \newif\ifrecthy@hyperreqs \recthy@hyperreqstrue +\newif\ifrecthy@nooperators \recthy@nooperatorsfalse +%\newif\ifrecthy@nomodule \recthy@nomodulefalse \DeclareOptionX{nohyphenation}{\recthy@nohyphenationtrue} \DeclareOptionX{mrref}{\recthy@mrreftrue} @@ -125,10 +128,19 @@ \DeclareOptionX{nosubfun}{\recthy@nosubfuntrue} \DeclareOptionX{nopfcases}{\recthy@nopfcasestrue} \DeclareOptionX{noprioritytrees}{\recthy@noprioritytreestrue} +\DeclareOptionX{suppPriorityTrees}{\recthy@nosuppprioritytreesfalse} \DeclareOptionX{nohyperreqs}{\recthy@hyperreqsfalse} +\DeclareOptionX{nooperators}{\recthy@nooperatorstrue} +%\DeclareOptionX{nomodule}{\recthy@nomoduletrue} \DeclareOptionX{degjoin}{\def\Tjoin{\Tdegjoin}} +\let\@recthy@modulescr\mathcal +\DeclareOptionX{modulescr}[mathcal]{\letcs{\@recthy@modulescr}{#1}} + +\def\@recthy@ballsymb@default{\mathscr{B}} +\let\@recthy@ballsymb\@recthy@ballsymb@default +\DeclareOptionX{ballsymb}[@recthy@ballsymb@default]{\letcs{\@recthy@ballsymb}{#1}} \AtEndOfPackage{ \ifrecthy@noprioritytrees @@ -138,19 +150,43 @@ \providecommand{\PriorityTree}{\mathbb{T}} \providecommand{\tpath}[1][]{\ifthenelse{\isempty{#1}}{\symbf{f}}{\mathbb{f}_{#1}}} \providecommand{\leftof}{\mathbin{<_L}} - \providecommand{\ball}[3][]{{\ifdefined\symbf - \symbf{\alpha} - \else - \alpha - \fi}^{#1}(#2, #3)} - \providecommand*{\Astages}[1]{\mathcal{S}_{\text{act}}^{#1}} - \providecommand*{\Vstages}[1]{\mathcal{S}^{#1}} + \providecommand{\leftofeq}{\mathbin{\leq_L}} + \providecommand{\rightof}{\mathbin{>_L}} + \providecommand{\rightofeq}{\mathbin{\geq_L}} + \providecommand{\nleftof}{\mathbin{\nless_L}} + \providecommand{\nleftofeq}{\mathbin{\nleq_L}} + \providecommand{\nrightof}{\mathbin{\ngtr_L}} + \providecommand{\nrightofeq}{\mathbin{\ngeq_L}} + \NewDocumentCommand{\PriorityTreeModule}{mO{}m}{\ensuremath{{\@recthy@modulescr{#1}}^{#2}_{#3} }} + \let\module=\PriorityTreeModule + \providecommand{\ball}[3][]{{\@recthy@ballsymb}^{#1}(#2, #3)} + \fi + +} + + +\AtEndOfPackage{ + \ifrecthy@nosuppprioritytrees + \@packinfo{Not loading Priority Tree Supplemental Helper} + \else + \providecommand*{\Astages}[1]{\mathcal{A}({#1})} + \providecommand*{\Vstages}[1]{\mathcal{V}(#1)} \providecommand{\reqof}[2][]{\mathbb{r}(#2)} + \let\modof=\reqof + \providecommand{\ancestor}{\succ} + \providecommand{\descendant}{\prec} + \providecommand{\ancestoreq}{\succeq} + \providecommand{\descendanteq}{\preceq} + \let\ances=\ancestor + \let\anceseq=\ancestoreq + \let\desc=\descendant + \let\desceq=\descendanteq \fi + } -\let\pmg@casefont=\textsc -\DeclareOptionX{pfcasefont}{\edef\pmg@casefont{\expandafter\noexpand\csname #1 \endcsname}} +\let\pmg@casefont\textsc +\DeclareOptionX{pfcasefont}[textsc]{\letcs{\pmg@casefont}{#1}} \AtEndOfPackage{ \ifrecthy@nopfcases @@ -266,9 +302,8 @@ -% \newcommand*{\@recthy@reqscr}[1]{\mathscr{#1}} -\let\@recthy@reqscr=\mathscr -\DeclareOptionX{reqscr}{\edef\@recthy@reqscr{\expandafter\noexpand\csname #1 \endcsname}} +\let\@recthy@reqscr\mathscr +\DeclareOptionX{reqscr}[mathscr]{\letcs{\@recthy@reqscr}{#1}} \AtEndOfPackage{ @@ -277,17 +312,15 @@ \else \@packinfo{Loading requirement assist.} \newcommand*{\req@orig}[3][]{\ensuremath{\ifthenelse{\isempty{#1}}{\@recthy@reqscr{#2}_{#3}}{\@recthy@reqscr{#2}^{#1}_{#3}}}} + + \NewDocumentCommand{\req@href}{O{}mO{}m}{\@ifundefined{hyperref}{\req@orig[#1#3]{#2}{#4}}{\hyperref[\detokenize{req:#2@#1#3}]{\req@orig[#1#3]{#2}{#4}}}} + \NewDocumentCommand{\req@nohref}{O{}mO{}m}{\req@orig[#1#3]{#2}{#4}} \ifrecthy@hyperreqs - \newcommand*{\req}[3][]{ - \@ifundefined{hyperref}{ - \req@orig[#1]{#2}{#3} - }{ - \hyperref[\detokenize{req:#2@#1}]{\req@orig[#1]{#2}{#3}} - }} + \let\req=\req@href \else - \let\req=\req@orig + \let\req=\req@nohref \fi - \WithSuffix\def\req*{\req@orig} + \WithSuffix\def\req*{\req@nohref} % \newsavebox{\@recthy@reqbox} % \def\defreq#1#2\par{ % \begin{equation}\let\veqno\@@leqno% @@ -316,17 +349,46 @@ % \let\maketag@@@=\maketag@@@orig@pmg } - \newenvironment{require}[3][]{ - \begin{requirement}{\req*[#1]{#2}{#3}} \label{\detokenize{req:#2@#1}} + \NewDocumentEnvironment{require}{O{}mO{}m}{ + \begin{requirement}{\req@nohref[#1#3]{#2}{#4}} \label{\detokenize{req:#2@#1#3}}% }{ - \end{requirement} + \end{requirement}% } - \newenvironment{require*}[3][]{ - \begin{requirement}{\req*[#1]{#2}{#3}} \label{\detokenize{req:#2@#1}} + % \NewDocumentEnvironment{require*}{O{}mO{}m}{ + % \begin{requirement}{\req@nohref[#1#3]{#2}{#4}}% + % }{ + % \end{requirement}% + % } + \NewDocumentCommand{\refreq}{O{}mO{}}{\ref{\detokenize{req:#2@#1#3}}} + + \NewDocumentCommand{\require@nested}{sO{}mO{}m}{ + \IfBooleanTF{#1}{\tag{\req@nohref[#2#4]{#3}{#5}}}{\tag{\req@nohref[#2#4]{#3}{#5}}\label{\detokenize{req:#3@#2#4}}} + } + % \newcommand*{\require@nested}{\require@nested@href} + % \WithSuffix\def\require@nested*{\require@nested@nohref} + % \NewDocumentEnvironment{require*}{O{}mO{}m}{ + % \tag{\req@nohref[#1#3]{#2}{#4}}% + % }{} + + + \NewDocumentEnvironment{requirements}{}{ + \let\@origif@fleqn@pmg=\if@fleqn + \let\@origiftagsleft@pmg=\iftagsleft@ + \@fleqntrue + \setlength\@mathmargin{1.5cm} + \tagsleft@true + \usetagform{colon} + \let\require=\require@nested + % \let\maketag@@@orig@pmg=\maketag@@@ + % \def\maketag@@@#1{\hbox{\m@th\normalfont#1:}} + \gather }{ - \end{requirement} + \endgather + \let\if@fleqn=\@origif@fleqn@pmg + \let\iftagsleft@=\@origiftagsleft@pmg + \usetagform{default} + % \let\maketag@@@=\maketag@@@orig@pmg } - \newcommand*{\refreq}[2][]{\ref{\detokenize{req:#2@#1}}} \fi } @@ -405,11 +467,7 @@ \DeclareMathOperator{\Ord}{Ord} \fi - \providecommand*{\meet}{\mathbin{\wedge}} - \providecommand*{\join}{\mathbin{\vee}} - \providecommand*{\Meet}{\mathop{\bigwedge}} - \let\MnJoin=\Join - \renewcommand*{\Join}{\mathop{\bigvee}} + \recthy@strip{abs} \ifdefined\dom \else @@ -438,26 +496,22 @@ } - -% corner quotes From Sam Buss http://www.phil.cam.ac.uk/teaching_staff/Smith/LaTeX/resources/godelquotes.txt -\newbox\@recthy@gnBoxA -\newdimen\@recthy@gnCornerHgt -\setbox\@recthy@gnBoxA=\hbox{$\ulcorner$} -\global\@recthy@gnCornerHgt=\ht\@recthy@gnBoxA -\newdimen\@recthy@gnArgHgt - -\newcommand{\@recthy@godelnum}[1]{% - \setbox\@recthy@gnBoxA=\hbox{$#1$}% - \@recthy@gnArgHgt=\ht\@recthy@gnBoxA% - \ifnum \@recthy@gnArgHgt<\@recthy@gnCornerHgt - \@recthy@gnArgHgt=0pt% +\AtEndOfPackage{ +\ifrecthy@nooperators + \@packinfo{No operators loading.} +\else + \@packinfo{Operators loading.} + \providecommand*{\meet}{\mathbin{\wedge}} + \providecommand*{\join}{\mathbin{\vee}} + \providecommand*{\Meet}{\mathop{\bigwedge}} + \let\MnJoin=\Join + \renewcommand*{\Join}{\mathop{\bigvee}} + \ifdefined\xor \else - \advance \@recthy@gnArgHgt by -\@recthy@gnCornerHgt% + \DeclareMathOperator{\xor}{xor} \fi - \raise\@recthy@gnArgHgt\hbox{$\ulcorner$} \box\@recthy@gnBoxA % - \raise\@recthy@gnArgHgt\hbox{$\urcorner$}} - - +\fi +} \newcommand*{\@recthy@llangle}{\mathopen{\langle\!\langle}} \newcommand*{\@recthy@rrangle}{\mathclose{\rangle\!\rangle}} @@ -468,7 +522,34 @@ \ifrecthy@nodelim \@packinfo{No delimiters loading.} \else - \newcommand*{\godelnum}[1]{\@recthy@godelnum{#1}} + \ltx@ifpackageloaded{MnSymbol}{}{ + \DeclareFontFamily{OMX}{MnSymbolE}{} + \DeclareSymbolFont{MnLargeSymbols}{OMX}{MnSymbolE}{m}{n} + \SetSymbolFont{MnLargeSymbols}{bold}{OMX}{MnSymbolE}{b}{n} + \DeclareFontShape{OMX}{MnSymbolE}{m}{n}{ + <-6> MnSymbolE5 + <6-7> MnSymbolE6 + <7-8> MnSymbolE7 + <8-9> MnSymbolE8 + <9-10> MnSymbolE9 + <10-12> MnSymbolE10 + <12-> MnSymbolE12 + }{} + \DeclareFontShape{OMX}{MnSymbolE}{b}{n}{ + <-6> MnSymbolE-Bold5 + <6-7> MnSymbolE-Bold6 + <7-8> MnSymbolE-Bold7 + <8-9> MnSymbolE-Bold8 + <9-10> MnSymbolE-Bold9 + <10-12> MnSymbolE-Bold10 + <12-> MnSymbolE-Bold12 + }{} + \DeclareMathDelimiter{\ulcorner} + {\mathopen}{MnLargeSymbols}{'036}{MnLargeSymbols}{'036} + \DeclareMathDelimiter{\urcorner} + {\mathclose}{MnLargeSymbols}{'043}{MnLargeSymbols}{'043} +} + \newcommand*{\godelnum}[1]{\left\ulcorner #1 \right\urcorner} \let\cornerquote=\godelnum \let\gcode=\godelnum \recthy@strip{llangle} @@ -478,6 +559,10 @@ \newcommand*{\@recthy@re}{\@recthy@ensuretext{r.e.\ }} \newcommand*{\@recthy@ce}{\@recthy@ensuretext{c.e.\ }} +\newcommand*{\@recthy@RE}{\@recthy@ensuretext{R.E.\ }} +\newcommand*{\@recthy@CE}{\@recthy@ensuretext{C.E.\ }} +\newcommand*{\@recthy@Re}{\@recthy@ensuretext{R.e.\ }} +\newcommand*{\@recthy@Ce}{\@recthy@ensuretext{C.e.\ }} \newcommand*{\@recthy@recursive}{\@recthy@ensuretext{recursive}} \newcommand*{\@recthy@computable}{\@recthy@ensuretext{computable}} \newcommand*{\@recthy@recursivelyEnumerable}{\@recthy@ensuretext{recursively enumerable}} @@ -487,29 +572,9 @@ \newcommand*{\@recthy@RecursivelyEnumerable}{\@recthy@ensuretext{Recursively enumerable}} \newcommand*{\@recthy@ComputablyEnumerable}{\@recthy@ensuretext{Computably enumerable}} \newcommand*{\@recthy@REA}{\ensuremath{\text{REA}}} -\WithSuffix\def\@recthy@REA[#1]{#1-\REA\relax} +\WithSuffix\def\@recthy@REA[#1]{#1-\@recthy@REA\relax} \newcommand*{\@recthy@CEA}{\ensuremath{\text{CEA}}} -\WithSuffix\def\@recthy@CEA[#1]{#1-\CEA\relax} - -\AtEndOfPackage{ -\ifrecthy@nonames - \@packinfo{No names loading.} -\else - \@packinfo{Names loading.} - \recthy@strip{re} - \recthy@strip{ce} - \recthy@strip{REA} - \recthy@strip{CEA} - \recthy@strip{recursive} - \recthy@strip{computable} - \recthy@strip{recursivelyEnumerable} - \recthy@strip{computablyEnumerable} - \recthy@strip{Recursive} - \recthy@strip{Computable} - \recthy@strip{RecursivelyEnumerable} - \recthy@strip{ComputablyEnumerable} -\fi -} +\WithSuffix\def\@recthy@CEA[#1]{#1-\@recthy@CEA\relax} \DeclareOptionX{reterms}{% \let\@recthy@ce=\@recthy@re @@ -532,6 +597,37 @@ \DeclareOptionX{ceaterms}{% \let\@recthy@REA=\@recthy@CEA } +\DeclareOptionX{reaterms}{% + \let\@recthy@CEA=\@recthy@REA + } + + + +\AtEndOfPackage{ +\ifrecthy@nonames + \@packinfo{No names loading.} +\else + \@packinfo{Names loading.} + \recthy@strip{re} + \recthy@strip{ce} + \recthy@strip{RE} + \recthy@strip{CE} + \recthy@strip{Re} + \recthy@strip{Ce} + \recthy@strip{REA} + \recthy@strip{CEA} + \recthy@strip{recursive} + \recthy@strip{computable} + \recthy@strip{recursivelyEnumerable} + \recthy@strip{computablyEnumerable} + \recthy@strip{Recursive} + \recthy@strip{Computable} + \recthy@strip{RecursivelyEnumerable} + \recthy@strip{ComputablyEnumerable} +\fi +} + + % Set stuff @@ -592,14 +688,14 @@ \def\Cross{} \renewcommand*{\Cross}{\mathop{\Pi}} \providecommand*{\symdiff}{\mathbin{\Delta}} - \ifdefined\interior - \else - \DeclareMathOperator{\interior}{int} - \fi - \ifdefined\closure - \else - \DeclareMathOperator{\closure}{cl} - \fi + % \ifdefined\interior + % \else + % \DeclareMathOperator{\interior}{int} + % \fi + % \ifdefined\closure + % \else + % \DeclareMathOperator{\clos}{cl} + % \fi \fi } @@ -608,36 +704,54 @@ \@packinfo{No quants loading.} \else \@packinfo{Quants loading.} - \newcommand*{\existsuniq}{\exists !} - \newcommand*{\nexistsuniq}{\nexists !} - \WithSuffix\def\existsuniq(#1){\left(\existsuniq\, #1 \right)\!} - \WithSuffix\def\nexistsuniq(#1){\left(\nexistsuniq\, #1 \right)\!} - \WithSuffix\def\existsuniq[#1]{\left[\existsuniq\, #1 \right]\!} - \WithSuffix\def\nexistsuniq[#1]{\left[\nexistsuniq\, #1 \right]\!} - - \newcommand*{\forallae}{\forall^{*}} - \WithSuffix\def\forallae(#1){\left(\forallae\, #1\right)\!} - \WithSuffix\def\forallae[#1]{\left[\forallae\, #1\right]\!} - - \providecommand*{\existsinf}{\exists^{\infty}} - \WithSuffix\def\existsinf(#1){\left(\existsinf\, #1\right)\!} - \WithSuffix\def\existsinf[#1]{\left[\existsinf\, #1\right]\!} - - \providecommand*{\nexistsinf}{\nexists^{\infty}} - \WithSuffix\def\nexistsinf(#1){\left(\nexistsinf\, #1\right)\!} - \WithSuffix\def\nexistsinf[#1]{\left[\nexistsinf\, #1\right]\!} - - \WithSuffix\def\exists(#1){\left(\exists\, #1 \right)\!} - \WithSuffix\def\forall(#1){\left(\forall\, #1 \right)\!} - \WithSuffix\def\nexists(#1){\left(\nexists\, #1 \right)\!} - \WithSuffix\def\exists[#1]{\left[\exists\, #1 \right]\!} - \WithSuffix\def\forall[#1]{\left[\forall\, #1 \right]\!} - \WithSuffix\def\nexists[#1]{\left[\nexists\, #1 \right]\!} - \WithSuffix\def\forall*{\forallae} - \WithSuffix\def\exists*{\existsinf} - \WithSuffix\def\nexists*{\nexistsinf} - \WithSuffix\def\exists!{\existsuniq} - + \AtBeginDocument{ + \let\exists@orig@recthy=\exists + \let\forall@orig@recthy=\forall + \newcommand*{\exists@recthy}{\exists@orig@recthy} + \newcommand*{\forall@recthy}{\forall@orig@recthy} + \let\nexists@orig@recthy=\nexists + \newcommand*{\nexists@recthy}{\nexists@orig@recthy} + \let\nforall@orig@recthy=\nforall + \newcommand*{\nforall@recthy}{\nforall@orig@recthy} + \newcommand*{\existsuniq}{\exists@orig@recthy !} + \newcommand*{\nexistsuniq}{\nexists@orig@recthy !} + \WithSuffix\def\existsuniq(#1){\left(\existsuniq #1 \right)\!} + \WithSuffix\def\nexistsuniq(#1){\left(\nexistsuniq #1 \right)\!} + \WithSuffix\def\existsuniq[#1]{\left[\existsuniq #1 \right]\!} + \WithSuffix\def\nexistsuniq[#1]{\left[\nexistsuniq #1 \right]\!} + + \newcommand*{\forallae}{\forall@orig@recthy^{*}} + \WithSuffix\def\forallae(#1){\left(\forallae #1\right)\!} + \WithSuffix\def\forallae[#1]{\left[\forallae #1\right]\!} + + \newcommand*{\nforallae}{\nforall@orig@recthy^{*}} + \WithSuffix\def\nforallae(#1){\left(\nforallae #1\right)\!} + \WithSuffix\def\nforallae[#1]{\left[\nforallae #1\right]\!} + + \providecommand*{\existsinf}{\exists@orig@recthy^{\infty}} + \WithSuffix\def\existsinf(#1){\left(\existsinf #1\right)\!} + \WithSuffix\def\existsinf[#1]{\left[\existsinf #1\right]\!} + + \providecommand*{\nexistsinf}{\nexists^{\infty}} + \WithSuffix\def\nexistsinf(#1){\left(\nexistsinf #1\right)\!} + \WithSuffix\def\nexistsinf[#1]{\left[\nexistsinf #1\right]\!} + + \WithSuffix\def\exists@recthy(#1){\left(\exists #1 \right)\!} + \WithSuffix\def\forall@recthy(#1){\left(\forall #1 \right)\!} + \WithSuffix\def\nexists@recthy(#1){\left(\nexists #1 \right)\!} + \WithSuffix\def\exists@recthy[#1]{\left[\exists #1 \right]\!} + \WithSuffix\def\forall@recthy[#1]{\left[\forall #1 \right]\!} + \WithSuffix\def\nexists@recthy[#1]{\left[\nexists #1 \right]\!} + \WithSuffix\def\forall@recthy*{\forallae} + \WithSuffix\def\nforall@recthy*{\nforallae} + \WithSuffix\def\exists@recthy*{\existsinf} + \WithSuffix\def\nexists@recthy*{\nexistsinf} + \WithSuffix\def\exists@recthy!{\existsuniq} + \let\exists=\exists@recthy + \let\forall=\forall@recthy + \let\nexists=\nexists@recthy + \let\nforall=\nforall@recthy + } @@ -651,9 +765,13 @@ \providecommand*{\liff}{\ensuremath{\leftrightarrow}} \providecommand*{\limplies}{\ensuremath{\rightarrow}} + \fi } + + + \AtEndOfPackage{ \ifrecthy@nospaces \@packinfo{No spaces loading.} @@ -673,13 +791,17 @@ %Strings -\def\@recthy@concatSYM{\widehat{\;}} -\def\@recthy@EmptyStr{\mathopen{\@recthy@llangle}\mathclose{\@recthy@rrangle}} - +\def\@recthy@concatSYM@Default{\widehat{\phantom{X}}} +\def\@recthy@EmptyStr@Default{\mathopen{\langle}\mathclose{\rangle}} +\let\@recthy@concatSYM\@recthy@concatSYM@Default +\let\@recthy@EmptyStr\@recthy@EmptyStr@Default -\DeclareOptionX{emptystr}{\edef\@recthy@EmptyStr{\expandafter\noexpand\csname #1 \endcsname}} -\DeclareOptionX{concatsym}{\edef\@recthy@concatSYM{\expandafter\noexpand\csname #1 \endcsname}} +\DeclareOptionX{emptystr}[@recthy@EmptyStr@Default]{\letcs{\@recthy@EmptyStr}{#1}} +\DeclareOptionX{concatsym}[@recthy@concatSYM@Default]{\letcs{\@recthy@concatSYM}{#1}} +\newcommand*{\@recthy@pair}[2]{\mathopen{\@recthy@llangle} #1, #2 \mathclose{\@recthy@rrangle}} +\NewDocumentCommand{\incompat@recthy}{o}{\mathrel{\mid}\IfValueTF{#1}{_{#1}}{}} +\NewDocumentCommand{\compat@recthy}{o}{\mathrel{\not\mid}\IfValueTF{#1}{_{#1}}{}} \AtEndOfPackage{ \ifrecthy@nostrings @@ -687,26 +809,29 @@ \else \@packinfo{Strings loading.} \newcommand*{\closedn}[1]{{#1}^\blacktriangledown} - \newcommand*{\str}[1]{\mathopen{\@recthy@llangle}#1\mathclose{\@recthy@rrangle}} - \newcommand*{\code}{\str} + \newcommand*{\str}[1]{\mathopen{\langle}#1\mathclose{\rangle}} + \newcommand*{\code}[1]{\mathopen{\@recthy@llangle}#1\mathclose{\@recthy@rrangle}} \newcommand*{\EmptyStr}{\@recthy@EmptyStr} \newcommand*{\estr}{\EmptyStr} \newcommand*{\decode}[2]{(#1)_{#2}} - \providecommand*{\godelpair}[2]{\mathopen{\langle} #1, #2 \mathclose{\rangle}} - \newcommand*{\gpair}{\godelpair} - \newcommand*{\concat}{\mathbin{\@recthy@concatSYM}} + \let\godelpair=\@recthy@pair + \let\gpair=\@recthy@pair + \newcommand*{\concat}{\@recthy@concatSYM} \WithSuffix\def\concat[#1]{\concat\str{#1}} \newcommand*{\strpred}[1]{{#1}^{-}} \providecommand*{\lh}[2][]{\@recthy@abs{#2}_{#1}} %% Gives length of a string - \providecommand*{\incompat}{\mathrel{\mid}} %incompatible stringes FIX SPACING - \providecommand*{\incomp}{\incompat} - \providecommand*{\compat}{\mathrel{\nmid}} + + \providecommand*{\incompat}{\incompat@recthy} %incompatible stringes FIX SPACING + \providecommand*{\incomp}{\incompat@recthy} + \providecommand*{\compat}{\compat@recthy} + \providecommand*{\nincompat}{\compat@recthy} + \providecommand*{\nincomp}{\compat@recthy} \newcommand*{\setcol}[2]{{#1}^{[#2]}} \ifrecthy@nopair \@packinfo{No redefining pair.} \else \@packinfo{pair=godelpair.} - \newcommand*{\pair}{\godelpair} + \let\pair=\@recthy@pair \fi \fi } @@ -740,34 +865,62 @@ \@packinfo{No setrels loading.} \else \@packinfo{setrels loading.} - - \WithSuffix\def\subset*{\subset^{*}} - \WithSuffix\def\supset*{\supset^{*}} - \WithSuffix\def\subseteq*{\subseteq^{*}} - \WithSuffix\def\supseteq*{\supseteq^{*}} - \providecommand*{\nsupset}{\not\supset} - \providecommand*{\nsubset}{\not\subset} - \WithSuffix\def\nsubset*{\nsubset^{*}} - \WithSuffix\def\nsupset*{\nsupset^{*}} - \WithSuffix\def\nsubseteq*{\nsubseteq^{*}} - \WithSuffix\def\nsupseteq*{\nsupseteq^{*}} - % \WithSuffix\def\subsetneq*{\subsetneq^{*}} - % \WithSuffix\def\supsetneq*{\supsetneq^{*}} - - \newcommand*{\eq}{=} - \WithSuffix\def\eq*{=^{*}} - \newcommand*{\eqae}{=^{*}} - \newcommand*{\neqae}{\neq^{*}} - \WithSuffix\def\neq*{\neq^{*}} - - \newcommand*{\infsubset}{\subset_{\infty}} - \WithSuffix\def\infsubset*{\infsubset^{*}} - \let\subsetnaeq=\infsubset - \newcommand*{\infsupset}{\supset_{\infty}} - \WithSuffix\def\infsupset*{\infsupset^{*}} - \let\supsetnaeq=\infsupset - \newcommand*{\majsubset}{\subset_{m}} - \newcommand*{\majsupset}{\supset_{m}} + \AtBeginDocument{ + \providecommand*{\nsupset}{\not\supset@recthy@orig} + \providecommand*{\nsubset}{\not\subset@recthy@orig} + \let\nsubset@recthy@orig=\nsubset + \let\nsupset@recthy@orig=\nsupset + \let\subset@recthy@orig=\subset + \let\supset@recthy@orig=\supset + \let\subseteq@recthy@orig=\subseteq + \let\supseteq@recthy@orig=\supseteq + \let\subsetneq@recthy@orig=\subsetneq + \let\supsetneq@recthy@orig=\supsetneq + \newcommand*{\subset@recthy}{\subset@recthy@orig} + \newcommand*{\supset@recthy}{\supset@recthy@orig} + \newcommand*{\subseteq@recthy}{\subseteq@recthy@orig} + \newcommand*{\supseteq@recthy}{\supseteq@recthy@orig} + \newcommand*{\nsubset@recthy}{\nsubset@recthy@orig} + \newcommand*{\nsupset@recthy}{\nsupset@recthy@orig} + \newcommand*{\nsubseteq@recthy}{\nsubseteq@recthy@orig} + \newcommand*{\nsupseteq@recthy}{\nsupseteq@recthy@orig} + \WithSuffix\def\subset@recthy*{\subset@recthy@orig^{*}} + \WithSuffix\def\supset@recthy*{\supset@recthy@orig^{*}} + \WithSuffix\def\subseteq@recthy*{\subseteq@recthy@orig^{*}} + \WithSuffix\def\supseteq@recthy*{\supseteq@recthy@orig^{*}} + \WithSuffix\def\subsetneq@recthy*{\subsetneq@recthy@orig^{*}} + \WithSuffix\def\supsetneq@recthy*{\supsetneq@recthy@orig^{*}} + \WithSuffix\def\nsubset@recthy*{\nsubset^{*}} + \WithSuffix\def\nsupset@recthy*{\nsupset^{*}} + \WithSuffix\def\nsubseteq@recthy*{\nsubseteq^{*}} + \WithSuffix\def\nsupseteq@recthy*{\nsupseteq^{*}} + \let\subset=\subset@recthy + \let\supset=\supset@recthy + \let\subseteq=\subseteq@recthy + \let\supseteq=\supseteq@recthy + \let\subsetneq=\subsetneq@recthy + \let\supsetneq=\supsetneq@recthy + \let\nsubset=\nsubset@recthy + \let\nsupset=\nsupset@recthy + \let\nsubseteq=\nsubseteq@recthy + \let\nsupseteq=\nsupseteq@recthy + + + \newcommand*{\eq}{=} + \WithSuffix\def\eq*{=^{*}} + \newcommand*{\eqae}{=^{*}} + \newcommand*{\neqae}{\neq^{*}} + \WithSuffix\def\neq*{\neq^{*}} + + \newcommand*{\infsubset}{\subset_{\infty}} + \WithSuffix\def\infsubset*{\infsubset^{*}} + \let\subsetnaeq=\infsubset + \newcommand*{\infsupset}{\supset_{\infty}} + \WithSuffix\def\infsupset*{\infsupset^{*}} + \let\supsetnaeq=\infsupset + \newcommand*{\majsubset}{\subset_{m}} + \newcommand*{\majsupset}{\supset_{m}} + } \fi } @@ -865,13 +1018,16 @@ %%%%%%%%% Formula Classes -\newcommand*{\@recthy@CDelta}{\prescript{\mathcal{C}}{}{\Delta}} -\newcommand*{\@recthy@CSigma}{\prescript{\mathcal{C}}{}{\Sigma}} -\newcommand*{\@recthy@CPi}{\prescript{\mathcal{C}}{}{\Pi}} +\newcommand*{\@recthy@CDelta@default}{\prescript{\mathcal{C}}{}{\Delta}} +\newcommand*{\@recthy@CSigma@default}{\prescript{\mathcal{C}}{}{\Sigma}} +\newcommand*{\@recthy@CPi@default}{\prescript{\mathcal{C}}{}{\Pi}} +\let\@recthy@CDelta=\@recthy@CDelta@default +\let\@recthy@CSigma=\@recthy@CSigma@default +\let\@recthy@CPi=\@recthy@CPi@default -\DeclareOptionX{cdeltasym}{\edef\@recthy@CDelta{\expandafter\noexpand\csname #1 \endcsname}} -\DeclareOptionX{csigmasym}{\edef\@recthy@CSigma{\expandafter\noexpand\csname #1 \endcsname}} -\DeclareOptionX{cpisym}{\edef\@recthy@CPi{\expandafter\noexpand\csname #1 \endcsname}} +\DeclareOptionX{cdeltasym}[@recthy@CDelta@default]{\letcs{\@recthy@CDelta}{#1}} +\DeclareOptionX{csigmasym}[@recthy@CSigma@default]{\letcs{\@recthy@CSigma}{#1}} +\DeclareOptionX{cpisym}[@recthy@CPi@default]{\letcs{\@recthy@CPi}{#1}} % \DeclareOptionX<\@recthy@family>{cdeltasym}[]{\def\@recthy@CDelta{#1}} % \DeclareOptionX<\@recthy@family>{csigmasym}[]{\def\@recthy@CSigma{#1}} @@ -1267,10 +1423,16 @@ } - +\def\@recthy@recfSYM@default{\phi} +\let\@recthy@recfSYM=\@recthy@recfSYM@default +\def\@recthy@recfnlSYM@default{\Phi} +\let\@recthy@recfnlSYM=\@recthy@recfnlSYM@default +\def\@recthy@useSYM@default{\ltx@ifpackageloaded{unicode-math}{\symbffrak{u}}{\mathfrak{u}}} +\let\@recthy@useSYM=\@recthy@useSYM@default %%%ABREVIATIONS -\DeclareOptionX{recfnlsym}[Phi]{\edef\recfnlSYM{\expandafter\noexpand\csname #1 \endcsname}} -\DeclareOptionX{recfsym}[phi]{\edef\recfSYM{\expandafter\noexpand\csname #1 \endcsname}} +\DeclareOptionX{recfnlsym}[@recthy@recfnlSYM@default]{\letcs{\@recthy@recfnlSYM}{#1}} +\DeclareOptionX{recfsym}[@recthy@recfSYM@default]{\letcs{\@recthy@recfSYM}{#1}} +\DeclareOptionX{usesym}[@recthy@useSYM@default]{\letcs{\@recthy@useSYM}{#1}} %Degree Classes @@ -1293,12 +1455,11 @@ \newcommand*{\murec}[2]{\ensuremath{\mu#1\left( #2 \right) }} %\newcommand*{\brecfSYM}{\phi} - \providecommand*{\recfSYM}{\phi} - \providecommand*{\recfnlSYM}{\Phi} - % \newcommand*{\recf}[3][]{\recfSYM^{#1}_{#2}\ifthenelse{\isempty{#3}}{}{\left(#3\right)}} %If give an empty arg just print function no parens + + % \newcommand*{\recf}[3][]{\@recthy@recfSYM^{#1}_{#2}\ifthenelse{\isempty{#3}}{}{\left(#3\right)}} %If give an empty arg just print function no parens %\newcommand*{\brecf}[3][]{\brecfSYM^{#1}_{#2}\ifthenelse{\isempty{#3}}{}{\left(#3\right)}} %\recfnl[d]{i}{Y}{x} gives i-th d-recursive functional operating on set Y and integer x - \newcommand*{\recfnl}[4][]{\recfnlSYM_{#2\ifthenelse{\isempty{#1}}{}{,{#1}} }% + \newcommand*{\recfnl}[4][]{\@recthy@recfnlSYM_{#2\ifthenelse{\isempty{#1}}{}{,{#1}} }% \ifthenelse{\isempty{#4}}% {\ifthenelse{\isempty{#3}}% {}% No args then print no parents @@ -1306,46 +1467,46 @@ }%If no oracle we just refer to the functional without any arguments {\ifthenelse{\isempty{#3}}{(#4)}{(#3;#4)}% }} - \NewDocumentCommand{\recf}{omod()}{ - \recfSYM_{#2\IfNoValueTF{#1}{}{, {#1}}}\IfNoValueTF{#3}{}{^{#3}}\IfNoValueTF{#4}{}{(#4)} + \NewDocumentCommand{\recf}{od()md()}{ + \@recthy@recfSYM_{#3\IfNoValueTF{#1}{}{\ifthenelse{\isempty{#3}}{}{, }{#1}}}\IfNoValueTF{#2}{}{^{#2}}\IfNoValueTF{#4}{}{(#4)} } - \newcommand*{\thetafnl}[4][]{\Theta_{#2\ifthenelse{\isempty{#1}}{}{,#1} }% - \ifthenelse{\isempty{#4}}% - {\ifthenelse{\isempty{#3}}% - {}% No args then print no parents - {(#3)} - }%If no oracle we just refer to the functional without any arguments - {\ifthenelse{\isempty{#3}}{(#4)}{(#3;#4)}% - }} - - \newcommand*{\psifnl}[4][]{\Psi_{#2\ifthenelse{\isempty{#1}}{}{,#1} }% - \ifthenelse{\isempty{#4}}% - {\ifthenelse{\isempty{#3}}% - {}% No args then print no parents - {(#3)} - }%If no oracle we just refer to the functional without any arguments - {\ifthenelse{\isempty{#3}}{(#4)}{(#3;#4)}% - }} - - \newcommand*{\phifnl}[4][]{\Phi_{#2\ifthenelse{\isempty{#1}}{}{,#1} }% - \ifthenelse{\isempty{#4}}% - {\ifthenelse{\isempty{#3}}% - {}% No args then print no parents - {(#3)} - }%If no oracle we just refer to the functional without any arguments - {\ifthenelse{\isempty{#3}}{(#4)}{(#3;#4)}% - }} - - \newcommand*{\upsilonfnl}[4][]{\Upsilon_{#2\ifthenelse{\isempty{#1}}{}{,#1} }% - \ifthenelse{\isempty{#4}}% - {\ifthenelse{\isempty{#3}}% - {}% No args then print no parents - {(#3)} - }%If no oracle we just refer to the functional without any arguments - {\ifthenelse{\isempty{#3}}{(#4)}{(#3;#4)}% - }} + % \newcommand*{\thetafnl}[4][]{\Theta_{#2\ifthenelse{\isempty{#1}}{}{,#1} }% + % \ifthenelse{\isempty{#4}}% + % {\ifthenelse{\isempty{#3}}% + % {}% No args then print no parents + % {(#3)} + % }%If no oracle we just refer to the functional without any arguments + % {\ifthenelse{\isempty{#3}}{(#4)}{(#3;#4)}% + % }} + + % \newcommand*{\psifnl}[4][]{\Psi_{#2\ifthenelse{\isempty{#1}}{}{,#1} }% + % \ifthenelse{\isempty{#4}}% + % {\ifthenelse{\isempty{#3}}% + % {}% No args then print no parents + % {(#3)} + % }%If no oracle we just refer to the functional without any arguments + % {\ifthenelse{\isempty{#3}}{(#4)}{(#3;#4)}% + % }} + + % \newcommand*{\phifnl}[4][]{\Phi_{#2\ifthenelse{\isempty{#1}}{}{,#1} }% + % \ifthenelse{\isempty{#4}}% + % {\ifthenelse{\isempty{#3}}% + % {}% No args then print no parents + % {(#3)} + % }%If no oracle we just refer to the functional without any arguments + % {\ifthenelse{\isempty{#3}}{(#4)}{(#3;#4)}% + % }} + + % \newcommand*{\upsilonfnl}[4][]{\Upsilon_{#2\ifthenelse{\isempty{#1}}{}{,#1} }% + % \ifthenelse{\isempty{#4}}% + % {\ifthenelse{\isempty{#3}}% + % {}% No args then print no parents + % {(#3)} + % }%If no oracle we just refer to the functional without any arguments + % {\ifthenelse{\isempty{#3}}{(#4)}{(#3;#4)}% + % }} \newcommand*{\cequiv}{\mathrel{\simeq}} @@ -1357,8 +1518,8 @@ \NewDocumentCommand{\nconv}{O{}}{\mathpunct{\mkern-4mu{\smallsetminus\mkern 4mu \downarrow}_{#1}}} \newcommand*{\diverge}{\mathpunct{\uparrow}} % \newcommand*{\use}[2]{\mathscr{u}(#1\ifthenelse{\isempty{#2}}{}{,#2})} - \newcommand*{\use}[1]{\mathop{\ltx@ifpackageloaded{unicode-math}{\symbffrak{u}}{\mathfrak{u}}}\!\left[{#1}\right]} - + \newcommand*{\use}[1]{\mathop{\@recthy@useSYM}[#1]} +% \newcommand*{\use}[1]{\ltx@ifpackageloaded{unicode-math}{\symbffrak{u}}{\mathfrak{u}}\left(#1\right)} % \NewDocumentCommand{\REset}{omd()}{ % W_{#2\IfNoValueTF{#1}{}{, #1}}\IfNoValueTF{#3}{}{^{#3}} % } @@ -1449,13 +1610,15 @@ \providecommand*{\TPlus}{\TsetJoin} \providecommand*{\Tjoin}{\Tsetjoin} \providecommand*{\TJoin}{\TsetJoin} + \providecommand*{\Tincompat}{\incompat@recthy[\@recthy@TSYM]} + \providecommand*{\Tincomp}{\Tincompat} + \providecommand*{\Tcompat}{\compat@recthy[\@recthy@TSYM]} + \providecommand*{\nTincompat}{\Tcompat} + \providecommand*{\nTincomp}{\Tcompat} - - - - \newcommand*{\@recthy@ttSYM}{\ensuremath{\text{\tiny tt}}} + \newcommand*{\@recthy@ttSYM}{\ensuremath{\tiny \mathtt{tt}}} \newcommand*{\ttSYM}{\@recthy@ttSYM} \newcommand*{\ttlneq}{\lneq_{\@recthy@ttSYM}} \newcommand*{\ttleq}{\leq_{\@recthy@ttSYM}} |