我如何调整一个图表的代码来绘制另一个图表?

我如何调整一个图表的代码来绘制另一个图表?

以下是我的图表代码:

\documentclass{book}
\usepackage[utf8]{inputenc}

\usepackage[a4paper, margin=1in]{geometry}

\usepackage[T1]{fontenc}
\usepackage{lmodern}

%\usepackage[ngerman]{babel}


\usepackage{tikz-cd}

\usepackage{mathtools}
\usepackage{commath}
\usepackage{bbm}
\usetikzlibrary{babel}
 \usetikzlibrary{shapes.geometric}
\usepackage{amsmath,amsfonts,amssymb}
\usepackage{graphicx}
\usepackage{setspace}
\usepackage{lipsum}
\usepackage{titlesec}
\newtheorem{theorem}{Theorem}
\newtheorem{prop}{Proposition}

\usepackage[nottoc]{tocbibind} % For adding List of Tables and List of Figures to Table of Contents
\usepackage[titles]{tocloft}

\makeatletter
\def\ps@headings{%
      \def\@oddfoot{\normalfont\hfil\thepage\hfil}%
      \def\@evenfoot{\normalfont\hfil\thepage\hfil}}
      \def\@evenhead{\hfil\slshape\leftmark}%
      \def\@oddhead{{\slshape\rightmark}\hfil%
      \let\@mkboth\markboth
    \def\chaptermark##1{%
      \markboth {\MakeUppercase{%
        \ifnum \c@secnumdepth >\m@ne
          \if@mainmatter
            \@chapapp\ \thechapter. \ %
          \fi
        \fi
        ##1}}{}}%
    \def\sectionmark##1{%
      \markright {\MakeUppercase{%
        \ifnum \c@secnumdepth >\z@
          \thesection. \ %
        \fi
        ##1}}}}
\makeatother
\pagestyle{headings}% apply new definitions

\begin{document}

\[
  \begin{tikzcd}[row sep=3em]
  & H_{*}(Y)
     & \\
  & H_{*}(\Sigma X\vee \Sigma X)
  \arrow[u,"\nabla_* \circ(f\vee g)_*"] 
  & \\
  H_{*}(\Sigma X)
  \arrow[uur,out=80,in=190,"f_*"]
  \arrow[r]
  \arrow[ur,"i_{1*}"]
  &
  H_{*}(\Sigma X)\times H_{*}(\Sigma X)
  \arrow[u,"i_{1*}\oplus i_{2*}"]
 &
  H_{*}(\Sigma X) 
  \arrow[l]
  \arrow[uul,out=100,in=-10,"g_*"'] 
  \arrow[ul,"i_{2*}"']
  \\
  \end{tikzcd}
\]

\end{document}

此代码显示下图:

在此处输入图片描述

但我还需要显示这个数字:

在此处输入图片描述

请问关于调整我的代码以绘制新图形有什么建议吗?

谢谢!

答案1

  • 请始终提供 MWE,即重现您问题的小文档。对于它来说,提供的大多数前言都是无关紧要的
  • 您只需要改变行的顺序,并相应地改变箭头方向,并写入新的边标签(即重写几乎完整的图表代码):
\documentclass{book}
\usepackage[a4paper, margin=1in]{geometry}
\usepackage[T1]{fontenc}
\usepackage{lmodern}

\usepackage{tikz-cd}

\begin{document}
  & H_{\bullet}(Y)
     & \\
  & H_{\bullet}(\Sigma X\vee \Sigma X)
  \arrow[u,"\nabla_* \circ(f\vee g)_*"]
  & \\
  H_{\bullet}(\Sigma X)
  \arrow[uur,out=80,bend left,"f_*"]
  \arrow[r]
  \arrow[ur,"i_{1*}"]
  &
  H_{\bullet}(\Sigma X)\times H_{\bullet}(\Sigma X)
  \arrow[u,"i_{1*}\oplus i_{2*}"]
 &
  H_{\bullet}(\Sigma X)
  \arrow[l]
  \arrow[uul,bend right,"g_*"']
  \arrow[ul,"i_{2*}"']
  \\
  \end{tikzcd}
\]

permutated rows and changed arrows directions and labels:
\[
\begin{tikzcd}[row sep=3em]
H_{\bullet}(\Sigma X)
    &   H_{\bullet}(\Sigma X)\times H_{\bullet}(\Sigma X)
        \lar
        \rar
        &   H_{\bullet}(\Sigma X)         \\
    &   H_{\bullet}(\Sigma X\vee \Sigma X)
        \arrow[u,"q_{1*}\times q_{2*}" ']
        \arrow[ul,"q_{1*}"]    
        \arrow[ur,"q_{2*}"']
         &                           \\
    &   H_{\bullet}(Y)
        \arrow[u,"c_x" ']
        \arrow[uul,bend left, "q_1\circ c_x"]
        \arrow[uur,bend right,"q_\circ c_x" ']
                &                   \\
\]

\end{document}

在此处输入图片描述

相关内容