summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex/semantex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2020-07-07 21:12:35 +0000
committerKarl Berry <karl@freefriends.org>2020-07-07 21:12:35 +0000
commitcbd59dbab4fb9c2903c44e15ba79b41b53ac0387 (patch)
treefa2024c6406cab3d2c7b370c70cccc5d895cc216 /Master/texmf-dist/doc/latex/semantex
parenta0e03ba72786c4d313cad23ccf38dd464f85d3e8 (diff)
semantex (7jul20)
git-svn-id: svn://tug.org/texlive/trunk@55773 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex/semantex')
-rw-r--r--Master/texmf-dist/doc/latex/semantex/README.md10
-rw-r--r--Master/texmf-dist/doc/latex/semantex/semantex.pdfbin234442 -> 235556 bytes
-rw-r--r--Master/texmf-dist/doc/latex/semantex/semantex.tex103
3 files changed, 23 insertions, 90 deletions
diff --git a/Master/texmf-dist/doc/latex/semantex/README.md b/Master/texmf-dist/doc/latex/semantex/README.md
index 9b7c6e4617f..fc472229811 100644
--- a/Master/texmf-dist/doc/latex/semantex/README.md
+++ b/Master/texmf-dist/doc/latex/semantex/README.md
@@ -1,10 +1,12 @@
SemanTeX - object-oriented mathematics
--------------------------------------
-The SemanTeX package for LaTeX delivers a more semantic, systematized way of writing mathematics compared to the ordinary math syntax. The system is
-object-oriented and uses keyval syntax, and everything is highly
-customizable. At the same time, care has been taken to make it the syntax as
-intuitive, natural, practical, and lightweight as possible.
+The SemanTeX package for LaTeX delivers a more semantic,
+systematized way of writing mathematics compared to the
+ordinary math syntax in LaTeX. The system uses keyval syntax
+and is highly customizable. At the same time, care has been
+taken to make it the syntax as simple, natural, practical,
+and lightweight as possible.
----------------------------------------------------------------
SemanTeX --- object-oriented mathematics
diff --git a/Master/texmf-dist/doc/latex/semantex/semantex.pdf b/Master/texmf-dist/doc/latex/semantex/semantex.pdf
index 4f4e3b00c91..8c9f32df7e0 100644
--- a/Master/texmf-dist/doc/latex/semantex/semantex.pdf
+++ b/Master/texmf-dist/doc/latex/semantex/semantex.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/semantex/semantex.tex b/Master/texmf-dist/doc/latex/semantex/semantex.tex
index c273d1dcecf..2a3bee0153e 100644
--- a/Master/texmf-dist/doc/latex/semantex/semantex.tex
+++ b/Master/texmf-dist/doc/latex/semantex/semantex.tex
@@ -34,7 +34,7 @@
\usepackage[nameinlink]{cleveref}
-\title{Seman\!\TeX: Semantic mathematics (v$0.2\alpha$)}
+\title{Seman\!\TeX: Semantic mathematics (v$0.201\alpha$)}
\date{\today}
\author{Sebastian Ørsted (\href{mailto:sorsted@gmail.com}{sorsted@gmail.com})}
@@ -288,8 +288,11 @@ $ \vh[inverseimage]{\sheafF}[spar,stalk=\vp]
% Now we create a couple of variables of the class \MyVar:
\NewObject\MyVar\vf{f}
-\NewObject\MyVarr\vg{g}
+\NewObject\MyVar\vg{g}
\NewObject\MyVar\vh{h}
+\NewObject\MyVar\vn{n}
+\NewObject\MyVar\vp{p}
+\NewObject\MyVar\vU{U}
\NewObject\MyVar\sheafF{\mathcal{F}}
% Now we set up the class \MyVar:
@@ -310,92 +313,20 @@ $ \vh[inverseimage]{\sheafF}[spar,stalk=\vp]
{res}{ return ,symbolputright ={|}, lower ={#1} },
},
}
+
+\begin{document}
+
+$ \vf[conj,der=\vn] $
+
+$ \vg[inv,res=\vU]{x} $
+
+$ \vh[inverseimage]{\sheafF}[spar,stalk=\vp]
+ = \sheafF[stalk=\vh{\vp}] $
+
+\end{document}
\end{lstlisting}
\endgroup
-%\begingroup
-% \SetupClass\MyVar{
-% singlekeys={
-% {inverseimage}{upper={-1},nopar},
-% },
-% valuekeys={
-% {stalk}{lower=#1},
-% {res}{ return,symbolputright={|}, lower={#1} },
-% },
-% argvaluekeys={
-% {coef}{othersep={;}{#1}},
-% },
-% }
-%
-% Traditional math notation in \TeX\ is not particularly semantic -- you usually type the raw \emph{notation} rather than the underlying
-% \emph{meaning} of your math.
-% Take, for instance, the following equations from algebraic geometry:
-% \begin{align*}
-% \vf[inverseimage]{\sheafF}[spar,stalk=\vp]
-% &=
-% \sheafF[stalk=\vf{\vp}] ,
-% \\
-% \sheafreg[\vU]
-% &=
-% \sheafreg[\vX,res=\vU] ,
-% \\
-% \sheafHom{ \sheafF , \sheafG }{\vU}
-% &=
-% \Hom[\sheafreg[\vU]]{ \sheafF[res=\vU] , \sheafG[res=\vU] } ,
-% \\
-% \co{0}{\vU,coef=\sheafreg[\vX]}
-% &= \sheafreg[\vX]{\vU}
-% .
-% \end{align*}
-% Here, \( \sheafF \) and~\( \sheafG \)
-% are sheaves on some scheme~\( \vX \),
-% \( \sheafreg[\vX] \)~is the structure sheaf,
-% and~\( \vU \subset \vX \) an open subset.
-% In traditional \TeX, you would probably define a collection of commands \lstinline!\sheafF!, \lstinline!\sheafG!, \lstinline!\sheafreg!, and~\lstinline!\sheafHom! for~\( \sheafF \),~\( \sheafG \), \( \sheafreg \), and~\( \sheafHom \) and then proceed
-% something like
-% \begin{lstlisting}
-%(f^{-1}\sheafF)_{p}=\sheafF_{f(p)},
-%\sheafreg_{U} = \sheafreg_{X}|_{U},
-%\sheafHom( \sheafF , \sheafG)(U)
-% = \Hom_{\sheafreg_{X} ( \sheafF|_{U} , \sheafG|_{V} ),
-% H^{0}(U;\sheafF) = \sheafF(U).
-% \end{lstlisting}
-% For more than~90~\% of all mathematicians, this solution will be completely satisfactory; it prints what it is supposed to, and that's that.
-% If this is how you feel, there is absolutely no reason for you to continue reading. This package is for the remaining less than~10~\% who would prefer to write
-% something like the following instead:
-% \begin{lstlisting}
-%\vf[inverseimage]{ \sheafF }[spar,stalk=\vp]
-% = \sheafF[ stalk=\vf{\vp} ] ,
-%\sheafreg[\vU] = \sheafreg[ \vX, res=\vU ],
-%\sheafHom{ \sheafF , \sheafG }{\vU}
-% = \Hom[\sheafreg[\vU]]{ \sheafF[res=\vU], \sheafG[res=\vU] },
-%\co{0}{ \vU, coef=\sheafreg[\vX] } = \sheafreg[\vX]{\vU}.
-% \end{lstlisting}
-%
-% A lot of comments are in order.
-% The whole syntax will be explained in later chapters, but let us take a moment to look at these examples and understand the logic.
-% First of all, what is up with all the~\lstinline!v!'s in the command names \lstinline!\vf!, \lstinline!\vX!, \lstinline!\vU!? The~\lstinline!v!~stands for \textquote{variable}, and it is the prefix I recommend using for all standard variables. So for all letters in the alphabet, uppercase and lowercase, as well as the Greek ones, there will be a command: \lstinline!\va!, \lstinline!\vA!, \lstinline!\vb!, \lstinline!\vB!,~etc.
-% It is not always necessary to use them; for instance, in the above example, both \lstinline!\vX! and \lstinline!\vU! could have been replaced by simply~\lstinline!X!,~\lstinline!U! without changing anything. This is because we did not apply any arguments to these symbols. However, for the sake of consistency, I prefer to switch completely to using commands instead of writing the symbols directly.
-% How \emph{you} use the system is completely up to you.
-%
-% In \semantex, all entries are being built up from the inside and out.
-% The basic syntax layout for most \semantex commands is
-% \begin{lstlisting}
-%\⟨object⟩[⟨options⟩]{⟨argument⟩}
-% \end{lstlisting}
-% Let us try focusing on the first example from above:
-% \begin{LTXexample}
-%$\vf[inverseimage]{\sheafF}[spar,stalk=\vp]$
-% \end{LTXexample}
-% You always start with a central piece: a \emph{⟨symbol⟩}.
-% In the case of~\lstinline!\vf!, the symbol is~\( f \). After the symbol follows the options we apply to it, written in brackets~\lstinline![...]!. In this case, we the option~\lstinline!inverseimage!. This tells \semantex that we want the inverse image functor~\( \vf[inverseimage] \), so it adds a superscript~\lstinline!-1! to the symbol. After this, we apply the function~\lstinline!\vf[inverseimage]! to something, namely the sheaf~{$\sheafF$}. This is done by enclosing them in braces~\lstinline!{...}!.\footnote{You should be aware that this argument in braces~\texttt{\{...\}} is \emph{optional}. You can simply write~\texttt{$\backslash$vf[inverseimage]} if you want, and it will produce~\smash{\( \vf[inverseimage] \)}.}
-%
-%
-% Next, we want to take the stalk of this sheaf at the point~\( \vp \). If we simply wrote~\lstinline!\vf[inverseimage]{\sheafF}[stalk=\vp]!, we would get~\smash{\( \vf[inverseimage]{\sheafF}[stalk=\vp] \)}, which looks confusing. So we want to enclose~\smash{\( \vf[inverseimage]{\sheafF} \)} in parentheses before taking the stalk. This is done with the key~\lstinline!spar! (an abbreviation for \textquote{symbol parentheses}).
-% This key takes whatever has been typed so far, symbol and indices, and adds parentheses around it (of course, type and size is adjustable).
-% This~\lstinline!spar! is a key you fill find yourself using a lot.
-%\endgroup
-
\chapter{Getting started}
To get started using \semantex, load down the package
@@ -2220,7 +2151,7 @@ As you see, we use the \lstinline!d!~key to tell the command what superscript it
\chapter{Bugs}
-Lots of things can be improved in the system, including the order in which things are being expanded internally. I am not going to explain this is detail for now, but hope to correct this in the future. For now, the system seems to work fine as long as you do \enquote{normal} things and insert~\lstinline!\noexpand!'s whenever something goes wrong. The only real bug that I currently know of occurs if you use the key~\lstinline!Othersep! in a heading. Then it all dies painfully.
+Lots of things can be improved in the system, including the order in which things are being expanded internally. I am not going to explain this is detail for now, but hope to correct this in the future. For now, the system seems to work fine as long as you do \enquote{normal} things and insert~\lstinline!\noexpand!'s whenever something goes wrong. The only real bug that I currently know of occurs if you use the key~\lstinline!Otherspar! in a heading. Then it all dies painfully.
Then again, why the heck would you do that in the first place? Who scales parentheses in headings?
%\input{testground}