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.

A080194 7-smooth numbers which are not 5-smooth.

Original entry on oeis.org

7, 14, 21, 28, 35, 42, 49, 56, 63, 70, 84, 98, 105, 112, 126, 140, 147, 168, 175, 189, 196, 210, 224, 245, 252, 280, 294, 315, 336, 343, 350, 378, 392, 420, 441, 448, 490, 504, 525, 560, 567, 588, 630, 672, 686, 700, 735, 756, 784, 840, 875, 882, 896, 945, 980
Offset: 1

Views

Author

Klaus Brockhaus, Feb 10 2003

Keywords

Comments

Numbers of the form 7*2^r*3^s*5^t*7^u with r, s, t, u >= 0.
Multiples of 7 which are members of A002473. Or multiples of 7 with the largest prime divisor < 10.
Numbers whose greatest prime factor (A006530) is 7. - M. F. Hasler, Nov 21 2018

Examples

			28 = 2^2*7 is a term but 30 = 2*3*5 is not.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[999], FactorInteger[#][[-1, 1]] == 7 &] (* Giovanni Resta, Nov 22 2018 *)
  • PARI
    A080194_list(M)={my(L=List(),a,b,c); for(r=1,logint(M\1,7), a=7^r; for(s=0, logint(M\a,3), b=a*3^s; for(t=0,logint(M\b,5), c=b*5^t; for(u=0,logint(M\c,2), listput(L,c<A051037. - Edited by M. F. Hasler, Nov 22 2018
    
  • PARI
    select( is_A080194(n)={n>1 && vecmax(factor(n,7)[,1])==7}, [0..10^3]) \\ Defines is_A080194(), used elsewhere. The select() command is a check and illustration. For longer lists, use list() above. - M. F. Hasler, Nov 21 2018
    
  • Python
    from sympy import integer_log
    def A080194(n):
        def bisection(f,kmin=0,kmax=1):
            while f(kmax) > kmax: kmax <<= 1
            while kmax-kmin > 1:
                kmid = kmax+kmin>>1
                if f(kmid) <= kmid:
                    kmax = kmid
                else:
                    kmin = kmid
            return kmax
        def f(x):
            c = n+x
            for i in range(integer_log(x,7)[0]+1):
                for j in range(integer_log(m:=x//7**i,5)[0]+1):
                    for k in range(integer_log(r:=m//5**j,3)[0]+1):
                        c -= (r//3**k).bit_length()
            return c
        return bisection(f,n,n)*7 # Chai Wah Wu, Sep 17 2024
    
  • Python
    # faster for initial segment of sequence
    import heapq
    from itertools import islice
    from sympy import primerange
    def A080194gen(p=7): # generator of terms
        v, oldv, h, psmooth_primes, = 1, 0, [1], list(primerange(1, p+1))
        while True:
            v = heapq.heappop(h)
            if v != oldv:
                yield 7*v
                oldv = v
                for p in psmooth_primes:
                    heapq.heappush(h, v*p)
    print(list(islice(A080194gen(), 65))) # Michael S. Branicky, Sep 17 2024

Formula

a(n) = 7 * A002473(n). - David A. Corneth, Nov 22 2018
Sum_{n>=1} 1/a(n) = 5/8. - Amiram Eldar, Nov 10 2020