Algebraic Representability as the Limiting Regime of Grokking: An Exactly Solvable Model with Holomorphic Activations

Chon-Fai Kam, Xavier Cadet, Miloud Bessafi, Frederic CadetarXiv 2026

TL;DR

By analyzing a two-layer neural network with holomorphic monomial activations ($\sigma(z)=z^k$) on modular arithmetic tasks, this paper provides an exactly solvable model that defines the absolute structural limit of grokking. The authors show that when model capacity is restricted to a fixed algebraic subspace, the typical delayed generalization ("grokking") disappears entirely, replaced by a binary split between instant success and outright failure that can be predicted with 99.8% accuracy using a simple Fourier-analytic criterion.

What Problem Does This Paper Address?

"Grokking" is a fascinating phenomenon in machine learning where a network trained on algorithmic data (like modular arithmetic) completely memorizes the training set long before it suddenly figures out how to generalize to unseen test data. Recent literature suggests that this delay is governed by model capacity: too little capacity and the network fails to memorize; too much capacity and it generalizes almost instantly.

However, standard neural networks are universal approximators—given enough width, they can eventually represent any target function, meaning memorization is always theoretically possible. This paper explores the absolute extreme end of the capacity spectrum: What happens when the network's architecture restricts its expressible function class to a small, fixed algebraic variety that does not grow with width? By making representability the binding constraint rather than optimization dynamics, the authors seek to uncover the foundational structural limits underlying grokking.

Methods

The authors construct an elegant, mathematically tractable model to study this regime:

  • Architecture: A two-layer complex-valued neural network using a holomorphic monomial activation function $\sigma(z) = z^k$, where $k$ is a fixed positive integer.
  • Encoding: Inputs are encoded using a "roots-of-unity" scheme ($\omega = e^{2\pi i/p}$), mapping integers to the unit circle in the complex plane. This turns modular addition into complex multiplication, allowing the network's polynomial structure to interact cleanly with the task's arithmetic structure.
  • Mathematical Framework: Using harmonic analysis on the finite abelian group $(\mathbb{Z}_p)^2$, the authors prove that the network's output is strictly confined to a $(k+1)$-dimensional subspace of characters. In the Fourier domain, the network acts as a hard bandpass filter.
  • Ablations: To connect this rigid algebraic model back to standard deep learning, they perform a bottleneck ablation (inserting a narrow linear layer into a standard ReLU network) and an encoding ablation (allowing the roots-of-unity embeddings to be learned dynamically during training).

Datasets

The paper evaluates its theoretical claims on synthetic modular arithmetic tasks over $\mathbb{Z}_{97} \times \mathbb{Z}_{97}$ ($p=97$):

  • Linear-phase targets: 35 tasks of the form $ma + nb \pmod{97}$ (e.g., modular addition).
  • Nonlinear-phase targets: 4 tasks including modular multiplication ($ab$), $a^2+b$, $a+b^2$, and $a^2+b^2$.

A total of 585 experimental runs (spanning 5 activation degrees, 39 tasks, and 3 random seeds) were evaluated. No external real-world benchmarks were used, as the focus is purely structural and algorithmic.

Key Insights and Ideas

  • Width-Independent Expressibility: Crucially, expanding the hidden width ($H$) of this holomorphic network does absolutely nothing to expand its expressible function class. It merely introduces redundancy within the same $(k+1)$-dimensional subspace.
  • The Death of Grokking: Because the network cannot express functions outside its strict algebraic subspace, it cannot even memorize non-representable targets. The typical "memorize first, grok later" regime completely vanishes. The outcome splits cleanly into instant generalization (INST) or outright failure (FAIL).
  • The Rank Barrier: When the input encoding is learned rather than fixed, the representability condition broadens into a matrix rank constraint: $\text{rank}(\omega^f) \le k+1$. This explains why nonlinear tasks like modular multiplication ($ab$) are completely unrepresentable under any encoding—they possess full rank ($p$), which easily overpowers the network's maximum rank of $k+1$.
  • The Three-Regime Spectrum: Through their bottleneck ReLU experiments, the authors bridge the gap between their algebraic extreme and universal approximators, mapping out a continuous transition: $$\text{Representational Failure (FAIL)} \longrightarrow \text{Memorization without Generalization (MEM)} \longrightarrow \text{Grokking (GROK)}$$

Key Results

  • 99.8% Prediction Accuracy: The algebraic representability criteria derived by the authors predicted the exact training outcome for 584 out of 585 runs. The single discrepancy was a transient optimization issue that resolved with longer training.
Table 1: Confusion matrix over all 585 runs. The single off-diagonal entry is an optimisation artefact discussed in the text.
  • The Staircase Condition: For linear tasks with fixed encodings, a task is perfectly representable if and only if $m+n=k$. This creates a beautiful "staircase" pattern of success across different activation degrees, while all nonlinear tasks fail completely.
Figure 1: Phase diagram for the holomorphic monomial network across activation degrees k (rows) and the 39 tasks (columns; linear tasks left of the dashed line ordered by m + n, nonlinear tasks to the right). Blue cells reach INST; red cells FAIL. The INST cells form the staircase m + n = k predicted by Theorem 1; all nonlinear tasks fail at every degree, as predicted by Theorem 2. The circled cell (k = 6, a + 5b) is the single optimisation exception, which resolves to INST under longer training.
  • Strict Loss Lower Bounds: The authors proved a positive lower bound on training loss for non-representable tasks. For nonlinear tasks, more than 99.9% of their spectral energy lies outside the network's pass-band, pinning the training accuracy flatly at chance level (~1%) regardless of how wide the network is.

Limitations and Future Work

  • Architectural Specificity: The exact closed-form solutions rely heavily on a two-layer architecture with a specific monomial activation ($\sigma(z)=z^k$). Extending this rigorous algebraic characterization to deeper networks or more generic activations (like ReLU) remains an open challenge.
  • Dependence on Group Symmetry: The Fourier approach exploits the clean abelian group structure of $(\mathbb{Z}_p)^2$. It is currently unclear how this bandpass-filter analogy translates to non-abelian groups or tasks lacking clear algebraic symmetries.
  • Dynamics of Learned Encodings: While the encoding ablation successfully proves what can be represented with learned embeddings, a full dynamical account of how gradient descent actually navigates the optimization landscape to discover these embedding phases is left for future work.

Summary updated

BibTeX
@misc{kam2026algebraic,
  author = {Chon-Fai Kam and Xavier Cadet and Miloud Bessafi and Frederic Cadet},
  title = {{Algebraic Representability as the Limiting Regime of Grokking: An Exactly Solvable Model with Holomorphic Activations}},
  year = {2026},
  eprint = {2607.13749},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2607.13749},
}
Figure