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.

A333978 Numbers of the form b_1 * b_2 * ... * b_t, where b_1 = 1 and b_(i + 1) - b_i = 0 or 1.

Original entry on oeis.org

1, 2, 4, 6, 8, 12, 16, 18, 24, 32, 36, 48, 54, 64, 72, 96, 108, 120, 128, 144, 162, 192, 216, 240, 256, 288, 324, 360, 384, 432, 480, 486, 512, 576, 600, 648, 720, 768, 864, 960, 972, 1024, 1080, 1152, 1200, 1296, 1440, 1458, 1536, 1728, 1800, 1920, 1944, 2048
Offset: 1

Views

Author

Peter Kagey, Sep 20 2020

Keywords

Comments

This sequence gives the distinct values in A284001, sorted.
If m and k are in this sequence, then so is their product m*k.
If a prime p divides a(n), then so does p!.
A001013 is a subsequence.
Define a set S of polynomials by: (i) 1 is in S; (ii) if P is in S, then x*P and dP/dx are in S; (iii) if the repeated application of (i) and (ii) fails to prove that P is in S then P is not in S. This sequence enumerates the elements of S of degree 0. - Luc Rousseau, Aug 20 2022
Numbers k divisible by A102068(k) (or in other words, numbers k divisible by h(k)! where h(k) is the largest prime factor of k). - David A. Corneth, Aug 20 2022

Examples

			The first 11 terms can be written as
   1 = 1
   2 = 1 * 2
   4 = 1 * 2 * 2
   6 = 1 * 2 * 3
   8 = 1 * 2 * 2 * 2
  12 = 1 * 2 * 2 * 3
  16 = 1 * 2 * 2 * 2 * 2
  18 = 1 * 2 * 3 * 3
  24 = 1 * 2 * 3 * 4 or 1 * 2 * 2 * 2 * 3
  32 = 1 * 2 * 2 * 2 * 2 * 2
  36 = 1 * 2 * 2 * 3 * 3
		

Crossrefs

Programs

  • PARI
    is(n) = if(n==1, return(1)); my(f = factor(n), p = f[#f~, 1]); n%p! == 0 \\ David A. Corneth, Sep 05 2022
  • Python
    import heapq
    from math import factorial
    from sympy import nextprime
    from itertools import islice
    def agen(): # generator of terms
        oldv, h, primes, nextp, nextfact = 0, [(1, 1)], [], 0, 0
        while True:
            v, maxp = heapq.heappop(h)
            if v != oldv:
                yield v; oldv = v
                while nextfact < v:
                    nextp = nextprime(nextp); nextfact = factorial(nextp)
                    primes.append(nextp); heapq.heappush(h, (nextfact, nextp))
                for p in primes:
                    if p <= maxp: heapq.heappush(h, (v*p, max(maxp, p)))
                    else: break
    print(list(islice(agen(), 60))) # Michael S. Branicky, Aug 20 2022