我想绘制一个 2 图,即柯尼斯堡图。我有:V={A,B,C,D} 顶点集 E={e1={A,B}, e2={A,B}, e3={A,D}, e4={C,D}, e5={B,C}, e6={B,C}, e7={B,D}} 节点集(轴,阿里斯塔斯)
谢谢
答案1
pst-eucl
如果您想尝试一下,可以使用 来完成pstricks
。这是一个简短的代码,pdflatex
如果您使用shell-escape
(TeX Live, MacTeX) 或--enable-write18
(MiKTeX) 开关,则可以编译:
\documentclass[12pt, pdf, x11names]{article}%
\usepackage{pst-eucl}
\begin{document}
\begin{pspicture*}(-1, -1.2)(2, 1.2)
\psset{linewidth=0.5pt, linecolor=SteelBlue3, fillcolor=SteelBlue3, PointNameSep=0.8em}
\pstGeonode[PointSymbol=none, PointName=none](0.5,-0.5){O1}(-0.5, -0.5){P1}(0.5,0.5){O2}(-0.5,0.5){P2}
\pstGeonode[PointSymbol=o, PosAngle={180,180,180,0}](0,-1){A}(0,0){B}(0,1){C}(1.5,0){D}
\ncline{A}{D} \ncline{B}{D} \ncline{C}{D}
\pstArcOAB{O1}{B}{A}\pstArcOAB{P1}{A}{B}
\pstArcOAB{O2}{C}{B}\pstArcOAB{P2}{B}{C}
\end{pspicture*}
\end{document}