texlive[68121] Master/texmf-dist: rank-2-roots (31aug23)
commits+karl at tug.org
commits+karl at tug.org
Thu Aug 31 23:39:32 CEST 2023
Revision: 68121
http://tug.org/svn/texlive?view=revision&revision=68121
Author: karl
Date: 2023-08-31 23:39:31 +0200 (Thu, 31 Aug 2023)
Log Message:
-----------
rank-2-roots (31aug23)
Modified Paths:
--------------
trunk/Master/texmf-dist/doc/latex/rank-2-roots/README
trunk/Master/texmf-dist/doc/latex/rank-2-roots/rank-2-roots.pdf
trunk/Master/texmf-dist/doc/latex/rank-2-roots/rank-2-roots.tex
trunk/Master/texmf-dist/tex/latex/rank-2-roots/rank-2-roots.sty
Modified: trunk/Master/texmf-dist/doc/latex/rank-2-roots/README
===================================================================
--- trunk/Master/texmf-dist/doc/latex/rank-2-roots/README 2023-08-30 23:43:26 UTC (rev 68120)
+++ trunk/Master/texmf-dist/doc/latex/rank-2-roots/README 2023-08-31 21:39:31 UTC (rev 68121)
@@ -2,9 +2,9 @@
Rank 2 roots
- v1.0
+ v1.1
- 30 August 2018
+ 31 August 2023
___________________________________
Authors : Ben McKay
Modified: trunk/Master/texmf-dist/doc/latex/rank-2-roots/rank-2-roots.pdf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/doc/latex/rank-2-roots/rank-2-roots.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/rank-2-roots/rank-2-roots.tex 2023-08-30 23:43:26 UTC (rev 68120)
+++ trunk/Master/texmf-dist/doc/latex/rank-2-roots/rank-2-roots.tex 2023-08-31 21:39:31 UTC (rev 68121)
@@ -1,12 +1,29 @@
\documentclass{amsart}
-\usepackage{etex}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenx}
-\title{The Rank 2 Roots Package \\ Version 1.0}
-\author{Ben McKay}
-\date{30 August 2018}
+\title{The Rank 2 Roots Package \\ Version 1.1}
+\makeatletter
+\DeclareRobustCommand{\scotsMc}{\scotsMcx{c}}
+\DeclareRobustCommand{\scotsMC}{\scotsMcx{\textsc{c}}}
+\DeclareRobustCommand{\scotsMcx}[1]{%
+ M%
+ \raisebox{\dimexpr\fontcharht\font`M-\height}{%
+ \check at mathfonts\fontsize{\sf at size}{0}\selectfont
+ \kern.3ex\underline{\kern-.3ex #1\kern-.3ex}\kern.3ex
+ }%
+}
+\expandafter\def\expandafter\@uclclist\expandafter{%
+ \@uclclist\scotsMc\scotsMC
+}
+\makeatother
+
+\author{Benjamin \scotsMc{}Kay}
+\address{School of Mathematical Sciences, University College Cork, Cork, Ireland}
+\email{b.mckay at ucc.ie}
+\date{31 August 2023}
+
\usepackage{etoolbox}
\usepackage{lmodern}
\usepackage[kerning=true,tracking=true]{microtype}
@@ -36,11 +53,9 @@
\usepackage{booktabs}
\usepackage{colortbl}
\usepackage{varwidth}
-\usepackage{dynkin-diagrams}
\usepackage{fancyvrb}
\usepackage{xspace}
\newcommand{\TikZ}{Ti\textit{k}Z\xspace}
-\usepackage{filecontents}
\usetikzlibrary{decorations.markings}
\usetikzlibrary{arrows,decorations.pathmorphing,backgrounds,positioning,fit}
\arrayrulecolor{white}
@@ -53,15 +68,6 @@
\rulecolor{white}
\makeatother
-
-
-
-
-\NewDocumentCommand\todo{m}%
-{%
-\textcolor{blue}{\textit{#1}}
-}%
-
\begin{document}
\maketitle
\tableofcontents
@@ -71,7 +77,23 @@
The purpose of this package is to ease drawing of rank 2 root systems, with Weyl chambers, weight lattices, and parabolic subgroups, mostly imitating the drawings of Fulton and Harris \cite{Fulton.Harris:1991}.
We use definitions of root systems and weight lattices as in Carter \cite{Carter:2005} p. 540--609.
+\begin{tcolorbox}[title={Load the \texttt{rank-2-roots} package}]
+\begin{verbatim}
+\documentclass{amsart}
+\usepackage{rank-2-roots}
+\begin{document}
+The root system \(G_2\):
+\begin{tikzpicture}[baseline=-.5]
+\begin{rootSystem}{G}
+\roots
+\end{rootSystem}
+\end{tikzpicture}
+\end{document}
+\end{verbatim}
+\end{tcolorbox}
+
+
\section{Root systems}
\NewDocumentCommand\drawroots{m}%
{%
@@ -90,6 +112,8 @@
\par\noindent%
\texttt{\detokenize{\roots}}%
\par\noindent%
+\texttt{\detokenize{\roots}}%
+\par\noindent%
\texttt{\detokenize{\end{rootSystem}}}%
\par\noindent%
\texttt{\detokenize{\end{tikzpicture}}}%
@@ -113,13 +137,49 @@
\mytablecontents
\end{longtable}
+\RenewDocumentCommand\drawroots{m}%
+{%
+\begin{tikzpicture}[baseline=-.5]
+\begin{rootSystem}{#1}
+\roots
+\simpleroots
+\end{rootSystem}
+\end{tikzpicture}
+}%
+\RenewDocumentCommand\csdrawroots{m}%
+{%
+\texttt{\detokenize{\begin{tikzpicture}[baseline=-.5]}}%
+\par\noindent%
+\texttt{\detokenize{\begin{rootSystem}}\{#1\}}%
+\par\noindent%
+\texttt{\detokenize{\roots}}%
+\par\noindent%
+\texttt{\detokenize{\simpleroots}}%
+\par\noindent%
+\texttt{\detokenize{\end{rootSystem}}}%
+\par\noindent%
+\texttt{\detokenize{\end{tikzpicture}}}%
+}%
+
+\begin{longtable}{rcm{8cm}}
+\caption{The root systems with the simple roots marked}\\
+\endfirsthead
+\caption{\dots continued}\\
+\endhead
+\multicolumn{3}{c}{continued \dots}\\
+\endfoot
+\endlastfoot
+\mytablecontents
+\end{longtable}
+
+
+
\section{Weights}
Type \verb!\wt{x}{y}! to get a weight at position \((x,y)\) (as measured in a basis of \emph{fundamental weights}).
Type \verb!\wt[multiplicity=n]{x}{y}! to get multiplicity \(m\).
-Add an option: \verb!\wt[Z]{x}{y}{m}! to get \verb!Z! passed to TikZ.
+Add an option: \verb!\wt[Z]{x}{y}! to get \verb!Z! passed to TikZ.
-
\RenewDocumentCommand\drawroots{m}%
{%
\begin{tikzpicture}[baseline=-.5]
@@ -177,7 +237,6 @@
-
\RenewDocumentCommand\drawroots{m}%
{%
\begin{tikzpicture}[baseline=-.5]
@@ -223,24 +282,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\RenewDocumentCommand\drawroots{m}%
{%
\begin{tikzpicture}[baseline=-.5]
@@ -285,24 +326,6 @@
\end{longtable}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\section{Parabolic subgroups}
\RenewDocumentCommand\drawroots{m}%
@@ -349,28 +372,6 @@
\end{longtable}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\RenewDocumentCommand\drawroots{mm}%
{%
\begin{tikzpicture}[baseline=-.5]
@@ -416,32 +417,6 @@
\mytablecontents
\end{longtable}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\RenewDocumentCommand\drawroots{mm}%
{%
\begin{tikzpicture}[baseline=-.5]
@@ -491,8 +466,6 @@
\end{longtable}
-
-
\NewDocumentCommand{\labelWt}{mmmm}%
{%
\node[#1,black] at \weight{#2}{#3} {\(#4\)};
@@ -584,7 +557,6 @@
\section{Coordinate systems}
-
The package provides three coordinate systems: hex, square and weight.
Above we have seen the weight coordinates: a basis of fundamental weights.
We can also use weight coordinates like
@@ -591,6 +563,30 @@
\[
\verb!\draw \weight{0}{1} -- \weight{1}{0};!
\]
+\begin{tcblisting}{title={Drawing weights as linear combinations of fundamental weights}}
+\begin{tikzpicture}
+\begin{rootSystem}{C}
+\roots
+\positiveRootHyperplane
+\fill[thick,brown] \weight{1}{0} circle (1.7pt);
+\fill[thick,blue] \weight{0}{1} circle (1.7pt);
+\fill[thick,red] \weight{2}{-1} circle (1.7pt);
+\end{rootSystem}
+\end{tikzpicture}
+\end{tcblisting}
+We can also specify roots in linear combinations of the simple roots:
+\begin{tcblisting}{title={Drawing roots as linear combinations of simple roots}}
+\begin{tikzpicture}
+\begin{rootSystem}{C}
+\roots
+\positiveRootHyperplane
+\fill[thick,brown] \Root{1}{0} circle (1.7pt);
+\fill[thick,blue] \Root{0}{1} circle (1.7pt);
+\fill[thick,red] \Root{2}{-1} circle (1.7pt);
+\end{rootSystem}
+\end{tikzpicture}
+\end{tcblisting}
+
The square system, used like \verb!\draw (square cs:x=1,y=2) circle (2pt);!, is simply the standard Cartesian coordinate system measured so that the minimum distance between weights is one unit.
The hex coordinate system has basis precisely the fundamental weights of the \(A_2\) lattice.
We can use the hex system in drawing on the \(A_2\) or \(G_2\) weight lattices, as below, as they are the same lattices.
@@ -685,8 +681,6 @@
\end{rootSystem}
\end{tikzpicture}
\end{tcblisting}
-
-
\begin{tcblisting}{}
\setlength{\weightRadius}{2pt}
\setlength\weightLength{.75cm}
@@ -699,7 +693,6 @@
\end{rootSystem}
\end{tikzpicture}
\end{tcblisting}
-
\begin{tcblisting}{title={Changing the weight length rescales}}
\begin{tikzpicture}
\setlength\weightLength{.3cm}
@@ -709,7 +702,6 @@
\end{rootSystem}
\end{tikzpicture}
\end{tcblisting}
-
\begin{tcblisting}{}
\begin{tikzpicture}
\setlength\weightLength{.3cm}
@@ -718,7 +710,6 @@
\end{rootSystem}
\end{tikzpicture}
\end{tcblisting}
-
\begin{tcblisting}{}
\begin{tikzpicture}
\setlength\weightLength{.3cm}
@@ -727,7 +718,6 @@
\end{rootSystem}
\end{tikzpicture}
\end{tcblisting}
-
\begin{tcblisting}{title={We use a basis of fundamental weights, as given in Carter's book \cite{Carter:2005} p. 540--609}}
\begin{tikzpicture}
\begin{rootSystem}{B}
@@ -734,26 +724,15 @@
\roots
\draw[green!50!black,very thick] \weight{0}{1} -- \weight{1}{0};
\weightLattice{3}
-\wt[blue]{1}{0}{1}
-\wt[red]{0}{1}{1}
+\wt[blue]{1}{0}
+\wt[red]{0}{1}
\end{rootSystem}
\end{tikzpicture}
\end{tcblisting}
-
-
-
-
-
-
Without automatic stretching of the weight lattice to fit the picture, you won't see the weight lattice at all unless you ask for it.
\AutoSizeWeightLatticefalse
-
-
-
-
-
\RenewDocumentCommand\drawroots{m}%
{%
\begin{tikzpicture}[baseline=-.5]
@@ -797,8 +776,8 @@
-Type \verb!\wt{x}{y}{m}! to get a weight at position \((x,y)\) (as measured in a basis of \emph{fundamental weights}) with multiplicity \(m\).
-Add an option: \verb!\wt[Z]{x}{y}{m}! to get \verb!Z! passed to TikZ.
+Type \verb!\wt{x}{y}! to get a weight at position \((x,y)\) (as measured in a basis of \emph{fundamental weights}).
+Add an option: \verb!\wt[Z]{x}{y}! to get \verb!Z! passed to TikZ, or with option \verb!multiplicity=!\texttt{n} to get multiplicity $n$.
\RenewDocumentCommand\drawroots{m}%
@@ -806,11 +785,11 @@
\begin{tikzpicture}[baseline=-.5]
\begin{rootSystem}{#1}
\roots
-\wt[brown]{1}{0}{1}
-\wt[red]{0}{1}{1}
-\wt[blue]{1}{3}{4}
-\wt[blue]{2}{2}{2}
-\wt[blue]{-1}{3}{1}
+\wt[brown]{1}{0}
+\wt[red]{0}{1}
+\wt[blue,multiplicity=4]{1}{3}
+\wt[blue,multiplicity=2]{2}{2}
+\wt[blue]{-1}{3}
\end{rootSystem}
\end{tikzpicture}
}%
@@ -823,15 +802,15 @@
\par\noindent%
\texttt{\detokenize{\roots}}%
\par\noindent%
-\texttt{\detokenize{\wt[brown]{1}{0}{1}}}%
+\texttt{\detokenize{\wt[brown]{1}{0}}}%
\par\noindent%
-\texttt{\detokenize{\wt[red]{0}{1}{1}}}%
+\texttt{\detokenize{\wt[red]{0}{1}}}%
\par\noindent%
-\texttt{\detokenize{\wt[blue]{1}{3}{4}}}%
+\texttt{\detokenize{\wt[blue,multiplicity=4]{1}{3}}}%
\par\noindent%
-\texttt{\detokenize{\wt[blue]{2}{2}{2}}}%
+\texttt{\detokenize{\wt[blue,multiplicity=2]{2}{2}}}%
\par\noindent%
-\texttt{\detokenize{\wt[blue]{-1}{3}{1}}}%
+\texttt{\detokenize{\wt[blue]{-1}{3}}}%
\par\noindent%
\texttt{\detokenize{\end{rootSystem}}}%
\par\noindent%
@@ -856,9 +835,6 @@
\mytablecontents
\end{longtable}
-
-
-
\RenewDocumentCommand\drawroots{m}%
{%
\begin{tikzpicture}[baseline=-.5]
@@ -904,24 +880,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\RenewDocumentCommand\drawroots{m}%
{%
\begin{tikzpicture}[baseline=-.5]
@@ -966,31 +924,6 @@
\end{longtable}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\RenewDocumentCommand\drawroots{m}%
{%
\begin{tikzpicture}[baseline=-.5]
@@ -1035,28 +968,6 @@
\end{longtable}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\RenewDocumentCommand\drawroots{mm}%
{%
\begin{tikzpicture}[baseline=-.5]
@@ -1104,30 +1015,6 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\RenewDocumentCommand\drawroots{mm}%
{%
\begin{tikzpicture}[baseline=-.5]
@@ -1237,6 +1124,65 @@
\end{tcblisting}
+
+\newpage
+
+\section{More options}
+
+\newcommand*{\typ}[1]{#1}
+\newcommand*{\optionLabel}[3]{%%
+\multicolumn{2}{l}{\(\texttt{#1}\!: \text{#2}\),} \\
+\multicolumn{2}{l}{\(\textrm{default}= \texttt{#3}\)} \\
+}%%
+\newcommand*{\commandLabel}[3]{%%
+\multicolumn{2}{l}{\(\texttt{\textbackslash #1}\!: \text{#2}\),} \\
+\multicolumn{2}{l}{\(\textrm{default}= \texttt{#3}\)} \\
+}%%
+
+\renewcommand*{\arraystretch}{1}
+\par\noindent%
+\begin{longtable}{p{1cm}p{10cm}}
+\endfirsthead
+\caption{\dots continued}\\
+\endhead
+\multicolumn{2}{c}{continued \dots}\\
+\endfoot
+\endlastfoot
+\commandLabel{weightRadius}{\typ{length}}{1.2pt}
+& Radius of dots used when marking specified weights. \\
+\commandLabel{weightLength}{\typ{length}}{.5cm}
+& Minimum distance between distinct weights. \\
+\commandLabel{gradingDot}{\typ{length}}{2pt}
+& Size of dot around a root using to indicate a grading of a parabolic subalgebra which only contains one root. \\
+\optionLabel{weight lattice}{\typ{TikZ style data}}{gray!40}
+& Style for drawing weight lattice lines. \\
+\optionLabel{root}{\typ{TikZ style data}}{gray}
+& Style for drawing roots. \\
+\optionLabel{root polygon}{\typ{TikZ style data}}{gray!40,opacity=.5}
+& Style for drawing a polygon which indicates the locations of the roots. \\
+\optionLabel{hyperplane}{\typ{TikZ style data}}{gray!50,fill opacity=.5}
+& Style for drawing a hyperplane in a root system which contains either the positive roots, or (more generally) the positive height roots of a parabolic subgroup. \\
+\optionLabel{Weyl chamber}{\typ{TikZ style data}}{gray!60,fill opacity=.5}
+& Style for drawing a wedge indicating the Weyl chamber of a root system. \\
+\optionLabel{grading}{\typ{TikZ style data}}{line width=3pt,gray,opacity=0.5,line cap=round}
+& Style for drawing a thick line over top of some roots to indicate that they lie in the same grading associated to a parabolic subgroup. \\
+\end{longtable}
+
+\begin{verbatim}
+\newlength\weightRadius
+\setlength\weightRadius{1.2pt}
+\newlength\weightLength
+\setlength\weightLength{.5cm}
+\newlength\gradingDot
+\setlength\gradingDot{2pt}
+\tikzstyle{weight lattice}=[gray!40]
+\tikzstyle{root}=[gray]
+\tikzstyle{root polygon}=[gray!40,opacity=.5]
+\tikzstyle{hyperplane}=[gray!50,fill opacity=.5]
+\tikzstyle{Weyl chamber}=[gray!60,fill opacity=.5]
+\tikzstyle{grading}=[line width=3pt,gray,opacity=0.5,line cap=round]
+\end{verbatim}
+
\bibliographystyle{amsplain}
\bibliography{rank-2-roots}
Modified: trunk/Master/texmf-dist/tex/latex/rank-2-roots/rank-2-roots.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/rank-2-roots/rank-2-roots.sty 2023-08-30 23:43:26 UTC (rev 68120)
+++ trunk/Master/texmf-dist/tex/latex/rank-2-roots/rank-2-roots.sty 2023-08-31 21:39:31 UTC (rev 68121)
@@ -2,12 +2,12 @@
%
% The Rank 2 Roots package.
%
-% Version 1.0
+% Version 1.1
%
%
% This package draws root and weight lattices for rank 2 root systems in LaTeX documents,
% using the TikZ package.
-% Please see the file ranktworoots.tex for examples of use of this package.
+% Please see the file rank-2-roots.tex for examples of use of this package.
%
% Benjamin McKay
% b.mckay at ucc.ie
@@ -19,7 +19,7 @@
%
%
\NeedsTeXFormat{LaTeX2e}[1994/06/01]
-\ProvidesPackage{rank-2-roots}[2018/08/30 Rank 2 roots]
+\ProvidesPackage{rank-2-roots}[2023/08/31 Rank 2 roots]
\RequirePackage{tikz}
\RequirePackage{xstring}
\RequirePackage{xparse}
@@ -100,6 +100,7 @@
\xdef\root at system{#1}%
\check at root@system{}%
\choose at weight@lattice{}%
+\choose at root@lattice{}%
}%
{%
\IfStrEq{\weight at lattice@size}{0}%%
@@ -111,8 +112,59 @@
\xdef\root at system{?}%
\xdef\parabolic at subalgebra{?}%
\xdef\weight at lattice@size{\defaultWeightLatticeSize}%
+\xdef\Root{?}%
}%
+\NewDocumentCommand\simpleroots{}%
+{\rt[black]{1}{0}\rt[black]{0}{1}}
+
+\NewDocumentCommand\choose at root@lattice{}
+{%
+\IfStrEqCase{\root at system}%
+{%%
+{A}{\global\let\Root=\A at root}%
+{B}{\global\let\Root=\B at root}%
+{C}{\global\let\Root=\C at root}%
+{G}{\global\let\Root=\G at root}%
+}%%
+[\check at root@system]%
+}%
+
+\NewDocumentCommand\A at root{mm}% x,y in units of simple roots
+{%
+(hex cs:x={(2*(#1)-(#2))},y={(-(#1)+2*(#2))})%
+}%
+
+\NewDocumentCommand\B at root{mm}% x,y in units of simple roots
+{%
+(square cs:x={((#1)-(#2))},y=#2)%
+}%
+
+\NewDocumentCommand\C at root{mm}% x,y in units of simple roots
+{%
+(square cs:x={(2*(#1)-(#2))},y={#2})%
+}%
+
+\NewDocumentCommand\G at root{mm}% x,y in units of simple roots
+{%
+(hex cs:x={(-(#1)+(#2))},y={(2*(#1)-(#2))})%
+}%
+
+\NewDocumentCommand\rt{O{}mm}%[tikz options,multiplicity=???]{x}{y}
+{%
+\check at root@system%
+\pgfkeys{/weight, default, #1}%
+\IfStrEq{\weight at multiplicity}{1}{}%
+{%%%
+\foreach \i in {2,...,\weight at multiplicity}%
+{%
+\draw[/weight,weight,#1,fill=none] \Root{#2}{#3} circle ({\i*\weightRadius});%
+}%
+}%%%
+\fill[/weight,weight,#1] \Root{#2}{#3} circle (\weightRadius);%
+%}%%
+}%
+
\NewDocumentCommand\unrecognized at root@system{m}%
{%
\ClassError{Rank 2 roots}{Unrecognized root system: ``#1''. Allowed values are A,B,C,G}{}%
@@ -517,7 +569,6 @@
(C weight cs:x=#1,y=#2)
}%
-
\NewDocumentCommand\G at weight{mm}%
{%
(hex cs:x={(#1+#2)},y=#2)
More information about the tex-live-commits
mailing list.