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.

A294812 Let b(n) be the number of permutations {c_1..c_n} of {1..n} for which c_1 - c_2 + ... + (-1)^(n-1)*c_n are pentagonal numbers (A000326). Then a(n) = b(n)/A010551(n).

Original entry on oeis.org

1, 1, 1, 2, 4, 5, 6, 10, 23, 38, 70, 110, 196, 346, 759, 1250, 2313, 3982, 8433, 14520, 29437, 50466, 102830, 179587, 376439, 654374, 1343540, 2352149, 4916286, 8654120, 18065200, 31783592, 66233160, 117371504, 246610521, 436972949, 913862320, 1626523783
Offset: 1

Views

Author

Keywords

Comments

All terms are positive integers (for a proof, cf. comment in A293984).
Note that a(1), a(2), a(3), a(4) remain the same, if in the definition the pentagonal numbers are replaced by k-gonal numbers for k >= 3 other than k=4.

Crossrefs

Programs

  • Mathematica
    polyQ[order_,n_]:=If[n==0,True,IntegerQ[(#-4+Sqrt[(#-4)^2+8 n (#-2)])/(2 (#-2))]&[order]];(*is a number polygonal?*)
    Map[Total,Table[
    possibleSums=Range[1/2-(-1)^n/2-Floor[n/2]^2,Floor[(n+1)/2]^2];
    filteredSums=Select[possibleSums,polyQ[5,#]&&#>-1&];
    positions=Map[Flatten[{#,Position[possibleSums,#,1]-1}]&,filteredSums];
    Map[SeriesCoefficient[QBinomial[n,Floor[(n+1)/2],q],{q,0,#[[2]]/2}]&,positions],{n,25}]] (* Peter J. C. Moses, Jan 02 2018 *)