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-9 of 9 results.

A348039 a(n) = gcd(A003557(n), A327564(n)).

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 6, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 12, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 6
Offset: 1

Views

Author

Antti Karttunen, Oct 19 2021

Keywords

Comments

There is interesting regularity in the scatter plot.

Crossrefs

Cf. A347960 (positions of terms > 1).

Programs

  • Mathematica
    {1}~Join~Array[GCD @@ Map[Times @@ # &, Transpose@ Map[{#1^(#2 - 1), (#1 + 1)^(#2 - 1)} & @@ # &, FactorInteger[#]]] &, 105, 2] (* Michael De Vlieger, Oct 20 2021 *)
  • PARI
    A003968(n) = {my(f=factor(n)); for (i=1, #f~, p= f[i, 1]; f[i, 1] = p*(p+1)^(f[i, 2]-1); f[i, 2] = 1); factorback(f); }
    A007947(n) = factorback(factorint(n)[, 1]);
    A348036(n) = gcd(n, A003968(n));
    A348039(n) = (A348036(n)/A007947(n));
    
  • PARI
    A003557(n) = (n/factorback(factorint(n)[, 1]));
    A327564(n) = { my(f=factor(n)); for(k=1, #f~, f[k, 1]++; f[k, 2]--); factorback(f); }; \\ From A327564
    A348039(n) = gcd(A003557(n), A327564(n));

Formula

a(n) = gcd(A003557(n), A327564(n)).
a(n) = A348036(n) / A007947(n).
a(n) = A003557(n) / A348037(n).
a(n) = A327564(n) / A348038(n).

A349394 a(p^e) = p^(e-1) for prime powers, a(n) = 0 for all other n; Dirichlet convolution of A003415 (arithmetic derivative of n) with A055615 (Dirichlet inverse of n).

Original entry on oeis.org

0, 1, 1, 2, 1, 0, 1, 4, 3, 0, 1, 0, 1, 0, 0, 8, 1, 0, 1, 0, 0, 0, 1, 0, 5, 0, 9, 0, 1, 0, 1, 16, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 7, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 32, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 1, 0, 27, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1, 0, 0
Offset: 1

Views

Author

Antti Karttunen, Nov 18 2021

Keywords

Comments

Dirichlet convolution of this sequence with Euler phi (A000010) is A300251.
Convolving this sequence with sigma (A000203) produces A319684.
With a(1) = 1 instead of 0, this would be the Dirichlet convolution of A129283 (A003415(n)+n) with A055615. Thus when we subtract A063524 from that convolution, we get this sequence. (See also A349434). Compare also to the convolution of A069359 (sequence agreeing with A003415 on squarefree numbers) with A055615, which is the characteristic function of primes, A010051. - Antti Karttunen, Nov 20 2021

Crossrefs

Programs

  • Haskell
    import Math.NumberTheory.Primes
    a n = case factorise n of
        [(p,e)] -> unPrime p^(e-1) :: Int
         -> 0 -- _Sebastian Karlsson, Nov 19 2021
  • Mathematica
    f[p_, e_] := e/p; d[1] = 0; d[n_] := n * Plus @@ f @@@ FactorInteger[n]; a[n_] := DivisorSum[n, # * MoebiusMu[#] * d[n/#] &]; Array[a, 100] (* Amiram Eldar, Nov 19 2021 *)
  • PARI
    A003415(n) = if(n<=1, 0, my(f=factor(n)); n*sum(i=1, #f~, f[i, 2]/f[i, 1]));
    A055615(n) = (n*moebius(n));
    A349394(n) = sumdiv(n,d,A003415(n/d)*A055615(d));
    
  • PARI
    A349394(n) = { my(p=0,e); if((e=isprimepower(n,&p)),p^(e-1),0); }; \\ (After Sebastian Karlsson's new formula) - Antti Karttunen, Nov 20 2021
    

Formula

a(n) = Sum_{d|n} A003415(n/d) * A055615(d).
a(n) = 0 unless n is a prime power (A246655), in which case a(p^e) = p^(e-1). - Sebastian Karlsson, Nov 19 2021
a(n) = A003557(n) * A069513(n). [From above] - Antti Karttunen, Nov 20 2021
Dirichlet g.f.: Sum_{p prime} 1/(p^s-p) [Follows from the D.g.f. of A003415 proved by Haukkanen et al.]. - Sebastian Karlsson, Nov 25 2021
Sum_{k=1..n} a(k) has an average value c*n, where c = A137245 = Sum_{primes p} 1/(p*log(p)) = 1.63661632335... - Vaclav Kotesovec, Mar 03 2023

Extensions

Added Sebastian Karlsson's formula as the new primary definition - Antti Karttunen, Nov 20 2021

A325126 a(1) = 1; a(n) = -Sum_{d|n, dA007947.

Original entry on oeis.org

1, -2, -3, 2, -5, 6, -7, -2, 6, 10, -11, -6, -13, 14, 15, 2, -17, -12, -19, -10, 21, 22, -23, 6, 20, 26, -12, -14, -29, -30, -31, -2, 33, 34, 35, 12, -37, 38, 39, 10, -41, -42, -43, -22, -30, 46, -47, -6, 42, -40, 51, -26, -53, 24, 55, 14, 57, 58, -59, 30
Offset: 1

Views

Author

Ilya Gutkovskiy, Sep 04 2019

Keywords

Comments

Dirichlet inverse of A007947.
Moebius transform of A125131.

Crossrefs

Programs

  • Mathematica
    a[n_] := If[n == 1, n, -Sum[If[d < n, Last[Select[Divisors[n/d], SquareFreeQ]] a[d], 0], {d, Divisors[n]}]]; Table[a[n], {n, 1, 60}]
    f[p_, e_] := -p*(1 - p)^(e - 1); a[1] = 1; a[n_] := Times @@ (f @@@ FactorInteger[n]); Array[a, 100] (* Amiram Eldar, Oct 14 2020 *)
  • PARI
    rad(n) = factorback(factorint(n)[, 1]); \\ A007947
    lista(nn) = {my(va=vector(nn)); va[1] = 1; for (n=2, nn, va[n] = -sumdiv(n, d, if (dMichel Marcus, Jun 01 2020

Formula

G.f. A(x) satisfies: A(x) = x - Sum_{k>=2} rad(k) * A(x^k).
From Isaac Saffold, May 30 2020: (Start)
a(n) = A008836(n)*A326297(n)*A007947(n).
Proof:
Define lambda(n) := A008836(n); h(n) := A326297(n); rad(n) := A007947(n).
As lambda(n), h(n), and rad(n) are multiplicative, the identity needs only to be proved for prime power n.
It is clear that the identity holds for n = 1 = p^0. For a given nonnegative integer k, assume the identity holds for all v such that 0 <= v <= k. Then, by the recursive formula for Dirichlet inverses,
a(p^(k+1)) = -Sum_{v=0..k} lambda(p^v)*h(p^v)*rad(p^v)*rad(p^(k+1-v))
= -p * (1 + p*Sum_{v=1..k}((-1)^v * (p-1)^(v-1)))
= -p * (1 - p*Sum_{v=0..(k-1)}((1 - p)^v))
= -p * (1 - p*(((1-p)^k - 1) / -p))
= -p * (1-p)^k
= (-1)^(k+1) * (p-1)^k * p
= lambda(p^(k+1)) * h(p^(k+1)) * rad(p^(k+1))
Thus the identity holds for p^(k+1), k >= 0.
As k is arbitrary and the identity holds for p^0, it holds for the prime powers, and thus for all positive integers. Q.E.D. (End)

A326297 If n = Product (p_j^k_j) then a(n) = Product ((p_j - 1)^(k_j - 1)).

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 4, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 6, 4, 1, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 4, 1, 1, 1, 1, 1, 8, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 6, 2, 4
Offset: 1

Views

Author

Ilya Gutkovskiy, Mar 03 2020

Keywords

Examples

			a(98) = a(2 * 7^2) = (2 - 1)^(1 - 1) * (7 - 1)^(2 - 1) = 6.
		

Crossrefs

Programs

  • Maple
    seq(mul((p-1)^(padic[ordp](n,p)-1), p in numtheory[factorset](n)), n =1..100); # Ridouane Oudra, Oct 29 2024
  • Mathematica
    a[n_] := If[n == 1, 1, Times @@ ((#[[1]] - 1)^(#[[2]] - 1) & /@ FactorInteger[n])]; Table[a[n], {n, 1, 100}]
  • PARI
    a(n) = my(f=factor(n)); for (k=1, #f~, f[k,1]--; f[k,2]--); factorback(f); \\ Michel Marcus, Mar 03 2020
    
  • Python
    from math import prod
    from sympy import factorint
    def a(n): return prod((p-1)**(e-1) for p, e in factorint(n).items())
    print([a(n) for n in range(1, 101)]) # Michael S. Branicky, Aug 30 2021

Formula

a(n) = A003958(n) / abs(A023900(n)) = abs(A325126(n)) / A007947(n).
Dirichlet g.f.: Product_{p prime} (1 + 1/(p^s - p + 1)). - Amiram Eldar, Dec 07 2023
a(n) = A003958(n)/A173557(n). - Ridouane Oudra, Oct 29 2024

A347960 Numbers k for which A348036(k) > A007947(k).

Original entry on oeis.org

36, 72, 100, 108, 144, 180, 196, 200, 216, 225, 252, 288, 300, 324, 360, 392, 396, 400, 432, 450, 468, 484, 500, 504, 540, 576, 588, 600, 612, 648, 675, 676, 684, 700, 720, 756, 784, 792, 800, 828, 864, 900, 936, 968, 972, 980, 1000, 1008, 1044, 1080, 1089, 1100, 1116, 1125, 1152, 1156, 1176, 1188, 1200, 1224, 1260, 1296
Offset: 1

Views

Author

Antti Karttunen, Oct 19 2021

Keywords

Comments

Numbers k such that A348039(k) > 1.
Numbers k such that A348037(k) < A003557(k).
Numbers k such that A327564(k) > A348038(k).
Differs from A036785 and A338539 for the first time at n=20, where a(n) = 450, as A036785(20) = A338539(20) = 441 is not included in this sequence.

Crossrefs

Programs

  • Mathematica
    f[p_, e_] := p*(p + 1)^(e - 1); q[n_] := GCD[n, Times @@ f @@@ (fct = FactorInteger[n])] > Times @@ First /@ fct; Select[Range[1300], q] (* Amiram Eldar, Oct 20 2021 *)
  • PARI
    A003968(n) = {my(f=factor(n)); for (i=1, #f~, p= f[i, 1]; f[i, 1] = p*(p+1)^(f[i, 2]-1); f[i, 2] = 1); factorback(f); }
    A007947(n) = factorback(factorint(n)[, 1]);
    A348036(n) = gcd(n, A003968(n));
    isA347960(n) = (A348036(n)>A007947(n));

A348038 a(n) = A003968(n) / gcd(n, A003968(n)), where A003968 is multiplicative with a(p^e) = p*(p+1)^(e-1).

Original entry on oeis.org

1, 1, 1, 3, 1, 1, 1, 9, 4, 1, 1, 3, 1, 1, 1, 27, 1, 4, 1, 3, 1, 1, 1, 9, 6, 1, 16, 3, 1, 1, 1, 81, 1, 1, 1, 2, 1, 1, 1, 9, 1, 1, 1, 3, 4, 1, 1, 27, 8, 6, 1, 3, 1, 16, 1, 9, 1, 1, 1, 3, 1, 1, 4, 243, 1, 1, 1, 3, 1, 1, 1, 3, 1, 1, 6, 3, 1, 1, 1, 27, 64, 1, 1, 3, 1, 1, 1, 9, 1, 4, 1, 3, 1, 1, 1, 81, 1, 8, 4, 9, 1
Offset: 1

Views

Author

Antti Karttunen, Oct 20 2021

Keywords

Crossrefs

Differs from A327564 at the positions given by A347960.
Cf. A003968, A005117 (positions of 1's), A327564, A348036, A348037, A348039.

Programs

  • Mathematica
    f[p_, e_] := p*(p + 1)^(e - 1); a[n_] := (m = Times @@ f @@@ FactorInteger[n]) / GCD[n, m]; Array[a, 100] (* Amiram Eldar, Oct 20 2021 *)
  • PARI
    A003968(n) = {my(f=factor(n)); for (i=1, #f~, p= f[i, 1]; f[i, 1] = p*(p+1)^(f[i, 2]-1); f[i, 2] = 1); factorback(f); }
    A348038(n) = { my(u=A003968(n)); (u/gcd(n, u)); };

Formula

a(n) = A003968(n) / A348036(n) = A003968(n) / gcd(n, A003968(n)).
a(n) = A327564(n) / A348039(n).

A340368 Multiplicative with a(p^e) = (p - 1) * (p + 1)^(e-1).

Original entry on oeis.org

1, 1, 2, 3, 4, 2, 6, 9, 8, 4, 10, 6, 12, 6, 8, 27, 16, 8, 18, 12, 12, 10, 22, 18, 24, 12, 32, 18, 28, 8, 30, 81, 20, 16, 24, 24, 36, 18, 24, 36, 40, 12, 42, 30, 32, 22, 46, 54, 48, 24, 32, 36, 52, 32, 40, 54, 36, 28, 58, 24, 60, 30, 48, 243, 48, 20, 66, 48, 44, 24, 70, 72, 72, 36, 48, 54, 60, 24, 78, 108, 128, 40
Offset: 1

Views

Author

Antti Karttunen, Jan 06 2021

Keywords

Crossrefs

Programs

  • Mathematica
    f[p_, e_] := (p - 1)*(p + 1)^(e - 1); a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Nov 12 2022 *)
  • PARI
    A340368(n) = if(1==n,n,my(f=factor(n)); prod(i=1,#f~,(f[i,1]-1)*((f[i,1]+1)^(f[i,2]-1))));

Formula

a(n) = A167344(n) / A340323(n).
a(n) = A173557(n) * A327564(n).
Sum_{k=1..n} a(k) ~ c * n^2, where c = (1/2) * Product_{p prime} (1 - 3/p^2 + 2/p^4) / Product_{p prime} (1 - 2/p^2 - 1/p^3) = 0.4313799748... . - Amiram Eldar, Nov 12 2022

A351434 If n = Product (p_j^k_j) then a(n) = Product ((p_j - 1)^(k_j + 1)).

Original entry on oeis.org

1, 1, 4, 1, 16, 4, 36, 1, 8, 16, 100, 4, 144, 36, 64, 1, 256, 8, 324, 16, 144, 100, 484, 4, 64, 144, 16, 36, 784, 64, 900, 1, 400, 256, 576, 8, 1296, 324, 576, 16, 1600, 144, 1764, 100, 128, 484, 2116, 4, 216, 64, 1024, 144, 2704, 16, 1600, 36, 1296, 784, 3364, 64, 3600, 900, 288, 1, 2304
Offset: 1

Views

Author

Ilya Gutkovskiy, Feb 11 2022

Keywords

Crossrefs

Programs

  • Maple
    a:= n-> mul((i[1]-1)^(i[2]+1), i=ifactors(n)[2]):
    seq(a(n), n=1..65);  # Alois P. Heinz, Feb 11 2022
  • Mathematica
    f[p_, e_] := (p - 1)^(e + 1); a[1] = 1; a[n_] := Times @@ (f @@@ FactorInteger[n]); Table[a[n], {n, 1, 65}]
  • PARI
    a(n) = my(f=factor(n)); for (k=1, #f~, f[k,1]--; f[k,2]++); factorback(f); \\ Michel Marcus, Feb 11 2022

Formula

a(n) = A003958(n) * |A023900(n)|.
Sum_{k=1..n} a(k) ~ c * n^3, where c = (1/3) * Product_{p prime} (1 - (3*p^2 - 4*p + 2)/(p*(p^3 - p + 1))) = 0.1161464566... . - Amiram Eldar, Nov 19 2022

A351435 If n = Product (p_j^k_j) then a(n) = Product ((p_j + 1)^(k_j + 1)).

Original entry on oeis.org

1, 9, 16, 27, 36, 144, 64, 81, 64, 324, 144, 432, 196, 576, 576, 243, 324, 576, 400, 972, 1024, 1296, 576, 1296, 216, 1764, 256, 1728, 900, 5184, 1024, 729, 2304, 2916, 2304, 1728, 1444, 3600, 3136, 2916, 1764, 9216, 1936, 3888, 2304, 5184, 2304, 3888, 512, 1944, 5184, 5292, 2916
Offset: 1

Views

Author

Ilya Gutkovskiy, Feb 11 2022

Keywords

Crossrefs

Programs

  • Maple
    a:= n-> mul((i[1]+1)^(i[2]+1), i=ifactors(n)[2]):
    seq(a(n), n=1..53);  # Alois P. Heinz, Feb 11 2022
  • Mathematica
    f[p_, e_] := (p + 1)^(e + 1); a[1] = 1; a[n_] := Times @@ (f @@@ FactorInteger[n]); Table[a[n], {n, 1, 53}]
  • PARI
    a(n) = my(f=factor(n)); for (k=1, #f~, f[k,1]++; f[k,2]++); factorback(f); \\ Michel Marcus, Feb 11 2022

Formula

a(n) = A003959(n) * A048250(n).
Sum_{k=1..n} a(k) ~ c * n^3, where c = 1/(3 * Product_{p prime} (1 - p/(p^3-1))) = 1 /(3 * A065478) = 0.5787439255... . - Amiram Eldar, Nov 19 2022
Sum_{n>=1} 1/a(n) = zeta(2)/zeta(3) (A306633). - Amiram Eldar, Dec 15 2023
Showing 1-9 of 9 results.