Skip to content
QFT.org

Search QFT.org

Enter a word or phrase.

    You can also browse the main navigation and chapter contents.

    Invariant and Equivariant Maps on a Lattice

    If an input vector is rotated, should a model's answer stay fixed or rotate with it? An energy should stay fixed. A force should rotate. Confusing these requirements can remove information that the next layer needs or impose the wrong physical constraint.

    First project a nonlinear map onto the eight rotations and reflections of a square. Then use that transformation law to construct and fit a periodic lattice predictor. Its local Ising-energy predictions move between sites, while their sum stays invariant. Compare the physical prediction error with the defect in the symmetry identity. The fit uses ridge regression and the finite Ising ensemble.

    Specify the action on each space

    Let a group GG act linearly on input and output spaces through representations ρin\rho_{\rm in} and ρout\rho_{\rm out}. Thus each representation obeys

    ρ(g)ρ(h)=ρ(gh),ρ(e)=I.(1)\rho(g)\rho(h)=\rho(gh), \qquad \rho(e)=I. \tag{1}

    A map FF is equivariant when

    F ⁣(ρin(g)x)=ρout(g)F(x)for every g∈G and every x.(2)F\!\left(\rho_{\rm in}(g)x\right) =\rho_{\rm out}(g)F(x) \quad\text{for every }g\in G\text{ and every }x. \tag{2}

    It is invariant if the output representation is trivial: ρout(g)=I\rho_{\rm out}(g)=I. Inputs and outputs need not have the same dimension or representation. This intertwining formulation is the starting point of group-equivariant networks. Cohen and Welling 2016, §2, Eq. (1).

    For a scalar function of a vector, invariance reads E(gx)=E(x)E(gx)=E(x). If gg is orthogonal and EE differentiable, the chain rule gives

    gT∇E(gx)=∇E(x),−∇E(gx)=g[−∇E(x)].(3)g^{\mathsf T}\nabla E(gx)=\nabla E(x), \qquad -\nabla E(gx)=g[-\nabla E(x)]. \tag{3}

    The corresponding force is equivariant. The converse requires care: an arbitrary equivariant vector field need not be the gradient of an energy. Symmetry does not replace an integrability or conservation condition.

    For the square group D4D_4, choose exact integer matrices

    R=(0−110),S=(100−1),D4={Rk,RkS:k=0,1,2,3}.(4)R=\begin{pmatrix}0&-1\\1&0\end{pmatrix}, \qquad S=\begin{pmatrix}1&0\\0&-1\end{pmatrix}, \qquad D_4=\{R^k,R^kS:k=0,1,2,3\}. \tag{4}

    They satisfy R4=S2=IR^4=S^2=I and SRS=R−1SRS=R^{-1}. The order matters: a reflection followed by a rotation is generally different from the reverse order. The companion checks all 6464 products and all inverses with integer matrices. No floating-point angle reconstruction is needed.

    Pullbacks explain the inverse

    A feature can itself be a function on positions. If a spatial point moves as x↦gxx\mapsto gx, define the transformed scalar field by

    [Tgf](x)=f(g−1x).(5)[T_g f](x)=f(g^{-1}x). \tag{5}

    The value originally at yy appears at x=gyx=gy. With this inverse,

    [TgThf](x)=f(h−1g−1x)=f((gh)−1x)=[Tghf](x).(6)[T_gT_h f](x)=f(h^{-1}g^{-1}x) =f((gh)^{-1}x) =[T_{gh}f](x). \tag{6}

    Using f(gx)f(gx) instead would reverse the composition order. The error can remain hidden if tests use only commuting translations or a single reflection. Cohen and Welling, §4.4, Eqs. (4)–(5).

    A vector-valued spatial field has both a coordinate pullback and a component transformation,

    [Tgv](x)=g v(g−1x).(7)[T_g v](x)=g\,v(g^{-1}x). \tag{7}

    A rank-two tensor instead transforms as Q(x)↦gQ(g−1x)gTQ(x)\mapsto gQ(g^{-1}x)g^{\mathsf T}. Merely storing two or four channels does not determine which transformation law those channels carry. It must be specified.

    Constructing an equivariant map by averaging

    For a finite group and any map FF with a linear output space, define its Reynolds projection

    (RF)(x)=1∣G∣∑g∈Gρout(g)−1F ⁣(ρin(g)x).(8)(\mathcal RF)(x) =\frac1{|G|}\sum_{g\in G} \rho_{\rm out}(g)^{-1} F\!\left(\rho_{\rm in}(g)x\right). \tag{8}

    The output is transformed back before averaging. To prove equivariance, set k=ghk=gh:

    (RF)(ρin(h)x)=1∣G∣∑gρout(g)−1F(ρin(gh)x)=ρout(h)1∣G∣∑kρout(k)−1F(ρin(k)x)=ρout(h)(RF)(x).(9)\begin{aligned} (\mathcal RF)(\rho_{\rm in}(h)x) &=\frac1{|G|}\sum_g \rho_{\rm out}(g)^{-1} F(\rho_{\rm in}(gh)x)\\ &=\rho_{\rm out}(h)\frac1{|G|} \sum_k\rho_{\rm out}(k)^{-1}F(\rho_{\rm in}(k)x)\\ &=\rho_{\rm out}(h)(\mathcal RF)(x). \end{aligned} \tag{9}

    The proof works for nonlinear FF. If FF was already equivariant, every summand in (8) equals F(x)F(x), so RF=F\mathcal RF=F. Therefore R2=R\mathcal R^2=\mathcal R: averaging is a projection onto the equivariant maps. With a trivial output representation it becomes ordinary invariant group averaging.

    Take the vector representation on both sides and

    F0(x,y)=(x3+2yy3−x).(10)F_0(x,y)= \begin{pmatrix}x^3+2y\\y^3-x\end{pmatrix}. \tag{10}

    The cubic vector (x3,y3)(x^3,y^3) already transforms correctly under sign changes and coordinate permutations. The linear part has matrix A=(02−10)A=\bigl(\begin{smallmatrix}0&2\\-1&0\end{smallmatrix}\bigr). Averaging its conjugates g−1Agg^{-1}Ag removes it: reflection averaging removes the off-diagonal part, while a square-equivariant linear map must be a scalar multiple of II. Here tr⁡A=0\operatorname{tr}A=0. Thus

    (RF0)(x,y)=(x3y3).(11)(\mathcal RF_0)(x,y)= \begin{pmatrix}x^3\\y^3\end{pmatrix}. \tag{11}

    A symbolic sum of all eight terms verifies (11) independently of the numerical equivariance test. Fixed generic-point tests give a relative equivariance defect below 6.5×10−176.5\times10^{-17} in binary64 arithmetic. Such a test checks the implementation; the algebra establishes the identity.

    Because the output representation is orthogonal, its squared norm gives an invariant readout:

    I(x,y)=∥(RF0)(x,y)∥2=x6+y6.(12)I(x,y)=\|(\mathcal RF_0)(x,y)\|^2=x^6+y^6. \tag{12}

    It is invariant under D4D_4, not under every planar rotation. At (1,0)(1,0) it equals 11; after a 45∘45^\circ rotation it equals 1/41/4. Nor is it a complete label of square-group orbits. An invariant readout can identify physically distinct inputs.

    Nonlinearities depend on the representation

    Componentwise nonlinearities commute with permutations of channels. They do not commute with arbitrary matrices mixing or changing the signs of components.

    A simple failure uses the vector representation and ReLU⁡(z)=max⁡(z,0)\operatorname{ReLU}(z)=\max(z,0). With x=(1,−1)x=(1,-1) and g=−Ig=-I,

    ReLU⁡(gx)=(0,1),g ReLU⁡(x)=(−1,0).(13)\operatorname{ReLU}(gx)=(0,1), \qquad g\,\operatorname{ReLU}(x)=(-1,0). \tag{13}

    The difference has norm 2\sqrt2. A layer that is linear-equivariant before this activation need not remain equivariant afterward.

    There is a useful alternative: let channels be indexed by group elements. For a fixed vector aa, scalar bias bb, and arbitrary scalar nonlinearity ν\nu, define

    hg(x)=ν(aTg−1x+b).(14)h_g(x)=\nu(a^{\mathsf T}g^{-1}x+b). \tag{14}

    Under x↦kxx\mapsto kx,

    hg(kx)=hk−1g(x).(15)h_g(kx)=h_{k^{-1}g}(x). \tag{15}

    This is a permutation of the orientation channels—the regular representation. Applying another identical pointwise scalar nonlinearity to every channel commutes with the permutation. Summing the channels gives an invariant readout. Keeping them instead retains orientation information for subsequent equivariant processing. Cohen and Welling, §6.2, Eq. (15).

    A bias shared by all orientation channels also respects this action. Different biases for different orientations generally do not. Similar reasoning applies to normalization: its estimated statistics and trainable parameters must obey the declared channel action. The word “convolutional” does not make an arbitrary sequence of operations equivariant.

    For orthogonal vector representations one can instead use a radial nonlinearity, v↦α(∥v∥2)vv\mapsto \alpha(\|v\|^2)v. Its scalar coefficient is invariant, so the output remains a vector. This is a different construction from applying the same function independently to vector components.

    Averaging, augmentation and restricted architectures

    Three procedures often appear together but solve different computational problems.

    ProcedureWhat is changedWhat follows
    Average a fitted map using (8)The prediction ruleExact finite-group equivariance
    Add transformed training examplesThe empirical lossMore constraints on the fitted map
    Restrict the architectureThe admissible functionsEquivariance for every parameter value, if all layers respect the action

    Finite data augmentation alone cannot establish (2) on every input. For example, consider

    Faug(x)=x+(∥x∥2−1)(x120).(16)F_{\rm aug}(x) =x+(\|x\|^2-1) \begin{pmatrix}x_1^2\\0\end{pmatrix}. \tag{16}

    On the entire D4D_4 orbit of (1,0)(1,0), its predictions equal the identity map exactly. Yet

    Faug(−2,−1)+Faug(2,1)=(32,0),(17)F_{\rm aug}(-2,-1)+F_{\rm aug}(2,1)=(32,0), \tag{17}

    whereas equivariance under −I-I requires zero. Thus interpolation on the sampled orbit can violate equivariance elsewhere.

    There are special cases where augmentation does yield an exactly invariant optimum. The Ising local-energy fit below uses a linear readout, a complete group-augmented squared-error loss, an orthogonal parameter action and a strictly positive ridge penalty. Uniqueness forces the optimum into the invariant parameter subspace, so a tied fit and the fully augmented fit agree. The hypotheses explain the equality; it is not a general equivalence between augmentation and equivariant neural networks.

    Projecting a fitted map also need not agree with fitting within the projected class. Projection changes the function after optimization, whereas a restricted fit optimizes the loss over that class from the beginning. Both can preserve symmetry while having different prediction errors.

    What the implementation establishes

    The companion finite_group_maps.py defines the integer group, its multiplication table and inverse, vector Reynolds projection, and pullbacks on a periodic square. group_map_checks.py verifies the polynomial result symbolically, then tests generic real points and selected exact points. The tests include idempotence, invariant readout and noncommuting composition.

    The retained negative controls distinguish actual mistakes from roundoff:

    ControlDefect
    Correct orientation permutation00 in the retained tests
    Replace k−1gk^{-1}g by kgkg1.9811.981
    Vector ReLU under −I-I2\sqrt2
    Projected cubic under 45∘45^\circ0.50.5 in vector norm
    Augmented-orbit interpolant away from its orbit3232 in vector norm

    Defects have different explicitly stated tests and normalizations; their magnitudes are not prediction-error rankings. In particular, testing a transformation outside D4D_4 is a limitation check, not a bug in a map designed for D4D_4.

    A symmetry of an architecture also does not establish that the data-generating dynamics possess that symmetry. External fields, boundaries, anisotropic couplings and channel definitions can change the relevant group. The physical action and observable must be identified before choosing the constraint.

    Periodicity defines the representation

    Apply the square transformations to a field on sites as well as to its channels. Positions are x=(x1,x2)∈ΛL=ZL2x=(x_1,x_2)\in\Lambda_L=\mathbb Z_L^2. The point group is D4D_4, represented by the square's integer rotation and reflection matrices. A point operation gg followed by a translation aa acts as x↦a+gxx\mapsto a+gx. For a scalar field,

    [Ta,gs](x)=s ⁣(g−1(x−a)),(18)[T_{a,g}s](x)=s\!\left(g^{-1}(x-a)\right), \tag{18}

    with coordinates reduced modulo LL. The composition law is

    (a,g)(b,h)=(a+gb,gh),Ta,gTb,h=Ta+gb,gh.(19)(a,g)(b,h)=(a+gb,gh), \qquad T_{a,g}T_{b,h}=T_{a+gb,gh}. \tag{19}

    This is a semidirect product: a rotation changes the direction of a translation. The inverse in (18) is essential. Our implementation uses coordinates rather than an image library's implicit choice of rotation center.

    For a finite-offset kernel k(δ)k(\delta), define a periodic correlation layer

    (Cks)(x)=∑δk(δ)s(x+δ).(20)(C_k s)(x)=\sum_\delta k(\delta)s(x+\delta). \tag{20}

    This is the correlation convention commonly called convolution in neural-network implementations. Its offsets have the displayed plus sign. Translation equivariance follows directly:

    Ck(Ta,Is)(x)=∑δk(δ)s(x+δ−a)=(Ta,ICks)(x).(21)C_k(T_{a,I}s)(x) =\sum_\delta k(\delta)s(x+\delta-a) =(T_{a,I}C_k s)(x). \tag{21}

    No padding approximation enters because the domain is a torus. The same derivation does not establish full translation equivariance for a finite array with zero padding. Correlation versus convolution and the corresponding group action are derived in Cohen and Welling 2016, §§4.4–5, Eqs. (4)–(9).

    Rotations act on channels as well as positions

    An arbitrary kernel generally breaks point-group covariance if its output is treated as a single scalar channel. One solution is to require k(gδ)=k(δ)k(g\delta)=k(\delta). Another preserves the differently oriented responses in separate channels.

    For each base filter kak_a, introduce one channel for every h∈D4h\in D_4,

    za,h[s](x)=∑δka(h−1δ)s(x+δ).(22)z_{a,h}[s](x) =\sum_\delta k_a(h^{-1}\delta)s(x+\delta). \tag{22}

    The label aa identifies a base filter; it is not a translation in this equation. Inserting (18) and changing summation variable to ϵ=g−1δ\epsilon=g^{-1}\delta gives

    za,h[Tb,gs](x)=za,g−1h[s] ⁣(g−1(x−b)).(23)z_{a,h}[T_{b,g}s](x) =z_{a,g^{-1}h}[s]\!\left(g^{-1}(x-b)\right). \tag{23}

    The spatial argument is pulled back and the orientation index is permuted. Rotating the pixels while leaving orientation channels fixed is an implementation error.

    A common scalar pointwise function ν\nu preserves (23). We use

    ha,h[s](x)=tanh⁡2za,h[s](x).(24)h_{a,h}[s](x)=\tanh^2 z_{a,h}[s](x). \tag{24}

    The square additionally gives h[−s]=h[s]h[-s]=h[s], appropriate for the spin-flip-even energy. It is an explicit global Z2\mathbb Z_2 constraint, distinct from the spatial group. Orientation channels carry a permutation representation, which is why a common pointwise nonlinearity is permitted. The general group-correlation construction is discussed in Cohen and Welling, §§6.1–6.2, Eqs. (10)–(15).

    For deeper models, a layer acting on these features must transform both the spatial and orientation indices. For example, on a finite group a correlation Φ(f)(q)=∑r∈Gf(r)ψ(q−1r)\Phi(f)(q)=\sum_{r\in G}f(r)\psi(q^{-1}r) obeys Φ(Tgf)(q)=Φ(f)(g−1q)\Phi(T_gf)(q)=\Phi(f)(g^{-1}q) after the substitution r=gur=gu. A stack of such layers and compatible nonlinearities remains equivariant. Arbitrarily mixing orientation channels between them need not.

    A physical local target

    Use the periodic Ising Hamiltonian of the collective-variable example, with J=1J=1. A site-centered local energy is

    ex(s)=−12sx∑δ=±e^1,±e^2sx+δ,∑xex(s)=H(s).(25)e_x(s)=-\frac12s_x \sum_{\delta=\pm\hat e_1,\pm\hat e_2}s_{x+\delta}, \qquad \sum_xe_x(s)=H(s). \tag{25}

    The factor 1/21/2 corrects the two appearances of each undirected bond in the site sum. This local energy obeys

    e[Ta,gs]=Ta,ge[s],e[−s]=e[s].(26)e[T_{a,g}s]=T_{a,g}e[s], \qquad e[-s]=e[s]. \tag{26}

    It is a scalar field of predictions: its values move between sites. Only the sum or spatial mean is invariant. It is not a continuous scalar-field force.

    The exact target is cheap to evaluate, making this a controlled learning example rather than a proposal to replace a useful formula by an expensive approximation. We can independently distinguish approximation error from failure of a transformation law.

    Training uses the first 512512 retained 4×44\times4 configurations at T=2.3T=2.3, and all sixteen sites in each. Tests use 10241024 independent configurations at each of five temperatures on both L=4L=4 and L=3L=3. The Gibbs samples come from exact categorical sampling, without Markov-chain correlations. No test configurations are used to select filters, a penalty or training duration.

    What is actually fitted

    Draw four 3×33\times3 filters once from independent standard normal entries and normalize each to Euclidean norm one. Their seeds are fixed in the companion. Every filter has all eight orientations, producing 3232 features (24) per site. The filters are fixed, while the readout is genuinely fitted:

    e^x(s)=β0+∑a=14∑h∈D4βa,hha,h[s](x).(27)\widehat e_x(s)=\beta_0+\sum_{a=1}^4\sum_{h\in D_4} \beta_{a,h}h_{a,h}[s](x). \tag{27}

    The nonlinear-feature ridge model has 3333 trainable coefficients. It has translation equivariance for every coefficient vector, because the same readout acts at every site. Point-group covariance requires additional structure.

    Let XX contain one row of features, including the intercept feature 11, per training site, and let yy contain the corresponding exact local energy. With n=512×16n=512\times16 and λ=10−4\lambda=10^{-4}, minimize

    L(β)=1n∥Xβ−y∥2+λ∥β∥2.(28)\mathcal L(\beta) =\frac1n\|X\beta-y\|^2+\lambda\|\beta\|^2. \tag{28}

    The stated penalty includes the intercept. All examples use the same convention. We solve the stacked least-squares system

    (X/nλI)β≃(y/n0)(29)\begin{pmatrix}X/\sqrt n\\ \sqrt\lambda I\end{pmatrix}\beta \simeq \begin{pmatrix}y/\sqrt n\\0\end{pmatrix} \tag{29}

    by singular-value decomposition. This avoids explicitly forming an inverse of XTXX^{\mathsf T}X. The largest retained half-gradient residual, ∥XT(Xβ−y)/n+λβ∥∞\|X^{\mathsf T}(X\beta-y)/n+\lambda\beta\|_\infty, is 1.5×10−131.5\times10^{-13} across the three fits. That checks the specified finite optimization problem, not the adequacy of the feature family.

    We fit three versions:

    1. Untied: all 3333 coefficients are free on the original training configurations.
    2. Augmented: use the same coefficients and penalty on all eight point-group transforms of each training configuration, transforming the target field too. Normalize the squared-error sum by 8n8n.
    3. Tied: replace the eight orientation coefficients for each base filter by one coefficient and fit directly on the original data.

    The normalization of the tied model matters. Define

    Ha[s](x)=18∑h∈D4ha,h[s](x),βa,h=ca8.(30)H_a[s](x)=\frac1{\sqrt8}\sum_{h\in D_4}h_{a,h}[s](x), \qquad \beta_{a,h}=\frac{c_a}{\sqrt8}. \tag{30}

    The prediction becomes β0+∑acaHa\beta_0+\sum_a c_aH_a, with five fitted coefficients. The embedding is isometric:

    β02+∑a,hβa,h2=β02+∑aca2.(31)\beta_0^2+\sum_{a,h}\beta_{a,h}^2 =\beta_0^2+\sum_a c_a^2. \tag{31}

    Using the raw channel sum while leaving the penalty unchanged would define a different optimization problem.

    When augmentation and tying agree

    Complete augmentation makes the loss invariant under permutation of the orientation coefficients. The ridge term is also invariant because this permutation is orthogonal. Since λ>0\lambda>0, the objective is strictly convex and has a unique minimizer β⋆\beta_\star.

    For every group element, a transformed coefficient vector has the same loss as β⋆\beta_\star and must therefore equal it. Hence β⋆\beta_\star has constant coefficients within each orientation orbit. It lies in the tied subspace. On that subspace, transformed training examples give exactly the same losses as their originals. Equations (30)–(31) then show that the augmented and tied minimizers coincide.

    The actual numerical coefficient difference is 1.44×10−131.44\times10^{-13}. The augmented and tied objective values both round to 0.125665010.12566501. The untied fit minimizes a different, unaugmented objective and obtains 0.124717910.12471791 on that problem.

    This equality uses complete augmentation, compatible targets and feature actions, the same loss normalization, an invariant penalty and uniqueness. It does not imply that finite augmentation and constrained architectures are interchangeable for an arbitrary nonlinear network or a partially converged optimizer.

    For comparison, we also project the already fitted untied model by averaging each set of eight coefficients. This is a Reynolds projection of its prediction rule and requires no new fit. It preserves the point-group law exactly, but its coefficient vector differs from the tied optimum by 0.004200.00420 in Euclidean norm. Averaging after fitting and fitting within the averaged class are different operations.

    Prediction error and symmetry error answer different questions

    At L=4,T=2.3L=4,T=2.3, the independent test results are:

    Prediction ruleLocal-energy RMSEEnergy-density RMSE
    Untied0.3237±0.00910.3237\pm0.00910.1213±0.00530.1213\pm0.0053
    Tied0.3231±0.00910.3231\pm0.00910.1211±0.00530.1211\pm0.0053
    Fully augmented0.3231±0.00910.3231\pm0.00910.1211±0.00530.1211\pm0.0053
    Projected untied0.3230±0.00910.3230\pm0.00910.1212±0.00530.1212\pm0.0053

    These differences do not establish a statistically resolved accuracy advantage. The same test configurations feed all models, so their errors are paired; their displayed standard errors must not be treated as independent when comparing models.

    For the local RMSE, define the squared error of independent configuration α\alpha by

    rα=1N∑x[e^x(s(α))−ex(s(α))]2,R^=rˉ.(32)r_\alpha=\frac1N\sum_x [\widehat e_x(s^{(\alpha)})-e_x(s^{(\alpha)})]^2, \qquad \widehat R=\sqrt{\bar r}. \tag{32}

    The companion records the sample standard error of rˉ\bar r, and uses SE⁡(R^)≃SE⁡(rˉ)/(2rˉ)\operatorname{SE}(\widehat R)\simeq\operatorname{SE}(\bar r)/(2\sqrt{\bar r}). It never counts the correlated sites as NN independent configurations. For energy-density error, it first averages the signed local residual within a configuration, then squares that mean. These errors condition on the one frozen training set and fitted map; they do not include retraining variability.

    Separately, for the first sixteen T=2.3T=2.3 test configurations at each size, we apply every translation and every point-group element. Define

    ϵG=max⁡a,g∥F(Ta,gs)−Ta,gF(s)∥∞max⁡(1,∥Ta,gF(s)∥∞),(33)\epsilon_G= \max_{a,g} \frac{\|F(T_{a,g}s)-T_{a,g}F(s)\|_\infty} {\max(1,\|T_{a,g}F(s)\|_\infty)}, \tag{33}

    where the norms include the retained test configurations. The results are:

    SizeUntiedTiedAugmentedProjected untied
    L=3L=30.14920.14923.3×10−163.3\times10^{-16}1.8×10−131.8\times10^{-13}3.3×10−163.3\times10^{-16}
    L=4L=40.12920.12924.9×10−164.9\times10^{-16}1.4×10−131.4\times10^{-13}5.8×10−165.8\times10^{-16}

    This evaluates the actual fitted outputs, not only the already symmetric target. The small tied-model defects reflect a structural identity. The tied model still has a local RMSE of approximately 0.320.32.

    The figure places these two diagnostics side by side.

    The tied model's local prediction error grows with temperature while its symmetry defect stays near roundoff; an untied readout has a much larger point-group defect.

    Left: independent-test local-energy RMSE of the tied model at both sizes, with configuration-based delta-method standard errors. The model was fitted only at L=4,T=2.3L=4,T=2.3. Right: maximum relative equivariance defects under all translations and square point operations on sixteen test configurations per size. Small transformation defects and small physical prediction errors are different requirements.

    Size, boundaries and stride are separate tests

    The same local filters and coefficients act on L=3L=3 without refitting. This is actual size transfer of the local rule, unlike the separate PCA fits on different-dimensional spin vectors. At T=2.3T=2.3, its L=3L=3 local RMSE is 0.3133±0.01520.3133\pm0.0152, while its energy-density RMSE is 0.17300.1730. At T=3.2T=3.2, the local RMSE rises to 0.58270.5827 on L=3L=3 and 0.59600.5960 on L=4L=4. Exact equivariance does not protect against a change in the statistical importance of local patterns.

    Boundary conditions change the representation. A zero-padded feature extractor tested against the periodic translation law gives a relative defect 0.9030.903 on fixed generic real fields. This is a large domain mismatch, not a roundoff problem. The periodic predictor evaluated against an open-boundary Ising target at T=2.3T=2.3 has edge-site RMSE 0.69440.6944, compared with interior RMSE 0.33070.3307. The open target omits boundary-crossing bonds; the physical question has changed.

    Stride also reduces the translation group. For L=4L=4, retaining only sites (2i,2j)(2i,2j) commutes with translations by two fine sites, which become one coarse-site translation. A one-site shift changes the sampling sublattice and cannot generally be represented by a coarse-grid translation. This subgroup issue is distinct from point-group channel indexing. Cohen and Welling, §6.3.

    The companion checks orientation channels on sixteen generic real-valued fields as well as on Ising spins. Correct channel transport differs by at most 5.6×10−165.6\times10^{-16}. Replacing g−1hg^{-1}h by ghgh produces a defect 0.9800.980. Even-stride translation is exact in the retained test, while the odd shift differs from every coarse-grid translation by at least 1.151.15 in the stated relative maximum norm. These controls make errors in the action visible rather than testing only specially symmetric configurations.

    Reproduction and scope

    The fixed exact Ising archive is shared with the collective-variable calculation. The pure lattice_local_model.py implements oriented filters and the stacked ridge fit; lattice_local_checks.py writes all models, coefficients, independent-test errors and transformation controls to lattice-local-results.json. The plotter reads those retained results. The chapter companion README records the seeds and commands.

    This calculation learns a local observable using a small fixed nonlinear feature family. Its purpose is to make approximation, optimization, statistical testing and exact transformation laws separately calculable.

    Summary

    A Reynolds projection gives an equivariant prediction rule once the input and output actions are specified. On the periodic Ising lattice the correctly transported orientation channels enforce exact square symmetry. A unique ridge optimum explains why the fully augmented and symmetry-tied fits coincide here. Their local-energy RMSE is still 0.32310.3231 at the training temperature and size. A gauge field adds a new requirement: the link output must transform at both endpoints.

    Exercises

    1. Projection and a symmetry outside the group

    Prove R2=R\mathcal R^2=\mathcal R from (8), compute RF0\mathcal RF_0, and test its equivariance under a 45∘45^\circ rotation at (1,0)(1,0). Does failure of the last test contradict the projection theorem?

    Solution

    Equation (9) shows that RF\mathcal RF is equivariant. Applying (8) to any equivariant GG gives ρout(g)−1G(ρin(g)x)=G(x)\rho_{\rm out}(g)^{-1}G(\rho_{\rm in}(g)x)=G(x) term by term, so RG=G\mathcal RG=G. Setting G=RFG=\mathcal RF proves idempotence.

    The vector (x3,y3)(x^3,y^3) commutes with the coordinate permutations and sign changes in D4D_4. For the linear part, conjugating by SS reverses the off-diagonal entries, so its pairwise reflection average is zero. Therefore RF0=(x3,y3)\mathcal RF_0=(x^3,y^3).

    Let UU be the 45∘45^\circ rotation. Then

    (RF0)(U(1,0))=122(1,1),U(RF0)(1,0)=12(1,1).(34)(\mathcal RF_0)(U(1,0)) =\frac1{2\sqrt2}(1,1), \qquad U(\mathcal RF_0)(1,0)=\frac1{\sqrt2}(1,1). \tag{34}

    Their difference has norm 1/21/2. Since U∉D4U\notin D_4, this does not contradict the theorem. Averaging over a finite subgroup imposes that subgroup, not the full continuous rotation group.

    2. Why channel labels matter

    Evaluate the failure of componentwise ReLU under −I-I. Then let PP be a permutation matrix and prove ν(Pz)=Pν(z)\nu(Pz)=P\nu(z) for any common scalar pointwise function ν\nu. Explain why fitting an augmented finite orbit still does not prove a global equivariance identity.

    Solution

    For z=(1,−1)z=(1,-1), ReLU gives (1,0)(1,0). Transforming afterward gives (−1,0)(-1,0), while transforming first and applying ReLU gives (0,1)(0,1). Thus the vector-representation identity fails.

    If (Pz)i=zπ(i)(Pz)_i=z_{\pi(i)}, then

    [ν(Pz)]i=ν(zπ(i))=[Pν(z)]i.(35)[\nu(Pz)]_i=\nu(z_{\pi(i)}) =[P\nu(z)]_i. \tag{35}

    No linearity or oddness of ν\nu is needed. The proof uses only a permutation action and the same function in every channel. It does not apply to arbitrary component mixing or sign changes.

    Finally, (16) agrees with the identity on all augmented points of the unit-vector orbit, because the extra term vanishes there. Equation (17) shows that it violates equivariance elsewhere. Training constraints on a finite set leave many functions undetermined away from that set; a structural proof needs additional assumptions.

    3. A three-parameter square-invariant kernel

    A scalar-to-scalar linear correlation uses a 3×33\times3 kernel and must be equivariant under D4D_4 on a periodic square. Determine its independent coefficients and its Fourier multiplier. Use a test field sx=e−ip⋅xs_x=e^{-ip\cdot x} with pi=2πni/Lp_i=2\pi n_i/L.

    Solution

    The offsets have three D4D_4 orbits: the center, four nearest axial neighbors, and four diagonal corners. Assign coefficients c0,c1,c2c_0,c_1,c_2 to those orbits. The kernel is

    k=(c2c1c2c1c0c1c2c1c2).(36)k= \begin{pmatrix} c_2&c_1&c_2\\ c_1&c_0&c_1\\ c_2&c_1&c_2 \end{pmatrix}. \tag{36}

    Substituting the plane wave in (20) yields Cks(x)=k~(p)s(x)C_ks(x)=\widetilde k(p)s(x) with

    k~(p)=c0+2c1(cos⁡p1+cos⁡p2)+4c2cos⁡p1cos⁡p2.(37)\widetilde k(p) =c_0+2c_1(\cos p_1+\cos p_2) +4c_2\cos p_1\cos p_2. \tag{37}

    This multiplier is unchanged by coordinate interchange and sign reversal, as required. A generic fixed kernel does not have these orbit equalities. Retaining all its orientations in separate channels instead allows it to detect directional information while transforming equivariantly. Summing those channels at a later readout produces a scalar.

    4. Why the augmented and tied fits coincide

    Assume a linear feature map transforms by orthogonal channel permutations, targets transform compatibly, and the empirical loss contains every group transform with equal weight. Prove that a positive ridge penalty forces its unique optimum to have invariant coefficients. Explain why the factor 1/81/\sqrt8 in (30) is needed, and why the proof does not repair a one-site translation after stride-two sampling.

    Solution

    Write the coefficient action as an orthogonal permutation PgP_g, leaving the intercept fixed. Reindexing a complete augmented dataset gives Laug(Pgβ)=Laug(β)\mathcal L_{\rm aug}(P_g\beta)=\mathcal L_{\rm aug}(\beta). The penalty preserves this equality. Its Hessian is

    ∇2Laug=2XaugTXaug/naug+2λI≻0.(38)\nabla^2\mathcal L_{\rm aug} =2X_{\rm aug}^{\mathsf T}X_{\rm aug}/n_{\rm aug} +2\lambda I\succ0. \tag{38}

    The minimizer is therefore unique. Since Pgβ⋆P_g\beta_\star is another minimizer, it must equal β⋆\beta_\star. In the regular orientation representation, this means a constant coefficient over each eight-element orbit.

    Let BB embed the five tied coefficients in the full space using βa,h=ca/8\beta_{a,h}=c_a/\sqrt8 and the unchanged intercept. Then BTB=IB^{\mathsf T}B=I. Consequently ∥Bc∥2=∥c∥2\|Bc\|^2=\|c\|^2, and restricting the augmented objective gives exactly the tied objective with the same ridge strength. Because the output of a tied model is equivariant, averaging its loss over transformed examples is identical to the original-data loss. Thus the fits agree.

    Using βa,h=ca\beta_{a,h}=c_a while applying the same penalty to cc would instead change the regularization: the full-space squared norm has an extra factor eight on those coefficients.

    Finally, stride-two sampling does not retain an action of every fine-lattice translation on the sampled values. A one-site translation moves to the other sublattice. The prerequisite representation identity fails before optimization, so uniqueness of a fitted objective cannot restore it. Two-site translations do have a consistent coarse-grid action.

    References

    • T. S. Cohen and M. Welling, “Group Equivariant Convolutional Networks,” Proceedings of the 33rd International Conference on Machine Learning, PMLR 48, 2990–2999 (2016), proceedings; arXiv:1602.07576v3, §2, §§4.4–5 and §§6.1–7.1 for pullbacks, orientation channels, correlation layers and stride.

    Scrollable formula. Use Left and Right arrow keys to reveal hidden content.

    Scrollable table. Use Left and Right arrow keys to reveal hidden columns.

    Scrollable figure. Use Left and Right arrow keys to reveal hidden content.