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.

Showing 1-10 of 20 results. Next

A007304 Sphenic numbers: products of 3 distinct primes.

Original entry on oeis.org

30, 42, 66, 70, 78, 102, 105, 110, 114, 130, 138, 154, 165, 170, 174, 182, 186, 190, 195, 222, 230, 231, 238, 246, 255, 258, 266, 273, 282, 285, 286, 290, 310, 318, 322, 345, 354, 357, 366, 370, 374, 385, 399, 402, 406, 410, 418, 426, 429, 430, 434, 435, 438
Offset: 1

Views

Author

Keywords

Comments

Note the distinctions between this and "n has exactly three prime factors" (A014612) or "n has exactly three distinct prime factors." (A033992). The word "sphenic" also means "shaped like a wedge" [American Heritage Dictionary] as in dentation with "sphenic molars." - Jonathan Vos Post, Sep 11 2005
Also the volume of a sphenic brick. A sphenic brick is a rectangular parallelepiped whose sides are components of a sphenic number, namely whose sides are three distinct primes. Example: The distinct prime triple (3,5,7) produces a 3x5x7 unit brick which has volume 105 cubic units. 3-D analog of 2-D A037074 Product of twin primes, per Cino Hilliard's comment. Compare with 3-D A107768 Golden 3-almost primes = Volumes of bricks (rectangular parallelepipeds) each of whose faces has golden semiprime area. - Jonathan Vos Post, Jan 08 2007
Sum(n>=1, 1/a(n)^s) = (1/6)*(P(s)^3 - P(3*s) - 3*(P(s)*P(2*s)-P(3*s))), where P is prime zeta function. - Enrique Pérez Herrero, Jun 28 2012
Also numbers n with A001222(n)=3 and A001221(n)=3. - Enrique Pérez Herrero, Jun 28 2012
n = 265550 is the smallest n with a(n) (=1279789) < A006881(n) (=1279793). - Peter Dolland, Apr 11 2020

Examples

			From _Gus Wiseman_, Nov 05 2020: (Start)
Also Heinz numbers of strict integer partitions into three parts, where the Heinz number of a partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k). These partitions are counted by A001399(n-6) = A069905(n-3), with ordered version A001399(n-6)*6. The sequence of terms together with their prime indices begins:
     30: {1,2,3}     182: {1,4,6}     286: {1,5,6}
     42: {1,2,4}     186: {1,2,11}    290: {1,3,10}
     66: {1,2,5}     190: {1,3,8}     310: {1,3,11}
     70: {1,3,4}     195: {2,3,6}     318: {1,2,16}
     78: {1,2,6}     222: {1,2,12}    322: {1,4,9}
    102: {1,2,7}     230: {1,3,9}     345: {2,3,9}
    105: {2,3,4}     231: {2,4,5}     354: {1,2,17}
    110: {1,3,5}     238: {1,4,7}     357: {2,4,7}
    114: {1,2,8}     246: {1,2,13}    366: {1,2,18}
    130: {1,3,6}     255: {2,3,7}     370: {1,3,12}
    138: {1,2,9}     258: {1,2,14}    374: {1,5,7}
    154: {1,4,5}     266: {1,4,8}     385: {3,4,5}
    165: {2,3,5}     273: {2,4,6}     399: {2,4,8}
    170: {1,3,7}     282: {1,2,15}    402: {1,2,19}
    174: {1,2,10}    285: {2,3,8}     406: {1,4,10}
(End)
		

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
  • "Sphenic", The American Heritage Dictionary of the English Language, Fourth Edition, Houghton Mifflin Company, 2000.

Crossrefs

Products of exactly k distinct primes, for k = 1 to 6: A000040, A006881. A007304, A046386, A046387, A067885.
Cf. A162143 (a(n)^2).
For the following, NNS means "not necessarily strict".
A014612 is the NNS version.
A046389 is the restriction to odds (NNS: A046316).
A075819 is the restriction to evens (NNS: A075818).
A239656 gives first differences.
A285508 lists terms of A014612 that are not squarefree.
A307534 is the case where all prime indices are odd (NNS: A338471).
A337453 is a different ranking of ordered triples (NNS: A014311).
A338557 is the case where all prime indices are even (NNS: A338556).
A001399(n-6) counts strict 3-part partitions (NNS: A001399(n-3)).
A005117 lists squarefree numbers.
A008289 counts strict partitions by sum and length.
A220377 counts 3-part pairwise coprime strict partitions (NNS: A307719).

Programs

  • Haskell
    a007304 n = a007304_list !! (n-1)
    a007304_list = filter f [1..] where
    f u = p < q && q < w && a010051 w == 1 where
    p = a020639 u; v = div u p; q = a020639 v; w = div v q
    -- Reinhard Zumkeller, Mar 23 2014
    
  • Maple
    with(numtheory): a:=proc(n) if bigomega(n)=3 and nops(factorset(n))=3 then n else fi end: seq(a(n),n=1..450); # Emeric Deutsch
    A007304 := proc(n)
        option remember;
        local a;
        if n =1 then
            30;
        else
            for a from procname(n-1)+1 do
                if bigomega(a)=3 and nops(factorset(a))=3 then
                    return a;
                end if;
            end do:
        end if;
    end proc: # R. J. Mathar, Dec 06 2016
    is_a := proc(n) local P; P := NumberTheory:-PrimeFactors(n); nops(P) = 3 and n = mul(P) end:
    A007304List := upto -> select(is_a, [seq(1..upto)]):  # Peter Luschny, Apr 14 2025
  • Mathematica
    Union[Flatten[Table[Prime[n]*Prime[m]*Prime[k], {k, 20}, {n, k+1, 20}, {m, n+1, 20}]]]
    Take[ Sort@ Flatten@ Table[ Prime@i Prime@j Prime@k, {i, 3, 21}, {j, 2, i - 1}, {k, j - 1}], 53] (* Robert G. Wilson v *)
    With[{upto=500},Sort[Select[Times@@@Subsets[Prime[Range[Ceiling[upto/6]]],{3}],#<=upto&]]] (* Harvey P. Dale, Jan 08 2015 *)
    Select[Range[100],SquareFreeQ[#]&&PrimeOmega[#]==3&] (* Gus Wiseman, Nov 05 2020 *)
  • PARI
    for(n=1,1e4,if(bigomega(n)==3 && omega(n)==3,print1(n", "))) \\ Charles R Greathouse IV, Jun 10 2011
    
  • PARI
    list(lim)=my(v=List(),t);forprime(p=2,(lim)^(1/3),forprime(q=p+1,sqrt(lim\p),t=p*q;forprime(r=q+1,lim\t,listput(v,t*r))));vecsort(Vec(v)) \\ Charles R Greathouse IV, Jul 20 2011
    
  • PARI
    list(lim)=my(v=List(), t); forprime(p=2, sqrtnint(lim\=1,3), forprime(q=p+1, sqrtint(lim\p), t=p*q; forprime(r=q+1, lim\t, listput(v, t*r)))); Set(v) \\ Charles R Greathouse IV, Jan 21 2025
    
  • Python
    from math import isqrt
    from sympy import primepi, primerange, integer_nthroot
    def A007304(n):
        def f(x): return int(n+x-sum(primepi(x//(k*m))-b for a,k in enumerate(primerange(integer_nthroot(x,3)[0]+1),1) for b,m in enumerate(primerange(k+1,isqrt(x//k)+1),a+1)))
        kmin, kmax = 0,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 # Chai Wah Wu, Aug 29 2024
    
  • SageMath
    def is_a(n):
        P = prime_divisors(n)
        return len(P) == 3 and prod(P) == n
    print([n for n in range(1, 439) if is_a(n)]) # Peter Luschny, Apr 14 2025

Formula

A008683(a(n)) = -1.
A000005(a(n)) = 8. - R. J. Mathar, Aug 14 2009
A002033(a(n)-1) = 13. - Juri-Stepan Gerasimov, Oct 07 2009, R. J. Mathar, Oct 14 2009
A178254(a(n)) = 36. - Reinhard Zumkeller, May 24 2010
A050326(a(n)) = 5, subsequence of A225228. - Reinhard Zumkeller, May 03 2013
a(n) ~ 2n log n/(log log n)^2. - Charles R Greathouse IV, Sep 14 2015

Extensions

More terms from Robert G. Wilson v, Jan 04 2006
Comment concerning number of divisors corrected by R. J. Mathar, Aug 14 2009

A101296 n has the a(n)-th distinct prime signature.

Original entry on oeis.org

1, 2, 2, 3, 2, 4, 2, 5, 3, 4, 2, 6, 2, 4, 4, 7, 2, 6, 2, 6, 4, 4, 2, 8, 3, 4, 5, 6, 2, 9, 2, 10, 4, 4, 4, 11, 2, 4, 4, 8, 2, 9, 2, 6, 6, 4, 2, 12, 3, 6, 4, 6, 2, 8, 4, 8, 4, 4, 2, 13, 2, 4, 6, 14, 4, 9, 2, 6, 4, 9, 2, 15, 2, 4, 6, 6, 4, 9, 2, 12, 7, 4, 2, 13, 4, 4, 4, 8, 2, 13, 4, 6, 4, 4, 4, 16, 2, 6, 6, 11, 2, 9, 2, 8, 9, 4, 2, 15, 2, 9, 4, 12, 2, 9, 4, 6, 6, 4, 4, 17
Offset: 1

Views

Author

David Wasserman, Dec 21 2004

Keywords

Comments

From Antti Karttunen, May 12 2017: (Start)
Restricted growth sequence transform of A046523, the least representative of each prime signature. Thus this partitions the natural numbers to the same equivalence classes as A046523, i.e., for all i, j: a(i) = a(j) <=> A046523(i) = A046523(j), and for that reason satisfies in that respect all the same conditions as A046523. For example, we have, for all i, j: if a(i) = a(j), then:
A000005(i) = A000005(j), A008683(i) = A008683(j), A286605(i) = A286605(j).
So, this sequence (instead of A046523) can be used for finding sequences where a(n)'s value is dependent only on the prime signature of n, that is, only on the multiset of prime exponents in the factorization of n. (End)
This is also the restricted growth sequence transform of many other sequences, for example, that of A181819. See further comments there. - Antti Karttunen, Apr 30 2022

Examples

			From _David A. Corneth_, May 12 2017: (Start)
1 has prime signature (), the first distinct prime signature. Therefore, a(1) = 1.
2 has prime signature (1), the second distinct prime signature after (1). Therefore, a(2) = 2.
3 has prime signature (1), as does 2. Therefore, a(3) = a(2) = 2.
4 has prime signature (2), the third distinct prime signature after () and (1). Therefore, a(4) = 3. (End)
From _Antti Karttunen_, May 12 2017: (Start)
Construction of restricted growth sequences: In this case we start with a(1) = 1 for A046523(1) = 1, and thereafter, for all n > 1, we use the least so far unused natural number k for a(n) if A046523(n) has not been encountered before, otherwise [whenever A046523(n) = A046523(m), for some m < n], we set a(n) = a(m).
For n = 2, A046523(2) = 2, which has not been encountered before (first prime), thus we allot for a(2) the least so far unused number, which is 2, thus a(2) = 2.
For n = 3, A046523(2) = 2, which was already encountered as A046523(1), thus we set a(3) = a(2) = 2.
For n = 4, A046523(4) = 4, not encountered before (first square of prime), thus we allot for a(4) the least so far unused number, which is 3, thus a(4) = 3.
For n = 5, A046523(5) = 2, as for the first time encountered at n = 2, thus we set a(5) = a(2) = 2.
For n = 6, A046523(6) = 6, not encountered before (first semiprime pq with distinct p and q), thus we allot for a(6) the least so far unused number, which is 4, thus a(6) = 4.
For n = 8, A046523(8) = 8, not encountered before (first cube of a prime), thus we allot for a(8) the least so far unused number, which is 5, thus a(8) = 5.
For n = 9, A046523(9) = 4, as for the first time encountered at n = 4, thus a(9) = 3.
(End)
From _David A. Corneth_, May 12 2017: (Start)
(Rough) description of an algorithm of computing the sequence:
Suppose we want to compute a(n) for n in [1..20].
We set up a vector of 20 elements, values 0, and a number m = 1, the minimum number we haven't checked and c = 0, the number of distinct prime signatures we've found so far.
[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
We check the prime signature of m and see that it's (). We increase c with 1 and set all elements up to 20 with prime signature () to 1. In the process, we adjust m. This gives:
[1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]. The least number we haven't checked is m = 2. 2 has prime signature (1). We increase c with 1 and set all elements up to 20 with prime signature (1) to 2. In the process, we adjust m. This gives:
[1, 2, 2, 0, 2, 0, 2, 0, 0, 0, 2, 0, 2, 0, 0, 0, 2, 0, 2, 0]
We check the prime signature of m = 4 and see that its prime signature is (2). We increase c with 1 and set all numbers up to 20 with prime signature (2) to 3. This gives:
[1, 2, 2, 3, 2, 0, 2, 0, 3, 0, 2, 0, 2, 0, 0, 0, 2, 0, 2, 0]
Similarily, after m = 6, we get
[1, 2, 2, 3, 2, 4, 2, 0, 3, 4, 2, 0, 2, 4, 4, 0, 2, 0, 2, 0], after m = 8 we get:
[1, 2, 2, 3, 2, 4, 2, 5, 3, 4, 2, 0, 2, 4, 4, 0, 2, 0, 2, 0], after m = 12 we get:
[1, 2, 2, 3, 2, 4, 2, 5, 3, 4, 2, 6, 2, 4, 4, 0, 2, 6, 2, 0], after m = 16 we get:
[1, 2, 2, 3, 2, 4, 2, 5, 3, 4, 2, 6, 2, 4, 4, 7, 2, 6, 2, 0], after m = 20 we get:
[1, 2, 2, 3, 2, 4, 2, 5, 3, 4, 2, 6, 2, 4, 4, 7, 2, 6, 2, 8]. Now, m > 20 so we stop. (End)
The above method is inefficient, because the step "set all elements a(n) up to n = Nmax with prime signature s(n) = S[c] to c" requires factoring all integers up to Nmax (or at least comparing their signature, once computed, with S[c]) again and again. It is much more efficient to run only once over each m = 1..Nmax, compute its prime signature s(m), add it to an ordered list in case it did not occur earlier, together with its "rank" (= new size of the list), and assign that rank to a(m). The list of prime signatures is much shorter than [1..Nmax]. One can also use m'(m) := the smallest n with the prime signature of m (which is faster to compute than to search for the signature) as representative for s(m), and set a(m) := a(m'(m)). Then it is sufficient to have just one counter (number of prime signatures seen so far) as auxiliary variable, in addition to the sequence to be computed. - _M. F. Hasler_, Jul 18 2019
		

Crossrefs

Cf. A025487, A046523, A064839 (ordinal transform of this sequence), A181819, and arrays A095904, A179216.
Sequences that are unions of finite number (>= 2) of equivalence classes determined by the values that this sequence obtains (i.e., sequences mentioned in David A. Corneth's May 12 2017 formula): A001358 (A001248 U A006881, values 3 & 4), A007422 (values 1, 4, 5), A007964 (2, 3, 4, 5), A014612 (5, 6, 9), A030513 (4, 5), A037143 (1, 2, 3, 4), A037144 (1, 2, 3, 4, 5, 6, 9), A080258 (6, 7), A084116 (2, 4, 5), A167171 (2, 4), A217856 (6, 9).
Cf. also A077462, A305897 (stricter variants, with finer partitioning) and A254524, A286603, A286605, A286610, A286619, A286621, A286622, A286626, A286378 for other similarly constructed sequences.

Programs

  • Maple
    A101296 := proc(n)
        local a046523, a;
        a046523 := A046523(n) ;
        for a from 1 do
            if A025487(a) = a046523 then
                return a;
            elif A025487(a) > a046523 then
                return -1 ;
            end if;
        end do:
    end proc: # R. J. Mathar, May 26 2017
  • Mathematica
    With[{nn = 120}, Function[s, Table[Position[Keys@s, k_ /; MemberQ[k, n]][[1, 1]], {n, nn}]]@ Map[#1 -> #2 & @@ # &, Transpose@ {Values@ #, Keys@ #}] &@ PositionIndex@ Table[Times @@ MapIndexed[Prime[First@ #2]^#1 &, Sort[FactorInteger[n][[All, -1]], Greater]] - Boole[n == 1], {n, nn}] ] (* Michael De Vlieger, May 12 2017, Version 10 *)
  • PARI
    find(ps, vps) = {for (k=1, #vps, if (vps[k] == ps, return(k)););}
    lisps(nn) = {vps = []; for (n=1, nn, ps = vecsort(factor(n)[,2]); ips = find(ps, vps); if (! ips, vps = concat(vps, ps); ips = #vps); print1(ips, ", "););} \\ Michel Marcus, Nov 15 2015; edited by M. F. Hasler, Jul 16 2019
    
  • PARI
    rgs_transform(invec) = { my(occurrences = Map(), outvec = vector(length(invec)), u=1); for(i=1, length(invec), if(mapisdefined(occurrences,invec[i]), my(pp = mapget(occurrences, invec[i])); outvec[i] = outvec[pp] , mapput(occurrences,invec[i],i); outvec[i] = u; u++ )); outvec; };
    write_to_bfile(start_offset,vec,bfilename) = { for(n=1, length(vec), write(bfilename, (n+start_offset)-1, " ", vec[n])); }
    write_to_bfile(1,rgs_transform(vector(100000,n,A046523(n))),"b101296.txt");
    \\ Antti Karttunen, May 12 2017

Formula

A025487(a(n)) = A046523(n).
Indices of records give A025487. - Michel Marcus, Nov 16 2015
From David A. Corneth, May 12 2017: (Start) [Corresponding characteristic function in brackets]
a(A000012(n)) = 1 (sig.: ()). [A063524]
a(A000040(n)) = 2 (sig.: (1)). [A010051]
a(A001248(n)) = 3 (sig.: (2)). [A302048]
a(A006881(n)) = 4 (sig.: (1,1)). [A280710]
a(A030078(n)) = 5 (sig.: (3)).
a(A054753(n)) = 6 (sig.: (1,2)). [A353472]
a(A030514(n)) = 7 (sig.: (4)).
a(A065036(n)) = 8 (sig.: (1,3)).
a(A007304(n)) = 9 (sig.: (1,1,1)). [A354926]
a(A050997(n)) = 10 (sig.: (5)).
a(A085986(n)) = 11 (sig.: (2,2)).
a(A178739(n)) = 12 (sig.: (1,4)).
a(A085987(n)) = 13 (sig.: (1,1,2)).
a(A030516(n)) = 14 (sig.: (6)).
a(A143610(n)) = 15 (sig.: (2,3)).
a(A178740(n)) = 16 (sig.: (1,5)).
a(A189975(n)) = 17 (sig.: (1,1,3)).
a(A092759(n)) = 18 (sig.: (7)).
a(A189988(n)) = 19 (sig.: (2,4)).
a(A179643(n)) = 20 (sig.: (1,2,2)).
a(A189987(n)) = 21 (sig.: (1,6)).
a(A046386(n)) = 22 (sig.: (1,1,1,1)).
a(A162142(n)) = 23 (sig.: (2,2,2)).
a(A179644(n)) = 24 (sig.: (1,1,4)).
a(A179645(n)) = 25 (sig.: (8)).
a(A179646(n)) = 26 (sig.: (2,5)).
a(A163569(n)) = 27 (sig.: (1,2,3)).
a(A179664(n)) = 28 (sig.: (1,7)).
a(A189982(n)) = 29 (sig.: (1,1,1,2)).
a(A179666(n)) = 30 (sig.: (3,4)).
a(A179667(n)) = 31 (sig.: (1,1,5)).
a(A179665(n)) = 32 (sig.: (9)).
a(A189990(n)) = 33 (sig.: (2,6)).
a(A179669(n)) = 34 (sig.: (1,2,4)).
a(A179668(n)) = 35 (sig.: (1,8)).
a(A179670(n)) = 36 (sig.: (1,1,1,3)).
a(A179671(n)) = 37 (sig.: (3,5)).
a(A162143(n)) = 38 (sig.: (2,2,2)).
a(A179672(n)) = 39 (sig.: (1,1,6)).
a(A030629(n)) = 40 (sig.: (10)).
a(A179688(n)) = 41 (sig.: (1,3,3)).
a(A179689(n)) = 42 (sig.: (2,7)).
a(A179690(n)) = 43 (sig.: (1,1,2,2)).
a(A189991(n)) = 44 (sig.: (4,4)).
a(A179691(n)) = 45 (sig.: (1,2,5)).
a(A179692(n)) = 46 (sig.: (1,9)).
a(A179693(n)) = 47 (sig.: (1,1,1,4)).
a(A179694(n)) = 48 (sig.: (3,6)).
a(A179695(n)) = 49 (sig.: (2,2,3)).
a(A179696(n)) = 50 (sig.: (1,1,7)).
(End)

Extensions

Data section extended to 120 terms by Antti Karttunen, May 12 2017
Minor edits/corrections by M. F. Hasler, Jul 18 2019

A179644 Product of the 4th power of a prime and 2 different distinct primes (p^4*q*r).

Original entry on oeis.org

240, 336, 528, 560, 624, 810, 816, 880, 912, 1040, 1104, 1134, 1232, 1360, 1392, 1456, 1488, 1520, 1776, 1782, 1840, 1904, 1968, 2064, 2106, 2128, 2256, 2288, 2320, 2480, 2544, 2576, 2754, 2832, 2835, 2928, 2960, 2992, 3078, 3216, 3248, 3280, 3344, 3408
Offset: 1

Views

Author

Keywords

Examples

			240=2^4*3*5,336=2^4*3*7,..810=2^3^4*5,..
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=Sort[Last/@FactorInteger[n]]=={1,1,4}; Select[Range[4000], f]
    Take[Union[#[[1]]^4 #[[2]]#[[3]]&/@(Flatten[Permutations/@ Subsets[ Prime[ Range[ 20]],{3}],1])],50] (* Harvey P. Dale, Feb 07 2013 *)
  • PARI
    list(lim)=my(v=List(),t);forprime(p=2,(lim\6)^(1/4),forprime(q=2,sqrt(lim\p^4),if(p==q,next);t=p^4*q;forprime(r=q+1,lim\t,if(p==r,next);listput(v,t*r))));vecsort(Vec(v)) \\ Charles R Greathouse IV, Jul 19 2011
    
  • Python
    from math import isqrt
    from sympy import primepi, primerange, integer_nthroot
    def A179644(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((t:=primepi(s:=isqrt(y:=x//r**4)))+(t*(t-1)>>1)-sum(primepi(y//k) for k in primerange(1, s+1)) for r in primerange(integer_nthroot(x,4)[0]+1))+sum(primepi(x//p**5) for p in primerange(integer_nthroot(x,5)[0]+1))-primepi(integer_nthroot(x,6)[0])
        return bisection(f,n,n) # Chai Wah Wu, Mar 27 2025

A229125 Numbers of the form p * m^2, where p is prime and m > 0: union of A228056 and A000040.

Original entry on oeis.org

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

Views

Author

Chris Boyd, Sep 14 2013

Keywords

Comments

No term is the product of two other terms.
Squares of terms and pairwise products of distinct terms form a subsequence of A028260.
Numbers n such that A162642(n) = 1. - Jason Kimberley, Oct 10 2016
Numbers k such that A007913(k) is a prime number. - Amiram Eldar, Jul 27 2020

Crossrefs

Programs

  • Mathematica
    With[{nn=70},Take[Union[Flatten[Table[p*m^2,{p,Prime[Range[nn]]},{m,nn}]]], nn]] (* Harvey P. Dale, Dec 02 2014 *)
  • PARI
    test(n)=isprime(core(n))
    for(n=1,200,if(test(n), print1(n",")))
    
  • Python
    from math import isqrt
    from sympy import primepi
    def A229125(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(x//y**2) 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). - Amiram Eldar, Jul 27 2020

A179668 Products of the 8th power of a prime and a distinct prime (p^8*q).

Original entry on oeis.org

768, 1280, 1792, 2816, 3328, 4352, 4864, 5888, 7424, 7936, 9472, 10496, 11008, 12032, 13122, 13568, 15104, 15616, 17152, 18176, 18688, 20224, 21248, 22784, 24832, 25856, 26368, 27392, 27904, 28928, 32512, 32805, 33536, 35072, 35584, 38144, 38656, 40192
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    f[n_]:=Sort[Last/@FactorInteger[n]]=={1,8}; Select[Range[40000], f]
    With[{nn=40},Take[Union[#[[1]]^8 #[[2]]&/@Flatten[Permutations/@Subsets[ Prime[Range[nn]],{2}],1]],nn]] (* Harvey P. Dale, Jan 20 2016 *)
  • PARI
    list(lim)=my(v=List(),t);forprime(p=2,(lim\2)^(1/8),t=p^8;forprime(q=2,lim\t,if(p==q,next);listput(v,t*q)));vecsort(Vec(v)) \\ Charles R Greathouse IV, Jul 20 2011
    
  • Python
    from sympy import primepi, primerange, integer_nthroot
    def A179668(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(x//p**8) for p in primerange(integer_nthroot(x,8)[0]+1))+primepi(integer_nthroot(x,9)[0])
        return bisection(f,n,n) # Chai Wah Wu, Feb 21 2025

A179692 Numbers of the form p^9*q where p and q are distinct primes.

Original entry on oeis.org

1536, 2560, 3584, 5632, 6656, 8704, 9728, 11776, 14848, 15872, 18944, 20992, 22016, 24064, 27136, 30208, 31232, 34304, 36352, 37376, 39366, 40448, 42496, 45568, 49664, 51712, 52736, 54784, 55808, 57856, 65024, 67072, 70144, 71168, 76288, 77312, 80384, 83456
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    f[n_]:=Sort[Last/@FactorInteger[n]]=={1,9}; Select[Range[90000], f]
  • PARI
    list(lim)=my(v=List(),t);forprime(p=2, (lim\2)^(1/9), t=p^9;forprime(q=2, lim\t, if(p==q, next);listput(v,t*q))); vecsort(Vec(v)) \\ Charles R Greathouse IV, Jul 24 2011
    
  • Python
    from sympy import primepi, integer_nthroot, primerange
    def A179692(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(x//p**9) for p in primerange(integer_nthroot(x,9)[0]+1))+primepi(integer_nthroot(x,10)[0])
        return bisection(f,n,n) # Chai Wah Wu, Feb 21 2025

A030636 Numbers with 18 divisors.

Original entry on oeis.org

180, 252, 288, 300, 396, 450, 468, 588, 612, 684, 700, 768, 800, 828, 882, 972, 980, 1044, 1100, 1116, 1280, 1300, 1332, 1452, 1476, 1548, 1568, 1575, 1692, 1700, 1792, 1900, 1908, 2028, 2124, 2156, 2178, 2196, 2205, 2300, 2412, 2420, 2450
Offset: 1

Views

Author

Keywords

Comments

Numbers of the form p^17, p*q^8 (A179668), p*q^2*r^2 (A179643) or p^2*q^5 (A179646), where p, q and r are distinct primes. - R. J. Mathar, Mar 01 2010

Crossrefs

Cf. A030635 (17 divs), A030637 (19 divs).

Programs

Extensions

882 inserted by N. J. A. Sloane, Mar 26 2007

A179642 Product of exactly 5 primes, 3 of which are distinct.

Original entry on oeis.org

120, 168, 180, 252, 264, 270, 280, 300, 312, 378, 396, 408, 440, 450, 456, 468, 520, 552, 588, 594, 612, 616, 680, 684, 696, 700, 702, 728, 744, 750, 760, 828, 882, 888, 918, 920, 945, 952, 980, 984, 1026, 1032, 1044, 1064, 1100, 1116, 1128, 1144, 1160
Offset: 1

Views

Author

Keywords

Examples

			120=2^3*3*5, 168=2^3*3*7, 180=2^2*3^2*5, 252=2^2*3^2*7, 264=2^3*3*11, 270=2*3^3*5
		

Crossrefs

Programs

  • Mathematica
    f[n_]:=Sort[Last/@FactorInteger[n]]=={1,1,3} || Sort[Last/@FactorInteger[n]]=={1,2,2}; Select[Range[2000], f]
  • PARI
    list(lim)=my(v=List(),t);forprime(p=2,(lim\6)^(1/3),forprime(q=2,sqrt(lim\p^3),if(p==q,next);t=p^3*q;forprime(r=q+1,lim\t,if(p==r,next);listput(v,t*r))));forprime(p=2,sqrt(lim\12),forprime(q=p+1,sqrt(lim\p^2\2),t=(p*q)^2;forprime(r=2,lim\t,if(p==r||q==r,next);listput(v,t*r))));vecsort(Vec(v)) \\ Charles R Greathouse IV, Jul 19 2011

A179689 Numbers with prime signature {7,2}, i.e., of form p^7*q^2 with p and q distinct primes.

Original entry on oeis.org

1152, 3200, 6272, 8748, 15488, 21632, 36992, 46208, 54675, 67712, 107163, 107648, 123008, 175232, 215168, 236672, 264627, 282752, 312500, 359552, 369603, 445568, 476288, 574592, 632043, 645248, 682112, 703125, 789507, 798848, 881792, 1013888
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Maple
    a:= proc(n) option remember; local k;
          for k from 1+ `if` (n=1, 1, a(n-1))
            while sort (map (x-> x[2], ifactors(k)[2]), `>`)<>[7, 2]
          do od; k
        end:
    seq (a(n), n=1..32);  # Alois P. Heinz, Jan 23 2011
  • Mathematica
    f[n_]:=Sort[Last/@FactorInteger[n]]=={2,7}; Select[Range[10^6], f]
  • PARI
    list(lim)=my(v=List(),t);forprime(p=2, (lim\4)^(1/7), t=p^7;forprime(q=2, sqrt(lim\t), if(p==q, next);listput(v,t*q^2))); vecsort(Vec(v)) \\ Charles R Greathouse IV, Jul 20 2011
    
  • Python
    from math import isqrt
    from sympy import primepi, integer_nthroot, primerange
    def A179689(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(isqrt(x//p**7)) for p in primerange(integer_nthroot(x,7)[0]+1))+primepi(integer_nthroot(x,9)[0])
        return bisection(f,n,n) # Chai Wah Wu, Feb 21 2025

Formula

Sum_{n>=1} 1/a(n) = P(2)*P(7) - P(9) = A085548 * A085967 - A085969 = 0.001741..., where P is the prime zeta function. - Amiram Eldar, Jul 06 2020

Extensions

Title edited by Daniel Forgues, Jan 22 2011

A179696 Numbers with prime signature {7,1,1}, i.e., of form p^7*q*r with p, q and r distinct primes.

Original entry on oeis.org

1920, 2688, 4224, 4480, 4992, 6528, 7040, 7296, 8320, 8832, 9856, 10880, 11136, 11648, 11904, 12160, 14208, 14720, 15232, 15744, 16512, 17024, 18048, 18304, 18560, 19840, 20352, 20608, 21870, 22656, 23424, 23680, 23936, 25728, 25984, 26240, 26752, 27264
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Maple
    a:= proc(n) option remember; local k;
          for k from 1+ `if` (n=1, 1, a(n-1))
            while sort (map (x-> x[2], ifactors(k)[2]), `>`)<>[7, 1, 1]
          do od; k
        end:
    seq (a(n), n=1..40); # Alois P. Heinz, Jan 23 2011
  • Mathematica
    f[n_]:=Sort[Last/@FactorInteger[n]]=={1,1,7}; Select[Range[30000], f]
  • PARI
    list(lim)=my(v=List(),t1,t2);forprime(p=2, (lim\6)^(1/7), t1=p^7;forprime(q=2, lim\t1, if(p==q, next);t2=t1*q;forprime(r=q+1, lim\t2, if(p==r,next);listput(v,t2*r)))); vecsort(Vec(v)) \\ Charles R Greathouse IV, Jul 20 2011
    
  • Python
    from math import isqrt
    from sympy import primerange, primepi, integer_nthroot
    def A179696(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((t:=primepi(s:=isqrt(y:=x//r**7)))+(t*(t-1)>>1)-sum(primepi(y//k) for k in primerange(1, s+1)) for r in primerange(integer_nthroot(x,7)[0]+1))+sum(primepi(x//p**8) for p in primerange(integer_nthroot(x,8)[0]+1))-primepi(integer_nthroot(x,9)[0])
        return bisection(f,n,n) # Chai Wah Wu, Mar 27 2025

Extensions

Title edited by Daniel Forgues, Jan 22 2011
Showing 1-10 of 20 results. Next