10

Following the advice of LaRiFaRi in an answer to this question, I switched from XY-Pic to tikz-cd. The file below contains my diagram in XY-Pic and in tikz-cd. Please help me to make my diagram in tikz-cd beautiful!

I would like:

  1. To improve the problematic arrow from $\ell-1$ to 1;

  2. To make the arrow tips sharper, as in XY-Pic;

  3. To make the solid lines touch (or at least almost touch) the small circles.

Note that my diagram is an (affine) Dynkin diagram, so it should look as a Dynkin diagram, see these pictures.

EDIT: I took the corrected arrow from LaRiFaRi's answer and found suitable arrow tips in the library following his advice. Now the diagram is nicer than that of XY-Pic. Still I need solid lines coming closer to the small circles. Find below the corrected diagram.

 \documentclass[a4paper,12pt]{amsart}
\usepackage[all]{xy}
\usepackage{tikz-cd}
\usetikzlibrary{arrows.meta}

\def\ccc{{  \lower0.3ex\hbox{{\text{\Large$\circ$}}}}}
\newcommand{\bc}[1]{{\overset{#1}{\ccc}}}
\newcommand{\bcu}[1]{{\underset{#1}{\ccc}}}

\begin{document}
\[   \xymatrix@1@R=-5pt@C=10pt{
& \bc{0} \ar@{-}[rd]\ar@/^0.75pc/@{-->}[rrrr] &&  &&\bc{\ell-1}\ar@{-}[ld]
    \ar@{-->} `l[lld]  `[lldd]  [lllldd] \\
&&\bc{2}\ar@{-}[r] & \cdots  \ar@{-}[r] & \bc{\ell-2} \\
&\bc{1}\ar@{-}[ru] \ar@/_0.7pc/@{-->}[rrrr] & &  & &\bc{\ell}\ar@{-}[lu]
    \ar@{--2>} `d[l] `l[lllll] `[uu]  [lllluu] \\
}   \]
\bigskip

\[  \begin{tikzcd}[every arrow/.append style={dash},row sep=-5pt, column sep=10pt]
\bc{0} \arrow{dr} \arrow[thin,-{Stealth[open]}, dashed,bend left=20]{rrr} 
 & &[.8cm] & \bc{\ell-1}
 \arrow[thin,-{Stealth[open]}, dashed, rounded corners, 
        to path={ -- ([xshift=-1.795cm]\tikztostart.west) |- 
        (\tikztotarget)}]{llldd}
\\
& \bc{2} \arrow{r}[description]{\ldots} & \bc{\ell-2} \arrow{ur}\arrow{dr} &
\\
\bc{1}\arrow[thin,-{Stealth[open]}, dashed,bend right=20]{rrr}\arrow{ur} &
       & & \bc{\ell}
       \arrow[thin,-{Stealth[open]}, dashed, rounded corners, 
            to path={ -- ([yshift=-2ex]\tikztostart.south) -|
            ([xshift=-1.5ex]\tikztotarget.west) -- (\tikztotarget)}]{uulll}
\end{tikzcd}  \]
\end{document}   

enter image description here

2 Answers 2

2

You can try the dynkin-diagrams package. This example is included in the documentation. Note that by default, the affine root of this D series diagram is marked with a white circle, while the other roots have solid circles; you can easily change this if you don't like it.

enter image description here

\documentclass{amsart}
\usepackage{dynkin-diagrams}
\tikzset{big arrow/.style={
    -Stealth,line cap=round,line width=1mm,
    shorten <=1mm,shorten >=1mm}}
\newcommand\catholic[2]{\draw[big arrow,green!25!white] 
(root #1) to (root #2);}
\newcommand\protestant[2]{
\begin{scope}[transparency group, opacity=.25]
\draw[big arrow,orange] (root #1) to (root #2);
\end{scope}}
\begin{document}
\begin{dynkinDiagram}[edge length=1.2cm,
indefinite edge/.style={thick,loosely dotted},
labels*={0,1,2,3,\ell-3,\ell-2,\ell-1,\ell}]{D}[1]{}
\catholic{0}{6}\catholic{1}{7}
\protestant{7}{0}\protestant{6}{1}
\end{dynkinDiagram}
\end{document}
0
5

Maybe this?

% arara: pdflatex

\documentclass[a4paper,12pt]{amsart}
\usepackage{tikz-cd}

\begin{document}
\[
\begin{tikzcd}[row sep=-5pt, column sep=10pt,cells={nodes={draw, circle,font=\tiny, inner sep=2pt, minimum size=24pt}}]
     1 \arrow[dash]{dr} \arrow[dashed,bend left=25]{rrr} & &[.8cm] & 
     \ell-1 \arrow[dashed, rounded corners, to path={ -- ([xshift=-1.795cm]\tikztostart.west) |- (\tikztotarget)}]{llldd}
    \\
    & 2 \arrow[dash]{r}[description]{\ldots} & \ell-2 \arrow[dash]{ur}\arrow[dash]{dr} & 
    \\
    1 \arrow[dash]{ur} & & & 
    \ell \arrow[dashed,bend left=25]{lll} \arrow[dashed, rounded corners, to path={ -- ([yshift=-2ex]\tikztostart.south) -| ([xshift=-1.5ex]\tikztotarget.west) -- (\tikztotarget)}]{uulll}
\end{tikzcd}  
\]
\end{document}

enter image description here

I have not changed the arrow tips as the ones from xy are just ugly. If you want to change to some other style, just look into the manual. xy arrow heads are not included asaif.

1
  • Dear @LaRiFaRi, this is very beautiful, but not what I need. I need a labeled graph: small circles and small numbers/symbols near the small circles. The solid lines should come very close to the circles (maybe even touch them). I have edited my file in the question, taking in account your answer. Still I don't know how to make the solid lines come closer to the small circles. Jun 10, 2015 at 19:17

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .