cs.AINov 20, 2026

Integral Multipliers and Arithmetic Obstructions for Two-Hidden-Layer ReLU Maxima

Authors: Pengcheng Cheng

Organizations: School of Mathematics, Jilin University, Changchun 130012, China

Abstract

We study exact representations of maximum functions by ReLU networks with two hidden layers and integer parameters. The least positive output multiplier is two for the six-input maximum, and either two or six for the seven-input maximum. We obtain these bounds from integral cubical fillings and a coefficient-preserving passage from polytope identities to networks. For the coordinate-facet complex of the six-simplex, we compute a coning index of six over the integers and three after inverting two, allowing arbitrary integral directions within each facet. A class in the homology of the unrestricted kernel complex characterizes the remaining seven-input problem; its vanishing is equivalent to an integral filling of a fixed target. We also construct a finite character that separates rational from three-local representability in a dictionary containing two known constructions and all pairs of edge-disjoint three-edge forests. This obstruction permits nonsymmetric coefficients and is confined to the specified dictionary. Control of lower-dimensional remainders yields a sufficient criterion in the top-dimensional quotient. Exact certificates and verification programs accompany the finite calculations.

Explore similar work

Jul 22, 2026

Shallower ReLU Network Representations via Exact Linear Algebra

We study the depth required by ReLU networks to exactly represent piecewise linear functions, focusing specifically on the maximum function. This problem has recently received significant attention in both the ML and TCS literature. We prove that max⁡n(x)=max⁡{x1,…,xn}\max_n(x)=\max\{x_1,\ldots,x_n\} is exactly representable with two hidden layers for every n≤12n\leq 12. Previously, this was only known up to n≤5n\leq5 [Bakaev, Brunck, Hertrich, Stade, Yehudayoff, STOC'26]. We obtain our constructions through an exact computer-assisted search within a space of candidate solutions: After a symmetry reduction, we obtain a finite system of linear equations over Q\mathbb{Q} such that any solution yields a valid representation of the maximum function. The resulting constructions have a structured first hidden layer, which enables recursive substitution into deeper networks. This yields an exact ReLU representation of max⁡n\max_n with at most ⌈log⁡6(n/2)⌉+1\lceil \log_6(n/2) \rceil+1 hidden layers. Consequently, every continuous piecewise-linear function on Rd\mathbb{R}^d admits an exact representation with at most ⌈log⁡6((d+1)/2)⌉+1\lceil\log_6((d+1)/2)\rceil+1 hidden layers; in particular, two hidden layers suffice for d≤11d\leq 11. Again, these results improve upon [Bakaev, Brunck, Hertrich, Stade, Yehudayoff, STOC'26], who proved analogous logarithmic bounds with base three.
Aug 25, 2026

Representing MAX functions using two-hidden-layer ReLU networks

We study exact representations of MAXN(x)=max⁡x1,…,xN\mathrm{MAX}_N(x)=\max{x_1,\ldots,x_N} using two-hidden-layer ReLU neural networks. This problem has been studied in recent years in an attempt to characterize the exact number of hidden layers required to represent continuous piecewise linear functions. The best lower bound is 2, while the current upper bound is logarithmic in NN. It remains completely open if the right answer is a constant number of hidden layers (possibly even 2!) or not. In fact, a recent breakthrough was the representation of MAX5\mathrm{MAX}_5 as a two-hidden-layer ReLU function obtained in [Bakaev et al., 2026], and the case of MAXN\mathrm{MAX}_N was stated as open for N≥6N\geq 6 in that paper. Using a careful computer assisted search, we obtain two-hidden-layer ReLU representations of MAX5,MAX6,MAX7\mathrm{MAX}_5, \mathrm{MAX}_6, \mathrm{MAX}_7, and MAX8\mathrm{MAX}_8. We obtain these by considering rational linear combinations of terms of the form max⁡{∑r=1smax⁡(xar,xbr),∑r=1smax⁡(xcr,xdr)}\max\{\sum_{r=1}^{s}\max(x_{a_r},x_{b_r}),\sum_{r=1}^{s}\max(x_{c_r},x_{d_r})\}, where ar,br,cr,dr∈{1,…,N}a_r,b_r,c_r,d_r\in\{1,\ldots,N\}. Each inner maximum of two coordinates can be computed in a first hidden layer, and the outer maximum of the two side-sums can be computed in a second hidden layer. Consequently, every finite linear combination of these terms has a two-hidden-layer ReLU realization. An identity for MAXN\mathrm{MAX}_N in this form therefore gives an exact two-hidden-layer ReLU representation of MAXN\mathrm{MAX}_N. Very recently, two-hidden-layer representations of MAXN\mathrm{MAX}_N of the above form were obtained for all N≤10N\leq 10 in [Ruess et al., 2026]. Our representations are different and were developed independently. While our techniques share most of the high-level ideas presented in [Ruess et al., 2026], there are also some minor differences which may be of interest for future research on this problem.
Oct 3, 2026

A Hand-Checkable Proof That Two Hidden ReLU Layers Compute the Maximum of Six Numbers

Exactly computing the maximum function is a standard test case for studying depth in ReLU networks. Two hidden layers are known to suffice for up to twelve inputs through computer-assisted constructions. For six real inputs, we give an explicit hexagon identity whose local structure yields a self-contained analytical proof of this depth bound. The identity was found by computer-assisted search; we prove it through explicit cancellations that can be checked entirely by hand, without executing a verification program. The identity also yields an explicit network with hidden widths 1717 and 4141, zero biases, and rational weights.