coloring_nested_tire_graphs: add picture for menagerie §6 (θ(1,3,3))
Adds fig_theta133.png illustrating the polygon-with-one-chord case: hexagon C_6 with the chord between v_0 and v_3 (the two trivalent vertices), edges colored with a valid proper 3-edge-coloring using the 3 colors a, b, c. Replaces the previous bracketed placeholder text in §6 of menagerie.tex. Adds draw_theta_133.py generator script. Paper stays at 4 pages. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,97 @@
|
||||
"""Draw theta(1, 3, 3) = hexagon with one chord, illustrating section 6
|
||||
of the menagerie. Shows a proper 3-edge-coloring with the two
|
||||
trivalent vertices highlighted."""
|
||||
import math
|
||||
import os
|
||||
import matplotlib.pyplot as plt
|
||||
|
||||
|
||||
def main():
|
||||
here = os.path.dirname(os.path.abspath(__file__))
|
||||
out = os.path.join(here, 'fig_theta133.png')
|
||||
|
||||
# Hexagon: 6 cycle vertices in regular hexagon, with v_0 at top and v_3 at bottom
|
||||
# so the chord v_0-v_3 is the vertical diameter.
|
||||
n = 6
|
||||
pos = {}
|
||||
for i in range(n):
|
||||
angle = math.pi / 2 - 2 * math.pi * i / n
|
||||
pos[i] = (math.cos(angle), math.sin(angle))
|
||||
|
||||
cycle_edges = [(i, (i + 1) % n) for i in range(n)]
|
||||
chord = (0, 3)
|
||||
|
||||
# Proper 3-edge-coloring:
|
||||
# chord = color C, e_0 = A, e_1 = C, e_2 = B, e_3 = A, e_4 = C, e_5 = B
|
||||
A = '#1f77b4' # blue
|
||||
B = '#d62728' # red
|
||||
C = '#2ca02c' # green
|
||||
|
||||
cycle_colors = [A, C, B, A, C, B]
|
||||
chord_color = C
|
||||
|
||||
fig, ax = plt.subplots(figsize=(4.5, 4.0))
|
||||
|
||||
# Draw cycle edges
|
||||
for i, (u, v) in enumerate(cycle_edges):
|
||||
x1, y1 = pos[u]; x2, y2 = pos[v]
|
||||
ax.plot([x1, x2], [y1, y2], color=cycle_colors[i], linewidth=3.0,
|
||||
solid_capstyle='round', zorder=1)
|
||||
|
||||
# Draw chord (slightly dashed to distinguish from polygon edges)
|
||||
x1, y1 = pos[chord[0]]; x2, y2 = pos[chord[1]]
|
||||
ax.plot([x1, x2], [y1, y2], color=chord_color, linewidth=3.0,
|
||||
linestyle=(0, (3, 2)), solid_capstyle='round', zorder=1)
|
||||
|
||||
# Draw vertices, highlighting trivalent vertices in a darker shade
|
||||
trivalent = {0, 3}
|
||||
for v, (x, y) in pos.items():
|
||||
if v in trivalent:
|
||||
ax.plot(x, y, 'o', color='#333333', markersize=22, zorder=2)
|
||||
label_color = 'white'; fontsize = 11
|
||||
else:
|
||||
ax.plot(x, y, 'o', color='#888888', markersize=18, zorder=2)
|
||||
label_color = 'white'; fontsize = 10
|
||||
ax.annotate(f"$v_{v}$", (x, y), color=label_color, ha='center',
|
||||
va='center', fontsize=fontsize, fontweight='bold', zorder=3)
|
||||
|
||||
# Annotations: indicate the 3 paths and the chord
|
||||
ax.annotate('chord (path of length 1)',
|
||||
xy=(0, 0), xytext=(1.65, 0.05),
|
||||
fontsize=9, color=chord_color,
|
||||
arrowprops=dict(arrowstyle='->', color=chord_color, lw=1.2))
|
||||
ax.annotate('right path (length 3)',
|
||||
xy=(1.0, -0.05), xytext=(1.6, -0.75),
|
||||
fontsize=9, color='#444',
|
||||
arrowprops=dict(arrowstyle='->', color='#444', lw=1.0))
|
||||
ax.annotate('left path (length 3)',
|
||||
xy=(-1.0, -0.05), xytext=(-2.45, -0.75),
|
||||
fontsize=9, color='#444',
|
||||
arrowprops=dict(arrowstyle='->', color='#444', lw=1.0))
|
||||
|
||||
# Legend for edge colors
|
||||
legend_items = [
|
||||
plt.Line2D([], [], color=A, linewidth=3, label='color $a$'),
|
||||
plt.Line2D([], [], color=B, linewidth=3, label='color $b$'),
|
||||
plt.Line2D([], [], color=C, linewidth=3, label='color $c$'),
|
||||
plt.Line2D([], [], marker='o', color='w', markerfacecolor='#333333',
|
||||
markersize=12,
|
||||
label='trivalent (degree-3) vertex'),
|
||||
]
|
||||
ax.legend(handles=legend_items, loc='upper left',
|
||||
bbox_to_anchor=(1.02, 1.0), fontsize=9, frameon=False)
|
||||
|
||||
ax.set_xlim(-2.6, 2.7)
|
||||
ax.set_ylim(-1.4, 1.4)
|
||||
ax.set_aspect('equal'); ax.axis('off')
|
||||
ax.set_title(r'$\theta(1, 3, 3)$: hexagon $C_6$ with one chord' + '\n' +
|
||||
r'(2-connected outerplanar, $\Delta = 3$, $P_e(\theta(1,3,3),3)=30$)',
|
||||
fontsize=11)
|
||||
|
||||
plt.savefig(out, dpi=160, bbox_inches='tight')
|
||||
plt.close()
|
||||
print(f"wrote {out}")
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 43 KiB |
@@ -1,4 +1,4 @@
|
||||
This is pdfTeX, Version 3.141592653-2.6-1.40.24 (TeX Live 2022) (preloaded format=pdflatex 2022.10.5) 25 MAY 2026 21:21
|
||||
This is pdfTeX, Version 3.141592653-2.6-1.40.24 (TeX Live 2022) (preloaded format=pdflatex 2022.10.5) 25 MAY 2026 21:25
|
||||
entering extended mode
|
||||
restricted \write18 enabled.
|
||||
%&-line parsing enabled.
|
||||
@@ -290,42 +290,48 @@ File: fig_corona.png Graphic file (type png)
|
||||
Package pdftex.def Info: fig_corona.png used on input line 76.
|
||||
(pdftex.def) Requested size: 197.29623pt x 197.29816pt.
|
||||
[2 <./fig_star.png> <./fig_corona.png>]
|
||||
<fig_blocktree.png, id=29, 242.55618pt x 147.70181pt>
|
||||
<fig_theta133.png, id=29, 451.23581pt x 177.51318pt>
|
||||
File: fig_theta133.png Graphic file (type png)
|
||||
<use fig_theta133.png>
|
||||
Package pdftex.def Info: fig_theta133.png used on input line 118.
|
||||
(pdftex.def) Requested size: 272.45877pt x 107.18588pt.
|
||||
[3 <./fig_theta133.png>]
|
||||
<fig_blocktree.png, id=38, 242.55618pt x 147.70181pt>
|
||||
File: fig_blocktree.png Graphic file (type png)
|
||||
<use fig_blocktree.png>
|
||||
Package pdftex.def Info: fig_blocktree.png used on input line 158.
|
||||
Package pdftex.def Info: fig_blocktree.png used on input line 157.
|
||||
(pdftex.def) Requested size: 258.36668pt x 157.34296pt.
|
||||
[3] [4 <./fig_blocktree.png>] (./menagerie.aux) )
|
||||
[4 <./fig_blocktree.png>] (./menagerie.aux) )
|
||||
Here is how much of TeX's memory you used:
|
||||
4627 strings out of 478268
|
||||
75226 string characters out of 5846347
|
||||
373157 words of memory out of 5000000
|
||||
22806 multiletter control sequences out of 15000+600000
|
||||
4634 strings out of 478268
|
||||
75369 string characters out of 5846347
|
||||
372157 words of memory out of 5000000
|
||||
22812 multiletter control sequences out of 15000+600000
|
||||
479481 words of font info for 67 fonts, out of 8000000 for 9000
|
||||
1141 hyphenation exceptions out of 8191
|
||||
55i,6n,63p,245b,198s stack positions out of 10000i,1000n,20000p,200000b,200000s
|
||||
{/usr/local/texlive/2022/texm
|
||||
f-dist/fonts/enc/dvips/cm-super/cm-super-ts1.enc}</usr/local/texlive/2022/texmf
|
||||
-dist/fonts/type1/public/amsfonts/cm/cmbx10.pfb></usr/local/texlive/2022/texmf-
|
||||
dist/fonts/type1/public/amsfonts/cm/cmbx12.pfb></usr/local/texlive/2022/texmf-d
|
||||
ist/fonts/type1/public/amsfonts/cm/cmex10.pfb></usr/local/texlive/2022/texmf-di
|
||||
st/fonts/type1/public/amsfonts/cm/cmmi10.pfb></usr/local/texlive/2022/texmf-dis
|
||||
t/fonts/type1/public/amsfonts/cm/cmmi12.pfb></usr/local/texlive/2022/texmf-dist
|
||||
/fonts/type1/public/amsfonts/cm/cmmi8.pfb></usr/local/texlive/2022/texmf-dist/f
|
||||
onts/type1/public/amsfonts/cm/cmr10.pfb></usr/local/texlive/2022/texmf-dist/fon
|
||||
ts/type1/public/amsfonts/cm/cmr12.pfb></usr/local/texlive/2022/texmf-dist/fonts
|
||||
/type1/public/amsfonts/cm/cmr17.pfb></usr/local/texlive/2022/texmf-dist/fonts/t
|
||||
ype1/public/amsfonts/cm/cmr6.pfb></usr/local/texlive/2022/texmf-dist/fonts/type
|
||||
1/public/amsfonts/cm/cmr8.pfb></usr/local/texlive/2022/texmf-dist/fonts/type1/p
|
||||
ublic/amsfonts/cm/cmsy10.pfb></usr/local/texlive/2022/texmf-dist/fonts/type1/pu
|
||||
blic/amsfonts/cm/cmsy8.pfb></usr/local/texlive/2022/texmf-dist/fonts/type1/publ
|
||||
ic/amsfonts/cm/cmti10.pfb></usr/local/texlive/2022/texmf-dist/fonts/type1/publi
|
||||
c/amsfonts/cm/cmtt10.pfb></usr/local/texlive/2022/texmf-dist/fonts/type1/public
|
||||
/cm-super/sfrm1095.pfb>
|
||||
Output written on menagerie.pdf (4 pages, 227201 bytes).
|
||||
{/usr/local/texlive/2022/texmf-dis
|
||||
t/fonts/enc/dvips/cm-super/cm-super-ts1.enc}</usr/local/texlive/2022/texmf-dist
|
||||
/fonts/type1/public/amsfonts/cm/cmbx10.pfb></usr/local/texlive/2022/texmf-dist/
|
||||
fonts/type1/public/amsfonts/cm/cmbx12.pfb></usr/local/texlive/2022/texmf-dist/f
|
||||
onts/type1/public/amsfonts/cm/cmex10.pfb></usr/local/texlive/2022/texmf-dist/fo
|
||||
nts/type1/public/amsfonts/cm/cmmi10.pfb></usr/local/texlive/2022/texmf-dist/fon
|
||||
ts/type1/public/amsfonts/cm/cmmi12.pfb></usr/local/texlive/2022/texmf-dist/font
|
||||
s/type1/public/amsfonts/cm/cmmi8.pfb></usr/local/texlive/2022/texmf-dist/fonts/
|
||||
type1/public/amsfonts/cm/cmr10.pfb></usr/local/texlive/2022/texmf-dist/fonts/ty
|
||||
pe1/public/amsfonts/cm/cmr12.pfb></usr/local/texlive/2022/texmf-dist/fonts/type
|
||||
1/public/amsfonts/cm/cmr17.pfb></usr/local/texlive/2022/texmf-dist/fonts/type1/
|
||||
public/amsfonts/cm/cmr6.pfb></usr/local/texlive/2022/texmf-dist/fonts/type1/pub
|
||||
lic/amsfonts/cm/cmr8.pfb></usr/local/texlive/2022/texmf-dist/fonts/type1/public
|
||||
/amsfonts/cm/cmsy10.pfb></usr/local/texlive/2022/texmf-dist/fonts/type1/public/
|
||||
amsfonts/cm/cmsy8.pfb></usr/local/texlive/2022/texmf-dist/fonts/type1/public/am
|
||||
sfonts/cm/cmti10.pfb></usr/local/texlive/2022/texmf-dist/fonts/type1/public/ams
|
||||
fonts/cm/cmtt10.pfb></usr/local/texlive/2022/texmf-dist/fonts/type1/public/cm-s
|
||||
uper/sfrm1095.pfb>
|
||||
Output written on menagerie.pdf (4 pages, 262034 bytes).
|
||||
PDF statistics:
|
||||
109 PDF objects out of 1000 (max. 8388607)
|
||||
111 PDF objects out of 1000 (max. 8388607)
|
||||
60 compressed objects within 1 object stream
|
||||
0 named destinations out of 1000 (max. 500000)
|
||||
26 words of extra memory for PDF output out of 10000 (max. 10000000)
|
||||
31 words of extra memory for PDF output out of 10000 (max. 10000000)
|
||||
|
||||
|
||||
Binary file not shown.
@@ -115,8 +115,7 @@ $C_{p+q}$ with a chord joining the two cycle vertices at distance $p$
|
||||
apart on the polygon.
|
||||
|
||||
\begin{center}
|
||||
\textit{[$\theta(1,p,q)$: polygon $C_{p+q}$ with one chord; both chord
|
||||
endpoints have degree~$3$, other polygon vertices have degree~$2$.]}
|
||||
\includegraphics[width=0.58\textwidth]{fig_theta133.png}
|
||||
\end{center}
|
||||
|
||||
$\theta(1,p,q)$ is outerplanar (the chord lies inside the polygon, and
|
||||
|
||||
Reference in New Issue
Block a user