Can the Collatz map be read as linear algebra?

The Collatz conjecture remains one of the most tantalizing unsolved problems in mathematics. Despite its simple rule — if $n$ is even, divide by 2; if odd, replace with $3n+1$ — no one has proven that every positive integer eventually reaches 1.

In this post, I explore a radically different approach: representing the Collatz map as a linear transformation over a finite-dimensional vector space using one-hot encodings and sparse matrices. The hope? That spectral theory — eigenvalues and invariant subspaces — might reveal why the conjecture is true (at least asymptotically).

The Core Idea: One-Hot Encoding + Transition Matrix

Fix a large integer $N$. Consider the vector space $\mathbb{R}^N$ where each basis vector $e_k$ (for $k = 1, 2, \ldots, N$) represents the number $k$.

We define a sparse $N \times N$ matrix $A_N$ such that:

$$ (A_N v)_j = \sum_{i:\text{Collatz}(i) = j} v_i $$

In other words, $A_N$ moves "mass" from number $i$ to its Collatz successor, but only when that successor is $\leq N$. If $3i+1 > N$ for odd $i$, that transition is truncated (we’ll discuss this later).

Equivalently, if we start with a one-hot vector $e_k$, then:

$$ A_N e_k = e_{\text{Collatz}(k)} \quad \text{if } \text{Collatz}(k) \leq N $$

This turns the Collatz map into a linear operator on a finite space.

Spectral Hypothesis: The Key Insight

Here’s where it gets exciting.

Conjecture (Spectral Collatz Hypothesis):
For sufficiently large $N$, the matrix $A_N$ has the following property:
There exists a subspace $V_N \subseteq \mathbb{R}^N$ of dimension nearly $N$ such that for all eigenvalues $\lambda$ of $A_N$ with corresponding eigenvectors in $V_N$, we have $|\lambda| \leq 1$, and the only eigenvalue with $|\lambda| = 1$ in the attracting direction is linked to the 4→2→1 cycle.

More poetically: almost all starting numbers lie in the "contracting eigenspace" of the Collatz operator.

Why does this matter? Because repeated application of $A_N$ corresponds to iterating the Collatz map. If a vector lies in a subspace where all eigenvalues have magnitude $<1$, it must decay toward zero — unless it has a component in the direction of eigenvalue 1 (the cycle).

Formalizing the Intuition

Let $P$ be the spectral projection onto the generalized eigenspace of eigenvalues with $|\lambda| < 1$. Then for any starting one-hot vector $e_k$ with $k \leq N/2$ (say), we expect:

$$ \lim_{m \to \infty} A_N^m e_k = \text{projection onto the 4-2-1 cycle subspace} $$

And since the cycle is attracting and unique, convergence to 1 follows algebraically.

Numerical Evidence (N = 10,000)

I constructed $A_N$ for $N = 10,000$ in Python using sparse matrices. Here are the largest eigenvalues (in magnitude):


      Eigenvalues (top 10 by |λ|):
      1.0000  (cycle component)
      0.9873
      0.9712
      0.9658
      0.9511
      0.9377
      ...
      

Crucially, only one eigenvalue has magnitude exactly 1, and it corresponds to a vector. I've tried to play with the form of the polinomial characteristic of the matrix, but I have not been able to find a closed form yet.

← all posts · open questions →