带有虚线的正方形,箭头方向相反或相同

带有虚线的正方形,箭头方向相反或相同

我想要绘制下图中的一个正方形:

在此处输入图片描述

我想知道如何反转这个粗体箭头。

提前致谢!

答案1

这不是最优雅的中途箭头方法,但你可以用普通的 来实现tikz。(更好的箭头方法在TikZ:如何在线中间画箭头?以了解更复杂的数据。)

\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\draw [thick] (3,0) -- (0,0) -- (0,3);
\draw [thick,  latex reversed-] (0,3)--(0,5)--(3,5);
\draw [thick, latex reversed-latex reversed] (3,5) -- (6,5) -- (6,3);
\draw [thick, -latex reversed] (6,3) -- (6,0) -- (3,0);
\draw [dashed] (0,2.5) -- (6,2.5) node [above, pos=.5] {c};
\node [draw=none, anchor=east] at (0,2.5) {3};
\node [draw=none, anchor=west] at (6,2.5) {4};
\node [draw=none, anchor=east] at (0,3) {a};
\node [draw=none, anchor=west] at (6,3) {a};
\node [draw=none, anchor=east] at (0,0) {5};
\node [draw=none, anchor=east] at (0,5) {1};
\node [draw=none, anchor=west] at (6,0) {6};
\node [draw=none, anchor=west] at (6,5) {2};
\node [draw=none, anchor=south] at (3,5) {b};
\node [draw=none, anchor=north] at (3,0) {b};
\end{tikzpicture}

\begin{tikzpicture}
\draw [thick] (3,0) -- (0,0) -- (0,3);
\draw [thick,  latex reversed-] (0,3)--(0,5)--(3,5);
\draw [thick, latex reversed-] (3,5) -- (6,5) -- (6,3);
\draw [thick, latex reversed-latex reversed] (6,3) -- (6,0) -- (3,0);
\draw [dashed] (0,2.5) -- (6,2.5) node [above, pos=.5] {c};
\node [draw=none, anchor=east] at (0,2.5) {$3'$};
\node [draw=none, anchor=west] at (6,2.5) {$4'$};
\node [draw=none, anchor=east] at (0,3) {a};
\node [draw=none, anchor=west] at (6,3) {a};
\node [draw=none, anchor=east] at (0,0) {$5'$};
\node [draw=none, anchor=east] at (0,5) {$1'$};
\node [draw=none, anchor=west] at (6,0) {$6'$};
\node [draw=none, anchor=west] at (6,5) {$2'$};
\node [draw=none, anchor=south] at (3,5) {b};
\node [draw=none, anchor=north] at (3,0) {b};
\end{tikzpicture}
\end{document}

在此处输入图片描述

相关内容