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.

A375535 a(n) = n - A075860(n).

Original entry on oeis.org

1, 0, 0, 2, 0, 1, 0, 6, 6, 3, 0, 7, 0, 11, 13, 14, 0, 13, 0, 13, 14, 9, 0, 19, 20, 24, 24, 25, 0, 23, 0, 30, 30, 15, 30, 31, 0, 31, 37, 33, 0, 37, 0, 31, 43, 41, 0, 43, 42, 43, 44, 50, 0, 49, 53, 53, 44, 27, 0, 53, 0, 59, 56, 62, 60, 64, 0, 49, 67, 67, 0, 67, 0, 72, 73, 69, 72, 73
Offset: 1

Views

Author

Rafik Khalfi, Aug 18 2024

Keywords

Comments

If p is a prime number, then a(p)=0.

Examples

			For n=15, a(15) = 15-2 = 13.
		

Crossrefs

Cf. A075860.

Programs

  • Maple
    f := proc(n)
        option remember:
        if isprime(n) then
            n
        else
            procname(convert(numtheory:-factorset(n), `+`))
        end if
    end proc:
    f(1) := 0:
    seq(n - f(n), n = 1..100);
  • Python
    from sympy import primefactors
    def a(n, pn):
        if n == pn:
            return n
        else:
            return a(sum(primefactors(n)), n)
    print([i-a(i, None) for i in range(1, 100)])