我需要在 TikZ 中绘制此图形以供工作使用。我该怎么做?
到目前为止,我已经:
\documentclass[tikz,border=2mm]{standalone}
\usepackage{lmodern}
\begin{document}
\begin{tikzpicture}[y=2cm, font=\sffamily\small]
\draw[->] (0,0) -- (4.5,0) node[below] {$$};
\foreach \i in {1,2,3,4} \draw (\i,1mm) -- (\i,-1mm) node[below] {\i};
\end{tikzpicture}
\end{document}
答案1
这里,没有不等的间距和位移的箭头,但有 TikZ。
\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{shapes.arrows}
\begin{document}
\begin{tikzpicture}[scale=0.5,
down arrow/.style = {
single arrow, draw,
minimum height=2.5em,
transform shape,
rotate=-90,
}]
\draw (0,0) -- (10,0);
\foreach \i in {1,...,9}
\draw (\i,0.3) -- (\i,-0.3) node[below] {\i};
\foreach \i in {1,2,4,6,7,9}
\node[down arrow] at (\i,1) {};
\end{tikzpicture}
\end{document}