2

With the following snippet:

\begin{tikzcd}[row sep=1.5cm, every arrow/.append style = {dash}]
    &  H_5 = S_3 & \\
    H_1 \arrow[ur] & H_2 \arrow[u] & H_3 \arrow[ul] & H_4 \arrow[ull] \\
    & \arrow[ul] \arrow[u] \arrow[ur] \arrow[urr] H_0 &
\end{tikzcd}

I get:

enter image description here

I'd like the top and bottom entries (i.e. $H_0$ and $H_5 = S_3$) to be positioned so that they are equidistant to $H_2$ and $H_3$ below them, rather than being shifted over to the left. I thought that using one fewer column in the top and bottom row would do the trick, but evidently not.

What is the right way to achieve this?

2
  • Maybe adding more columns and put H5=S3 between H2 and H3? Jun 20 at 20:40
  • I changed 2.5em to 3em, which seems slightly better.
    – egreg
    Jun 20 at 20:56

1 Answer 1

5

Add a column, but make some space between columns smaller to cover your tracks.

\documentclass{article}
\usepackage{amsmath}
\usepackage{tikz-cd}

\begin{document}

\[
\begin{tikzcd}[row sep=1.5cm, arrows=dash]
  &&[-3em]  H_5 = S_3 &[-3em] \\
  H_1 \arrow[urr] & H_2 \arrow[ur] &&  H_3 \arrow[ul] & H_4 \arrow[ull] \\
  && H_0 \arrow[ull] \arrow[ul] \arrow[ur] \arrow[urr]
\end{tikzcd}
\]

\end{document}

enter image description here

Note the simpler way to get all arrows to be dashes.

3

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.