有什么想法可以开始绘制这个动态图形吗?

有什么想法可以开始绘制这个动态图形吗?

电枢

我没有放置 MWE,因为我不知道从哪里开始并检查可以完成这项工作的包。

答案1

如果您想使用 TikZ,可以从这里开始:

\documentclass[12pt,a4paper]{article}
\usepackage{tikz}

\begin{document}
\begin{tikzpicture}
\draw (0,10) -- (5,10); % line between 2 points, coordinates of points in ()
\draw (0,9) -- node[above]{$A$} (5,9); % and with some text above it
\draw (0,8) -- node[below]{$B_1$} (5,8); % or below
\draw (0,7) -- node[below]{$B_1$} node[above]{$A$} (5,7); % or both
\draw[<-] (0,6) -- (5,6); % arrow at the start
\draw[->] (0,5) -- (5,5); % or at the end
\draw[<->] (0,4) -- (5,4); % or at both ends
\draw[very thick] (0,3) -- (5,3); % thick line
\draw[line width=5pt] (0,2) -- (5,2); % arbitarry line width
\draw[dashed] (0,1) -- (5,1); % dashed line
\draw[red] (0,0) -- (5,0); % colored line
\draw (6,0) rectangle (7,10); % a rectangle
\draw (8,0) -- node[left] {$C_n$} (8,10); % some text left from line
\draw (9,0) -- node[right] {$D$} (9,10); % or right of it
\draw[->] (10,0) -- (10,9) node[anchor=south west] {$X$}; % some text at the end of the line
\draw[<-,very thick] (11,1) node[anchor=north east] {$Y$} -- (11,10); % or at the start
\fill (11,5.5) circle (0.1); % a circle at a given coordinate
\node[anchor=north west] at (6,10) {$P$}; % some text near a point
\draw[densely dashed] (12,0) -- (12,3); % different styles for dashed lines
\draw[dashed] (12,3.5) -- (12,6.5);
\draw[loosely dashed] (12,7) -- (12,10);
\end{tikzpicture}
\end{document}

Ti*k*Z 采样器

通过结合这些示例并选择适当的坐标,您可以绘制您的图画。

TikZ 使用 1cm 作为单位长度。您也可以使用长度作为坐标(例如(1mm,10pt))。有关更漂亮的箭头,请参阅第 16 章pgf 手册。TikZ 可以做很多事情。只需在手册中搜索命令和选项即可。

相关内容