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-20 of 27 results. Next

A082905 Modified Pascal-triangle, read by rows. All C(n,j) binomial coefficients are replaced by C(n/g, j/g), where g = gcd(n,j).

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 3, 3, 1, 1, 4, 2, 4, 1, 1, 5, 10, 10, 5, 1, 1, 6, 3, 2, 3, 6, 1, 1, 7, 21, 35, 35, 21, 7, 1, 1, 8, 4, 56, 2, 56, 4, 8, 1, 1, 9, 36, 3, 126, 126, 3, 36, 9, 1, 1, 10, 5, 120, 10, 2, 10, 120, 5, 10, 1, 1, 11, 55, 165, 330, 462, 462, 330, 165, 55, 11, 1, 1, 12, 6, 4, 3, 792, 2, 792, 3, 4, 6, 12, 1
Offset: 0

Views

Author

Labos Elemer, Apr 23 2003

Keywords

Examples

			Triangle begins:
  1;
  1,  1;
  1,  2,  1;
  1,  3,  3,   1;
  1,  4,  2,   4,   1;
  1,  5, 10,  10,   5,   1;
  1,  6,  3,   2,   3,   6,  1;
  1,  7, 21,  35,  35,  21,  7,   1;
  1,  8,  4,  56,   2,  56,  4,   8, 1;
  1,  9, 36,   3, 126, 126,  3,  36, 9,  1;
  1, 10,  5, 120,  10,   2, 10, 120, 5, 10, 1;
		

Crossrefs

Programs

  • GAP
    T:= function(n,k)
        if k=0 or k=n then return 1;
        else return Binomial(n/Gcd(n,k), k/Gcd(n,k));
        fi;
      end;
    Flat(List([0..12], n-> List([0..n], k-> T(n,k) ))); # G. C. Greubel, Aug 30 2019
  • Mathematica
    Flatten[Table[Table[Binomial[n/GCD[n, j], j/GCD[n, j]], {j, 0, n}], {n, 1, 32}], 1]
  • PARI
    T(n,k) = my(g=gcd(n,k)); if (!g, g=1); binomial(n/g, k/g);
    tabl(nn) = for (n=0, nn, for (k=0, n, print1(T(n,k), ", "))); \\ Michel Marcus, Aug 30 2019
    
  • Sage
    def T(n,k):
        if k==0 or k==n: return 1
        else: return binomial(n/gcd(n,k), k/gcd(n,k))
    [[T(n,k) for k in (0..n)] for n in (0..12)] # G. C. Greubel, Aug 30 2019
    

Extensions

More terms from Michel Marcus, Aug 30 2019

A308812 a(n) = Sum_{k=1..n} binomial(n,k) * floor(n/k).

Original entry on oeis.org

1, 5, 13, 33, 61, 143, 246, 521, 985, 1995, 3499, 7923, 14028, 28642, 55603, 115369, 210665, 455399, 838338, 1755983, 3383652, 6974159, 13034492, 28011611, 52475486, 108821068, 210050941, 436273458, 824191369, 1744975533, 3301974301, 6867107913, 13250454241
Offset: 1

Views

Author

Ilya Gutkovskiy, Aug 22 2019

Keywords

Crossrefs

Cf. A056045.

Programs

  • Maple
    f:= proc(n) local k; add(binomial(n,k)*floor(n/k),k=1..n) end proc:
    map(f, [$1..100]); # Robert Israel, Aug 23 2019
  • Mathematica
    Table[Sum[Binomial[n, k] Floor[n/k] , {k, 1, n}], {n, 1, 33}]
    Table[SeriesCoefficient[1/(1 - x) Sum[Binomial[n, k] x^k/(1 - x^k), {k, 1, n}], {x, 0, n}], {n, 1, 33}]
    Table[Sum[Sum[Binomial[n, d], {d, Divisors[k]}], {k, 1, n}], {n, 1, 33}]

Formula

a(n) = [x^n] (1/(1 - x)) * Sum_{k=1..n} binomial(n,k) * x^k/(1 - x^k).
a(n) = Sum_{k=1..n} Sum_{d|k} binomial(n,d).
a(n) ~ 3 * 2^(n-1). - Vaclav Kotesovec, May 28 2021

A327124 Expansion of Sum_{k>=1} ((1 - (-x)^k)^k - 1).

Original entry on oeis.org

1, -2, 3, -3, 5, -3, 7, -2, 10, 0, 11, -1, 13, 7, 25, 13, 17, -2, 19, 30, 56, 33, 23, 1, 26, 52, 111, 98, 29, -51, 31, 158, 198, 102, 56, 24, 37, 133, 325, 304, 41, -189, 43, 517, 626, 207, 47, 191, 50, -2, 731, 988, 53, -435, 517, 1315, 1026, 348, 59, 18
Offset: 1

Views

Author

Ilya Gutkovskiy, Sep 14 2019

Keywords

Crossrefs

Programs

  • Mathematica
    nmax = 60; CoefficientList[Series[Sum[((1 - (-x)^k)^k - 1), {k, 1, nmax}], {x, 0, nmax}], x] // Rest
    Table[DivisorSum[n, (-1)^(n - #) Binomial[n/#, #] &], {n, 1, 60}]
  • PARI
    a(n)={sumdiv(n, d, (-1)^(n-d) * binomial(n/d,d))} \\ Andrew Howroyd, Sep 14 2019

Formula

a(n) = Sum_{d|n} (-1)^(n-d) * binomial(n/d,d).
a(p) = p, where p is odd prime.

A330017 a(1) = 1; a(n+1) = Sum_{d|n} binomial(n,d) * a(d).

Original entry on oeis.org

1, 1, 3, 6, 16, 21, 102, 109, 565, 826, 4913, 4924, 28036, 28049, 378218, 427646, 1841532, 1841549, 29704312, 29704331, 182590131, 194454702, 3660242371, 3660242394, 17058569521, 17059419626, 308650641577, 311298706504, 1436650115240, 1436650115269
Offset: 1

Views

Author

Ilya Gutkovskiy, Nov 27 2019

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_] := a[n] = Sum[Binomial[n - 1, d] a[d], {d, Divisors[n - 1]}]; a[1] = 1; Table[a[n], {n, 1, 30}]

A105863 a(n) = n * Sum_{d|n} (binomial(n,d) / gcd(n,d)).

Original entry on oeis.org

1, 6, 12, 44, 30, 252, 56, 856, 846, 3080, 132, 20616, 182, 49532, 52110, 237232, 306, 1227096, 380, 4106320, 2470272, 15525092, 552, 86092176, 1328900, 270424752, 126624006, 1157002616, 870, 5577100260, 992, 19572325728, 6386892930
Offset: 1

Views

Author

Robert G. Wilson v, Apr 23 2005

Keywords

Crossrefs

Programs

  • Mathematica
    f[n_] := Block[{d = Divisors[n]}, n*Plus @@ (Binomial[n, d])]; Table[ f[n], {n, 34}]

Formula

a(n) = n * A056045(n) = n * Sum_{d|n} (binomial(n, d) / gcd(n, d)).

A308943 a(n) = Product_{d|n} binomial(n,d).

Original entry on oeis.org

1, 2, 3, 24, 5, 1800, 7, 15680, 756, 113400, 11, 79693891200, 13, 4372368, 20495475, 44972928000, 17, 2028339316523520, 19, 52737518268864000, 3247700400, 3585005424, 23, 38135556819759802035135799296, 1328250, 87885070000, 370142004375, 10293527616645873600000, 29
Offset: 1

Views

Author

Ilya Gutkovskiy, Jul 01 2019

Keywords

Crossrefs

Cf. A001142, A008578 (fixed points), A056045 (similar, with Sum), A098710, A135396.
Cf. A000010 (comments on product formulas).

Programs

  • Mathematica
    Table[Product[Binomial[n, d], {d, Divisors[n]}], {n, 1, 29}]
  • PARI
    a(n) = my(p=1); fordiv(n, d, p *= binomial(n, d)); p; \\ Michel Marcus, Jul 02 2019
    
  • Python
    from math import prod, comb
    from sympy import divisors
    def A308943(n): return prod(comb(n,d) for d in divisors(n,generator=True)) # Chai Wah Wu, Jul 22 2024

Formula

a(n) = Product_{k=1..n} binomial(n,gcd(n,k))^(1/phi(n/gcd(n,k))) = Product_{k=1..n} binomial(n,n/gcd(n,k))^(1/phi(n/gcd(n,k))) where phi = A000010. - Richard L. Ollerton, Nov 08 2021

A345136 a(1) = 1; a(n) = Sum_{d|n, d < n} binomial(n,d) * a(d).

Original entry on oeis.org

1, 2, 3, 16, 5, 96, 7, 1184, 261, 1360, 11, 97428, 13, 24220, 16395, 15267456, 17, 14474736, 19, 251423600, 817971, 7760236, 23, 264344406312, 265675, 135208476, 1223270127, 971632668664, 29, 2584070688810, 31, 9176980861031424, 2128920321, 39671306896, 48694835
Offset: 1

Views

Author

Ilya Gutkovskiy, Jun 09 2021

Keywords

Crossrefs

Cf. A008578 (fixed points), A056045, A074206, A330017.

Programs

  • Mathematica
    a[1] = 1; a[n_] := a[n] = Sum[If[d < n, Binomial[n, d] a[d], 0], {d, Divisors[n]}]; Table[a[n], {n, 1, 35}]

A056189 a(n) = 2^n - A056188(n).

Original entry on oeis.org

1, 2, 2, 8, 2, 52, 2, 128, 170, 764, 2, 2488, 2, 11624, 16928, 32768, 2, 181324, 2, 555296, 931610, 2802584, 2, 11007664, 6643782, 43955032, 44739242, 136585808, 2, 720895864, 2, 2147483648, 3250384970, 10923540812, 11517062218
Offset: 1

Views

Author

Labos Elemer, Aug 02 2000

Keywords

Comments

For n > 1, a(n) is the number of binary words of length n such that the numbers of 0's and 1's are not coprime. - Bartlomiej Pawlik, Sep 03 2023

Examples

			For n=6, a(6)=52 because the sum of coefficients is restricted only to k=1,5 so a(6)=64-6-6.
		

Crossrefs

Programs

  • PARI
    a(n) = if (n==1, 1, 2^n - sum(k=0, n, if (gcd(n,k) == 1, binomial(n,k)))); \\ Michel Marcus, Mar 22 2020

Formula

a(n) = 2^n-Sum{binomial[n, k]; k>0, GCD[n, k]=1}, for n>1.
a(n) = 2 for primes.

A056190 a(n) = Sum_{d|n and gcd(d, n/d)=1} binomial(n,d).

Original entry on oeis.org

1, 3, 4, 5, 6, 42, 8, 9, 10, 308, 12, 728, 14, 3538, 3474, 17, 18, 48792, 20, 20370, 117632, 705686, 24, 737520, 26, 10400952, 28, 1204544, 30, 185903342, 32, 33, 193542210, 2333606816, 7049188, 94202222, 38, 35345264542, 8122434623
Offset: 1

Views

Author

Labos Elemer, Aug 02 2000

Keywords

Examples

			n=100 has 9 divisors of which {1,4,25,100} are unitary, so a(100) = 100 + 3921225 + 242519269720337121015504 + 1.
		

Crossrefs

Cf. A056045.

Programs

  • Maple
    a:= n-> add(`if`(igcd(d, n/d)=1, binomial(n, d), 0),
                          d=numtheory[divisors](n)):
    seq(a(n), n=1..40);  # Alois P. Heinz, Aug 25 2019
  • Mathematica
    a[n_] := Total[Binomial[n, Select[Divisors[n], CoprimeQ[#, n/#] &]]]; Array[a, 40] (* Amiram Eldar, Jul 28 2024 *)
  • PARI
    a(n) = sumdiv(n, d, if (gcd(d, n/d)==1, binomial(n, d))); \\ Michel Marcus, Aug 25 2019

Formula

a(n) = A056045(n) for squarefree n, when all divisors are unitary.

A082906 Sum of terms in n-th row of modified Pascal's triangle displayed in A082905.

Original entry on oeis.org

1, 2, 4, 8, 12, 32, 22, 128, 140, 350, 294, 2048, 1638, 8192, 4890, 15878, 32908, 131072, 81184, 524288, 493582, 1165676, 1393770, 8388608, 5771318, 26910682, 23162026, 89478836, 131854546, 536870912, 352862112, 2147483648, 2147516556
Offset: 0

Views

Author

Labos Elemer, Apr 23 2003

Keywords

Comments

In A082905, all binomial coefficients C(n,j) are replaced by C(n/g, j/g), where g=gcd(n,j); a(n) = Sum_{j=0..n-1} C(n/g, j/g).

Examples

			a(0)=1; a(12) = 1 + 12 + 6 + 4 + 3 + 792 + 2 + 792 + 3 + 4 + 6 + 12 + 1 = 1638.
		

Crossrefs

Programs

  • Mathematica
    Table[Apply[Plus, Table[Binomial[n/GCD[n, j], j/GCD[n, j]], {j, 0, n}]], {n, 0, 32}]
Previous Showing 11-20 of 27 results. Next