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 11-19 of 19 results.

A258171 a(n) = Sum_{d|n} phi(d)*Bell(n/d) for n>0, a(0) = 0.

Original entry on oeis.org

0, 1, 3, 7, 19, 56, 214, 883, 4163, 21163, 116039, 678580, 4213848, 27644449, 190900217, 1382958677, 10480146333, 82864869820, 682076827740, 5832742205075, 51724158351527, 474869816158547, 4506715739125923, 44152005855084368, 445958869299027638
Offset: 0

Views

Author

Alois P. Heinz, May 22 2015

Keywords

Comments

Dirichlet convolution of phi(n) (A000010) and the Bell numbers (A000110) (n >= 1). - Richard L. Ollerton, May 09 2021

Crossrefs

Row sums of A258170.
Similar: A078392 (numbpart), this sequence (bell), A053635 (numbcomb), A181847 and A034738 (numbcomp), A327030 (numbperm).

Programs

  • Maple
    with(numtheory):
    A:= proc(n, k) option remember;
          add(phi(d)*k^(n/d), d=divisors(n))
        end:
    T:= (n, k)-> add((-1)^(k-i)*binomial(k, i)*A(n, i), i=0..k)/k!:
    a:= n-> add(T(n, k), k=0..n):
    seq(a(n), n=0..30);
  • Mathematica
    a[n_] := If[n == 0, 0, DivisorSum[n, EulerPhi[#] BellB[n/#] &]];
    Table[a[n], {n, 0, 25}] (* Peter Luschny, Aug 27 2019 *)

Formula

a(n) = Sum_{k=0..n} A258170(n,k).
For n >= 1, a(n) = Sum_{k=1..n} Bell(gcd(n,k)). - Richard L. Ollerton, May 09 2021

Extensions

New name from Peter Luschny, Aug 27 2019

A343489 Square array T(n,k), n >= 0, k >= 0, read by antidiagonals, where T(n,k) = Sum_{j=1..n} k^(gcd(j, n) - 1).

Original entry on oeis.org

0, 0, 1, 0, 1, 1, 0, 1, 2, 2, 0, 1, 3, 3, 2, 0, 1, 4, 6, 4, 4, 0, 1, 5, 11, 12, 5, 2, 0, 1, 6, 18, 32, 20, 6, 6, 0, 1, 7, 27, 70, 85, 42, 7, 4, 0, 1, 8, 38, 132, 260, 260, 70, 8, 6, 0, 1, 9, 51, 224, 629, 1050, 735, 144, 9, 4, 0, 1, 10, 66, 352, 1300, 3162, 4102, 2224, 270, 10, 10
Offset: 0

Views

Author

Seiichi Manyama, Apr 17 2021

Keywords

Examples

			Square array begins:
  0, 0,  0,   0,    0,    0,    0, ...
  1, 1,  1,   1,    1,    1,    1, ...
  1, 2,  3,   4,    5,    6,    7, ...
  2, 3,  6,  11,   18,   27,   38, ...
  2, 4, 12,  32,   70,  132,  224, ...
  4, 5, 20,  85,  260,  629, 1300, ...
  2, 6, 42, 260, 1050, 3162, 7826, ...
		

Crossrefs

Columns k=0..5 give A000010, A001477, A034738, A034754, A343490, A343492.
Main diagonal gives A056665.

Programs

  • Mathematica
    T[n_, k_] := Sum[If[k == (g = GCD[j, n] - 1) == 0, 1, k^g], {j, 1, n}]; Table[T[k, n - k], {n, 0, 11}, {k, 0, n}] // Flatten (* Amiram Eldar, Apr 17 2021 *)
  • PARI
    T(n, k) = sum(j=1, n, k^(gcd(j, n)-1));
    
  • PARI
    T(n, k) = if(n==0, 0, sumdiv(n, d, eulerphi(n/d)*k^(d-1)));

Formula

G.f. of column k: Sum_{j>=1} phi(j) * x^j / (1 - k*x^j).
T(n,k) = A185651(n,k)/k for k > 0.
T(n,k) = Sum_{d|n} phi(n/d)*k^(d - 1).

A349570 Dirichlet convolution of A011782 [2^(n-1)] with A055615 (Dirichlet inverse of n).

Original entry on oeis.org

1, 0, 1, 4, 11, 24, 57, 112, 244, 480, 1013, 1972, 4083, 8064, 16331, 32512, 65519, 130488, 262125, 523244, 1048377, 2095104, 4194281, 8384176, 16777136, 33546240, 67108096, 134201316, 268435427, 536836584, 1073741793, 2147418112, 4294964213, 8589803520, 17179868787, 34359470272, 68719476699, 137438429184, 274877894643
Offset: 1

Views

Author

Antti Karttunen, Nov 22 2021

Keywords

Comments

Dirichlet convolution of this sequence with phi (A000010) is A000740, with sigma (A000203) it is A034729, and with A018804 it is A034738.

Crossrefs

Cf. A011782, A055615, A349569 (Dirichlet inverse).

Programs

  • Mathematica
    a[n_] := DivisorSum[n, # * MoebiusMu[#] * 2^(n/# - 1) &]; Array[a, 40] (* Amiram Eldar, Nov 22 2021 *)
  • PARI
    A055615(n) = (n*moebius(n));
    A349570(n) = sumdiv(n,d,(2^(d-1)) * A055615(n/d));

Formula

a(n) = Sum_{d|n} 2^(d-1) * A055615(n/d).

A160619 a(n) = Sum_{d|n} phi(n/d)*2^(d+1), with a(0) = 0.

Original entry on oeis.org

0, 4, 12, 24, 48, 80, 168, 280, 576, 1080, 2160, 4136, 8448, 16432, 33096, 65760, 131712, 262208, 525672, 1048648, 2099520, 4194960, 8392824, 16777304, 33564096, 67109200, 134234256, 268437672, 536904480, 1073741936, 2147554080, 4294967416, 8590066944
Offset: 0

Views

Author

N. J. A. Sloane, Nov 21 2009

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_]:= If[n<1, 0, Sum[EulerPhi[n/d] 2^(d+1), {d, Divisors[n]}]]; Table[a[n], {n, 0, 50}] (* G. C. Greubel, May 06 2018 *)
  • PARI
    a(n) = if (n==0, 0, sumdiv(n, d, eulerphi(n/d)*2^(d+1))); \\ Michel Marcus, May 07 2018; corrected Jun 14 2022

Formula

a(n) = 4*A034738(n). - Michel Marcus, May 07 2018

Extensions

Name edited by Michel Marcus, Jun 14 2022

A181847 Triangle read by rows: T(n,k)= Sum_{c in C(n,k)}gcd(c) where C(n,k) is the set of all k-tuples of positive integers whose elements sum to n.

Original entry on oeis.org

1, 2, 1, 3, 2, 1, 4, 4, 3, 1, 5, 4, 6, 4, 1, 6, 9, 11, 10, 5, 1, 7, 6, 15, 20, 15, 6, 1, 8, 12, 24, 36, 35, 21, 7, 1, 9, 12, 30, 56, 70, 56, 28, 8, 1, 10, 17, 42, 88, 127, 126, 84, 36, 9, 1
Offset: 1

Views

Author

Peter Luschny, Dec 07 2010

Keywords

Comments

C(n,k) counted by A007318(n-1,k-1) are also called compositions of n of size k (see A181842).

Examples

			[1]   1
[2]   2   1
[3]   3   2    1
[4]   4   4    3    1
[5]   5   4    6    4    1
[6]   6   9   11   10    5   1
[7]   7   6   15   20   15   6   1
		

Crossrefs

Programs

  • Maple
    with(combstruct): # By generating the objects, very inefficient.
    a181847_row := proc(n) local k,L,l,R,comp; R := NULL;
    for k from 1 to n do
       L := 0;
       comp := iterstructs(Composition(n),size=k):
       while not finished(comp) do
          l := nextstruct(comp);
          L := L + igcd(op(l));
       od;
       R := R,L;
    od;
    R end:
    # second Maple program:
    with(numtheory):
    T := (n, k) -> add(phi(d)*binomial(n/d-1, k-1), d = divisors(n)):
    seq(seq(T(n, k), k=1..n), n=1..10); # Peter Luschny, Aug 27 2019
  • Sage
    # uses[DivisorTriangle from A327029]
    # DivisorTriangle Computes the (0,0)-based version.
    DivisorTriangle(euler_phi, lambda n,k: binomial(n-1, k-1), 10) # Peter Luschny, Aug 27 2019

A327030 a(n) = Sum_{d|n} phi(d)*(n/d)! for n > 0, a(0) = 0.

Original entry on oeis.org

0, 1, 3, 8, 28, 124, 732, 5046, 40352, 362898, 3628932, 39916810, 479002388, 6227020812, 87178296258, 1307674368272, 20922789928384, 355687428096016, 6402373706092350, 121645100408832018, 2432902008180269152, 51090942171709450128, 1124000727777647596830
Offset: 0

Views

Author

Peter Luschny, Aug 27 2019

Keywords

Comments

Dirichlet convolution of phi(n) and n! (n >= 1). - Richard L. Ollerton, May 09 2021

Crossrefs

Similar: A078392 (numbpart), A258171 (bell), A053635 (numbcomb), A181847 and A034738 (numbcomp), this sequence (numbperm).

Programs

  • Magma
    [0] cat [&+[EulerPhi(d)*Factorial(n div d):d in Divisors(n)]:n in [1..22]]; // Marius A. Burtea, Nov 13 2019
    
  • Magma
    [0] cat [&+[Factorial(Gcd(n,i)):i in [1..n]]:n in [1..22]]; // Marius A. Burtea, Nov 13 2019
  • Maple
    with(numtheory); A327030 := n -> add(phi(d)*(n/d)!, d = divisors(n)):
    seq(A327030(n), n=0..22);
  • Mathematica
    a[0] = 0; a[n_] := DivisorSum[n, EulerPhi[#] * (n/#)! &]; Array[a, 23, 0] (* Amiram Eldar, May 24 2021 *)
  • PARI
    a(n) = if (n>0, sumdiv(n, d, eulerphi(d)*(n/d)!), 0); \\ Michel Marcus, Aug 28 2019
    

Formula

a(n) = Sum_{i=1..n} gcd(n,i)!. - Ridouane Oudra, Nov 13 2019

A382999 a(n) = Sum_{d|n} phi(n/d) * (-2)^(d-1).

Original entry on oeis.org

1, -1, 6, -8, 20, -30, 70, -136, 270, -500, 1034, -2088, 4108, -8134, 16440, -32912, 65552, -130878, 262162, -524800, 1048740, -2096138, 4194326, -8390976, 16777300, -33550348, 67109418, -134225840, 268435484, -536855640, 1073741854, -2147516704, 4294969404
Offset: 1

Views

Author

Seiichi Manyama, Apr 12 2025

Keywords

Crossrefs

Column k=2 of A382995.

Programs

  • PARI
    a(n) = sumdiv(n, d, eulerphi(n/d)*(-2)^(d-1));

Formula

a(n) = Sum_{k=1..n} (-2)^(gcd(n,k) - 1).
G.f.: Sum_{k>=1} phi(k) * x^k / (1 + 2*x^k).

A338647 a(n) = Sum_{k=1..n} 2^(k/gcd(n,k) - 1).

Original entry on oeis.org

1, 2, 4, 7, 16, 22, 64, 92, 223, 342, 1024, 1132, 4096, 5462, 13534, 21937, 65536, 70978, 262144, 333472, 890590, 1398102, 4194304, 4528402, 16236031, 22369622, 57522106, 88435312, 268435456, 272976502, 1073741824, 1431677702, 3679303390, 5726623062, 16490405374, 18543422953
Offset: 1

Views

Author

Ilya Gutkovskiy, Apr 22 2021

Keywords

Crossrefs

Programs

  • Mathematica
    Table[Sum[2^(k/GCD[n, k] - 1), {k, 1, n}], {n, 1, 36}]
  • PARI
    a(n) = sum(k=1, n, 2^(k/gcd(n,k) - 1)); \\ Michel Marcus, Apr 22 2021

Formula

a(n) = Sum_{d|n} A054432(d).

A346558 a(n) = Sum_{d|n} phi(n/d) * (2^d - 1).

Original entry on oeis.org

1, 4, 9, 20, 35, 78, 133, 280, 531, 1070, 2057, 4212, 8203, 16534, 32865, 65840, 131087, 262818, 524305, 1049740, 2097459, 4196390, 8388629, 16782024, 33554575, 67117102, 134218809, 268452212, 536870939, 1073777010, 2147483677, 4295033440, 8589938775, 17180000318, 34359739085
Offset: 1

Views

Author

Ilya Gutkovskiy, Sep 17 2021

Keywords

Crossrefs

Programs

  • Mathematica
    Table[Sum[EulerPhi[n/d] (2^d - 1), {d, Divisors[n]}], {n, 1, 35}]
    nmax = 35; CoefficientList[Series[Sum[EulerPhi[k] x^k/((1 - x^k) (1 - 2 x^k)), {k, 1, nmax}], {x, 0, nmax}], x] // Rest
  • PARI
    a(n) = sumdiv(n, d, eulerphi(n/d)*(2^d - 1)); \\ Michel Marcus, Sep 17 2021

Formula

G.f.: Sum_{k>=1} phi(k) * x^k / ((1 - x^k) * (1 - 2*x^k)).
a(n) = Sum_{k=1..n} (2^gcd(n,k) - 1).
a(n) = n * (A000031(n) - 1) = n * A008965(n).
Dirichlet convolution of A000225 and A000010. - R. J. Mathar, Sep 30 2021
Previous Showing 11-19 of 19 results.