We study the repunit word Rₙ = 2ⁿ - 1, viewed both as an integer and as the binary word of n consecutive ones. Using the classical identity gcd (2ᵃ - 1, 2ᵇ - 1) = 2ᵍcd (a, b) - 1, we derive a scalar binary characterization of primality for the index n. If W = Rₙ, then for n >= 2, n is prime if and only if the sum from k = 0 to n - 1 of gcd (W, W shifted right by k) is equal to W + popcount (W) - 1. Since popcount (Rₙ) = n, the criterion can also be written as the same sum being equal to Rₙ + n - 1. The interest of the result is structural rather than algorithmic: primality of the index is encoded inside a single binary object W, together with the operations gcd, right shift, addition, and population count. The theorem may be read as a compact binary reformulation of primality within a dyadic framework based on the power-of-two transform.
Ricardo Adonis Caraccioli Abrego (Sat,) studied this question.