# Nonresonant Quasi-Periodic Output Averaging

- ID: 1259
- Canonical URL: https://synthcore.org/idea/1259/nonresonant-quasi-periodic-output-averaging
- API JSON: https://synthcore.org/api/idea/1259.json
- API Markdown: https://synthcore.org/api/idea/1259.md
- Verification status: unverified
- Source: [arXiv:2607.21950](https://arxiv.org/abs/2607.21950)
- Category: dynamics
- Solves: accuracy, stability
- ML areas: ssm, rnn, inference-speedup, training-dynamics
- Math tags: dynamical-systems, harmonic-analysis, approximation-theory, statistics
- Ratings: usefulness 6/10; difficulty 5/10; novelty 7/10

## Idea description

Add a deterministic torus phase to a recurrent or state-space model and average predictions over a quasi-periodic phase orbit using a frequency-aware normalized window instead of a uniform average. The window is chosen to attenuate Fourier modes near the orbit frequencies, transferring the paper's cancellation mechanism to reduce coherent long-horizon oscillation and bias without requiring a highly smooth predictor.

## Mathematical statement

Let the d-dimensional torus be denoted by T^d, let alpha in R^d satisfy the nonresonance condition that the inner product of every nonzero integer vector k with alpha is not an integer, and let the phase orbit be z_n = z_0 + n alpha modulo one. For an observable f with Fourier expansion f(z) = sum over k of f_k exp(2 pi i inner product(k,z)) and absolutely summable Fourier coefficients, use normalized weights w_{n,N} satisfying sum over n from zero to N minus one of w_{n,N} equals one. The weighted average is A_N(z_0) = sum over n of w_{n,N} f(z_0 + n alpha). The zero Fourier mode is the torus mean f_0. Each nonzero mode has residual multiplier H_N(k) = sum over n of w_{n,N} exp(2 pi i n inner product(k,alpha)). The paper's theorem states that, for every sigma in (0,1), weights and low-regularity observables can be constructed so that the uniform error is bounded by C exp(-c N^sigma), where C and c are positive constants. In the neural adaptation, f is the model output as a function of an injected phase, while H_N(k) is a directly measurable frequency-response diagnostic.

## Key formulas

- $$z_n=z_0+n\alpha\pmod 1,\qquad A_N(z_0)=\sum_{n=0}^{N-1}w_{n,N}f(z_n),\qquad \sum_{n=0}^{N-1}w_{n,N}=1.$$
- $$f(z)=\sum_{k\in\mathbb{Z}^d}f_k e^{2\pi i\langle k,z\rangle},\qquad A_N(z_0)-f_0=\sum_{k\neq 0}f_k e^{2\pi i\langle k,z_0\rangle}H_N(k),$$
- $$H_N(k)=\sum_{n=0}^{N-1}w_{n,N}e^{2\pi i n\langle k,\alpha\rangle},\qquad \sup_{z_0}\left\|A_N(z_0)-f_0\right\|\leq\sum_{k\neq0}\left\|f_k\right\|\left|H_N(k)\right|,$$
- $$\sup_{z_0}\left\|A_N(z_0)-f_0\right\|\leq C e^{-cN^\sigma}\quad\Longrightarrow\quad \log E_N\lesssim -cN^\sigma.$$

## Implementation notes

Integrate the mechanism at the output of a recurrent model, S4-style state-space model, or neural ODE used for long-horizon prediction. Add a fixed phase state z in [0,1)^d, update z <- (z + alpha) modulo one at every forecast step, and concatenate sine and cosine features of each phase coordinate to the model input. Maintain the last N outputs or run N phase-shifted evaluations, then return their weighted average. Start with d=1 or d=2 and choose alpha from fractional parts of irrational numbers such as square root of 2 and square root of 3. Construct weights offline by solving the convex quadratic program that minimizes the sum over k in a calibration set K of the squared magnitude of H_N(k), subject to the weights summing to one; add a small smoothness penalty and initially constrain the weights to be nonnegative. Estimate K from an FFT of calibration residuals, while H_N(k) is computed exactly from the selected weights and alpha. The first cheap experiment should use a synthetic torus signal with slowly decaying Fourier coefficients, comparing uniform, Hann, and optimized windows over 1,000 initial phases. Repeat with a small GRU forecasting a sinusoid plus colored noise at horizons 32, 64, 128, and 256. The prediction is that optimized-window error follows log E_N approximately equal to negative c N raised to sigma, whereas uniform averaging is algebraic. Fit both models and require the stretched-exponential model to predict held-out horizons within 20 percent. Also require the optimized response magnitude for calibration modes to be at least ten times smaller than the uniform-window response.

## Disclaimer

AI-generated research hypothesis, automatically tested. Not peer-reviewed.
