Does light charge the quons? › Files cited on the page › the trials
fig_reflection_grid.py
"""fig_reflection_grid.py - Figure 4 of the charging-quons paper (section 8.5), from trial 5's time runs R4b and R4d
(reflection_grid_R4d.npz, written by reflection_grid.py). Plots only; no new results.
Run: ~/aspden-review-venv/bin/python3 fig_reflection_grid.py (writes ../../papers/figures/fig-reflection-grid.png)
"""
import numpy as np
import matplotlib
matplotlib.use("Agg")
import matplotlib.pyplot as plt
d = np.load("reflection_grid_R4d.npz")
tb, rb = d["t_b"], d["rms_b"] # R4b: no friction; the finer quons' rms displacement from the even grid
td, rq = d["t"], d["rms_from_quon"] # R4d: friction 1; the finer quons' rms distance from the quon
GAMMA = 5.505501 # sqrt(-lowest eigenvalue) of the mass-weighted Phi(Gamma) (R3, R4)
S1 = 0.152876 # rms width of the quon's charge in the run
INK, MUTED, GRIDC = "#222222", "#666666", "#e3e3e3"
BLUE, ORANGE = "#2471a3", "#ca6f1e"
fig, ax = plt.subplots(1, 2, figsize=(11, 4.6))
a = ax[0]
a.semilogy(tb, rb, color=BLUE, lw=2, label="the run (no friction)")
m = (rb > 1e-5) & (rb < 1e-3)
c = np.exp(np.mean(np.log(rb[m]) - GAMMA * tb[m]))
tt = np.linspace(0.5, tb[-1], 50)
a.semilogy(tt, c * np.exp(GAMMA * tt), color=ORANGE, lw=1.5, ls="--", label=f"growth rate from the stability analysis ({GAMMA:.2f})")
a.set_xlabel("time (trial units)", color=INK)
a.set_ylabel("finer quons' rms displacement\nfrom the even grid (quon spacings)", color=INK)
a.set_title("(a) A disturbance of 10⁻⁷ grows at the rate the\nstability analysis gives (to 1 part in 10⁴)", fontsize=10, loc="left", color=INK)
a.grid(True, which="major", color=GRIDC, lw=0.8)
a.legend(loc="upper left", fontsize=8.5, frameon=False)
b = ax[1]
RQ = np.sqrt(3) * S1 # the rms radius of the quon's (Gaussian) charge
b.axhspan(0, RQ, color="#d6e4f0", lw=0)
b.text(20, RQ * 0.4, "inside the quon's charge\n(within its rms radius, 0.26)", fontsize=8.5, color=MUTED, ha="center")
b.plot(td, rq, color=BLUE, lw=2)
b.annotate("even grid: finer quons at their sites\n(rms distance 0.61)", xy=(0.3, rq[0]), xytext=(6, 0.52), fontsize=8.5, color=INK,
arrowprops=dict(arrowstyle="-", color=MUTED, lw=0.8))
b.annotate("at rest from about t = 15 to the run's end (t = 100):\nall 8 on a shell at 0.19, inside the quon's charge", xy=(25, rq[-1]), xytext=(9, 0.36),
fontsize=8.5, color=INK, arrowprops=dict(arrowstyle="-", color=MUTED, lw=0.8))
b.set_xlim(0, 30); b.set_ylim(0, 0.7)
b.set_xlabel("time (trial units)", color=INK)
b.set_ylabel("finer quons' rms distance\nfrom the quon (quon spacings)", color=INK)
b.set_title("(b) With a little friction, the finer quons fall into\nthe quon and come to rest inside its charge", fontsize=10, loc="left", color=INK)
b.grid(True, color=GRIDC, lw=0.8)
for x in ax:
for sp in ("top", "right"):
x.spines[sp].set_visible(False)
x.tick_params(colors=MUTED)
fig.text(0.01, 0.01, "Trial 5, runs R4b and R4d (sim/charge_wave/reflection_grid.py): one periodic cell of Doug's even grid twice as fine as the "
"quons' lattice, a finer quon under the quon,\nelectric forces only (Ewald sums), masses in proportion to charge. With springs keeping the "
"grid's shape (R4c) the disturbance stays at 10⁻⁷.\nOne periodic cell makes every quon keep its own eight finer quons; in a cell of "
"2 × 2 × 2 quons they fall in unevenly, 7 to 9 to a quon (section 8.5).", fontsize=8, color=MUTED)
plt.tight_layout(rect=(0, 0.10, 1, 1))
plt.savefig("../../papers/figures/fig-reflection-grid.png", dpi=150)
print("wrote papers/figures/fig-reflection-grid.png")