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

A046776 Number of partitions of 5n with equal number of parts congruent to each of 0, 1, 2, 3 and 4 (mod 5).

Original entry on oeis.org

1, 0, 0, 1, 5, 15, 36, 75, 146, 271, 495, 891, 1601, 2851, 5051, 8851, 15362, 26331, 44642, 74787, 123991, 203433, 330717, 532872, 851779, 1351147, 2128324, 3330059, 5177768, 8002170, 12296754, 18791945, 28566751, 43204575, 65022987, 97395386, 145217908
Offset: 0

Views

Author

Keywords

Comments

Number of partitions of m with equal numbers of parts congruent to each of 1, 2, 3 and 4 (mod 5) is 0 unless m == 0 mod 5.

Crossrefs

Programs

  • Maple
    mkl:= proc(i,l) local ll, mn, ii, x; ii:= irem(i,5); ii:= `if`(ii=0, 5, ii); ll:= applyop(x->x+1, ii, l); mn:= min(l[]); `if`(mn=0, ll, map (x->x-mn, ll)) end:
    g:= proc(n,i,t) local m, mx, j; if n<0 then 0 elif n=0 then `if`(nops ({t[]})=1, 1, 0) elif i=0 then 0 elif i<6 then mx:= max (t[]); m:= n-15*mx +add(t[j]*j, j=1..5); g(n,i,t):= `if`(m>=0 and irem(m, 15)=0, 1, 0) else g(n,i,t):= g(n, i-1, t) + g(n-i, i, mkl(i, t)) fi end:
    a:= n-> g(5*n, 5*n, [0$5]):
    seq(a(n), n=0..20);  # Alois P. Heinz, Jul 04 2009
  • Mathematica
    $RecursionLimit = 1000; mkl[i_, l_List] := Module[{ ll, mn, ii, x}, ii = Mod[i, 5]; ii = If[ii == 0, 5, ii]; ll = MapAt[#+1&, l, ii]; mn = Min[l]; If[mn == 0, ll, Map [#-mn&, ll]]]; g[n_, i_, t_List] := g[n, i, t] = Module[{ m, mx, j}, Which[n<0, 0 , n == 0, If[Length[t // Union] == 1, 1, 0], i==0, 0, i<6, mx = Max[t]; m = n-15*mx + Sum[t[[j]]*j, {j, 1, 5}]; If[m >= 0 && Mod[m, 15] == 0, 1, 0], True, g[n, i-1, t] + g[n-i, i, mkl[i, t]]]]; a[n_] := g[5*n, 5*n, {0, 0, 0, 0, 0}]; Table[a[n], {n, 0, 20}] (* Jean-François Alcover, Jul 21 2015, after Alois P. Heinz *)
  • PARI
    seq(n)={Vec(sum(k=0, n\3, x^(3*k)/prod(j=1, k, 1 - x^j + O(x*x^n))^5) + O(x*x^n))} \\ Andrew Howroyd, Sep 16 2019

Formula

a(n) = A202085(n) - A202086(n).
a(n) = A036884(n) - A036886(n).
a(n) = A036889(n) - A036892(n).
a(n) = A202087(n) - A202088(n).
G.f.: Sum_{k>=0} x^(3*k)/(Product_{j=1..k} 1 - x^j)^5. - Andrew Howroyd, Sep 16 2019

Extensions

a(18)-a(35) from Alois P. Heinz, Jul 04 2009
Edited by Max Alekseyev, Dec 11 2011
a(36) from Alois P. Heinz, Feb 03 2013

A036892 Number of partitions of 5n such that cn(1,5) = cn(4,5) < cn(0,5) = cn(2,5) = cn(3,5).

Original entry on oeis.org

0, 1, 3, 7, 14, 30, 62, 133, 275, 562, 1109, 2145, 4035, 7457, 13509, 24115, 42405, 73667, 126420, 214681, 360778, 600625, 990756, 1620449, 2628504, 4230770, 6758916, 10721739, 16892541, 26443435, 41137558, 63618639, 97825383, 149605621, 227593695
Offset: 1

Views

Author

Keywords

Comments

Alternatively, number of partitions of 5n such that cn(2,5) = cn(3,5) < cn(0,5) = cn(1,5) = cn(4,5).
For a given partition, cn(i,n) means the number of its parts equal to i modulo n.

Formula

a(n) = A036891(n) - A036895(n)
a(n) = A036890(n) - A036894(n)
a(n) = A036889(n) - A046776(n)

Extensions

Terms a(10) onward from Max Alekseyev, Dec 11 2011

A036881 Number of partitions of 5n such that cn(1,5) = cn(4,5) <= cn(0,5) <= cn(2,5) = cn(3,5).

Original entry on oeis.org

1, 4, 11, 29, 69, 160, 349, 743, 1526, 3067, 6011, 11566, 21813, 40476, 73879, 132927, 235842, 413211, 715261, 1224476, 2074156, 3479110, 5781362, 9523182, 15556055, 25210722, 40550228, 64757269, 102708208, 161838160, 253415308, 394437255
Offset: 1

Views

Author

Keywords

Comments

Alternatively, number of partitions of 5n such that cn(2,5) = cn(3,5) <= cn(0,5) <= cn(1,5) = cn(4,5).
For a given partition, cn(i,n) means the number of its parts equal to i modulo n.

Programs

  • Maple
    mkl:= proc(i,l) local ll, mn, x; ll:= applyop (x->x+1, irem (i,5)+1, l); mn:= min (ll[]); `if` (mn=0, ll, map (x->x-mn, ll)) end:
    g:= proc (n,i,t) if n<0 then 0 elif n=0 then `if` (t[2]=t[5] and t[5]<=t[1] and t[1]<=t[3] and t[3]=t[4],1,0) elif i=0 then 0 elif i=1 then g (0, 0, [t[1], t[2]+n, t[3], t[4], t[5]]) elif i=2 then `if` (t[3]>t[4], 0, g (n-2*(t[4]-t[3]), 1, [t[1], t[2], t[4], t[4], t[5]])) else g(n,i,t):= g (n,i-1,t) +g (n-i,i, mkl(i,t)) fi end:
    a:= n-> g(5*n, 5*n, [0,0,0,0,0]):
    seq(a(n), n=1..15);  # Alois P. Heinz, Jul 02 2009
  • Mathematica
    mkl[i_, l_] := Module[{ll, mn, x}, ll = MapAt[#+1&, l, Mod[i, 5]+1]; mn = Min[ll]; If[mn==0, ll, Map[#-mn&, ll]]]; g[n_, i_, t_List] := g[n, i, t] = Which[n<0, 0, n == 0, If[t[[2]] == t[[5]] && t[[5]] <= t[[1]] && t[[1]] <= t[[3]] && t[[3]] == t[[4]], 1, 0], i==0, 0, i==1, g[0, 0, {t[[1]], t[[2]]+n, t[[3]], t[[4]], t[[5]]}] , i==2, If[t[[3]]>t[[4]], 0, g[n-2*(t[[4]]-t[[3]]), 1, {t[[1]], t[[2]], t[[4]], t[[4]], t[[5]]}]], True, g[n, i-1, t] + g[n-i, i, mkl[i, t]]]; a[n_] := g[5*n, 5*n, {0, 0, 0, 0, 0}]; Table[a[n], {n, 1, 15}] (* Jean-François Alcover, Jul 29 2015, after  Alois P. Heinz *)

Formula

a(n) = A036889(n) + A036885(n)
a(n) = A036884(n) + A036890(n)

Extensions

a(10)-a(32) from Alois P. Heinz, Jul 02 2009
Edited by Max Alekseyev, Dec 11 2011

A036882 Number of partitions of 5n such that cn(1,5) = cn(4,5) <= cn(2,5) = cn(3,5) <= cn(0,5).

Original entry on oeis.org

1, 1, 3, 8, 22, 54, 128, 282, 602, 1235, 2474, 4831, 9263, 17418, 32242, 58737, 105519, 186976, 327238, 565896, 967910, 1638175, 2745588, 4558864, 7503737, 12248234, 19835700, 31882617, 50881290, 80648122, 126998962, 198743334, 309163475, 478177505, 735522058
Offset: 0

Views

Author

Keywords

Comments

Alternatively, number of partitions of 5n such that cn(2,5) = cn(3,5) <= cn(1,5) = cn(4,5) <= cn(0,5).
For a given partition cn(i,n) means the number of its parts equal to i modulo n.

Programs

  • Maple
    mkl:= proc(i, l) local ll, x, j; j:= irem (i, 5); j:= `if` (j=0, 5, j); ll:= applyop (x->x+1, j, l); map (x-> x-min(ll[]), ll) end:
    g:= proc (n, i, t) local x; if n<0 then 0 elif n=0 then `if` (t[1]=t[4] and t[4]<=t[2] and t[2]=t[3] and t[3]<=t[5], 1, 0) elif i=0 then 0 elif i=1 then g (0, 0, applyop (x-> x+n, 1, t)) elif i=2 then `if` (t[2]>t[3], 0, g (n-2*(t[3]-t[2]), 1, subsop(2=t[3], t))) elif (i=3 or i=4) and t[i]>t[5] then 0 else g(n, i, t):= g (n, i-1, t) +g (n-i, i, mkl(i, t)) fi end:
    a:= n-> g(5*n, 5*n, [0, 0, 0, 0, 0]):
    seq(a(n), n=0..15);  # Alois P. Heinz, Jul 07 2009
  • Mathematica
    mkl[i_, l_List] := Module[{ll, x, j}, j = Mod[i, 5]; j = If[j == 0, 5, j]; ll = MapAt [#+1&, l, j]; ll - Min[ll]]; g[n_, i_, t_List] := g[n, i, t] = Which[n<0, 0, n == 0, If[t[[1]] == t[[4]] && t[[4]] <= t[[2]] && t[[2]] == t[[3]] && t[[3]] <= t[[5]], 1, 0], i == 0, 0, i == 1, g[0, 0, MapAt [#+n&, t, 1]], i == 2, If[t[[2]] > t[[3]], 0, g[n - 2*(t[[3]] - t[[2]]), 1, ReplacePart[t, 2 -> t[[3]]]]], (i == 3 || i == 4) && t[[i]] > t[[5]], 0, True, g[n, i, t] = g[n, i-1, t] + g[n-i, i, mkl[i, t]]]; a[n_] := a[n] = g[5*n, 5*n, {0, 0, 0, 0, 0}]; Table[Print["a(", n, ") = ", a[n]]; a[n], {n, 0, 32}] (* Jean-François Alcover, Dec 23 2015, after Alois P. Heinz *)

Formula

a(n) = A036889(n) + A036887(n)
a(n) = A202085(n) + A036891(n)

Extensions

a(10)-a(32) from Alois P. Heinz, Jul 07 2009
Edited by Max Alekseyev, Dec 11 2011
More terms from Alois P. Heinz, Dec 23 2015

A036885 Number of partitions of 5n such that cn(1,5) = cn(4,5) <= cn(0,5) < cn(2,5) = cn(3,5).

Original entry on oeis.org

1, 3, 7, 17, 40, 94, 212, 464, 980, 2010, 4011, 7820, 14927, 27968, 51519, 93450, 167106, 294902, 514054, 885804, 1509945, 2547768, 4257734, 7050954, 11576404, 18851628, 30461253, 48857762, 77813497, 123097971, 193485805, 302251865, 469376012
Offset: 1

Views

Author

Keywords

Comments

Alternatively, number of partitions of 5n such that cn(2,5) = cn(3,5) <= cn(0,5) < cn(1,5) = cn(4,5).
For a given partition, cn(i,n) means the number of its parts equal to i modulo n.

Formula

a(n) = A036881(n) - A036889(n)
a(n) = A036886(n) + A036894(n)

Extensions

Terms a(10) onward from Max Alekseyev, Dec 10 2011

A036887 Number of partitions of 5n such that cn(1,5) = cn(4,5) <= cn(2,5) = cn(3,5) < cn(0,5).

Original entry on oeis.org

1, 2, 4, 10, 25, 62, 145, 323, 689, 1417, 2831, 5517, 10532, 19734, 36377, 66042, 118240, 208929, 364689, 629238, 1073964, 1814246, 3035236, 5031509, 8268583, 13476606, 21793642, 34981783, 55753411, 88258773, 138813831, 216978085, 337147547
Offset: 1

Views

Author

Keywords

Comments

Alternatively, number of partitions of 5n such that cn(2,5) = cn(3,5) <= cn(1,5) = cn(4,5) < cn(0,5).
For a given partition, cn(i,n) means the number of its parts equal to i modulo n.

Formula

a(n) = A036882(n) - A036889(n)
a(n) = A202086(n) + A036895(n)

Extensions

Terms a(10) onward from Max Alekseyev, Dec 10 2011

A351318 a(n) is the least prime prime(k), k > n, such that A036689(k) or A036690(k) is s(n) + s(n+1) + ... + s(j), j < k, where each s(i) is either A036689(i) or A036690(i).

Original entry on oeis.org

3, 7, 13, 31, 47, 47, 53, 53, 73, 137, 103, 131, 109, 137, 239, 257, 229, 349, 257, 269, 331, 347, 389, 409, 257, 389, 251, 229, 499, 487, 509, 491, 541, 487, 353, 739, 571, 743, 727, 307, 883, 743, 929, 827, 971, 911, 887, 569, 1063, 751, 1013, 883, 1451, 977, 1259, 853, 983, 947, 967, 1049
Offset: 1

Views

Author

J. M. Bergot and Robert Israel, Mar 18 2022

Keywords

Comments

a(n) is the least prime p such that p*(p-1) or p*(p+1) is the sum of a sequence where each term is either prime(i)*(prime(i)-1) or prime(i)*(prime(i)+1), for i from n to some j.

Examples

			a(3) = 13 because prime(3) = 5, the next two primes are 7 and 11, and 5*6 + 7*6 + 11*10 = 182 = 13*14.
		

Crossrefs

Programs

  • Maple
    P:= select(isprime, [2,seq(i,i=3..10^6,2)]):
    R:= convert(map(p -> (p*(p-1),p*(p+1)),P),set):
    f:= proc(n) local S,T,SR,i,s;
      S:= {P[n]*(P[n]-1),P[n]*(P[n]+1)};
      for i from n+1 do
        T:= [P[i]*(P[i]-1),P[i]*(P[i]+1)];
        S:= map(s -> (s+T[1],s+T[2]),S);
        SR:= S intersect R;
        if SR <> {} then
            s:= (sqrt(1+4*min(SR))-1)/2;
          if isprime(s) then return s else return s+1 fi
        fi
      od
    end proc:
    map(f, [$1..100]);

A202091 Number of partitions of 5n such that cn(1,5) = cn(4,5) and cn(2,5) = cn(3,5).

Original entry on oeis.org

1, 3, 11, 32, 88, 221, 532, 1213, 2672, 5676, 11724, 23568, 46315, 89076, 168124, 311763, 569000, 1023128, 1814776, 3178000, 5499588, 9411392, 15938221, 26726372, 44402336, 73121988, 119418609, 193488816, 311150404, 496783420, 787753316
Offset: 0

Views

Author

Max Alekseyev, Dec 11 2011

Keywords

Comments

For a given partition, cn(i,n) means the number of its parts equal to i modulo n.

Crossrefs

Formula

a(n) = A046776(n) + A202086(n) + A202088(n) + 2*( A036886(n) + A036892(n) + A036893(n) + A036894(n) + A036895(n) )
a(n) = A202192(n) + 2*( A036886(n) + A036892(n) + A036893(n) + A036894(n) + A036895(n) )
Showing 1-8 of 8 results.