arXiv:2609.11362cs.ITSep 2026

Manuscript Offprint

arXiv:2609.11362

Maximal Kolmogorov Complexity in a Hamming Ball

Alexander Kozachinskiy, Nikolay Vereshchagin

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

Abstract

The minimal Kolmogorov complexity of a string within Hamming distance r of a given string x is the algorithmic rate–distortion function of x, and Vereshchagin and Vitányi characterized completely which shapes it can have. This paper is about the opposite extreme. For a binary string x of length n let gx(r)g_x(r) denote the maximal Kolmogorov complexity of a string within Hamming distance r of x; we study which values, and more generally which functions of r, this quantity can attain.

First we characterize, up to an additive error O(log⁡n)O(\log n), the possible values of the triple (C(x),r,gx(r))(C(x), r, g_x(r)): writing rkr_k for the radius of a Hamming ball of cardinality about 2k2^k, a triple (k,r,l)(k, r, l) is realizable if and only if log⁡V(rk+r)⩽l⩽min⁡{n,k+log⁡V(r)}\log V(r_k + r) \leqslant l \leqslant \min\{n, k + \log V(r)\}, where V(a)V(a) is the cardinality of a ball of radius aa. In particular, for rk+r>n/2r_k + r > n/2 both bounds collapse to nn and only l≈nl \approx n is realizable. The two ends of this interval correspond to the two extreme ways of placing a set of complexity kk in the cube: a single Hamming ball, where the lower bound comes from Harper's isoperimetric inequality, and an error-correcting code, which for the intermediate parameters we relax to a family of centers with bounded covering multiplicity, in the spirit of list decoding. Then we turn to the function r↦gx(r)r \mapsto g_x(r) as a whole: we establish four properties that it always has, and show that the minimal and the maximal functions consistent with these properties are both attained, for every complexity level kk. Which intermediate profiles are attainable remains open.

1 Introduction

Let xx be a binary string of length nn. All strings in this paper are binary of length nn, and C denotes the plain Kolmogorov complexity (see Section 2). Write Br(x)B_r(x) for the Hamming ball of radius rr centered at xx, and consider the complexities of the strings it contains.

The minimal complexity in Br(x)B_r(x) is a well-studied quantity. As a function of rr it is the algorithmic rate–distortion function of the individual string xx for the Hamming distortion, the individual-string counterpart of Shannon’s rate–distortion function [11, 1]. It is a variant of Kolmogorov’s structure function and belongs to algorithmic statistics [4, 14, 13]; Vereshchagin and Vitányi [15] characterized completely which shapes this curve can have, and read it as a denoising procedure for xx: the string of minimal complexity in the ball is the natural candidate for the “denoised” version of xx at distortion level rr.

This paper is about the opposite extreme. Define

gx(r)  =  max⁡{C(y):y∈Br(x)}.g_{x}(r)\;=\;\max\{\mathrm{C}(y):y\in B_{r}(x)\}.

Thus gx(0)=C(x)g_x(0) = \mathrm{C}(x), and gxg_x is a non-decreasing function reaching n−O(1)n - O(1) at r=nr = n. We call gxg_x the complexity profile of xx and ask: what can this profile look like? In contrast with the minimum, this question seems not to have been studied systematically.

It is related to the effect of random noise on complexity, studied by Posobin and Shen [10]: they show that a typical corruption of a simple string increases its complexity. We ask about

∗^{*}Centro Nacional de Inteligencia Artificial (CENIA).

†^{\dagger}Moscow State University, HSE University, Yandex. The research was carried out within the framework of the scientific program at the Faculty of Mechanics and Mathematics, Lomonosov Moscow State University.

the extreme rather than the typical behaviour: how complex can the most complex string in the ball be? The answer turns out to depend on x and not only on C(x)C(x), which is what makes the profile an interesting object.

We prove two kinds of results: a pointwise one, describing the possible values of gx(r)g_x(r) for a single radius rr, and global ones, describing possible profiles as functions of rr.

Pointwise results. Call a triple (k,r,l)(k,r,l) of natural numbers realizable if there is a string xx of length nn with C(x)=k\mathrm{C}(x) = k and gx(r)=lg_x(r) = l. Let V(a)=∑i⩽a(ni)V(a) = \sum_{i \leqslant a} \binom{n}{i} be the cardinality of a Hamming ball of radius aa, and for k⩽nk \leqslant n let rkr_k denote the least radius with V(rk)⩾2k−1V(r_k) \geqslant 2^{k-1}, so that log⁡V(rk)=k+O(log⁡n)\log V(r_k) = k + O(\log n) and, conveniently, rk⩽⌊n/2⌋r_k \leqslant \lfloor n/2 \rfloor (Section 2). Our first main result characterizes the realizable triples up to O(log⁡n)O(\log n)-changes of the parameters.

Theorem 1. There is a constant cc (independent of nn) such that for all nn and all triples (k,r,l)(k, r, l) of natural numbers with k⩽nk \leqslant n the following hold.

(a) (Necessity) 1^{1} If (k,r,l)(k, r, l) is realizable, then

log⁡V(rk+r)−clog⁡n⩽l⩽min⁡{n,log⁡V(rk)+log⁡V(r)}+clog⁡n.\log V(r_{k}+r)-c\log n\leqslant l\leqslant\min\{n,\log V(r_{k})+\log V(r)\}+c\log n.

(b) (Sufficiency) If

log⁡V(rk+r)⩽l⩽min⁡{n,log⁡V(rk)+log⁡V(r)},\log V(r_{k}+r)\leqslant l\leqslant\min\{n,\log V(r_{k})+\log V(r)\},

then some triple (k′′,r,l′′)(k'', r, l'') with ∣k′′−k∣⩽clog⁡n|k'' - k| \leqslant c \log n and ∣l′′−l∣⩽clog⁡n|l'' - l| \leqslant c \log n is realizable.

In the loosest form, ignoring all additive O(log⁡n)O(\log n) terms (in the inequalities and in the parameters), Theorem 1 says that a triple (k,r,l)(k, r, l) is realizable if and only if

log⁡V(rk+r)⩽l⩽min⁡{n,log⁡V(rk)+log⁡V(r)}.\log V(r_{k}+r)\leqslant l\leqslant\min\{n,\log V(r_{k})+\log V(r)\}.

The interval here is never empty. Indeed, V(a)V(b)⩾V(a+b)V(a) V(b) \geqslant V(a+b) for all a,ba, b (a string of weight at most a+ba+b splits into a part of weight at most aa and a part of weight at most bb, and this map is injective), so the right end is at least the left end. For rk+r⩾n/2r_k + r \geqslant n/2 both ends collapse to nn: indeed, log⁡V(rk+r)⩾n−1\log V(r_k + r) \geqslant n - 1, since a ball of radius ⌊n/2⌋\lfloor n/2 \rfloor contains at least half of the cube.

Informally: for a string of complexity kk, the maximal complexity at distance rr can be anything between log⁡V(rk+r)\log V(r_k + r) (as for a random string of a ball of radius rkr_k centered at 0n0^n) and k+log⁡V(r)k + \log V(r) (as for a random codeword of a code correcting rr errors [9]), and these are the only constraints. The upper bound is straightforward and the lower bound follows from Harper's isoperimetric inequality. The sufficiency is proved by a construction interpolating between the two extreme examples above: a union of MM balls of radius qq centered at codewords, with qq ranging from 0 to rkr_k. For the intermediate parameters a code with disjoint balls need not exist, and we replace it by a list-decoding relaxation [2, 5]: a family of centers whose balls cover every point O(n)O(n) times (Lemma 6).

Global results. The profile gxg_x always has the following four properties (Section 3): it is non-decreasing; gx(0)=C(x)g_x(0) = \mathrm{C}(x) and gx(r)⩽n+O(1)g_x(r) \leqslant n + O(1); it grows at most as fast as

gx(r+a)⩽gx(r)+log⁡V(a)+O(log⁡n);g_{x}(r+a)\leqslant g_{x}(r)+\log V(a)+O(\log n);

and at least as fast as

gx(r)⩾log⁡V(m)+2log⁡n+O(1)  ⟹  gx(r+a)⩾log⁡V(m+a).g_{x}(r)\geqslant\log V(m)+2\log n+O(1)\implies g_{x}(r+a)\geqslant\log V(m+a).

1^{1}In both parts, one may write kk instead of log⁡V(rk)\log V(r_k): by (1) the two differ by at most log⁡(n+1)\log(n+1).

For a given complexity level k=gx(0)k = g_x(0), the minimal function consistent with these properties is gmin⁡(r)=log⁡V(rk+r)g_{\min}(r) = \log V(r_k + r), and the maximal one is gmax⁡(r)=min⁡{n,k+log⁡V(r)}g_{\max}(r) = \min\{n, k + \log V(r)\}. We show (Section 5) that both are attained for every kk: there are strings of complexity k+O(log⁡n)k + O(\log n) whose profile is gmin⁡+O(log⁡n)g_{\min} + O(\log n), and strings whose profile is gmax⁡+O(log⁡n)g_{\max} + O(\log n) — for all radii simultaneously. Theorem 1 controls the profile at a single radius; whether every function satisfying the four properties is a profile of some string remains open (Section 6).