From 55ea6c84e488dfc296cfcd4ee3b9d67b7e2fc7bc Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Wed, 18 Jul 2018 22:20:31 +0000 Subject: dynkin-diagrams (18jul18) git-svn-id: svn://tug.org/texlive/trunk@48220 c570f23f-e606-0410-a88d-b1316a301751 --- .../tex/latex/dynkin-diagrams/dynkin-diagrams.sty | 198 ++++++++++++++++----- 1 file changed, 154 insertions(+), 44 deletions(-) (limited to 'Master/texmf-dist/tex') diff --git a/Master/texmf-dist/tex/latex/dynkin-diagrams/dynkin-diagrams.sty b/Master/texmf-dist/tex/latex/dynkin-diagrams/dynkin-diagrams.sty index 2449588637e..f62565b93e8 100644 --- a/Master/texmf-dist/tex/latex/dynkin-diagrams/dynkin-diagrams.sty +++ b/Master/texmf-dist/tex/latex/dynkin-diagrams/dynkin-diagrams.sty @@ -2,7 +2,7 @@ % % The Dynkin Diagrams package. % -% Version 3.12 +% Version 3.13 % % % This package draws Dynkin diagrams in LaTeX documents, using the TikZ package. @@ -18,7 +18,7 @@ % % \NeedsTeXFormat{LaTeX2e}[1994/06/01] -\ProvidesPackage{dynkin-diagrams}[2018/04/30 Dynkin diagrams] +\ProvidesPackage{dynkin-diagrams}[2018/07/18 Dynkin diagrams] \RequirePackage{tikz} \RequirePackage{xstring} \RequirePackage{xparse} @@ -729,11 +729,16 @@ arc (90:0:{\dynkin@fold@radius}) -- ($(\dynkin@root@name \the\@toRoot)$);% \ifdynkin@arrows% \ifdynkin@reverse@arrows% - \path[-<,tips] - ($(\dynkin@root@name \the\@fromRoot)$)% - arc (90:45:{\dynkin@fold@radius});% + \path[-{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] + ($(\dynkin@root@name \the\@toRoot)$)% + arc (45:90:{\dynkin@fold@radius});% +% \path[/Dynkin diagram,edge,-<,tips] +% ($(\dynkin@root@name \the\@fromRoot)$)% +% arc (90:45:{\dynkin@fold@radius});% \else% - \path[->,tips] + \path[-{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] ($(\dynkin@root@name \the\@fromRoot)$)% arc (90:45:{\dynkin@fold@radius});% \fi% @@ -762,11 +767,15 @@ arc (180:90:{\dynkin@fold@radius}) -- ($(\dynkin@root@name \the\@toRoot)$);% \ifdynkin@arrows% \ifdynkin@reverse@arrows% - \path[-<,tips] - ($(\dynkin@root@name \the\@fromRoot)$)% - arc (180:135:{\dynkin@fold@radius});% + \path[/Dynkin diagram,edge, + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] + ($(\dynkin@root@name \the\@toRoot)$)% + arc (135:180:{\dynkin@fold@radius});% \else% - \path[->,tips] + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] ($(\dynkin@root@name \the\@fromRoot)$)% arc (180:135:{\dynkin@fold@radius});% \fi% @@ -795,11 +804,14 @@ arc (-90:0:{\dynkin@fold@radius}) -- ($(\dynkin@root@name \the\@toRoot)$);% \ifdynkin@arrows% \ifdynkin@reverse@arrows% - \path[-<,tips] - ($(\dynkin@root@name \the\@fromRoot)$)% - arc (-90:-45:{\dynkin@fold@radius});% + \path[/Dynkin diagram,edge, + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] + ($(\dynkin@root@name \the\@toRoot)$)% + arc (-45:-90:{\dynkin@fold@radius});% \else% - \path[->,tips] + \path[-{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] ($(\dynkin@root@name \the\@fromRoot)$)% arc (-90:-45:{\dynkin@fold@radius});% \fi% @@ -832,11 +844,15 @@ arc (-180:-90:{\dynkin@fold@radius}) -- ($(\dynkin@root@name \the\@toRoot)$);% \ifdynkin@arrows% \ifdynkin@reverse@arrows% - \path[-<,tips] - ($(\dynkin@root@name \the\@toRoot)+(-\dynkin@fold@radius,\dynkin@fold@radius)$)% - arc (-180:-135:{\dynkin@fold@radius});% + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + tips] + ($(\dynkin@root@name \the\@fromRoot)+(-\dynkin@fold@radius,\dynkin@fold@radius)$)% + arc (-135:-180:{\dynkin@fold@radius});% \else% - \path[->,tips] + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] ($(\dynkin@root@name \the\@toRoot)+(-\dynkin@fold@radius,\dynkin@fold@radius)$)% arc (-180:-135:{\dynkin@fold@radius});% \fi% @@ -864,7 +880,9 @@ ($(\dynkin@root@name \the\@fromRoot)$)% arc (270:360:{\dynkin@fold@radius}) -- ($(\dynkin@root@name \the\@toRoot)$);% \ifdynkin@arrows% - \path[->,tips] + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] ($(\dynkin@root@name \the\@fromRoot)$)% arc (270:315:\dynkin@fold@radius);% \fi% @@ -891,11 +909,15 @@ arc (90:180:{\dynkin@fold@radius}) -- ($(\dynkin@root@name \the\@toRoot)$);% \ifdynkin@arrows% \ifdynkin@reverse@arrows% - \path[-<,tips] - ($(\dynkin@root@name \the\@fromRoot)$)% - arc (90:135:{\dynkin@fold@radius});% + \path[/Dynkin diagram,edge, + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] + ($(\dynkin@root@name \the\@toRoot)$)% + arc (135:90:{\dynkin@fold@radius});% \else% - \path[->,tips] + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] ($(\dynkin@root@name \the\@fromRoot)$)% arc (90:135:{\dynkin@fold@radius});% \fi% @@ -924,11 +946,15 @@ arc (360:270:{\dynkin@fold@radius}) -- ($(\dynkin@root@name \the\@toRoot)$);% \ifdynkin@arrows% \ifdynkin@reverse@arrows% - \path[-<,tips] - ($(\dynkin@root@name \the\@fromRoot)$)% - arc (360:315:{\dynkin@fold@radius});% + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] + ($(\dynkin@root@name \the\@toRoot)$)% + arc (315:360:{\dynkin@fold@radius});% \else% - \path[->,tips] + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] ($(\dynkin@root@name \the\@fromRoot)$)% arc (360:315:{\dynkin@fold@radius});% \fi% @@ -958,11 +984,15 @@ arc (-90:-180:{\dynkin@fold@radius}) -- ($(\dynkin@root@name \the\@toRoot)$);% \ifdynkin@arrows% \ifdynkin@reverse@arrows% - \path[-<,tips] - ($(\dynkin@root@name \the\@fromRoot)$)% - arc (-90:-135:\dynkin@fold@radius);% + \path[/Dynkin diagram,edge + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] + ($(\dynkin@root@name \the\@toRoot)$)% + arc (-135:-90:\dynkin@fold@radius);% \else% - \path[->,tips] + \path[, + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + tips] ($(\dynkin@root@name \the\@fromRoot)$)% arc (-90:-135:\dynkin@fold@radius);% \fi% @@ -991,11 +1021,57 @@ arc (90:-90:{\dynkin@fold@radius}) -- ($(\dynkin@root@name \the\@toRoot)$);% \ifdynkin@arrows% \ifdynkin@reverse@arrows% - \path[-<,tips] + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] + ($(\dynkin@root@name \the\@toRoot)$)% + arc (0:90:\dynkin@fold@radius);% + \else% + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] ($(\dynkin@root@name \the\@fromRoot)$)% arc (90:0:\dynkin@fold@radius);% + \fi% + \fi% + \end{scope}% +}% + + + + +%% \dynkinDefiniteTripleDownRightSemiCircle{

}{} +%% Draws a semi circle from root

to root on the current Dynkin diagram in the current label ordering +%% as a triple path. +%% The starred form accepts

and in the Bourbaki ordering. +\NewDocumentCommand\dynkinDefiniteTripleDownRightSemiCircle{sO{}mm}% +{% + \IfBooleanTF{#1}% + {% + \convertRootPair{#3}{#4}% + }% + {% + \@fromRoot=#3% + \@toRoot=#4% + }% + \begin{scope}[on background layer]% + \draw[/Dynkin diagram,/Dynkin diagram/edge,double,double distance=\dynkin@root@radius,fill=none,#2]% + ($(\dynkin@root@name \the\@fromRoot)$)% + arc (90:-90:{\dynkin@fold@radius}) -- ($(\dynkin@root@name \the\@toRoot)$);% + \draw[/Dynkin diagram,/Dynkin diagram/edge,fill=none,#2]% + ($(\dynkin@root@name \the\@fromRoot)$)% + arc (90:-90:{\dynkin@fold@radius}) -- ($(\dynkin@root@name \the\@toRoot)$);% + \ifdynkin@arrows% + \ifdynkin@reverse@arrows% + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] + ($(\dynkin@root@name \the\@toRoot)$)% + arc (0:90:\dynkin@fold@radius);% \else% - \path[->,tips] + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] ($(\dynkin@root@name \the\@fromRoot)$)% arc (90:0:\dynkin@fold@radius);% \fi% @@ -1005,6 +1081,7 @@ + %% \dynkinDefiniteDoubleUpRightSemiCircle{

}{} %% Draws a semi circle from root

to root on the current Dynkin diagram in the current label ordering %% as a double path. @@ -1025,11 +1102,15 @@ arc (-90:90:{\dynkin@fold@radius}) -- ($(\dynkin@root@name \the\@toRoot)$);% \ifdynkin@arrows% \ifdynkin@reverse@arrows% - \path[-<,tips] - ($(\dynkin@root@name \the\@fromRoot)$)% - arc (-90:0:\dynkin@fold@radius);% + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] + ($(\dynkin@root@name \the\@toRoot)$)% + arc (0:-90:\dynkin@fold@radius);% \else% - \path[->,tips] + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + ,tips] ($(\dynkin@root@name \the\@fromRoot)$)% arc (-90:0:\dynkin@fold@radius);% \fi% @@ -1080,12 +1161,16 @@ }% \begin{scope}[on background layer]% \ifdynkin@reverse@arrows% - \path[-<,tips] - ($(\dynkin@root@name \the\@fromRoot)$) + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + tips] + ($(\dynkin@root@name \the\@toRoot)$) -- - ($.3*(\dynkin@root@name \the\@fromRoot)+.7*(\dynkin@root@name \the\@toRoot)$);% + ($.3*(\dynkin@root@name \the\@toRoot)+.7*(\dynkin@root@name \the\@fromRoot)$);% \else% - \path[->,tips] + \path[ + -{Computer Modern Rightarrow[\dynkin@arrow@color]}, + tips] ($(\dynkin@root@name \the\@fromRoot)$) -- ($.3*(\dynkin@root@name \the\@fromRoot)+.7*(\dynkin@root@name \the\@toRoot)$);% @@ -1353,6 +1438,8 @@ \def\dynkin@current@location{(0,0)} +\def\dynkin@arrow@color{} + \NewDocumentCommand\regurgitate{m}{#1} \pgfkeys{ @@ -1378,6 +1465,8 @@ foldStyle/.style = {draw=black!40,fill=none,line width=\dynkin@root@radius}, leftFold/.style = {}, rightFold/.style = {}, + arrowColor/.estore in = \dynkin@arrow@color, + arrowColor=black, doubleEdges/.style = { foldStyle/.style = { draw=black, @@ -2913,6 +3002,7 @@ %% Draws a D series Dynkin diagram of rank 4, folded over a G2. \NewDocumentCommand\DthreePly{}% {% +\ifdynkin@right@fold% \dynkinPlaceRootHere*{2}{right}% \xdef\old@edge@length{\dynkin@edge@length}% \pgfmathparse{1.5*\dynkin@edge@length}% @@ -2931,6 +3021,17 @@ \dynkin@fold@arrow@if@oo{2}{3}% \dynkin@fold@arrow@if@oo{3}{4}% \fi% +\else% + \global\dynkin@ply=1\relax% + \Ddynkin{}% + \begin{scope}[on background layer]% + \draw + [/Dynkin diagram/foldStyle] + ($(\dynkin@root@name 2)$) + circle + (\dynkin@edge@length);% + \end{scope}% +\fi% }% %% \Ddynkin @@ -3153,9 +3254,18 @@ \ifdynkin@Coxeter% \Idynkin% \else% - \dynkinPlaceRootHere*{1}{below}% - \dynkinPlaceRootRelativeTo*{2}{1}{east}{below}% - \dynkinTripleEdge*{1}{2}% + \ifnum\dynkin@ply>1% + \dynkinPlaceRootHere*{1}{left}% + \dynkinPlaceRootRelativeTo*{2}{1}{southfold}{left}% + \dynkinEdge*{TripleDownRightSemiCircle}{1}{2}% + \ifdynkin@arrows% + \dynkinLeftFold*{1}{2}% + \fi% + \else% + \dynkinPlaceRootHere*{1}{below}% + \dynkinPlaceRootRelativeTo*{2}{1}{east}{below}% + \dynkinTripleEdge*{1}{2}% + \fi% \fi% }% -- cgit v1.2.3