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.

Previous Showing 21-30 of 64 results. Next

A069276 15-almost primes (generalization of semiprimes).

Original entry on oeis.org

32768, 49152, 73728, 81920, 110592, 114688, 122880, 165888, 172032, 180224, 184320, 204800, 212992, 248832, 258048, 270336, 276480, 278528, 286720, 307200, 311296, 319488, 373248, 376832, 387072, 401408, 405504, 414720, 417792, 430080
Offset: 1

Views

Author

Rick L. Shepherd, Mar 13 2002

Keywords

Comments

Product of 15 not necessarily distinct primes.
Divisible by exactly 15 prime powers (not including 1).
Any 15-almost prime can be represented in several ways as a product of three 5-almost primes A014614, and in several ways as a product of five 3-almost primes A014612. - Jonathan Vos Post, Dec 11 2004

Crossrefs

Sequences listing r-almost primes, that is, the n such that A001222(n) = r: A000040 (r = 1), A001358 (r = 2), A014612 (r = 3), A014613 (r = 4), A014614 (r = 5), A046306 (r = 6), A046308 (r = 7), A046310 (r = 8), A046312 (r = 9), A046314 (r = 10), A069272 (r = 11), A069273 (r = 12), A069274 (r = 13), A069275 (r = 14), this sequence (r = 15), A069277 (r = 16), A069278 (r = 17), A069279 (r = 18), A069280 (r = 19), A069281 (r = 20). - Jason Kimberley, Oct 02 2011

Programs

  • Mathematica
    Select[Range[90000], Plus @@ Last /@ FactorInteger[ # ] == 15 &] (* Vladimir Joseph Stephan Orlovsky, Apr 23 2008 *)
    Select[Range[450000],PrimeOmega[#]==15&] (* Harvey P. Dale, Aug 14 2019 *)
  • PARI
    k=15; start=2^k; finish=500000; v=[]; for(n=start,finish, if(bigomega(n)==k,v=concat(v,n))); v
    
  • Python
    from math import isqrt, prod
    from sympy import primerange, integer_nthroot, primepi
    def A069276(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 g(x,a,b,c,m): yield from (((d,) for d in enumerate(primerange(b,isqrt(x//c)+1),a)) if m==2 else (((a2,b2),)+d for a2,b2 in enumerate(primerange(b,integer_nthroot(x//c,m)[0]+1),a) for d in g(x,a2,b2,c*b2,m-1)))
        def f(x): return int(n+x-sum(primepi(x//prod(c[1] for c in a))-a[-1][0] for a in g(x,0,1,1,15)))
        return bisection(f,n,n) # Chai Wah Wu, Nov 03 2024

Formula

Product p_i^e_i with Sum e_i = 15.

A069277 16-almost primes (generalization of semiprimes).

Original entry on oeis.org

65536, 98304, 147456, 163840, 221184, 229376, 245760, 331776, 344064, 360448, 368640, 409600, 425984, 497664, 516096, 540672, 552960, 557056, 573440, 614400, 622592, 638976, 746496, 753664, 774144, 802816, 811008, 829440, 835584, 860160
Offset: 1

Views

Author

Rick L. Shepherd, Mar 13 2002

Keywords

Comments

Product of 16 not necessarily distinct primes.
Divisible by exactly 16 prime powers (not including 1).
Any 16-almost prime can be represented in several ways as a product of two 8-almost primes A046310; in several ways as a product of four 4-almost primes A014613; and in several ways as a product of eight semiprimes A001358. - Jonathan Vos Post, Dec 12 2004

Crossrefs

Sequences listing r-almost primes, that is, the n such that A001222(n) = r: A000040 (r = 1), A001358 (r = 2), A014612 (r = 3), A014613 (r = 4), A014614 (r = 5), A046306 (r = 6), A046308 (r = 7), A046310 (r = 8), A046312 (r = 9), A046314 (r = 10), A069272 (r = 11), A069273 (r = 12), A069274 (r = 13), A069275 (r = 14), A069276 (r = 15), this sequence (r = 16), A069278 (r = 17), A069279 (r = 18), A069280 (r = 19), A069281 (r = 20). - Jason Kimberley, Oct 02 2011

Programs

  • Mathematica
    Select[Range[300000], Plus @@ Last /@ FactorInteger[ # ] == 16 &] (* Vladimir Joseph Stephan Orlovsky, Apr 23 2008 *)
    Select[Range[10^6],PrimeOmega[#]==16&] (* Harvey P. Dale, Jan 30 2015 *)
  • PARI
    k=16; start=2^k; finish=1000000; v=[]; for(n=start,finish, if(bigomega(n)==k,v=concat(v,n))); v
    
  • Python
    from math import isqrt, prod
    from sympy import primerange, integer_nthroot, primepi
    def A069277(n):
        def g(x,a,b,c,m): yield from (((d,) for d in enumerate(primerange(b,isqrt(x//c)+1),a)) if m==2 else (((a2,b2),)+d for a2,b2 in enumerate(primerange(b,integer_nthroot(x//c,m)[0]+1),a) for d in g(x,a2,b2,c*b2,m-1)))
        def f(x): return int(n+x-sum(primepi(x//prod(c[1] for c in a))-a[-1][0] for a in g(x,0,1,1,16)))
        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
        return bisection(f) # Chai Wah Wu, Aug 31 2024

Formula

Product p_i^e_i with Sum e_i = 16.

A069274 13-almost primes (generalization of semiprimes).

Original entry on oeis.org

8192, 12288, 18432, 20480, 27648, 28672, 30720, 41472, 43008, 45056, 46080, 51200, 53248, 62208, 64512, 67584, 69120, 69632, 71680, 76800, 77824, 79872, 93312, 94208, 96768, 100352, 101376, 103680, 104448, 107520, 112640, 115200
Offset: 1

Views

Author

Rick L. Shepherd, Mar 13 2002

Keywords

Comments

Product of 13 not necessarily distinct primes.
Divisible by exactly 13 prime powers (not including 1).

Crossrefs

Sequences listing r-almost primes, that is, the n such that A001222(n) = r: A000040 (r = 1), A001358 (r = 2), A014612 (r = 3), A014613 (r = 4), A014614 (r = 5), A046306 (r = 6), A046308 (r = 7), A046310 (r = 8), A046312 (r = 9), A046314 (r = 10), A069272 (r = 11), A069273 (r = 12), this sequence (r = 13), A069275 (r = 14), A069276 (r = 15), A069277 (r = 16), A069278 (r = 17), A069279 (r = 18), A069280 (r = 19), A069281 (r = 20). - Jason Kimberley, Oct 02 2011

Programs

  • Mathematica
    Select[Range[30000], Plus @@ Last /@ FactorInteger[ # ] == 13 &] (* Vladimir Joseph Stephan Orlovsky, Apr 23 2008 *)
    Select[Range[116000],PrimeOmega[#]==13&] (* Harvey P. Dale, Mar 11 2019 *)
  • PARI
    k=13; start=2^k; finish=130000; v=[]; for(n=start,finish, if(bigomega(n)==k,v=concat(v,n))); v
    
  • Python
    from math import isqrt, prod
    from sympy import primerange, integer_nthroot, primepi
    def A067274(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 g(x, a, b, c, m): yield from (((d, ) for d in enumerate(primerange(b, isqrt(x//c)+1), a)) if m==2 else (((a2, b2), )+d for a2, b2 in enumerate(primerange(b, integer_nthroot(x//c, m)[0]+1), a) for d in g(x, a2, b2, c*b2, m-1)))
        def f(x): return int(n+x-sum(primepi(x//prod(c[1] for c in a))-a[-1][0] for a in g(x, 0, 1, 1, 13)))
        return bisection(f, n, n) # Chai Wah Wu, Nov 03 2024

Formula

Product p_i^e_i with Sum e_i = 13.

A069278 17-almost primes (generalization of semiprimes).

Original entry on oeis.org

131072, 196608, 294912, 327680, 442368, 458752, 491520, 663552, 688128, 720896, 737280, 819200, 851968, 995328, 1032192, 1081344, 1105920, 1114112, 1146880, 1228800, 1245184, 1277952, 1492992, 1507328, 1548288, 1605632, 1622016
Offset: 1

Views

Author

Rick L. Shepherd, Mar 13 2002

Keywords

Comments

Product of 17 not necessarily distinct primes.
Divisible by exactly 17 prime powers (not including 1).
For n = 1..2628 a(n)=2*A069277(n). - Zak Seidov, Jun 25 2017

Crossrefs

Sequences listing r-almost primes, that is, the n such that A001222(n) = r: A000040 (r = 1), A001358 (r = 2), A014612 (r = 3), A014613 (r = 4), A014614 (r = 5), A046306 (r = 6), A046308 (r = 7), A046310 (r = 8), A046312 (r = 9), A046314 (r = 10), A069272 (r = 11), A069273 (r = 12), A069274 (r = 13), A069275 (r = 14), A069276 (r = 15), A069277 (r = 16), this sequence (r = 17), A069279 (r = 18), A069280 (r = 19), A069281 (r = 20). - Jason Kimberley, Oct 02 2011

Programs

  • Mathematica
    Select[Range[2*10^6],PrimeOmega[#]==17&] (* Harvey P. Dale, Sep 28 2016 *)
  • PARI
    k=17; start=2^k; finish=2000000; v=[]
    for(n=start,finish, if(bigomega(n)==k,v=concat(v,n))); v
    
  • Python
    from math import isqrt, prod
    from sympy import primerange, integer_nthroot, primepi
    def A069278(n):
        def g(x,a,b,c,m): yield from (((d,) for d in enumerate(primerange(b,isqrt(x//c)+1),a)) if m==2 else (((a2,b2),)+d for a2,b2 in enumerate(primerange(b,integer_nthroot(x//c,m)[0]+1),a) for d in g(x,a2,b2,c*b2,m-1)))
        def f(x): return int(n+x-sum(primepi(x//prod(c[1] for c in a))-a[-1][0] for a in g(x,0,1,1,17)))
        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
        return bisection(f) # Chai Wah Wu, Aug 31 2024

Formula

Product p_i^e_i with Sum e_i = 17.

A069280 19-almost primes (generalization of semiprimes).

Original entry on oeis.org

524288, 786432, 1179648, 1310720, 1769472, 1835008, 1966080, 2654208, 2752512, 2883584, 2949120, 3276800, 3407872, 3981312, 4128768, 4325376, 4423680, 4456448, 4587520, 4915200, 4980736, 5111808, 5971968, 6029312, 6193152
Offset: 1

Views

Author

Rick L. Shepherd, Mar 13 2002

Keywords

Comments

Product of 19 not necessarily distinct primes.
Divisible by exactly 19 prime powers (not including 1).

Crossrefs

Sequences listing r-almost primes, that is, the n such that A001222(n) = r: A000040 (r = 1), A001358 (r = 2), A014612 (r = 3), A014613 (r = 4), A014614 (r = 5), A046306 (r = 6), A046308 (r = 7), A046310 (r = 8), A046312 (r = 9), A046314 (r = 10), A069272 (r = 11), A069273 (r = 12), A069274 (r = 13), A069275 (r = 14), A069276 (r = 15), A069277 (r = 16), A069278 (r = 17), A069279 (r = 18), this sequence (r = 19), A069281 (r = 20). - Jason Kimberley, Oct 02 2011

Programs

  • PARI
    k=19; start=2^k; finish=8000000; v=[]; for(n=start,finish, if(bigomega(n)==k,v=concat(v,n))); v
    
  • Python
    from math import prod, isqrt
    from sympy import primerange, integer_nthroot, primepi
    def A069280(n):
        def g(x,a,b,c,m): yield from (((d,) for d in enumerate(primerange(b,isqrt(x//c)+1),a)) if m==2 else (((a2,b2),)+d for a2,b2 in enumerate(primerange(b,integer_nthroot(x//c,m)[0]+1),a) for d in g(x,a2,b2,c*b2,m-1)))
        def f(x): return int(n-1+x-sum(primepi(x//prod(c[1] for c in a))-a[-1][0] for a in g(x,0,1,1,19)))
        kmin, kmax = 1,2
        while f(kmax) >= kmax:
            kmax <<= 1
        while True:
            kmid = kmax+kmin>>1
            if f(kmid) < kmid:
                kmax = kmid
            else:
                kmin = kmid
            if kmax-kmin <= 1:
                break
        return kmax # Chai Wah Wu, Aug 23 2024

Formula

Product p_i^e_i with Sum e_i = 19.

A101695 a(n) = n-th n-almost prime.

Original entry on oeis.org

2, 6, 18, 40, 108, 224, 480, 1296, 2688, 5632, 11520, 25600, 53248, 124416, 258048, 540672, 1105920, 2228224, 4587520, 9830400, 19922944, 40894464, 95551488, 192937984, 396361728, 822083584, 1660944384, 3397386240, 6845104128
Offset: 1

Views

Author

Jonathan Vos Post, Dec 12 2004

Keywords

Comments

A k-almost-prime is a positive integer that has exactly k prime factors, counted with multiplicity.
This is the diagonalization of the set of sequences {j-almost prime(k)}. The cumulative sums of this sequence are in A101696. This is the diagonal just below A078841.

Examples

			a(1) = first 1-almost prime = first prime = A000040(1) = 2.
a(2) = 2nd 2-almost prime = 2nd semiprime = A001358(2) = 6.
a(3) = 3rd 3-almost prime = A014612(3) = 18.
a(4) = 4th 4-almost prime = A014613(4) = 40.
a(5) = 5th 5-almost prime = A014614(5) = 108.
		

Crossrefs

Programs

  • Maple
    A101695 := proc(n)
        local s,a ;
        s := 0 ;
        for a from 2^n do
            if numtheory[bigomega](a) = n then
                s := s+1 ;
                if s = n then
                    return a;
                end if;
            end if;
        end do:
    end proc: # R. J. Mathar, Aug 09 2012
  • Mathematica
    AlmostPrimePi[k_Integer, n_] := Module[{a, i}, a[0] = 1; If[k == 1, PrimePi[n], Sum[PrimePi[n/Times @@ Prime[Array[a, k - 1]]] - a[k - 1] + 1, Evaluate[ Sequence @@ Table[{a[i], a[i - 1], PrimePi[(n/Times @@ Prime[Array[a, i - 1]])^(1/(k - i + 1))]}, {i, k - 1}]]]]]; (* Eric W. Weisstein, Feb 07 2006 *)
    AlmostPrime[k_, n_] := Block[{e = Floor[ Log[2, n] + k], a, b}, a = 2^e; Do[b = 2^p; While[ AlmostPrimePi[k, a] < n, a = a + b]; a = a - b/2, {p, e, 0, -1}]; a + b/2]; AlmostPrime[1, 1] = 2; lst = {}; Do[ AppendTo[lst, AlmostPrime[n, n]], {n, 30}]; lst (* Robert G. Wilson v, Oct 07 2007 *)
  • Python
    from math import prod, isqrt
    from sympy import primerange, primepi, integer_nthroot
    def A101695(n):
        if n == 1: return 2
        def g(x,a,b,c,m): yield from (((d,) for d in enumerate(primerange(b,isqrt(x//c)+1),a)) if m==2 else (((a2,b2),)+d for a2,b2 in enumerate(primerange(b,integer_nthroot(x//c,m)[0]+1),a) for d in g(x,a2,b2,c*b2,m-1)))
        def f(x): return int(n-1+x-sum(primepi(x//prod(c[1] for c in a))-a[-1][0] for a in g(x,0,1,1,n)))
        kmin, kmax = 1,2
        while f(kmax) >= kmax:
            kmax <<= 1
        while True:
            kmid = kmax+kmin>>1
            if f(kmid) < kmid:
                kmax = kmid
            else:
                kmin = kmid
            if kmax-kmin <= 1:
                break
        return kmax # Chai Wah Wu, Aug 23 2024

Formula

Conjecture: lim_{ n->inf.} a(n+1)/a(n) = 2. - Robert G. Wilson v, Oct 07 2007, Nov 13 2007
Stronger conjecture: a(n)/(n * 2^n) is polylogarithmic in n. That is, there exist real numbers b < c such that (log n)^b < a(n)/(n * 2^n) < (log n)^c for large enough n. Probably b and c can be chosen close to 0. - Charles R Greathouse IV, Aug 28 2012

Extensions

a(21)-a(30) from Robert G. Wilson v, Feb 11 2006
a(12) corrected by N. J. A. Sloane, Nov 23 2007

A162142 Numbers that are the cube of a product of two distinct primes (p^3*q^3).

Original entry on oeis.org

216, 1000, 2744, 3375, 9261, 10648, 17576, 35937, 39304, 42875, 54872, 59319, 97336, 132651, 166375, 185193, 195112, 238328, 274625, 328509, 405224, 456533, 551368, 614125, 636056, 658503, 753571, 804357, 830584, 857375, 1191016, 1367631, 1520875, 1643032
Offset: 1

Views

Author

Keywords

Comments

Subset of A046306, of A000578, and of A007774. - R. J. Mathar, Jun 27 2009

Examples

			216=2^3*3^3. 1000=2^3*5^3. 2744=2^3*7^3.
		

Crossrefs

Programs

  • Mathematica
    fQ[n_]:=Last/@FactorInteger[n]=={3,3}; lst={};Do[If[fQ[n],AppendTo[lst, n]],{n,6*9!}];lst
    With[{nn=30},Select[Union[(Times@@@Subsets[Prime[Range[nn]],{2}])^3],#<= (2Prime[ nn])^3&]](* Harvey P. Dale, May 27 2024 *)
  • Python
    from math import isqrt
    from sympy import primepi, primerange
    def A162142(n):
        def f(x): return int(n+x+(t:=primepi(s:=isqrt(x)))+(t*(t-1)>>1)-sum(primepi(x//k) for k in primerange(1, s+1)))
        m, k = n, f(n)
        while m != k: m, k = k, f(k)
        return m**3 # Chai Wah Wu, Dec 09 2024

Formula

a(n) = (A006881(n))^3 = A000578(A006881(n)). - R. J. Mathar, Jun 27 2009
Sum_{n>=1} 1/a(n) = (P(3)^2 - P(6))/2 = (A085541^2 - A085966)/2 = 0.006735..., where P is the prime zeta function. - Amiram Eldar, Jul 06 2020

Extensions

Definition rephrased by R. J. Mathar, Jun 27 2009

A110231 6-almost primes p * q * r * s * t * u relatively prime to p+q+r+s+t+u.

Original entry on oeis.org

96, 224, 352, 360, 416, 486, 504, 544, 600, 608, 736, 792, 810, 928, 936, 992, 1000, 1176, 1184, 1224, 1312, 1368, 1376, 1400, 1504, 1656, 1696, 1701, 1782, 1888, 1890, 1952, 2025, 2040, 2088, 2144, 2184, 2200, 2232, 2250, 2272, 2336, 2528, 2600, 2646
Offset: 1

Views

Author

Jonathan Vos Post, Jul 17 2005

Keywords

Comments

p, q, r, s, t, u are not necessarily distinct. The converse to this is A110232: 6-almost primes p * q * r * s * t * u which are not relatively prime to p+q+r+s+t+u. A046306 is the 6-almost primes.

Examples

			96 is an element of this sequence because 96 = 2^5 * 3, the sum of whose prime factors is 2 + 2 + 2 + 2 + 2 + 3 = 13, which has no prime factors in common with 96.
		

Crossrefs

Programs

  • PARI
    list(lim)=my(v=List()); forprime(p=2, lim\32, forprime(q=2, min(p, lim\16\p), my(pq=p*q); forprime(r=2, min(lim\pq\8, q), my(pqr=pq*r); forprime(s=2, min(lim\pqr\4, r), my(pqrs=pqr*s); forprime(t=2,min(lim\pqrs\2,s), my(pqrst=pqrs*t,n); forprime(u=2,min(lim\pqrst,t), n=pqrst*u; if(gcd(n, p+q+r+s+t+u)==1, listput(v, n)))))))); Set(v) \\ Charles R Greathouse IV, Jan 31 2017

Extensions

Extended by Ray Chandler, Jul 20 2005

A110232 6-almost primes p * q * r * s * t * u not relatively prime to p+q+r+s+t+u.

Original entry on oeis.org

64, 144, 160, 216, 240, 324, 336, 400, 528, 540, 560, 624, 729, 756, 784, 816, 840, 880, 900, 912, 1040, 1104, 1134, 1188, 1215, 1232, 1260, 1320, 1350, 1360, 1392, 1404, 1456, 1488, 1500, 1520, 1560, 1764, 1776, 1836, 1840, 1848, 1904, 1936, 1960, 1968
Offset: 1

Views

Author

Jonathan Vos Post, Jul 17 2005

Keywords

Comments

p, q, r, s, t, u are not necessarily distinct. The converse to this is A110231: 6-almost primes p * q * r * s * t * u which are relatively prime to p+q+r+s+t+u. A046306 is the 6-almost primes.

Examples

			160 is in this sequence because 160 = 2^5 * 5, the sum of whose prime factors is 2 + 2 + 2 + 2 + 2 + 5 = 15 = 3 * 5, which has a prime factor in common with 160.
		

Crossrefs

Programs

  • PARI
    list(lim)=my(v=List()); forprime(p=2, lim\16, forprime(q=2, min(p, lim\8\p), my(pq=p*q); forprime(r=2, min(lim\pq\4, q), my(pqr=pq*r); forprime(s=2, min(lim\pqr\2, r), my(pqrs=pqr*s); forprime(t=2,min(lim\pqrs,s), my(pqrst=pqrs*t,n); forprime(u=2,min(lim\pqrst,t), n=pqrst*u; if(gcd(n, p+q+r+s+t+u)>1, listput(v, n)))))))); Set(v) \\ Charles R Greathouse IV, Jan 31 2017

Extensions

Extended by Ray Chandler, Jul 20 2005

A091538 Triangle built from m-primes as columns.

Original entry on oeis.org

1, 0, 2, 0, 3, 4, 0, 5, 6, 8, 0, 7, 9, 12, 16, 0, 11, 10, 18, 24, 32, 0, 13, 14, 20, 36, 48, 64, 0, 17, 15, 27, 40, 72, 96, 128, 0, 19, 21, 28, 54, 80, 144, 192, 256, 0, 23, 22, 30, 56, 108, 160, 288, 384, 512, 0, 29, 25, 42, 60, 112, 216, 320, 576, 768, 1024
Offset: 0

Views

Author

Wolfdieter Lang, Feb 13 2004

Keywords

Comments

m-primes (also called m-almost primes) are the numbers which have precisely m prime factors counting multiple factors. 1 is included as 0-prime.
The number N>=1 appears in column no. m = A001222(N).

Examples

			From _Michael De Vlieger_, May 24 2017: (Start)
Chart a(n,m) read by antidiagonals:
  n | m ->
  ------------------------------------------------
  0 |    1     0     0     0     0     0     0 ... (A000007)
  1 |    2     3     5     7    11    13    17     (A000040)
  2 |    4     6     9    10    14    15    21     (A001358)
  3 |    8    12    18    20    27    28    30     (A014612)
  4 |   16    24    36    40    54    56    60     (A014613)
  5 |   32    48    72    80   108   112   120     (A014614)
  6 |   64    96   144   160   216   224   240     (A046306)
  7 |  128   192   288   320   432   448   480     (A046308)
  8 |  256   384   576   640   864   896   960     (A046310)
       ...
Triangle begins:
  0 |    1
  1 |    0    2
  2 |    0    3    4
  3 |    0    5    6    8
  4 |    0    7    9   12   16
  5 |    0   11   10   18   24   32
  6 |    0   13   14   20   36   48    64
  7 |    0   17   15   27   40   72    96   128
  8 |    0   19   21   28   54   80   144   192   256
       ...
(End)
		

Crossrefs

The column sequences (without leading zeros) are: A000007, A000040 (primes), A001358, A014612-4, A046306, A046308, A046310, A046312, A046314, A069272-A069281 for m=0..20, respectively.
A078840 is this table with the zeros omitted.

Programs

  • Mathematica
    With[{nn = 11}, Function[s, Function[t, Table[Function[m, If[m == 1, Boole[k == 1], t[[m, k]]]][n - k + 1], {n, nn}, {k, n, 1, -1}]]@ Map[Position[s, #][[All, 1]] &, Range[0, nn]]]@ PrimeOmega@ Range[2^nn]] (* or *)
    a = {1}; Do[Block[{r = {Prime@ n}}, Do[AppendTo[r, SelectFirst[ Range[a[[-(n - i)]] + 1, 2^n], PrimeOmega@ # == i &]], {i, 2, n - 1}]; a = Join[a, {0}, If[n == 1, {}, r], {2^n}]], {n, 11}]; a (* Michael De Vlieger, May 24 2017 *)
  • Python
    from math import isqrt, comb, prod
    from sympy import prime, primerange, integer_nthroot, primepi
    def A091538(n):
        a = (m:=isqrt(k:=n+1<<1))+(k>m*(m+1))
        r = n-comb(a,2)
        w = a-r
        if r==0: return int(w==1)
        if r==1: return prime(w)
        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 g(x,a,b,c,m): yield from (((d,) for d in enumerate(primerange(b,isqrt(x//c)+1),a)) if m==2 else (((a2,b2),)+d for a2,b2 in enumerate(primerange(b,integer_nthroot(x//c,m)[0]+1),a) for d in g(x,a2,b2,c*b2,m-1)))
        def f(x): return int(w+x-sum(primepi(x//prod(c[1] for c in a))-a[-1][0] for a in g(x,0,1,1,r)))
        return bisection(f,w,w) # Chai Wah Wu, Jun 11 2025

Formula

For n>=m>=1: a(n, m)= (n-m+1)-th member in the strictly monotonically increasing sequence of numbers N satisfying: N=product(p(k)^(e_k), k=1..) with p(k) := A000040(k) (k-th prime) such that sum(e_k, k=1..) = m, where the e_k are nonnegative. if m=0 : a(n, 0)=1 if n=0 else 0. If n
Previous Showing 21-30 of 64 results. Next