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.

A336615 Numbers of the form p * m^2, where p is prime and m > 0 is not divisible by p.

Original entry on oeis.org

2, 3, 5, 7, 11, 12, 13, 17, 18, 19, 20, 23, 28, 29, 31, 37, 41, 43, 44, 45, 47, 48, 50, 52, 53, 59, 61, 63, 67, 68, 71, 73, 75, 76, 79, 80, 83, 89, 92, 97, 98, 99, 101, 103, 107, 109, 112, 113, 116, 117, 124, 127, 131, 137, 139, 147, 148, 149, 151, 153, 157, 162
Offset: 1

Views

Author

Amiram Eldar, Jul 27 2020

Keywords

Comments

Numbers k such that A008833(k) is a unitary divisor of k and A007913(k) = k / A008833(k) is a prime number.

Crossrefs

Intersection of A229125 and A335275.
Subsequences: A000040, A054753, A179643.

Programs

  • Mathematica
    Select[Range[2, 200], Select[FactorInteger[#][[;;, 2]], OddQ] == {1} &]
  • Python
    from math import isqrt
    from sympy import primepi, primefactors
    def A336615(n):
        def bisection(f,kmin=0,kmax=1):
            while f(kmax) > kmax: kmax <<= 1
            kmin = kmax >> 1
            while kmax-kmin > 1:
                kmid = kmax+kmin>>1
                if f(kmid) <= kmid:
                    kmax = kmid
                else:
                    kmin = kmid
            return kmax
        def f(x): return n+x-sum(primepi(m:=x//y**2)-sum(1 for p in primefactors(y) if p<=m) for y in range(1,isqrt(x)+1))
        return bisection(f,n,n) # Chai Wah Wu, Jan 30 2025

Formula

The number of terms not exceeding x is (Pi^2/6) * x/log(x) + O(x/(log(x))^2) (Cohen, 1962).