[OS X TeX] Complete Graphs on n vertices

David Craig dac at panix.com
Sat Nov 26 06:01:00 EST 2022


This popped up in a my Quora feed: <https://qr.ae/pvfsAy <https://qr.ae/pvfsAy>>

The code is supposed to generate a complete graph on n vertices using pstricks:

% !TEX TS-program = xelatex 
 
\documentclass{article} 
\pagestyle{empty} 
 
\usepackage{pstricks,pst-node,pst-plot} 
\usepackage{multido} 
 
\newcommand{\K}[1]{% 
   \psset{linewidth=0.15pt} 
    \begin{pspicture}(-3,-3)(3,3) 
        \SpecialCoor 
        \degrees[#1] 
         \multido{\n=1+1}{#1}{\multido{\i=1+1}{#1}{\psline[linecolor=orange](3;\n)(3;\i)}} 
   \end{pspicture} 
} 
 
\begin{document} 
\begin{center} 
\K{28} 
\end{center} 
\end{document} 

However, this does not compile for me.  TeXShop (with fully updated TeXLive 2022) complains of an undefined control sequence in pst-node:

/usr/local/texlive/2022/texmf-dist/tex/generic/pst-node/pst-node.tex:829: Undefined control sequence.
\reserved at c ->\psset@@rot 
                          
l.829 \psset[pst-node]{nrot=0}

and it’s downhill from there.  I haven’t a clue what to do with that, or how to fix it.

Any ideas?  (Please cc replies directly to me as I’m on the digest.)

Thanks,
David Craig

PS. Also, would love to see how this would be done in tikz!


<http://www.panix.com/~dac/>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://email.esm.psu.edu/pipermail/macosx-tex/attachments/20221126/2c3748ab/attachment.htm>


More information about the MacOSX-TeX mailing list