
Ich bin auf diese erstaunlichen Vorlesungsnotizen gestoßenhttps://yufeizhao.com/gtacbook/gtacbook.pdf, und ich wollte Beispiele für Graphengrenzen erstellen. Weiß jemand, welches Paket/welche Software man zum Erstellen solcher Abbildungen verwenden kann?
Für jede Hilfe ist wir dankbar. Vielen Dank.
Antwort1
Mit Schleifen (und Test für die zweite Abbildung):
\documentclass[tikz,border=5pt]{standalone}
\begin{document}
\begin{tikzpicture}[line width=0.8pt]
\foreach \i in {0,...,6}{
\foreach \j in {\i,...,6}{
\draw (\i,0) -- (\j,5);
}
\draw[fill=white] (\i,5) circle [radius=2mm];
\draw[fill=lightgray] (\i,0) circle [radius=2mm];
}
\foreach \i in {0,...,14}{
\draw (7.5+\i/2,-1) -- (7.5+\i/2,6);
\draw (7.5,\i/2-1) -- (14.5,\i/2-1);
\ifnum \i<7
\filldraw (7.5+\i/2,-1) rectangle (8+\i/2,2.5-\i/2);
\filldraw (14.5-\i/2,6) rectangle (14-\i/2,2.5+\i/2);
\fi
}
\end{tikzpicture}
\end{document}