fix: Nummerierung GaltonbrettFächer ab 0
This commit is contained in:
+8
-8
@@ -360,21 +360,21 @@
|
||||
\begin{multicols}{2}
|
||||
\begin{tikzpicture}[scale=0.8]
|
||||
% Definition der Reihen
|
||||
\def\rows{4}
|
||||
\def\rows{3}
|
||||
|
||||
% Zähler für die Beschriftung
|
||||
\newcounter{labelcount}
|
||||
|
||||
% Fächer (Bins) am unteren Ende basierend auf der Reihenanzahl
|
||||
\foreach \i in {1,...,\rows} {
|
||||
\foreach \i in {0,...,\rows} {
|
||||
\pgfmathsetmacro{\xpos}{\i * 2 - \rows}
|
||||
\draw[thick] (\xpos - 0.4, -\rows - 1.5) rectangle (\xpos + 0.4, -\rows - 0.2);
|
||||
\node at (\xpos, -\rows - 1.8) {\i};
|
||||
}
|
||||
|
||||
% Dreieckiges Nagelbrett
|
||||
\foreach \y in {1,...,\rows} {
|
||||
\foreach \x in {1,...,\y} {
|
||||
\foreach \y in {0,...,\rows} {
|
||||
\foreach \x in {0,...,\y} {
|
||||
\pgfmathsetmacro{\coordx}{2 * \x - \y}
|
||||
|
||||
% Nagel zeichnen
|
||||
@@ -402,21 +402,21 @@
|
||||
|
||||
\begin{tikzpicture}[scale=0.8]
|
||||
% Definition der Reihen
|
||||
\def\rows{5}
|
||||
\def\rows{4}
|
||||
|
||||
% Zähler für die Beschriftung
|
||||
\newcounter{labelcountzwo}
|
||||
|
||||
% Fächer (Bins) am unteren Ende basierend auf der Reihenanzahl
|
||||
\foreach \i in {1,...,\rows} {
|
||||
\foreach \i in {0,...,\rows} {
|
||||
\pgfmathsetmacro{\xpos}{\i * 2 - \rows}
|
||||
\draw[thick] (\xpos - 0.4, -\rows - 1.5) rectangle (\xpos + 0.4, -\rows - 0.2);
|
||||
\node at (\xpos, -\rows - 1.8) {\i};
|
||||
}
|
||||
|
||||
% Dreieckiges Nagelbrett
|
||||
\foreach \y in {1,...,\rows} {
|
||||
\foreach \x in {1,...,\y} {
|
||||
\foreach \y in {0,...,\rows} {
|
||||
\foreach \x in {0,...,\y} {
|
||||
\pgfmathsetmacro{\coordx}{2 * \x - \y}
|
||||
|
||||
% Nagel zeichnen
|
||||
|
||||
Reference in New Issue
Block a user