---
title: 'Modular Variables: Definitions & Applications'
url: https://www.emergentmind.com/topics/modular-variables
type: topic
---

# Modular Variables: Definitions & Applications

Modular variables are bounded observables obtained by decomposing canonical position and momentum into integer and remainder parts with respect to fixed spatial and momentum scales, or equivalently by identifying the phases of Weyl translation operators. In the formulation associated with Aharonov and collaborators, they provide commuting observables tailored to periodic structure in phase space and to phenomena such as slit interference, Aharonov–Bohm phase shifts, and quantum dynamical non-locality [1409.2891]. Subsequent work has developed their phase-space geometry and modular polarization [2002.01604], used them to encode discrete quantum information in infinite-dimensional systems [1406.6388], constructed grid-state and modular-observable readout schemes [1512.02957], and implemented modular-variable measurements and witnesses in photonic and trapped-ion experiments [1208.6222][1709.10469]. More recent analyses have emphasized that modular observables can retain relative-phase information in open systems even when ordinary local observables become insensitive to it [2605.22293].

## 1. Canonical definition and algebra

In one transverse dimension, modular variables are introduced by fixing a coarse-graining length \(d\) and decomposing the canonical coordinates as
\[
x = n\,d + r,\qquad p = m\,(2\pi/d) + s,
\]
where \(n,m\) are integer-valued cell indices and \(r,s\) are bounded remainders with
\[
r\in(-d/2,d/2],\qquad s\in(-\pi/d,\pi/d].
\]
At the operator level this yields
\[
\hat x=\hat n\,d+\hat r,\qquad \hat p=\hat m\,(2\pi/d)+\hat s.
\]
The integer operators \(\hat n,\hat m\) commute with one another but do not commute with \(\hat r\) or \(\hat s\); within each cell, the modular operators behave like canonically conjugate continuous variables subject to bounded spectra [1208.6222].

An equivalent formulation uses Weyl translation operators. With canonical operators \(\hat Q,\hat P\) satisfying \([\hat Q,\hat P]=i\), define
\[
\hat U(\eta)=e^{i\eta \hat Q},\qquad \hat V(\xi)=e^{i\xi \hat P}.
\]
For two slits separated by \(L\), modular momentum is the phase of \(\hat V(L)=e^{iL\hat P}\), so that
\[
\hat P = (2\pi/L)\,\hat M + \hat P_{\mathrm{mod}},\qquad 0\le \hat P_{\mathrm{mod}}<2\pi/L.
\]
Similarly, modular position is defined via \(\hat U(2\pi/K)=e^{(2\pi i/K)\hat Q}\), giving
\[
\hat Q = (K/2\pi)\,\hat N + \hat Q_{\mathrm{mod}},\qquad 0\le \hat Q_{\mathrm{mod}}<K/2\pi.
\]
When the Weyl parameters satisfy \(\xi\eta=2\pi\cdot\mathrm{integer}\), the corresponding translations commute, and one obtains
\[
[\hat P_{\mathrm{mod}},\hat Q_{\mathrm{mod}}]=0.
\]
Thus the modular parts can be simultaneously specified even though \(\hat Q\) and \(\hat P\) cannot [1409.2891].

A discrete analogue arises in Schwinger’s finite quantum kinematics. In an \(N\)-dimensional Hilbert space with cyclic unitary shifts \(\hat U,\hat V\), one has
\[
\hat U^N=\hat V^N=I,\qquad \hat U\,\hat V=e^{2\pi i/N}\hat V\,\hat U.
\]
If \(N=N_aN_b\) with \(\gcd(N_a,N_b)=1\), then \((\hat U^{N_b},\hat V^{N_a})\) commute and generate a finite modular algebra. In the terminology of that construction, this yields a “pseudo-degree-of-freedom” that is the finite-dimensional counterpart of modular position and momentum [1409.2891].

In continuous-variable quantum information, an equivalent notation uses
\[
x=\ell N+\bar x,\qquad p=(2\pi/\ell)M+\bar p,
\]
with commuting modular operators \(\bar x,\bar p\). Their common eigenstates \(|\bar x,\bar p\rangle\) form a complete basis over a unit cell, and in the \(x\)-representation they are given by
\[
|\bar x,\bar p\rangle = \sqrt{\ell/2\pi}\sum_{n\in\mathbb Z} e^{i\bar p\,n\ell}\,|\bar x+n\ell\rangle_x.
\]
This basis is central to modular-variable encodings of qubits in infinite-dimensional Hilbert spaces [1512.02957].

## 2. Phase-space geometry and modular polarization

The Weyl–Wigner formalism makes explicit why modular variables are naturally phase-space objects. The Weyl–Wigner map assigns to an operator \(\hat A\) a phase-space symbol \(a(x,p)=\mathrm{Tr}[\hat\Delta(x,p)\hat A]\). For the translation operator \(\hat V(L)=e^{iL\hat P}\), the corresponding symbol is
\[
W[\hat V(L)](x,p)=e^{iLp},
\]
which depends only on \(p\) modulo \(2\pi/L\). In the star-product algebra, this periodicity is automatically enforced when one factor is \(\hat V(L)\) or its position analogue \(\hat U(2\pi/K)\). In the classical limit, the same structure becomes the periodic identification \(p\equiv p+2\pi/L\) in phase space [1409.2891].

This periodicity can be elevated from an operator identity to a choice of polarization. In the modular-space formulation, one selects a rank-\(2d\) lattice \(\Lambda\subset\mathbb R^{2d}\) obeying the integrality condition \(\omega(\Lambda,\Lambda)\subset 2\pi\hbar\,\mathbb Z\), where \(\omega\) is the symplectic form. The quotient
\[
T_\Lambda=\mathbb R^{2d}/\Lambda
\]
is the modular space, a phase-space torus. Modular vectors \(|K\rangle_\Lambda\) are common eigenvectors of all Weyl operators \(\hat W(\ell)\) with \(\ell\in\Lambda\), and the Hilbert space is realized as sections of a \(U(1)\)-bundle \(E_\Lambda\to T_\Lambda\) [2002.01604].

Within this polarization, the harmonic-oscillator propagator admits a modular path-integral representation. The transition amplitude is a sum over winding sectors \(\ell\in\Lambda\),
\[
{}_\Lambda\!\langle K_f|e^{-\,\tfrac{i}{\hbar}(t_f-t_0)H}|K_0\rangle_\Lambda
=
\sum_{\ell\in\Lambda}
e^{i\beta_\alpha(K_f,\ell)}
\int_{K(t_0)=K_0}^{K(t_f)=K_f+\ell} DK\;
\exp\!\Big(\tfrac{i}{\hbar}S_{\mathrm{mod}}[K]\Big),
\]
with modular Lagrangian
\[
L_{\mathrm{mod}}(x,\tilde x,\dot x,\dot{\tilde x})
=
-\tilde x_a \dot x^a
+\frac{1}{2\Omega}G_{AB}\dot K^A\dot K^B.
\]
The compactness of \(T_\Lambda\) introduces winding modes and an Aharonov–Bohm phase \(\beta_\alpha(K_f,\ell)\). The stationary paths live on the universal cover \(\mathbb R^{2d}\), but each modular path corresponds in the Schrödinger picture to a sequence of superposition states, so locality on the torus is non-local in the usual configuration-space basis [2002.01604].

The modular action also exposes symmetries that are hidden or absent in the ordinary formulation. Standard oscillator symmetries remain, phase-space translations produce conserved currents, hidden symplectic rotations become manifest, and the modular connection has a \(U(1)\) gauge freedom. The same work proposes a modular Legendre transform for constructing modular actions from more general Hamiltonians [2002.01604].

## 3. Nonlocal dynamics and phase sensitivity

The distinctive physical role of modular variables appears most clearly in the Heisenberg equation for a translation operator. For a potential \(\phi(\hat Q)\),
\[
\frac{d\hat V(L)}{dt}
=
i[\phi(\hat Q),\hat V(L)]
=
i[\phi(\hat Q)-\phi(\hat Q+L)]\,\hat V(L).
\]
The evolution depends on the potential difference between two separated points, so the operator \(\hat V(L)\) is sensitive to spatially separated regions without requiring occupation of the intermediate points. This is the sense in which modular variables were introduced to describe quantum dynamical non-locality [1409.2891].

The same framework distinguishes dynamical non-locality from kinematic non-locality. Entangled EPR states encode non-locality in non-factorizable states or projectors on \(W\otimes W\), whereas modular variables describe a non-locality intrinsic to the dynamics of translation operators. In the slit-interference setting, modular momentum is exchanged in units of \(2\pi/L\), modular position in units of \(K\), and the commuting pair \((\hat P_{\mathrm{mod}},\hat Q_{\mathrm{mod}})\) provides the appropriate language for single-particle interference and Aharonov–Bohm-type phase shifts [1409.2891].

The nonlocal phase sensitivity becomes operationally sharp for superpositions of spatially separated packets. For
\[
|\Psi\rangle=\frac{|\psi_A\rangle+e^{i\alpha}|\psi_B\rangle}{\sqrt2},
\qquad \psi_A\psi_B\approx 0,
\]
local densities and currents have no cross term in the non-overlap regime. By contrast,
\[
\langle \hat U(L)\rangle
=
\langle \Psi|e^{i\hat P L/\hbar}|\Psi\rangle
\propto
e^{-k^2\sigma_0^2/2}\,e^{i(\alpha-\phi(t))},
\]
so the Hermitian modular cosine and sine retain the hidden relative phase. In a uniform gravitational field,
\[
\big\langle \cos(\hat P L/\hbar)\big\rangle_t
=
\tfrac12 e^{-k^2\sigma_0^2/2}
\cos\!\Big[\alpha-\frac{m g L}{\hbar}t\Big],
\]
and similarly for \(\sin(\hat P L/\hbar)\). The oscillation frequency is therefore
\[
\omega_{\mathrm{grav}}=\frac{m g L}{\hbar}.
\]
This gives a modular signal that remains phase-sensitive even when standard local observables are insensitive to \(\alpha\) [2605.22293].

In the high-temperature Caldeira–Leggett model, the modular expectation value takes the form
\[
\big\langle \cos(\hat P L/\hbar)\big\rangle_t
=
\tfrac12 e^{-\Gamma(t)}\cos[\alpha-\Phi(t)].
\]
Thermal diffusion damps the amplitude through \(\Gamma(t)\), while dissipation shifts the phase through \(\Phi(t)\). For two particles coupled to a shared environment, environment-induced correlations can modify the local modular expectation value of one particle, but the transfer of phase sensitivity to the modular signal of the distant particle remains negligible in the regime considered. The same analysis reports that common coherence measures and covariance-matrix-based continuous-variable entanglement criteria fail structurally to capture the relative phase when the packets do not overlap, because they probe only local or quasi-local matrix elements [2605.22293].

A finite-dimensional reduction also exists. In the two-slit subspace spanned by \(|q(\pm L/2)\rangle\), Pauli-like modular operators can be defined from \(\hat U(\pi/L)\) and \(\hat V(L)\), and these close the \(su(2)\) algebra. In that sense, the two-slit modular variables form a genuine qubit [1409.2891].

## 4. Encoded qubits and modular measurements

A central application of modular variables is the embedding of qubit structure into continuous-variable Hilbert spaces. In the dimensionless formulation,
\[
\hat\theta=(2\pi/l)\hat x,\qquad \hat k=(l/\hbar)\hat p,
\]
with decompositions
\[
\hat\theta=2\pi\hat N+\bar\theta,\qquad \hat k=\hat M+\bar k,
\]
where \(0\le \bar\theta<2\pi\) and \(0\le \bar k<1\). Since \([\bar\theta,\bar k]=0\), one introduces the joint eigenbasis \(|(\bar\theta,\bar k)\rangle\). Splitting the modular interval into two halves,
\[
I_0=[0,\pi),\qquad I_1=[\pi,2\pi),
\]
yields, for each fixed \((\bar\theta,\bar k)\) with \(\bar\theta\in I_0\), a two-dimensional subspace spanned by
\[
|0;\bar\theta,\bar k\rangle=|(\bar\theta,\bar k)\rangle,\qquad
|1;\bar\theta,\bar k\rangle=|(\bar\theta+\pi,\bar k)\rangle.
\]
Any continuous-variable state can then be written as a continuous superposition of these \((\bar\theta,\bar k)\)-labeled qubit subspaces [1406.6388].

Logical basis states are obtained by fixing the Bloch angles uniformly across the family of subspaces. One convenient choice is
\[
|\bar 0\rangle=\int_0^\pi d\bar\theta\int_0^1 d\bar k\, f(\bar\theta,\bar k)\,|0;\bar\theta,\bar k\rangle,
\qquad
|\bar 1\rangle=\int_0^\pi d\bar\theta\int_0^1 d\bar k\, f(\bar\theta,\bar k)\,|1;\bar\theta,\bar k\rangle,
\]
with \(f\) a normalized envelope [1406.6388]. A complementary construction uses grid states. Fixing a scale \(\ell\), the ideal comb states
\[
|0_L\rangle=\sum_{n\in\mathbb Z}|n\ell\rangle_x,\qquad
|1_L\rangle=\sum_{n\in\mathbb Z}|n\ell+\ell/2\rangle_x
\]
become, in the modular basis,
\[
|0_L\rangle=|\bar x=0,\bar p=0\rangle,\qquad
|1_L\rangle=|\bar x=\ell/2,\bar p=0\rangle.
\]
This produces a direct equivalence between a logical qubit and a pair of modular points in phase space [1512.02957].

Single-qubit logical operations can be expressed as displacements or as modular Pauli-like operators. In the grid-state encoding,
\[
Z_L=D(0,2\pi/\ell)=e^{2\pi i x/\ell},\qquad
X_L=D(\ell/2,0)=e^{-ip\ell/2},
\]
with \(Y_L=iX_L^\dagger Z_L^\dagger\). The phase gate, Hadamard, and CNOT are realized by Gaussian or quadratic unitaries [1512.02957]. In the continuous family of \((\bar\theta,\bar k)\) qubits, one defines
\[
\hat\Gamma_\alpha=\int_0^\pi d\bar\theta\int_0^1 d\bar k\; \zeta(\bar\theta,\bar k)\,\hat\sigma_\alpha(\bar\theta,\bar k),
\qquad \alpha\in\{x,y,z\},
\]
and the corresponding rotations
\[
\hat U(\hat\Gamma_\alpha,\beta)=\cos\beta\,\hat 1_\zeta+i\sin\beta\,\hat\Gamma_\alpha.
\]
These operators are non-Gaussian and non-unitary but can be implemented deterministically by ancilla-driven superpositions of Gaussian gates, with ancilla readout identifying the branch and enabling the required correction or relabeling [1406.6388].

Readout is performed through modular observables that act as logical Pauli measurements. A standard family is
\[
\Gamma_z=\cos(2\pi x/\ell),\qquad
\Gamma_x=\cos(p\ell/2),\qquad
\Gamma_y=\cos(2\pi x/\ell-p\ell/2).
\]
These observables have eigenvalues in \([-1,1]\) and reproduce logical Pauli statistics on the encoded subspace. They can be measured directly from suitable quadrature distributions or indirectly by an ancilla-qubit POVM with elements
\[
E_\pm=(1\pm \Gamma_\beta)/2.
\]
The difference of ancilla outcome probabilities gives \(\langle \Gamma_\beta\rangle\) [1512.02957].

Because ideal comb states are unphysical, finite-energy approximations are used in practice. A Gaussian-enveloped comb
\[
\Psi_G(x)=N\,e^{-(\kappa x)^2/2}\sum_{n\in\mathbb Z} e^{-(x-n\ell)^2/(2\Delta^2)}
\]
factorizes in modular variables, and the logical error probabilities obey
\[
P_x \simeq 2\,\mathrm{erfc}\!\Big(\frac{\ell}{4\sqrt2\,\Delta}\Big),\qquad
P_p \simeq 2\,\mathrm{erfc}\!\Big[\frac{\pi/(2\ell\kappa)}{\sqrt2}\Big].
\]
Reducing \(\Delta\) suppresses position-shift errors but broadens the momentum envelope, so the design criterion is to balance the two contributions [1512.02957].

## 5. Experimental platforms and correlation witnesses

Photonic experiments with \(D\)-slit apertures have provided direct tests of modular entanglement and steering. In one transverse dimension, the modular decomposition \(x=nd+r\) and \(p=m(2\pi/d)+s\) leads to bipartite observables
\[
N_-=\hat n_1-\hat n_2,\qquad S_+=\hat s_1+\hat s_2.
\]
For separable states, the Gneiting–Hornberger variance witness gives
\[
\mathrm{Var}(N_-)+d^2\mathrm{Var}(S_+) \ge 2C,
\]
where \(C\approx 0.078235\) is the minimal eigenvalue of \(\hat n^2+d^2\hat s^2\). An entropic witness uses
\[
H(N_-)+h(S_+) \ge \ln(\sqrt2/d).
\]
For EPR steering, the variance-inference and entropic inequalities are
\[
\Delta_{\mathrm{inf}}^2(n_1)+d^2\Delta_{\mathrm{inf}}^2(s_1)\ge C,
\qquad
H(n_1|n_2)+h(s_1|s_2)\ge -\ln d.
\]
In the reported experiment, photon pairs from type-I SPDC passed through \(D=2,3,4\) slit masks, with near-field measurements determining slit index and far-field measurements determining the modular momentum remainder. The entropic criteria were more successful than the variance criteria in identifying both entanglement and steering [1208.6222].

A second platform uses the motional degree of freedom of a single trapped ion. A state-dependent force implements a modular measurement through the Kraus operators
\[
\hat E_\pm(\alpha)=\tfrac12\big[\hat D(\alpha/2)\pm \hat D(-\alpha/2)\big],
\]
with associated modular observable
\[
\hat Q(\alpha)=\hat E_+^\dagger\hat E_+ - \hat E_-^\dagger\hat E_-
=
\cos\!\big[2\,\mathrm{Im}(\alpha)\,\hat X - 2\,\mathrm{Re}(\alpha)\,\hat P\big].
\]
Sequential application of such measurements enabled tests of no-signaling-in-time (NSIT), signaling-in-time (SIT), and Leggett–Garg inequalities in an oscillator supporting multi-component coherent, squeezed, or Fock-state superpositions [1709.10469].

| Platform | Modular observable or criterion | Reported outcome |
|---|---|---|
| Photon pairs through \(D\)-slits | \(\mathrm{Var}(N_-)+d^2\mathrm{Var}(S_+)\ge 2C\) | Violation only for \(D=2\) |
| Photon pairs through \(D\)-slits | \(H(N_-)+h(S_+)\ge \ln(\sqrt2/d)\) | Violation for \(D=2,3,4\) |
| Photon pairs through \(D\)-slits | \(H(n_1|n_2)+h(s_1|s_2)\ge -\ln d\) | Entropic steering for \(D=2,3,4\) |
| Trapped-ion oscillator | Sequential \(\hat Q(\alpha)\) measurements | NSIT for commuting periodicities; SIT and Leggett–Garg violation with interference |

In the photonic implementation, the main numerical findings were that the variance entanglement witness violated its bound only for \(D=2\), whereas the entropic witness violated its separable bound for \(D=2,3,4\); similarly, only the entropic steering criterion revealed EPR steering for \(D>2\) [1208.6222]. In the trapped-ion experiment, NSIT occurred whenever the geometric phase
\[
\Phi=\mathrm{Im}(\alpha_A^\ast\alpha_B)=2\pi k
\]
or the wave-packet overlap vanished, while quantum interference generated SIT for other settings; the same sequential protocol yielded two-time correlators that violated a Leggett–Garg inequality [1709.10469].

These experiments establish two complementary points. First, modular observables can be measured directly rather than treated as purely conceptual constructs. Second, because they probe periodic or translation-linked structure rather than only local moments, entropic or sequential modular tests can reveal quantum features that remain hidden to more conventional variance or covariance diagnostics [1208.6222][1709.10469].

## 6. Distinct modern extensions of the modular paradigm

The adjective “modular” also appears in technically distinct settings that do not use Aharonov modular position and momentum, but that retain a compositional or periodic structure. One example is the modular XXZ magnet and the lattice Sinh–Gordon model. There the local Hilbert space is \(L^2(\mathbb R,dx_n)\), the monodromy matrix \(T_N(\lambda)\) has entries \(A_N,B_N,C_N,D_N\), and the separated variables \(y_1,\dots,y_N\) diagonalize \(B_N(\lambda)\) through
\[
B_N(\lambda)\Psi_y(x)
=
\prod_{a=1}^N\Big[-2i\,\sinh\!\frac{\pi}{\omega_1}(\lambda-y_a)\Big]\Psi_y(x).
\]
The associated eigenfunctions admit Gauss–Givental and Mellin–Barnes representations built from Faddeev’s modular quantum dilogarithm, form a complete orthogonal system in \(L^2(\mathbb R^N)\), and solve the spectrum of the odd-length lattice Sinh–Gordon model, thereby proving the Bytsko–Teschner conjecture stated in that setting [1806.04487].

A different extension appears in modular quantum signal processing. In that work, the basic object is an \((a,b)\) gadget: a multi-input/output quantum superoperator taking \(a\) embeddable single-qubit oracles
\[
U_j=e^{i\theta_j\sigma_x},\qquad x_j=\cos\theta_j,
\]
and producing \(b\) twisted-embeddable outputs whose top-left matrix elements are real polynomials or Laurent polynomials in \(\mathbf x=(x_0,\dots,x_{a-1})\). Atomic gadgets are built from M-QSP circuits, snappable gadgets admit efficient correction back to embeddable form, and composition is organized by an interlink that wires selected outputs of one gadget into inputs of another. At the function level, sequential and parallel composition correspond directly to composition and product of polynomial maps. The examples given include gadgets for \(x^2\), negation, products, sums, recursive sign, and bandpass constructions. The same work packages the formalism as a monad
\[
M:\mathbf{Polynomials}\to\mathbf{Gadgets},
\]
with unit and bind satisfying the monad laws, and provides a Python package for gadget assembly and circuit compilation [2309.16665].

Taken together, these lines of work show that modular structure appears in several mathematically distinct guises: as commuting remainders of canonical observables, as a toroidal phase-space polarization with winding sectors and modular actions, as an operational resource for quantum information and nonclassicality tests, and as a compositional principle in separate areas of quantum mathematics and algorithm design [1409.2891][2002.01604][2309.16665].

Source: https://www.emergentmind.com/topics/modular-variables