如何创建显示字段扩展的垂直条?

如何创建显示字段扩展的垂直条?

具体来说,我想创建类似这样的东西:

答案1

您可以使用pst-node或 来完成此操作tikz-cd。对于 pstricks 代码,您必须使用开关--enable-write18(MiKTeX) 或--shell-escape(TeX Live、MacTeX) 启动 pdflatex:

\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage{fourier}
\usepackage{auto-pst-pdf}
 \usepackage{pst-node}
\usepackage{tikz-cd}

\begin{document}

 \[ \psset{arrows=->, arrowinset=0.15, arrowsize=2pt 2, linewidth=0.5pt, nodesep=3pt, rowsep=0.9cm, colsep = 1.1cm, dash=3pt 2pt, shortput =nab, labelsep=2pt}
 \everypsbox{\scriptstyle}
 \begin{psmatrix}
 F(\beta) & F'(\beta') \\%
 F & F'
 %%%
\psset{nodesepB=2pt}
 \ncline[linestyle=dashed ]{1,1}{1,2}^{\widehat{\mathstrut\sigma}} \ncline{2,1}{2,2}^{\sigma}
 \psset{arrows=-}
 \ncline{1,1}{2,1}
 \ncline{1,2}{2,2}
 \end{psmatrix}
 \]

\[ \begin{tikzcd}[column sep=2.5em, row sep=2.5em]
 F(\beta) \arrow[dashrightarrow, end anchor={[xshift=3pt]}]{r}{\widehat{\mathstrut\sigma}} \arrow[dash]{d}{} & F'(\beta') \arrow[dash]{d}{} \\%
F\arrow[end anchor={[xshift=2pt]}]{r}{\sigma}& F
\end{tikzcd}
\]

\end{document} 

在此处输入图片描述

答案2

更短的方式tikz-cd

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

\begin{document}

\[
\begin{tikzcd}[row sep=1cm]
F(\beta) \arrow [d,-] \arrow[r,dashed,->,"\hat{\sigma}"] & F'(\beta')\arrow [d,-] \\
F \arrow[r,"\sigma"',below]&  F
\end{tikzcd}
\]

\end{document}

在此处输入图片描述

答案3

\documentclass{article}

\usepackage{tikz}
\usepackage{amssymb}

\begin{document}

\begin{tikzpicture}
    \node (A) at (0,0) {$F(\beta)$};
    \node (B) at (2,0) {$F'(\beta')$};
    \node (C) at (0,-2) {$F$};
    \node (D) at (2,-2) {$F'$};
    \draw[->,dashed] (A) -- (B) node[midway,above] {$\hat{\sigma}$};
    \draw[->] (C) -- (D) node[midway,below] {$\sigma$};
    \draw (A) -- (C);
    \draw (B) -- (D);
\end{tikzpicture}

\end{document}

相关内容