# Kac-rotated fast projection MVP ## Implementation `run_experiment.py` implements the exact streamed update `z[a]=cos(theta)*u+sin(theta)*v`, `z[b]=-sin(theta)*u+cos(theta)*v`, followed by scaled coordinate subsampling. It compares the Kac product with Gaussian and Haar projections for `n=64, m=16`, using fixed seeds. Run: ```bash /home/maxwelhelp/main/bin/python3 run_experiment.py ``` The complete machine-readable output is in `results.json`. ## Mechanism checks 1. **Orthogonality:** every finite product stayed orthogonal, with maximum entrywise defect in `Q.T @ Q-I` of `1.33e-15` across all tested `T`. 2. **Quadratic mean relaxation:** for a fixed unit vector, the measured means at `T=0, 16, 32, 64, 128, 256, 512, 1024` were respectively `0.8388, 0.8845, 0.9031, 0.9571, 0.9636, 1.0001, 0.9934, 0.9987`. They matched the analytic prediction `1 + (initial_scaled_energy - 1)*((n-1)/n)^T` within at most `0.0159` absolute error over the sweep. 3. **Degree-two pseudo-mixing:** the standard deviation of the scaled coordinate energy divided by the Haar reference standard deviation was `0, 0.568, 0.740, 0.847, 0.958, 0.969, 1.002, 1.023` over the same `T` values. Thus the quadratic statistic reached Haar-like spread around `8n` rotations, as predicted qualitatively by the mechanism. ## Secondary comparison At `T=8n`, pair-distance distortion on 64 random normalized vectors was: - Kac: mean `1.0478`, MAE `0.2678`, 95th-percentile absolute error `0.5414` - Gaussian: mean `1.0469`, MAE `0.2749`, 95th-percentile absolute error `0.6406` - Haar: mean `1.0421`, MAE `0.2898`, 95th-percentile absolute error `0.6618` The literal NumPy streamed implementation took `0.0173 s` per batch versus `4.39e-5 s` for dense Gaussian multiplication. This is not a speed win without fused/vectorized kernels. The explicit `(i,j,theta)` representation at `T=8n` uses `8192` bytes in this setup versus `32768` bytes for a full dense orthogonal matrix, a 4x reduction; the runtime arrays additionally store precomputed sine/cosine and use `12288` bytes. ## Conclusion The mathematical mechanism manifested clearly: exact orthogonality, the predicted first-moment relaxation, and convergence of the relevant quadratic statistic toward Haar behavior. The experiment does **not** establish an end-to-end speedup; Python-level sequential updates are much slower than optimized dense BLAS. No CIFAR/MLP accuracy experiment was run.