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.

A362864 Numbers k that divide Sum_{i=1..k} (i - d(i)), where d(n) is the number of divisors of n (A000005).

Original entry on oeis.org

1, 2, 5, 8, 15, 24, 26, 47, 121, 204, 347, 562, 4204, 6937, 6947, 31108, 379097, 379131, 379133, 2801205, 12554202, 20698345, 56264197, 13767391064, 37423648626, 37423648726, 61701166395, 276525443156, 276525443176, 455913379395, 455913379831, 751674084802
Offset: 1

Views

Author

Ctibor O. Zizka, May 06 2023

Keywords

Comments

Numbers k such that the mean number of nondivisors in the range 1..k is an integer.
Numbers k such that A161664(k) is divisible by k.
Numbers k such that (A000217(k) - A006218(k)) is divisible by k.
The subsequence of odd terms k equals the intersection of A050226 and this sequence.

Examples

			k = 5: Sum_{i=1..5} (i - d(i))/k = 5/5 = 1, so k = 5 is a term.
		

Crossrefs

Programs

  • Mathematica
    seq[kmax_] := Module[{sum = 0, s = {}}, Do[sum += k - DivisorSigma[0, k]; If[Divisible[sum, k], AppendTo[s, k]], {k, 1, kmax}]; s]; seq[10^6] (* Amiram Eldar, May 06 2023 *)
  • PARI
    isok(k) = !(sum(i=1, k, i - numdiv(i)) % k); \\ Michel Marcus, May 06 2023
    
  • Python
    from itertools import count, islice
    from sympy import divisor_count
    def A362864_gen(): # generator of terms
        c = 0
        for k in count(1):
            if not (c:=c+k-divisor_count(k))%k:
                yield k
    A362864_list = list(islice(A362864_gen(),15)) # Chai Wah Wu, May 20 2023

Extensions

More terms from Amiram Eldar, May 06 2023
a(24)-a(32) from Martin Ehrenstein, May 22 2023