repunits
Repunits are positive integers that consist entirely of the digit 1 in a given base. The most familiar case is base 10, where the n-digit repunit is denoted R_n and equals 111...1 with n ones. In closed form, R_n(b) = (b^n - 1)/(b - 1) = 1 + b + b^2 + ... + b^{n-1}, where b is the base.
General properties: For any base b ≥ 2, if n is composite then R_n(b) is composite. If n
Special cases: In base 2, R_n(2) = 2^n - 1, the Mersenne numbers; many of these are prime
Connections and applications: Repunits relate to cyclotomic factorization, since 10^n − 1 factors into a product involving