Supplementary Code for "Exclusion of Non-Trivial Cycles and Emergence of Contractive Windows in Collatz Dynamics" Author: Moon Kyung-Up Date: October 2025 Overview This repository contains the supplementary Python scripts referenced in the paper "Exclusion of Non-Trivial Cycles and Emergence of Contractive Windows in Collatz Dynamics." These scripts are provided to allow for the full replication of all key constants and numerical results presented in the paper, particularly those in Appendices B and D. Files * crt_penalty.py: Builds the admissible residue graph modulo M_d = 3 \cdot 2^d to verify the stabilization of the CRT penalty ratio. This script reproduces the data in Table B.1, confirming the ratio stabilizes at 15/16 for d \ge 4. * rho_star_scan.py: Numerically explores the "Bridge Lemma" by comparing the required number of v_2 cancellations for a given odd-step density \rho against the available O(\log L) budget. This script reproduces the odd-density ceiling of \rho^\star \approx 0.627. * trajectory_sim.py: Simulates the accelerated Collatz map for a given starting number N. It generates the trajectory's state, including \Delta_k and \epsilon_k, reproducing the tables in Appendix D for numbers like N=7 and N=27. Getting Started Requirements * Python 3.9 or higher * numpy * matplotlib (optional, for plotting) * sympy (optional, for symbolic checks) Installation You can install the required packages using pip: pip install numpy matplotlib sympy Usage Examples 1. Verify CRT Penalty Stabilization Run the script to generate the CRT penalty ratio table. Command: python crt_penalty.py Expected Output (excerpt): d=2, ratio=1.0000 d=3, ratio=0.8750 d=4, ratio=0.9375 d=5, ratio=0.9375 ... Stabilized penalty: 1/48 2. Scan for the Odd-Density Ceiling (\rho^\star) Run the script to see where the required cancellations exceed the budget. Command: python rho_star_scan.py Expected Output (excerpt): rho=0.60 → feasible rho=0.62 → feasible rho=0.63 → infeasible (budget exceeded) rho*=0.627 ± 0.001 3. Simulate a Trajectory Run the script with a starting number and optionally the number of steps. Command: python trajectory_sim.py 27 --steps 50 Expected Output (excerpt): k T^k(27) Delta_k epsilon_k 0 27 0 0 1 41 2 0.5 2 62 2 0.25 ... Citation If you use these scripts or the methods described in the paper, please cite the primary work: > Moon Kyung-Up, Exclusion of Non-Trivial Cycles and Emergence of Contractive Windows in Collatz Dynamics, October 2025. > License This software is released under the MIT License. You are free to use, modify, and share it with attribution.