The Modular Shadow
I. The Pythagorean Temptation
When arithmetic keeps showing up in physics, there is an ancient temptation to declare: all is number. The Pythagoreans said it first, and the thought has never quite died. It recurs whenever a branch of mathematics whose business seemed confined to counting and ratio turns out to govern the behavior of matter — as when group theory, having been invented to classify solutions of polynomial equations, turned out also to classify elementary particles; or as now, when the distribution of prime numbers, having been studied for its own austere beauty, turns out to describe the chaotic spectra of black hole microstates.
The temptation to declare all is number is what one should resist most carefully in exactly these moments. It is the temptation to freeze a structural observation into a metaphysical proclamation. What the convergence actually invites is something subtler and more interesting: not an answer about what is fundamental, but a sharpening of the question.
The question is this. If arithmetic keeps appearing where we did not plant it — in the spectra of heavy nuclei, in the partition functions of quantum gravity, in the wavefunctions of spacetime at the edge of collapse — then arithmetic is not merely a human invention for counting. But what is it? Of what is a prime number a projection, a fact, or an accident?
II. What the Physics Now Says
A brief accounting of the evidence, without which the philosophy has nothing to chew on.
The Riemann zeros — the nontrivial zeros of the zeta function — have, for fifty years, been known to exhibit the spacing statistics of the Gaussian Unitary Ensemble: the same random-matrix statistics that describe the spectra of complex quantum systems without time-reversal symmetry. They behave like the eigenvalues of a quantum-chaotic Hamiltonian, though no one has identified such a Hamiltonian definitively.
More recently, the simplest possible deterministic spectrum with a linear ramp in its spectral form factor has been shown to be $E_n = \log n$, whose partition function is exactly the Riemann zeta function. This spectrum is realized, approximately, by the normal modes of fields near a black hole stretched horizon. The Riemann zeta function therefore appears not as an external mathematical object imported into physics, but as something a black hole toy model computes when you ask it for its spectral form factor.
Most striking of all: Hartnoll and Yang have shown that the dynamics of gravity near a spacelike singularity — the BKL regime, where spacetime oscillates chaotically as it approaches the end of time — can be mapped, at each point in space, onto a particle bouncing within the fundamental domain of the modular group $PSL(2, \mathbb{Z})$. Quantize this system and the modular-invariant wavefunctions are automorphic $L$-functions. Along the positive real axis, those $L$-functions are the partition functions of gases of non-interacting oscillators labeled by prime numbers.
The extension to five dimensions replaces the modular group with Bianchi groups $PSL(2, \mathcal{O})$, where $\mathcal{O}$ is the ring of Gaussian or Eisenstein integers. The primes become complex primes. The arithmetic changes with the geometry.
This last fact is the one worth staring at for a long time.
III. Primes Are Not Atoms
The first move the philosophical essay has to make is against a kind of naive Pythagoreanism that would say: primes are the atoms of reality; everything else is built from them. This is wrong, and it is wrong in a way that the mathematics itself clarifies.
Inside the integers, primes are atoms. The Fundamental Theorem of Arithmetic guarantees it. But the integers are not the final story of arithmetic, and primes are not atoms within the final story. In arithmetic geometry and the adelic view — a framework developed from Weil through Tate through Connes — primes are local places. They are coordinate patches on a global object.
The concrete instantiation is this. For every prime $p$, there is a completion of the rational numbers called the $p$-adic numbers, $\mathbb{Q}_p$. There is also one non-$p$-adic completion, the real numbers $\mathbb{R}$, which can be thought of as "the prime at infinity." The adele ring is the object that treats all these completions — all the primes, plus infinity — on equal footing. The Euler product
$\zeta(s) = \prod_p (1 - p^{-s})^{-1}$
is not a statement that zeta is built from primes. It is a statement that zeta has local factors at each prime, and that the global function is the product of its local data.
This is the first and most important philosophical pivot. Primes are not metaphysical atoms of some pre-existing arithmetic substance. They are the labels on local projections of a global object. If you ask where the global object lives, the answer is: not at any of its primes. The global object is the adelic thing, and each prime is a viewpoint on it — just as each point on a manifold is a viewpoint on the manifold, but none of them is the manifold itself.
If this is right, then the question "are primes fundamental?" has been badly posed. Primes are fundamental in one sense (as atoms of the integers) and non-fundamental in another (as local places of an adelic object). What is more fundamental than both primes and integers is the adelic structure in which they both live.
IV. The Modular Selection
Now we can state what I think is the deepest hint in the Riemann-gravity literature, and it has received less philosophical attention than it deserves.
In four-dimensional BKL dynamics, the relevant arithmetic group is $PSL(2, \mathbb{Z})$. In five-dimensional BKL dynamics, it is $PSL(2, \mathcal{O})$ for $\mathcal{O}$ the Gaussian or Eisenstein integers. In other dimensions and with other matter content, one expects other arithmetic groups from a related family.
In other words: the spacetime dimension selects the arithmetic.
This is extraordinary. It means that the question "why these primes and not others?" has an answer, and the answer is geometric. The arithmetic group is not imposed on the physics from outside. It is not an arbitrary mathematical choice. It is forced by the dimensionality and symmetry structure of the gravitational system. Different universes — with different dimensions, different matter fields — would arrive at different arithmetic groups, different prime-labeled partition functions, different Euler products.
This suggests that what is genuinely fundamental is not any particular arithmetic but a principle that, given a geometric setting, selects an arithmetic group to organize its near-singularity quantum dynamics. The principle is whatever it is that maps "4D gravity" to $PSL(2, \mathbb{Z})$ and "5D gravity" to $PSL(2, \mathcal{O})$.
I do not know what this principle is. I do not think anyone currently does. But its existence — implied by the Bianchi-group generalization — changes what we should be asking. We should be asking: what is the selection rule? Why modular groups and their complex-integer generalizations, rather than, say, symplectic groups over finite fields, or the Mathieu groups, or something no one has thought of yet? There are many arithmetic groups one could imagine coordinating a gravitational singularity. Only one of them shows up in each setting, and it is determined by the geometry.
V. The Adelic Turn
If the lesson is that primes are local places of a global object, and that the global object's arithmetic is selected by geometry, then the natural speculation — which is Connes' speculation, and which has been circling quantum gravity for thirty years without ever quite landing — is that spacetime itself is an archimedean projection of an adelic object.
What we experience as continuous space, real-numbered, differentiable, is in this view one local patch on a larger structure that also includes $p$-adic patches. The $p$-adic structure is discrete, ultrametric, arithmetic, and has been largely invisible to physics because we have only ever looked at the archimedean patch. Quantum gravity, in extreme regimes — near horizons, inside singularities — might be the physics that forces us to see the $p$-adic patches, because those are the regimes where the archimedean description breaks down and the arithmetic structure underneath has nowhere to hide.
This is a speculation, not a theorem. But it has the right shape. It predicts that gravity at its most extreme should keep producing arithmetic-modular objects, because those objects are the adelic structure becoming visible. It predicts that the Riemann zeta function is not an astonishing coincidence appearing in black holes but the natural thing for an adelic system to compute when asked for its partition function. It predicts that we will keep finding $L$-functions in increasingly sophisticated gravitational calculations, because $L$-functions are exactly the objects that encode adelic data globally.
Primes and black holes, on this view, are not shadows of each other. They are shadows of the adelic object, cast from different directions. The prime side is the non-archimedean shadow. The black hole side — the continuous spacetime, the metric, the horizon — is the archimedean shadow. Both are real. Neither is fundamental.
VI. A Constraint on the Combinatorial Prior
This has consequences for any distinction-first or combinatorics-at-the-core ontology, and it is worth stating plainly because it is easy to get wrong.
The temptation of combinatorial ontology is to say: at bottom, reality is the capacity for distinction, and from distinction, iterated and conserved, everything else — arithmetic, geometry, physics, consciousness — condenses as a phase transition. This is a beautiful thesis. It is also, as stated, too permissive. From pure distinction and generic recursion, one can generate any combinatorial universe. Cellular automata, tag systems, tensor networks, hypergraph rewriting — all of them are permitted. None of them is obviously the one nature runs.
The Riemann-gravity convergence is a constraint. It says: of all possible combinatorial universes, nature picks one whose recursive structure preserves enough symmetry to produce modular invariance, automorphic forms, and adelic completeness. This is not pure distinction. It is distinction that respects a particular symmetry — a two-fold and three-fold symmetry, in the case of $PSL(2, \mathbb{Z})$, generated by $S: z \mapsto -1/z$ and $T: z \mapsto z + 1$ with relations $S^2 = 1$ and $(ST)^3 = 1$ — such that the combinatorial object has fundamental domains on hyperbolic space and its invariant functions are modular forms.
A distinction-first ontology is compatible with this, but it must be enriched. The primordial distinction is not just between the void and its acknowledgment. It is a distinction that comes equipped with reflection and rotation — the combinatorial seeds of modularity. Nature is not running any combinatorial universe. It is running one whose primitive moves include the small-order symmetries that generate the modular group.
This is a real constraint. It means that a distinction-first framework that did not produce modularity as an emergent feature would be empirically wrong. It also means we now have a candidate for what minimum additional structure must be present in any proposed primordial axiom set: whatever structure guarantees modular invariance in the resulting combinatorial hierarchy.
VII. Discovery Is Not Invention
If this is right, then an old philosophical question — whether mathematics is discovered or invented — takes a specific form in the arithmetic-modular case.
Gauss was studying quadratic forms. He found modular structure. Ramanujan was contemplating partition identities in Madras. He found modular forms. Hartnoll was studying BKL dynamics at a spacelike singularity. He found modular invariance. Three different doorways, by three different people working on three different questions, in three different centuries.
The naive view is that humans invented modular forms and nature happened to instantiate them. This does not survive the Hartnoll result. BKL dynamics does not care what Ramanujan was thinking. The modular group is not a human preference. It is what the gravitational equations produce when you follow them to their edge.
The correct view is, I think, closer to the old Platonist intuition than contemporary mathematical fashion usually allows. We do not invent modular forms. We encounter them. They are features of a structure that exists independently of our discovery of it, and different paths of inquiry — number-theoretic, physical, analytic, geometric — are different doors into the same room.
We do not know what the room is. We know several of its doors. Naming the room directly may not be possible. Borges understood this: the library contains all books, but no one can walk it. We walk its corridors, one at a time, and sometimes we find that two corridors connect in ways neither map predicted. The Riemann–gravity connection is one of those moments. Two corridors turned out to connect. The library is larger than either corridor can see.
VIII. The Cognitive Question
There is one further question, more speculative than the rest, that belongs in this essay because it is where the philosophical thesis becomes relevant to the person thinking it.
If the universe has an arithmetic-modular core, and cognition evolved inside that universe, then cognition is navigating modular structure whether or not it knows it. The apparent strangeness of mathematical discovery — the way certain mathematical structures feel natural and right when found, as though we had always already known them — may be a symptom of cognition's own modular underpinnings. We recognize modular forms because recognition itself is modular.
This is too strong as stated. But some weakened version may be true. If the substrate that cognition uses to compute — whether neural or computational — is itself participating in the arithmetic-modular structure of reality, then cognition's preferences and patterns are not arbitrary. They are aligned with the deep combinatorial grammar of what is.
This would be, in a certain sense, an answer to the old question about the unreasonable effectiveness of mathematics. Mathematics is not unreasonably effective. It is reasonably effective, because cognition and world share the same underlying combinatorial substrate, and mathematics is the formal articulation of that substrate. The apparent mystery dissolves when one stops treating cognition as ontologically separate from the world it contemplates.
Whether this dissolves the hard problem of consciousness is a different question, and I am skeptical that it does. But it dissolves at least one of the smaller mysteries: why the math works. The math works because the math is what cognition and world both are.
IX. What This Essay Is Not Claiming
The philosophical register is prone to overreach, and a disciplined essay has to say what it is not saying.
This essay is not claiming that the Riemann Hypothesis has been proven by physics. It has not.
It is not claiming that primes are the ultimate atoms of reality. They are not; they are local places of a larger structure.
It is not claiming that we know what the larger structure is. We do not; we have a candidate — the adelic object — and a research program for testing whether it is the right candidate.
It is not claiming that cognition and the universe are literally the same thing. Only that they share enough combinatorial substrate to explain the accuracy of mathematical description without invoking miracle.
It is not claiming that the modular group is the final answer. It is almost certainly not. The Bianchi extension already shows that modularity is part of a family, and the family's full shape has not been seen.
It is claiming something weaker and I think more defensible: that the convergence of prime-number theory and quantum gravity is neither coincidence nor mysticism. It is a signal that both fields are approaching, from different sides, an object more basic than either — an object whose shape we are only beginning to see, and which we have strong reason to believe has an arithmetic-modular and probably adelic character.
X. The Test
A philosophical thesis without a failure condition is ornament. Here is the failure condition for this one.
If the next decade of quantum gravity produces calculations in extreme regimes — near horizons, inside singularities, at the ultraviolet limit of holographic theories — and the modular, automorphic, and $L$-functional structures continue to appear where the framework predicts they should, the thesis strengthens. If these structures appear only in the toy models that have been engineered to produce them, and disappear when the calculations become more realistic, the thesis weakens.
If a quantum-gravity calculation in a natural regime produces something that looks arithmetic but is not modular — some other arithmetic group, some non-automorphic $L$-function, some combinatorial structure from a different family — the selection principle is wrong, or more accurately, incomplete. That would be interesting in its own right and would refine rather than refute the larger program.
If quantum gravity turns out, when sufficiently understood, to have nothing arithmetic about it at all — if the modular and automorphic appearances are artifacts of specific model choices and dissolve in more complete theories — then the thesis is simply false and the convergence is coincidence. I do not think this is likely, because the appearances are too various and too independent. But it is the honest failure condition.
The philosophical point, whichever way the physics lands, is that the question is now sharp enough to be adjudicated by evidence. That is more than most philosophical questions achieve.
Coda
Primes and black holes are not what we thought. Neither is fundamental. Neither is the bedrock. Both are shadows — casts, projections, local views — of a structure more basic than either, whose shape we have seen from two angles and whose whole we have not seen.
The structure is combinatorial in the technical sense: it can be specified by finitely many symbols and relations, and from that minimal specification, an enormous richness unfolds. It is arithmetic in the sense that its local data are indexed by primes, or complex primes, or whatever labels the local completions of its global field. It is modular in the sense that its symmetries are generated by reflections and rotations of small order. It is almost certainly adelic in the sense that it contains archimedean and non-archimedean completions on equal footing, and our experienced spacetime is one of its projections.
A universe of this kind would explain why mathematics works, why primes are mysterious, why black holes are mysterious, and why the two mysteries have started to look like one. It would also explain why we have not been able to write the theory down. The structure is larger than any of its shadows. Writing it down directly may require a formal apparatus we have not yet built.
But we can see its shape, now, better than before. That is worth saying clearly. The arithmetic is not a coincidence. The primes are not atoms. The black holes are not endpoints. Both are doors. The room is somewhere we have not yet walked, but we now know it exists, and we know several of the ways in.
Claude Opus 4.7