\documentclass[11pt,a4paper]{article} \usepackage[T1]{fontenc} \usepackage{lmodern,amsmath,amssymb,amsthm} \usepackage[a4paper,margin=28mm]{geometry} \usepackage{microtype,xcolor,booktabs,array} \usepackage[unicode,colorlinks=true,linkcolor=blue!55!black,citecolor=blue!55!black,urlcolor=blue!55!black]{hyperref} \hypersetup{pdftitle={Faster deterministic min-plus matrix multiplication},pdfauthor={Yilin Liu},pdfkeywords={min-plus matrix multiplication, all-pairs shortest paths, deterministic algorithms, rectangular matrix multiplication}} \newtheorem{theorem}{Theorem}[section] \newtheorem{lemma}[theorem]{Lemma} \newtheorem{corollary}[theorem]{Corollary} \newtheorem{proposition}[theorem]{Proposition} \newcommand{\Oh}{\widetilde O} \newcommand{\eps}{\varepsilon} \newcommand{\R}{\mathbb R} \newcommand{\W}{\mathcal W} \newcommand{\Hent}{\mathcal H} \newcommand{\card}[1]{\lvert #1\rvert} \newcommand{\br}[1]{\left\lceil #1\right\rceil} \setlength{\emergencystretch}{1em} \clubpenalty=10000 \widowpenalty=10000 \displaywidowpenalty=10000 \allowdisplaybreaks[1] \title{Faster deterministic min-plus matrix multiplication} \author{Yilin Liu} \date{30 November 2026} \begin{document} \makeatletter \begin{center} {\LARGE\bfseries\parbox{.99\linewidth}{\centering\@title}\par} \vspace{.8em} {\large\@author\par} \vspace{.4em} {\small\@date\par} \end{center} \makeatother \begin{abstract} We compute the exact min-plus product of two square matrices with arbitrary real entries in deterministic time \(O(n^{2.991627})\). The same bound holds for all-pairs shortest paths in directed real-weighted graphs without negative cycles. The algorithm uses a common set of candidates with a certified rank bound across all outputs. It also batches the high-degree contributions of selected ordinary products across jobs with the same requested positions. A single-level redistribution and a deterministic cover of descendant words reduce the number of groups that each output must access. \end{abstract} \section{Introduction} For \(A,B\in\R^{n\times n}\), the min-plus product \(A\star B\) has entries \[ (A\star B)_{ij}=\min_{k\in[n]} (A_{ik}+B_{kj}). \] It is a basic operation in shortest-path algorithms and is equivalent up to standard reductions to all-pairs shortest paths (APSP). Alman and Vassilevska Williams~\cite{AW} gave truly subcubic algorithms for APSP. Chan, Itakura, Ma, and Yu~\cite{CIMY} obtained a deterministic truly subcubic algorithm for real inputs. Essayag and Zabokritskiy~\cite[Theorem~1.1 and footnote~1]{EZ} proved a bound of \(O(n^{2.9929729})\) and announced a further refinement. We improve both bounds in the same model. \begin{theorem}[Min-plus product]\label{thm:main} There is a deterministic algorithm that computes the exact min-plus product of two \(n\times n\) matrices with arbitrary finite real entries in \(O(n^{2.991627})\) worst-case time. It returns an attaining inner index for each entry. The real operations are unit-cost exact addition, subtraction, and comparison. Auxiliary integer operations and indexed memory accesses are charged at bit cost. \end{theorem} The algorithm first recursively compresses the set of candidate indices into a single small set whose best member has a bounded rank at every output. It then asks for exact counts of improving candidates using ordinary integer products. Essayag and Zabokritskiy's encoding splits these products into low- and high-degree contributions~\cite[Section~9]{EZ}. We collect the high-degree contributions on one level of a word order and partition that level into groups. All jobs with the same requested positions use the same selector matrices. This shares high-degree reads across jobs as well as across the positions of each job. We use \(n^{o(1)}\) for uniform subpolynomial overhead and \(\Oh\) to suppress polylogarithmic factors. For a fixed shape \((a,b,c)\), \(\omega(a,b,c)\) is the ordinary matrix multiplication exponent. We use Uzna\'nski's bound~\cite[Theorem~1.1]{Uznanski}, written with sorted exponents \(a\ge b\ge c>0\) as \begin{equation}\label{eq:omega} \Omega(a,b,c)= \begin{cases} a+b, & c\le ab/(a+b),\\ (ab+ac+bc)^2/(4abc), & c>ab/(a+b). \end{cases} \end{equation} On all permutations of the shape, \(\Omega\) has the same value. Each use reserves a fixed positive exponent loss. Fixed rational bilinear formulas implement these bounds on bounded-bit integers with polylogarithmic bit overhead. A characteristic-zero rank bound gives a fixed-size rational formula with any prescribed positive slack. One can also descend from an exact complex formula through a finite number field and tensor powers, as in~\cite[Appendix~B]{EZ}. Recursive evaluation uses \(O(\log n)\) levels and clears only fixed denominators per level. For effectiveness, the algorithm can find each fixed base formula by enumerating rational coefficient lists and testing their bilinear identities exactly. This has constant cost in \(n\). \section{A common set of candidates}\label{sec:sample} Order the labels \(k\in[n]\) at output \((i,j)\) by \((A_{ik}+B_{kj},k)\) in lexicographic order. Write \(\operatorname{rank}_{ij}(k)\) for the number of predecessors of \(k\) in this order. We use the following local primitive from~\cite[Lemmas~3.2 and~4.1]{EZ}. In a group of \(d\le n^{1/10}\) labels, for \(1\le R\le d\), it finds a common set of \(O(1+d/R)\) labels whose least member at every output has at most \(\lambda R\) predecessors in the group, where \(\lambda=O(\log n)\). For each fixed \(\eps>0\) the cost is \(\Oh(n^{2+\eps}d/R)\). Its dimension conditions hold for all sufficiently large \(n\) because \(d^2\le n\) and \(d^4(1+\log_2 d^2)=o(n^{1/2})\), and \eqref{eq:omega} gives the required half-width product. Reindexing a surviving group in the original order preserves ties. \begin{lemma}\label{lem:sample} Fix \(0h_0\) labels, partition it into \(g=\br{N/m_0}\) groups of nearly equal sizes. For large \(n\) each group has at least \(h_0\) labels. Apply the group procedure and pad each retained set to exactly \(h_0\) using additional labels from the same group. Repeat on the concatenation. The number of levels is bounded in terms of \(x\). Outside the final level the contraction factor is \(O(h_0/m_0)\). For any output and fixed score threshold, let \(f\) and \(f'\) be the fractions strictly below it before and after a level. The maximum group size is at most \(2N/g\). Summing the local prefix bounds gives \[ f\ \,\le\,\, O(\lambda/h)+O(\lambda h_0/h) f'. \] At each output choose the threshold to be the least final tagged score. The last fraction is zero, so a bounded number of substitutions gives \(f\le h^{-1}(\log n)^{O(1)}\) in the original list. The total number of groups is \(O(n/m_0)\), and each costs \(\Oh(n^{2+\eps}h)\). \end{proof} \section{Reduction to ordinary products with common positions}\label{sec:reduction} \subsection{Sparse recovery} For each output choose the least tagged score among the common labels and let \(W_p\) be the set of outputs with incumbent label \(p\). These sets partition \([n]^2\). By Lemma~\ref{lem:sample} a known cap \(\kappa=\br{(n/h)(\log n)^C}\), for a sufficiently large fixed \(C\), bounds the number of improving labels at every output. We use the binary measurement family of~\cite[Lemma~6.1]{EZ}. With \(n\) labels and a support cap \(\kappa\), the family has \(\Oh(\kappa)\) subsets of total size \(\Oh(n)\), can be listed in \(\Oh(n)\) bit operations, and recovers a support in \(\Oh(\kappa)\) time given its exact subset counts. Split each subset into chunks of size at most \(\br{n/\kappa}\). There are \(\Oh(\kappa)\) chunks. \subsection{Certified comparison counts} Fix a chunk \(C\) and an incumbent \(p\). For each \(k\in C\) separately sort the \(n\) row keys \(A_{ik}-A_{ip}\) and the \(n\) column keys \(B_{pj}-B_{kj}\) together. At a tie order rows before columns if \(k5\) the factor \(\binom Lj4^{L-j}\) increases through \(j=M\). Its log-concavity puts the largest product, under the total cap, at a nearly equal split of \(2M-t\). The entropy bounds for binomial coefficients give \eqref{eq:table}. \subsection{Operand encoders and low reads} The low encoding contracts the channels at the private positions. In each run it needs the subsets of fewer than \(t\) channel positions and a polynomial number of coefficients for each subset. Its two operand vectors are read through the fixed selectors of~\cite[Lemma~9.6]{EZ}. With vector length \(C_*=\br{D^{s\zeta}}\), take a product shape \((a_\ell,1,k_\ell)\), with \(W_\ell=\Omega(a_\ell,1,k_\ell)+\xi\). Here and below \(\xi>0\) is a fixed loss. Put \(\alpha_\ell=W_\ell-k_\ell-1\) and \(\beta_\ell=W_\ell-k_\ell-a_\ell\). The low cost uses the following guards from~\cite[Eq.~(15)]{EZ}. \begin{equation}\label{eq:window} \zeta<(c-1)\gamma(2v),\qquad \frac{2\ln((1-v)/v)}{\ln 4} +\frac{\zeta\gamma'(v)}{2\gamma(v)^2}>0,\qquad JK\ge\br{C_*^{k_\ell}}. \end{equation} For these choices the root, residual, and high operand encoders cost \(nD^{A_i+o(1)}\) per job, with \begin{align*} A_0 &=r+s\left(2C_0+(2c-1)\log_4 3+\psi-T_s\right),\\ A_1 &=r+s\left(T_s+\psi+\zeta(1+\alpha_\ell)-\frac{\zeta}{2\gamma(v)}\right),\\ A_2 &=r+s(T_s-G). \end{align*} The low read charge is \(m_{\W}D^{q_\ell+o(1)}\) per job, where \begin{equation}\label{eq:ql} q_\ell=r+s(\psi+\zeta\beta_\ell). \end{equation} These counts follow from~\cite[Eqs.~(13) and (19)--(22)]{EZ}. There are \(D^{s\psi+o(1)}\) channel subsets for a locator. Per component band, the number of residual groups is \(D^{s(2T_s+\psi-\zeta/(2\gamma(v)))+o(1)}\). Batching a group with \(R\) selector rows against its \(JK\) columns uses at most \(JK(C_*^{1+\alpha_\ell}+RC_*^{\beta_\ell})\) operations up to polylogarithmic overhead. Summing over the \(O(n/\Lambda)\) component bands, their \(K\) components, and the projected requests gives \(A_1\) and \eqref{eq:ql}. The corresponding root count per component band is \(D^{s(2C_0+(2c-1)\log_4 3+\psi)+o(1)}\). Equation~\eqref{eq:table} bounds the high encoder in the same sum. \subsection{High base products} Use shape \((u,r,u)\) for the high base products and put \(W_{\mathrm{base}}=\Omega(u,r,u)+\xi\). The fit condition \(eT<1\) ensures \(B\Lambda\le n\) for large \(n\). Across the \(O((n/(B\Lambda))^2)\) outer-block pairs, the high base products cost \begin{equation}\label{eq:vp} n^2 D^{-V_p+o(1)}\quad\text{per job},\qquad V_p=sG-(W_{\mathrm{base}}-2u). \end{equation} This covers all inputs and outputs of the products. The low encoding and high leaf construction use only exact integer operations after the initial sorting of real keys. \section{Batching the high-degree read}\label{sec:cover} Say that \(b\) is a descendant of \(q\) if it replaces some private letters of \(q\) by ordinary letters and leaves the other positions unchanged. For a table word \(b\) let \(d(b)\) be \(H\) minus its number of private letters. Every high table word has \(d(b)\ge t\). \subsection{Redistribution to one level} For each valid word \(b\) of order \(t\), define an integer \begin{equation}\label{eq:redistribute} F(b)=\sum_{u\text{ descendant of }b} \frac{H!}{\binom{d(u)}{t}} P(u). \end{equation} The quotient is integral since \(\binom{d}{t}\) divides \(d!\). Compute the whole table by initializing every word of order \(d\) with \((H!/\binom dt)P(u)\). Then process one position at a time, adding into each word private at that position the four entries obtained by substituting an ordinary symbol there. The latter entries stay fixed during that coordinate pass. The table is closed under these substitutions, so the transform costs \(O(LZ)\) additions. Each high descendant of a query \(q\), of order \(d\), is reached from exactly \(\binom dt\) order-\(t\) descendants of \(q\). Therefore the sum of \(F(b)\) over those order-\(t\) descendants equals \(H!\) times the high numerator. The scaling and additions increase the bit length by only \(O(H\log H+L)\). \subsection{The descendant cover} \begin{lemma}\label{lem:cover} Fix \(00\). We have \(\sum_i h_i=H\) and \(\sum_i h_i x_i=t\). Up to \(O(\log L)\) per block, the logarithm of \(U_i/L_i\) is at most \(h_i\) times \[ \Hent(\lambda+(1-\lambda)x_i)-(1-x_i)\Hent(\lambda)+x_i\ln 4. \] Blocks with \(h_i=0\) contribute a factor one. The displayed function is concave in \(x_i\). Jensen's inequality and the entropy estimate bound the total list size, up to polynomial factors in \(L\), by \[ \frac{\binom Ht 4^t}{\binom{t+wH}{wH}} . \] The denominator uses nearest integers when necessary. Taking logarithms to base \(D\) gives \eqref{eq:qo}. A group can contain incompatible bases, which the exact descendant test discards. \end{proof} \subsection{Group products} Fix a physical pair of bands, a run, and a translation. For a group of \(A\) bases and \(R\) routed query occurrences, form a zero-one matrix of descendant tests of size \(R\times A\). Multiply it by the \(A\times J\) matrix of redistributed values. The selector depends on the queries and their groups alone and is used across all \(J\) jobs. Summing the routed products counts every compatible base exactly once. Divide by \(H!\) to obtain the high numerator. Use a shape \((a_h,1,k_h)\) and write \[ W_h=\Omega(a_h,1,k_h)+\xi,\qquad \alpha_h=W_h-k_h-1,\qquad \beta_h=W_h-k_h-a_h. \] If \(J\ge\br{A^{k_h}}\), tile the rows in groups of \(\br{A^{a_h}}\) and the job columns in groups of \(\br{A^{k_h}}\), padding the last tiles. The amortized cost per job is \[ \Oh\left(A^{1+\alpha_h}+RA^{\beta_h}\right). \] The formula covers selector formation because \(J\ge A\) for our choice \(k_h>1\). It also covers the input and output writes, since the multiplication exponent dominates both corresponding sizes. Each group belongs to a fixed band pair. The sum of group sizes over that pair is at most \(Z\), and by Lemma~\ref{lem:cover} each request is routed to \(D^{q_o+o(1)}\) groups. There are \(O((n/\Lambda)^2)\) physical band pairs. The total cost per job for the high group startup is at most \(n^2D^{-V_c+o(1)}\) and the high read cost is \(m_{\W}D^{q_h+o(1)}\), where \begin{equation}\label{eq:highrates} V_c=sG-z\alpha_h,\qquad q_h=q_o+z\beta_h. \end{equation} This includes redistribution, grouping, and routing. The startup and high base products in \eqref{eq:vp} are separate additive costs. Lemma~\ref{lem:cover} was constructed independently of the graph and the numerical column values, so it is reused across band pairs and sweeps. \section{The time bound}\label{sec:parameters} Set \(\delta=3-2.991627\). The dimension conditions reduce to positivity of \begin{equation}\label{eq:fit-check} 1-eT,\qquad \eta+er-es\zeta k_\ell,\qquad \eta-ezk_h \end{equation} and the two window inequalities in \eqref{eq:window}. Strictness absorbs the rounding and subpolynomial terms in the dimensions. Summing the encoder and startup costs over \(n^{1+o(1)}\) jobs and the read costs over \(n^{3-x+o(1)}\) requests yields the first seven savings below. The last four cover dense formation, common sample construction, incumbent formation, and decoding. At zero exponent loss the required test is \begin{equation}\label{eq:saving-check} \begin{split} \min\bigl\{& 1-eA_0,\ 1-eA_1,\ 1-eA_2,\ eV_p,\ eV_c,\ x-eq_\ell,\ x-eq_h,\\ &1-e,\ 1/10-x,\ 1-x,\ x\bigr\}>\delta . \end{split} \end{equation} Appendix~\ref{app:certificate} gives a rational witness and an enclosure method for these tests. Because the inequalities are strict, continuity permits a common sufficiently small positive loss \(\xi\) for the rectangular products and the selection lemma. All costs are then \(n^{3-\delta-\tau+o(1)}\) for some fixed \(\tau>0\). This proves Theorem~\ref{thm:main}. \begin{corollary}[All-pairs shortest paths] All-pairs shortest paths in an \(n\)-vertex directed graph with arbitrary finite real edge weights, missing edges, and no negative cycles can be computed deterministically in time \(O(n^{2.991627})\) in the same model. \end{corollary} \begin{proof} Adjoin zero self-loops, preserving a smaller existing loop weight, and let \(U\) be the maximum absolute finite edge weight, with \(U=0\) when there are none. Use the sentinel \((4n+1)(1+U)\) for absent edges, constructed by additions and doublings. Compute the minimum weights of walks of at most the smallest power of two at least \(n-1\) by repeated min-plus squaring. For \(n\ge2\) this power is less than \(2n\). A walk in this calculation that uses a sentinel edge costs more than \(nU\), while all genuine finite shortest distances are at most \(nU\), since each has a simple minimizer. Thus the output entries larger than \(nU\) represent unreachable pairs. The \(O(\log n)\) factor is absorbed by the strict savings in the proof of Theorem~\ref{thm:main}. \end{proof} \clearpage \appendix \section{Rational certificate}\label{app:certificate} The witness for \eqref{eq:fit-check} and \eqref{eq:saving-check} is the following tuple, with all entries interpreted as exact rationals. \begin{align*} (e,c,v,r,u,w) &= (0.084796,\ 10.57065,\ 0.077072,\ 0.0155776,\ 0.021436,\ 0.110788),\\ (\zeta,a_\ell,k_\ell,a_h,k_h) &= (1/5,\ 11/10,\ 11,\ 0.95014,\ 13.11475). \end{align*} The rectangular bounds in \eqref{eq:omega} are rational at this tuple. The remaining expressions use logarithms of positive rational arguments. For \(1\le y\le2\), put \(z_0=(y-1)/(y+1)\) and \(J=16\). Then \[ 0\le \ln y-2\sum_{j=0}^{J-1}\frac{z_0^{2j+1}}{2j+1} \le \frac{2z_0^{2J+1}}{(2J+1)(1-z_0^2)}. \] The power series for the logarithm gives the lower endpoint and the geometric tail bound gives the upper endpoint. For other arguments, scale by a power of two and use the same enclosure for \(\ln 2\). Evaluate the expressions by rational interval arithmetic. The lower endpoints of every dimension margin and window margin are positive. The lower endpoint of every saving exceeds \(\delta\). Run \texttt{python3 anc/verify.py} from the extracted source directory to reproduce these checks. The verifier uses only Python's standard library. \section*{Acknowledgment} The author used OpenAI's GPT-6.2 Astra to develop and review the proofs. \begin{thebibliography}{99}\small\raggedright\setlength{\itemsep}{1pt} \bibitem{AW} J. Alman and V. Vassilevska Williams. \href{https://arxiv.org/abs/2610.06783}{Truly subquadratic 3SUM and truly subcubic APSP via triangles in sparse lopsided graphs}. arXiv:2610.06783, 2026. \bibitem{CIMY} T. M. Chan, R. Itakura, Z. Ma and Y. Yu. \href{https://arxiv.org/abs/2610.42012v2}{3SUM made simpler (without matrix multiplication), \(k\)-SUM hypothesis refuted for odd \(k\), and real 3SUM/APSP derandomized}. arXiv:2610.42012v2, 2026. \bibitem{EZ} I. B. Essayag and A. L. Zabokritskiy. \href{https://arxiv.org/abs/2611.17215v3}{Faster deterministic all-pairs shortest paths with real edge weights}. arXiv:2611.17215v3, 2026. \bibitem{Uznanski} P. Uzna\'nski. \href{https://arxiv.org/abs/2610.10494v2}{Rectangular matrix multiplication from polynomial products}. arXiv:2610.10494v2, 2026. \end{thebibliography} \end{document}