如何使用LaTeX绘制圆圈

时间:2016-01-15 11:18:06

标签: latex

我想绘制一个在Latex中有6个等距点的圆圈,标记为1,...,6,然后连接点1,点2,点3 ......有谁知道如何绘制它?谢谢!

1 个答案:

答案 0 :(得分:1)

您可以使用the tikz library

\documentclass{minimal}
\usepackage{tikz}

\begin{document}

\begin{tikzpicture}
    % equidistant points and arc
    \foreach \x [count=\p] in {0,...,11} {
        \node[shape=circle,fill=black, scale=0.5] (\p) at (-\x*30:2) {};};
    \foreach \x [count=\p] in {0,...,5} {
        \draw (-\x*60:2.4) node {\p};
        \draw (-30-\x*60:2.4) node {$\bar{\p}$};}; 
    \draw (1) arc (0:360:2);
    \draw[dashed] (1) -- (3) -- (5) -- (1);
    % axes
    \draw [dotted, gray] (-2.6,0) -- (2.6,0);
    \draw [dotted, gray] (0,-2.15) -- (0,2.15);
\end{tikzpicture}

\end{document}

Circle