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.

A078709 a(n) = floor(n/d(n)), where d(n) is the number of divisors of n (A000005).

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 3, 2, 3, 2, 5, 2, 6, 3, 3, 3, 8, 3, 9, 3, 5, 5, 11, 3, 8, 6, 6, 4, 14, 3, 15, 5, 8, 8, 8, 4, 18, 9, 9, 5, 20, 5, 21, 7, 7, 11, 23, 4, 16, 8, 12, 8, 26, 6, 13, 7, 14, 14, 29, 5, 30, 15, 10, 9, 16, 8, 33, 11, 17, 8, 35, 6, 36, 18, 12, 12, 19, 9, 39, 8, 16, 20, 41, 7, 21, 21, 21, 11
Offset: 1

Views

Author

Joseph L. Pe, Dec 19 2002

Keywords

Comments

Also, integer part of the mean subinterval length in the partition of [0,n] by the divisors of n.
If the first occurrence of m in the sequence is greater than all preceding terms, the corresponding n is noncomposite. - Donald Sampson (Marsquo(AT)hotmail.com), Dec 10 2003

Examples

			The divisors of 9 partition the closed interval [0,9] into subintervals [0,1), [1,3), [3,9], with lengths 1, 2, 6, respectively. The mean of these lengths has integer part = 3. Hence a(9) = 3.
		

Crossrefs

Programs

  • Mathematica
    << Statistics`DescriptiveStatistics` f[n_] := Module[{d, l, a, i}, d = Divisors[n]; l = Length[d]; a = {1}; For[i = 1, i <= l - 1, i++, a = Append[a, d[[i + 1]] - d[[i]]]]; a]; Table[Floor[Mean[f[i]]], {i, 1, 100}]
    Table[Floor[n/DivisorSigma[0,n]],{n,90}] (* Harvey P. Dale, Jun 10 2016 *)
  • Python
    from sympy import divisor_count
    def A078709(n): return n//divisor_count(n) # Chai Wah Wu, Jun 03 2022

Extensions

Replaced definition with a simpler definition suggested by Reinhard Zumkeller, Feb 26 2003. The original definition is now a comment. - N. J. A. Sloane, Jun 19 2022