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 29 results. Next

A084920 a(n) = (prime(n)-1)*(prime(n)+1).

Original entry on oeis.org

3, 8, 24, 48, 120, 168, 288, 360, 528, 840, 960, 1368, 1680, 1848, 2208, 2808, 3480, 3720, 4488, 5040, 5328, 6240, 6888, 7920, 9408, 10200, 10608, 11448, 11880, 12768, 16128, 17160, 18768, 19320, 22200, 22800, 24648, 26568, 27888, 29928
Offset: 1

Views

Author

Reinhard Zumkeller, Jun 11 2003

Keywords

Comments

Squares of primes minus 1. - Wesley Ivan Hurt, Oct 11 2013
Integers k for which there exist exactly two positive integers b such that (k+1)/(b+1) is an integer. - Benedict W. J. Irwin, Jul 26 2016

Crossrefs

Programs

Formula

a(n) = A006093(n) * A008864(n);
a(n) = A084921(n)*2, for n > 1; a(n) = A084922(n)*6, for n > 2.
Product_{n > 0} a(n)/A066872(n) = 2/5. a(n) = A001248(n) - 1. - R. J. Mathar, Feb 01 2009
a(n) = prime(n)^2 - 1 = A001248(n) - 1. - Vladimir Joseph Stephan Orlovsky, Oct 17 2009
a(n) ~ n^2*log(n)^2. - Ilya Gutkovskiy, Jul 28 2016
a(n) = (1/2) * Sum_{|k|<=2*sqrt(p)} k^2*H(4*p-k^2) where H() is the Hurwitz class number and p is n-th prime. - Seiichi Manyama, Dec 31 2017
a(n) = 24 * A024702(n) for n > 2. - Jianing Song, Apr 28 2019
Sum_{n>=1} 1/a(n) = A154945. - Amiram Eldar, Nov 09 2020
From Amiram Eldar, Nov 07 2022: (Start)
Product_{n>=1} (1 + 1/a(n)) = Pi^2/6 (A013661).
Product_{n>=1} (1 - 1/a(n)) = A065469. (End)

A190641 Numbers having exactly one non-unitary prime factor.

Original entry on oeis.org

4, 8, 9, 12, 16, 18, 20, 24, 25, 27, 28, 32, 40, 44, 45, 48, 49, 50, 52, 54, 56, 60, 63, 64, 68, 75, 76, 80, 81, 84, 88, 90, 92, 96, 98, 99, 104, 112, 116, 117, 120, 121, 124, 125, 126, 128, 132, 135, 136, 140, 147, 148, 150, 152, 153, 156, 160, 162, 164
Offset: 1

Views

Author

Reinhard Zumkeller, Dec 29 2012

Keywords

Comments

Numbers k such that the powerful part of k, A057521(k), is a composite prime power (A246547). - Amiram Eldar, Aug 01 2024

Crossrefs

Subsequence of A013929 and of A327877.
Cf. A056170, A057521, A154945, A246547, A359466 (characteristic function).

Programs

  • Haskell
    a190641 n = a190641_list !! (n-1)
    a190641_list = map (+ 1) $ elemIndices 1 a056170_list
    
  • Mathematica
    Select[Range[164],Count[FactorInteger[#][[All, 2]], 1] == Length[FactorInteger[#]] - 1 &] (* Geoffrey Critzer, Feb 05 2015 *)
  • PARI
    list(lim)=my(s=lim\4, v=List(), u=vectorsmall(s, i, 1), t, x); forprime(k=2, sqrtint(s), t=k^2; forstep(i=t, s, t, u[i]=0)); forprime(k=2, sqrtint(lim\1), for(e=2,logint(lim\1,k), t=k^e; for(i=1, #u, if(u[i] && gcd(k, i)==1, x=t*i; if(x>lim, break); listput(v, x))))); Set(v) \\ Charles R Greathouse IV, Aug 02 2016
    
  • PARI
    isok(n) = my(f=factor(n)); #select(x->(x>1), f[,2]) == 1; \\ Michel Marcus, Jul 30 2017

Formula

A056170(a(n)) = 1.
a(n) ~ k*n, where k = Pi^2/(6*A154945) = 2.9816096.... - Charles R Greathouse IV, Aug 02 2016

A056798 Prime powers with even nonnegative exponents.

Original entry on oeis.org

1, 4, 9, 16, 25, 49, 64, 81, 121, 169, 256, 289, 361, 529, 625, 729, 841, 961, 1024, 1369, 1681, 1849, 2209, 2401, 2809, 3481, 3721, 4096, 4489, 5041, 5329, 6241, 6561, 6889, 7921, 9409, 10201, 10609, 11449, 11881, 12769, 14641, 15625, 16129, 16384
Offset: 1

Views

Author

Labos Elemer, Aug 28 2000

Keywords

Comments

Also numbers whose geometric mean of divisors is an integer. - Ctibor O. Zizka, Sep 29 2008
This is just a special case. In fact, the numbers whose geometric mean of divisors is an integer are all the squares of integers (A000290). - Daniel Lignon, Nov 29 2014

Crossrefs

Programs

  • Mathematica
    Take[Union[Flatten[Table[Prime[n]^k, {n, 31}, {k, 0, 14, 2}]]], 45] (* Alonso del Arte, Jul 05 2011 *)
  • PARI
    is(n)=my(e=isprimepower(n)); if(e, e%2==0, n==1) \\ Charles R Greathouse IV, Sep 18 2015
    
  • Python
    from sympy import primepi, integer_nthroot
    def A056798(n):
        if n==1: return 1
        def f(x): return int(n-2+x-sum(primepi(integer_nthroot(x,k)[0])for k in range(2,x.bit_length(),2)))
        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 13 2024

Formula

a(n) = A025473(n)^(2*A025474(n)) = A000961(n)^2;
A001222(a(n)) mod 2 = 0;
A003415(a(n)) = A192083(n); A068346(a(n)) = A192084(n). - Reinhard Zumkeller, Jun 26 2011
Sum_{n>=2} 1/a(n) = A154945. - Amiram Eldar, Sep 21 2020

A036785 Numbers divisible by the squares of two distinct primes.

Original entry on oeis.org

36, 72, 100, 108, 144, 180, 196, 200, 216, 225, 252, 288, 300, 324, 360, 392, 396, 400, 432, 441, 450, 468, 484, 500, 504, 540, 576, 588, 600, 612, 648, 675, 676, 684, 700, 720, 756, 784, 792, 800, 828, 864, 882, 900, 936, 968, 972, 980, 1000, 1008, 1044
Offset: 1

Views

Author

Keywords

Comments

Not squarefree, not a nontrivial prime power and not in {squarefree} times {nontrivial prime powers}.
Numbers k such that A056170(k) > 1. The asymptotic density of this sequence is 1 - (6/Pi^2) * (1 + A154945) = 0.05668359058... - Amiram Eldar, Nov 01 2020

References

  • CRC Standard Mathematical Tables and Formulae, 30th ed., (1996) page 102-105.

Crossrefs

Equivalent sequence for 3 distinct primes: A318720.
Cf. A085986, A338539, A339245 (subsequences).
Subsequence of A038838.

Programs

  • Mathematica
    Select[Range@ 1050, And[Length@ # > 1, Total@ Boole@ Map[# > 1 &, #[[All, -1]]] > 1] &@ FactorInteger@ # &] (* Michael De Vlieger, Apr 25 2017 *)
    dstdpQ[n_]:=Length[Select[Sqrt[#]&/@Divisors[n],PrimeQ]]>1; Select[ Range[ 1100],dstdpQ] (* Harvey P. Dale, Jan 15 2020 *)
  • PARI
    is(n)=my(f=vecsort(factor(n)[,2],,4));#f>1&&f[2]>1 \\ Charles R Greathouse IV, Nov 15 2012

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), Apr 03 2000
New name from Charles R Greathouse IV, Nov 15 2012

A380840 Decimal expansion of Sum_{p prime} 1/(p-1)^3.

Original entry on oeis.org

1, 1, 4, 7, 5, 2, 9, 0, 9, 7, 7, 5, 8, 5, 8, 0, 0, 4, 6, 9, 3, 3, 2, 8, 3, 8, 0, 6, 2, 8, 2, 1, 3, 0, 4, 0, 1, 6, 4, 4, 7, 6, 4, 7, 3, 5, 5, 2, 5, 1, 1, 2, 2, 5, 5, 2, 7, 5, 8, 2, 4, 1, 2, 3, 9, 5, 0, 5, 3, 3, 5, 9, 0, 4, 5, 5, 0, 4, 5, 4, 3, 1, 4, 7, 2, 6, 5, 2, 2, 8, 7, 3, 7, 2, 6, 9, 0, 9, 4, 6, 7, 5, 1, 6, 8, 0
Offset: 1

Views

Author

Artur Jasinski, Mar 19 2025

Keywords

Examples

			1.1475290977585800469332838..,
		

Crossrefs

Programs

  • PARI
    sumeulerrat(1/(p-1)^3)

A116512 a(n) is the number of positive integers each of which is <= n and is divisible by exactly one prime dividing n (but is coprime to every other prime dividing n). a(1) = 0.

Original entry on oeis.org

0, 1, 1, 2, 1, 3, 1, 4, 3, 5, 1, 6, 1, 7, 6, 8, 1, 9, 1, 10, 8, 11, 1, 12, 5, 13, 9, 14, 1, 14, 1, 16, 12, 17, 10, 18, 1, 19, 14, 20, 1, 20, 1, 22, 18, 23, 1, 24, 7, 25, 18, 26, 1, 27, 14, 28, 20, 29, 1, 28, 1, 31, 24, 32, 16, 32, 1, 34, 24, 34, 1, 36, 1, 37, 30, 38, 16, 38, 1, 40, 27, 41, 1
Offset: 1

Views

Author

Leroy Quet, Mar 23 2006

Keywords

Comments

a(n) = number of m's, 1 <= m <= n, where gcd(m,n) is a power of a prime (> 1).
We could also have taken a(1) = 1, but a(1) = 0 is better since there are no numbers <= 1 with the desired property. - N. J. A. Sloane, Sep 16 2006

Examples

			12 is divisible by 2 and 3. The positive integers which are <= 12 and which are divisible by 2 or 3, but not by both 2 and 3, are: 2,3,4,8,9,10. Since there are six such integers, a(12) = 6.
		

Crossrefs

Cf. A095112 (Inverse Möbius transform), A354109 (positions of even terms).

Programs

  • Maple
    with(numtheory): a:=proc(n) local c,j: c:=0: for j from 1 to n do if nops(factorset(gcd(j,n)))=1 then c:=c+1 else c:=c: fi od: c; end: seq(a(n),n=1..90); # Emeric Deutsch, Apr 01 2006
  • Mathematica
    Table[Length@Select[GCD[n, Range@n], MatchQ[FactorInteger@#, {{, }}] && # != 1 &], {n, 93}] (* Giovanni Resta, Apr 04 2006; corrected by Ilya Gutkovskiy, Sep 26 2021 *)
    a[n_] := Module[{p = FactorInteger[n][[;; , 1]]}, n * Times @@ (1-1/p) * Total[1/(p-1)]]; a[1] = 0; Array[a, 100] (* Amiram Eldar, Jun 21 2025 *)
  • PARI
    { for(n=1,60, hav=0; for(i=1,n, g = gcd(i,n); d = factor(g); dec=matsize(d); if( dec[1] == 1, hav++; ); ); print1(hav,","); ); } \\ R. J. Mathar, Mar 29 2006
    
  • PARI
    a(n) = sumdiv(n, d, eulerphi(n/d) * (isprimepower(d) >= 1)); \\ Daniel Suteu, Jun 27 2018
    
  • PARI
    a(n) = {my(p = factor(n)[,1]); n * vecprod(apply(x -> 1-1/x, p)) * vecsum(apply(x -> 1/(x-1), p));} \\ Amiram Eldar, Jun 21 2025

Formula

Dirichlet g.f.: A(s)*zeta(s-1)/zeta(s) where A(s) is the Dirichlet g.f. for A069513. - Geoffrey Critzer, Feb 22 2015
a(n) = Sum_{d|n, d is a prime power} phi(n/d), where phi(k) is the Euler totient function. - Daniel Suteu, Jun 27 2018
a(n) = phi(n)*Sum_{p|n} 1/(p-1), where p is a prime and phi(k) is the Euler totient function. - Ridouane Oudra, Apr 29 2019
a(n) = Sum_{k=1..n, gcd(n,k) = 1} omega(gcd(n,k-1)). - Ilya Gutkovskiy, Sep 26 2021
a(n) = Sum_{p|n, p prime} p^(v(n,p)-1)*phi(n/p^v(n,p)), where p^v(n,p) is the highest power of p dividing n. - Ridouane Oudra, Oct 06 2023
From Amiram Eldar, Jun 21 2025: (Start)
a(n) = A131233(n) - A000010(n).
Sum_{k=1..n} a(k) ~ c * n^2 / 2, where c = Sum_{p prime} (1/(p^2-1)) / zeta(2) = A154945 / A013661 = 0.3353893075569103736099... . (End)

Extensions

More terms from R. J. Mathar, Emeric Deutsch and Giovanni Resta, Apr 01 2006
Edited by N. J. A. Sloane, Sep 16 2006

A324833 Decimal expansion of eta_2, a constant related to the asymptotic density of certain sets of residues.

Original entry on oeis.org

1, 2, 9, 0, 3, 8, 9, 2, 5, 8, 9, 7, 8, 0, 7, 5, 5, 6, 4, 9, 7, 4, 3, 4, 8, 6, 3, 4, 8, 1, 7, 7, 5, 8, 7, 7, 6, 3, 8, 4, 9, 3, 2, 1, 4, 1, 9, 9, 2, 0, 5, 6, 8, 8, 3, 0, 0, 4, 1, 2, 7, 0, 4, 5, 6, 3, 9, 8, 0, 6, 6, 5, 7, 3, 0, 9, 1, 7, 0, 3, 9, 8, 9, 9, 9, 7, 1, 6, 7, 7, 8, 3, 5, 9, 8, 1, 9, 3, 4, 3, 8
Offset: 0

Views

Author

Jean-François Alcover, Mar 17 2019

Keywords

Examples

			0.12903892589780755649743486348177587763849321419920568830041270456398...
		

Crossrefs

Cf. A154945 (eta_1), A324834 (eta_3), A324835 (eta_4), A324836 (eta_5).

Programs

  • Mathematica
    digits = 101; m0 = 2 digits; Clear[rd]; rd[m_] := rd[m] = RealDigits[eta2 = Sum[n PrimeZetaP[2n + 2], {n, 1, m}], 10, digits][[1]]; rd[m0]; rd[m = 2m0]; While[rd[m] != rd[m-m0], Print[m]; m = m+m0]; Print[N[eta2, digits] ]; rd[m]

Formula

Sum_{p prime} 1/(p^2-1)^2.
Sum_{n>0} n P(2n+2) where P is the prime zeta P function.
Equals - A136141/4 + A086242/4 - A179119/4 + A382554/4. - Artur Jasinski, Mar 31 2025

A095112 a(n) is the sum of n/k over all prime powers k > 1 which divide n.

Original entry on oeis.org

0, 1, 1, 3, 1, 5, 1, 7, 4, 7, 1, 13, 1, 9, 8, 15, 1, 17, 1, 19, 10, 13, 1, 29, 6, 15, 13, 25, 1, 31, 1, 31, 14, 19, 12, 43, 1, 21, 16, 43, 1, 41, 1, 37, 29, 25, 1, 61, 8, 37, 20, 43, 1, 53, 16, 57, 22, 31, 1, 77, 1, 33, 37, 63, 18, 61, 1, 55, 26, 59, 1, 95, 1, 39, 43, 61, 18, 71, 1, 91, 40
Offset: 1

Views

Author

Dean Hickerson, following a suggestion of Leroy Quet, May 28 2004

Keywords

Comments

A073093(n)-1 terms are added to produce a(n). - Michel Marcus, Aug 29 2013

Examples

			The prime power divisors of 24 are 2, 4, 8 and 3, so a(24) = 24/2 + 24/4 + 24/8 + 24/3 = 29.
		

Crossrefs

Cf. A000010, A001221, A001222, A046337 (positions of even terms), A073093, A154945, A366265.
Inverse Möbius transform of A116512.

Programs

  • Maple
    with(numtheory): seq(add(bigomega(d)*phi(n/d),d in divisors(n)), n=1..60); # Ridouane Oudra, Oct 30 2023
  • Mathematica
    a[n_]:=Plus@@(n/Flatten[ #[[1]]^Range[ #[[2]]]&/@FactorInteger[n]])
  • PARI
    A095112(n) = sumdiv(n,d,(1==omega(d))*(n/d)); \\ Antti Karttunen, Feb 25 2018

Formula

a(n) = Sum_{k=1..n} bigomega(gcd(n,k)). - Lechoslaw Ratajczak, Jun 18 2017
Sum_{k=1..n} a(k) ~ A154945 * n*(n+1)/2. - Daniel Suteu, Apr 01 2019
a(n) = Sum_{d|n} bigomega(d)*phi(n/d). - Ridouane Oudra, Oct 30 2023
a(n) = Sum_{d|n} A116512(d). [From Sequence Machine] - Antti Karttunen, Nov 22 2023

A318720 Numbers k such that there exists a strict relatively prime factorization of k in which no pair of factors is relatively prime.

Original entry on oeis.org

900, 1764, 1800, 2700, 3528, 3600, 4356, 4500, 4900, 5292, 5400, 6084, 6300, 7056, 7200, 8100, 8712, 8820, 9000, 9800, 9900, 10404, 10584, 10800, 11025, 11700, 12100, 12168, 12348, 12600, 12996, 13068, 13500, 14112, 14400, 14700, 15300, 15876, 16200, 16900
Offset: 1

Views

Author

Gus Wiseman, Sep 02 2018

Keywords

Comments

From Amiram Eldar, Nov 01 2020: (Start)
Also, numbers with more than two non-unitary prime divisors, i.e., numbers k such that A056170(k) > 2, or equivalently, numbers divisible by the squares of three distinct primes.
The complement of the union of A005117, A190641 and A338539.
The asymptotic density of this sequence is 1 - 6/Pi^2 - (6/Pi^2)*A154945 - (3/Pi^2)*(A154945^2 - A324833) = 0.0033907041... (End)

Examples

			900 is in the sequence because the factorization 900 = (6*10*15) is relatively prime (since the GCD of (6,10,15) is 1) but each of the pairs (6,10), (6,15), (10,15) has a common divisor > 1. Larger examples are:
1800 = (6*15*20) = (10*12*15).
9900 = (6*10*165) = (6*15*110) = (10*15*66).
5400 = (6*20*45) = (10*12*45) = (10*15*36) = (15*18*20).
60 is not in the sequence because all its possible factorizations (4 * 15, 3 * 4 * 5, etc.) contain at least one pair that is coprime, if not more than one prime.
		

Crossrefs

Programs

  • Mathematica
    strfacs[n_] := If[n <= 1, {{}}, Join@@Table[(Prepend[#1, d] &)/@Select[strfacs[n/d], Min@@#1 > d &], {d, Rest[Divisors[n]]}]]; Select[Range[10000], Function[n, Select[strfacs[n], And[GCD@@# == 1, And@@(GCD[##] > 1 &)@@@Select[Tuples[#, 2], Less@@# &]] &] != {}]]
    Select[Range[20000], Count[FactorInteger[#][[;;,2]], ?(#1 > 1 &)] > 2 &] (* _Amiram Eldar, Nov 01 2020 *)

A338539 Numbers having exactly two non-unitary prime factors.

Original entry on oeis.org

36, 72, 100, 108, 144, 180, 196, 200, 216, 225, 252, 288, 300, 324, 360, 392, 396, 400, 432, 441, 450, 468, 484, 500, 504, 540, 576, 588, 600, 612, 648, 675, 676, 684, 700, 720, 756, 784, 792, 800, 828, 864, 882, 936, 968, 972, 980, 1000, 1008, 1044, 1080, 1089
Offset: 1

Views

Author

Amiram Eldar, Nov 01 2020

Keywords

Comments

Numbers k such that A056170(k) = A001221(A057521(k)) = 2.
Numbers divisible by the squares of exactly two distinct primes.
Subsequence of A036785 and first differs from it at n = 44.
The asymptotic density of this sequence is (3/Pi^2)*(eta_1^2 - eta_2) = 0.0532928864..., where eta_j = Sum_{p prime} 1/(p^2-1)^j (Pomerance and Schinzel, 2011).

Examples

			36 = 2^2 * 3^2 is a term since it has exactly 2 prime factors, 2 and 3, that are non-unitary.
		

Crossrefs

Subsequence of A013929 and A036785.
Cf. A154945 (eta_1), A324833 (eta_2).

Programs

  • Mathematica
    Select[Range[1000], Count[FactorInteger[#][[;;,2]], _?(#1 > 1 &)] == 2 &]
Showing 1-10 of 29 results. Next