cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A179193 Sum of the number of repeating digits for each reciprocal of integer m, where 1 < m < n and n is the base.

Original entry on oeis.org

0, 1, 1, 4, 1, 9, 9, 9, 9, 20, 15, 30, 22, 28, 23, 52, 33, 63, 58, 44, 65, 86, 84, 67, 68, 102, 135, 140, 74, 142, 171, 159, 142, 124, 88, 220, 204, 205, 238, 258, 209, 244, 231, 201, 245, 304, 328, 214, 291, 292, 465, 422, 380, 350, 422, 381, 507, 507, 417, 627
Offset: 2

Views

Author

Will Nicholes, Jul 01 2010

Keywords

Comments

No digits are counted as repeating for 1/m if 1/m terminates.
Equivalent to 1 <= m <= n, since 1/n and 1/1 do not have repeating digits in any integer base n.

Examples

			7th term considers octal: the fractions 1/2, 1/3, 1/4, 1/5, 1/6 and 1/7 have 0, 2, 0, 4, 2 and 1 repeating (octal) digits respectively, for a total of 9.
9th term considers decimal: the fractions 1/2, 1/3, 1/4, 1/5, 1/6, 1/7, 1/8 and 1/9 have 0, 1, 0, 0, 1, 6, 0 and 1 repeating (decimal) digits respectively, for a total of 9.
		

Crossrefs

Cf. A051626.

Programs

  • Mathematica
    a[n_] := Sum[Length[RealDigits[1/k, n][[1, -1]]], {k, 2, n-1}]; Array[a, 100, 2] (* Amiram Eldar, Jun 28 2024 *)

Extensions

Data corrected and extended by Amiram Eldar, Jun 28 2024