在 Tikzcd 中将节点稍微向上移动

在 Tikzcd 中将节点稍微向上移动

我正在尝试在 tikzcd 中绘制下图,但我想将标记的节点稍微向上移动,在 tikzcd 中可以这样做吗?或者这是最好正确使用 tikz 的情况之一?我还附上了 Barot 的《代数表示论导论》中的一张图表来说明这一点。我的图表巴罗特图

这是我当前的代码:

\documentclass{amsart}
\usepackage{mathtools}
\usepackage{tikz-cd}

\newcommand{\dimvec}[3]{%
  \begin{smallmatrix}#1\\#2\\#3\end{smallmatrix}%
}

\begin{document}

  \begin{tikzcd}[column sep = small]
    && \dimvec{1}{10}{100} \ar{dr} &&&&&& \dimvec{1}{01}{001} \ar{dr}\\
    & \dimvec{0}{10}{100} \ar{ur} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{1}{10}{000} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{0}{00}{010} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{1}{01}{000} \ar{dr} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{0}{01}{001} \ar{dr} \\
    \dimvec{0}{00}{100} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{0}{10}{000} \ar{ur} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{1}{10}{010} \ar{ur} \ar{r} \ar{dr} & \dimvec{1}{11}{010} \ar{r} & \dimvec{1}{01}{010} \ar{ur} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{0}{01}{000} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{0}{00}{001} \\
    &&& \dimvec{0}{10}{010} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{1}{00}{000} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{0}{01}{010} \ar{ur}
  \end{tikzcd}
\end{document}

非常感谢您的帮助。

如果有人好奇的话,该图是(假设我正确地解决了我的家庭作业)以下箭筒的 Auslander-Reiten 箭筒与关系(https://en.wikipedia.org/wiki/Quiver_(数学)在此处输入图片描述

答案1

您可以使用yshift并可能需要\smash移位的对象以避免扭曲。

\documentclass{amsart}
\usepackage{mathtools}
\usepackage{tikz-cd}

\newcommand{\dimvec}[3]{%
  \begin{smallmatrix}#1\\#2\\#3\end{smallmatrix}%
}

\begin{document}

  \begin{tikzcd}[column sep = small]
    && \dimvec{1}{10}{100} \ar{dr} &&&&&& \dimvec{1}{01}{001} \ar{dr}\\
    & \dimvec{0}{10}{100} \ar{ur} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{1}{10}{000} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{0}{00}{010} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{1}{01}{000} \ar{dr} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{0}{01}{001} \ar{dr} \\
    \dimvec{0}{00}{100} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{0}{10}{000}
    \ar{ur} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{1}{10}{010} \ar{ur}
    \ar{r} \ar{dr} \ar[dotted, no head]{rr} & |[yshift=1.2em]| 
    \smash{\dimvec{1}{11}{010}} \ar{r} & \dimvec{1}{01}{010} \ar{ur} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{0}{01}{000} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{0}{00}{001} \\
    &&& \dimvec{0}{10}{010} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{1}{00}{000} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{0}{01}{010} \ar{ur}
  \end{tikzcd}
\end{document}

在此处输入图片描述

或者,如符号 1 所建议的那样,使用覆盖选项,如果您将节点移动很远并且使用不同的箭头样式,它也会起作用。

\documentclass{amsart}
\usepackage{mathtools}
\usepackage{tikz-cd}

\newcommand{\dimvec}[3]{%
  \begin{smallmatrix}#1\\#2\\#3\end{smallmatrix}%
}

\begin{document}

  \begin{tikzcd}[column sep = small,every arrow/.append
  style={-stealth,semithick}]
    && \dimvec{1}{10}{100} \ar{dr} &&&&&& \dimvec{1}{01}{001} \ar{dr}\\
    & \dimvec{0}{10}{100} \ar{ur} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{1}{10}{000} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{0}{00}{010} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{1}{01}{000} \ar{dr} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{0}{01}{001} \ar{dr} \\
    \dimvec{0}{00}{100} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{0}{10}{000}
    \ar{ur} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{1}{10}{010} \ar{ur}
    \ar{r} \ar{dr} \ar[dotted, no head]{rr} & |[yshift=1.2em,overlay]| 
    \dimvec{1}{11}{010} \ar{r} & \dimvec{1}{01}{010} \ar{ur} \ar{dr} \ar[dotted, no head]{rr} && \dimvec{0}{01}{000} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{0}{00}{001} \\
    &&& \dimvec{0}{10}{010} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{1}{00}{000} \ar{ur} \ar[dotted, no head]{rr} && \dimvec{0}{01}{010} \ar{ur}
  \end{tikzcd}
\end{document}

在此处输入图片描述

相关内容