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

A117571 Expansion of (1+2*x^2)/((1-x)*(1-x^3)).

Original entry on oeis.org

1, 1, 3, 4, 4, 6, 7, 7, 9, 10, 10, 12, 13, 13, 15, 16, 16, 18, 19, 19, 21, 22, 22, 24, 25, 25, 27, 28, 28, 30, 31, 31, 33, 34, 34, 36, 37, 37, 39, 40, 40, 42, 43, 43, 45, 46, 46, 48, 49, 49, 51, 52, 52, 54, 55, 55, 57, 58, 58, 60, 61, 61, 63, 64, 64, 66, 67, 67, 69, 70, 70, 72
Offset: 0

Views

Author

Paul Barry, Mar 29 2006

Keywords

Comments

Row sums of A116948.
Place n+2 equally-spaced points around a circle, labeled 0,1,2,...,n+1. For each i = 0..n+1 such that 2i != i mod n+2, draw an (undirected) chord from i to 2i mod n+2. Then a(n) is the number of distinct chords. - Kival Ngaokrajang, May 13 2016 (Edited by N. J. A. Sloane, Jun 23 2016)
From Gus Wiseman, Apr 19 2019: (Start)
Also the number of integer partitions of n + 2 with 1 fewer distinct multiplicities than (not necessarily distinct) parts. These are partitions of the form (x,x), (x,y), (x,x,y), or (x,y,y). For example, the a(0) = 1 through a(8) = 9 partitions are the following. The Heinz numbers of these partitions are given by A325270.
(11) (21) (22) (32) (33) (43) (44) (54) (55)
(31) (41) (42) (52) (53) (63) (64)
(211) (221) (51) (61) (62) (72) (73)
(311) (411) (322) (71) (81) (82)
(331) (332) (441) (91)
(511) (422) (522) (433)
(611) (711) (442)
(622)
(811)
(End)

Crossrefs

Programs

  • Magma
    [1 + Floor(2*n/3) + Floor((n+1)/3) : n in [0..100]]; // Wesley Ivan Hurt, Jul 25 2016
  • Maple
    A117571:=n->1 + floor(2*n/3) + floor((n+1)/3): seq(A117571(n), n=0..100); # Wesley Ivan Hurt, Jul 25 2016
  • Mathematica
    CoefficientList[Series[(1 + 2 x^2)/((1 - x) (1 - x^3)), {x, 0, 71}], x] (* Michael De Vlieger, May 13 2016 *)

Formula

G.f.: (1+2*x^2)/((1-x)*(1-x^3)).
a(n) = a(n-1) + a(n-3) - a(n-4) for n>3.
a(n) = cos(2*Pi*n/3+Pi/6)/sqrt(3)-sin(2*Pi*n/3+Pi/6)/3+(3n+2)/3.
a(n) = Sum_{k=0..n} 2*A001045(L((n-k+2)/3)) where L(j/p) is the Legendre symbol of j and p.
a(n) = 1 + floor((n+1)/3) + floor(2*n/3). - Wesley Ivan Hurt, Jul 25 2016
a(n) = n+sign((n-1) mod 3). - Wesley Ivan Hurt, Sep 25 2017

A274462 Place n equally-spaced points around a circle, labeled 0,1,2,...,n-1. For each i = 0..n-1 such that 4i != i mod n, draw an (undirected) chord from i to (4i mod n). Then a(n) is the total number of distinct chords.

Original entry on oeis.org

0, 0, 1, 0, 3, 2, 3, 6, 7, 6, 7, 10, 9, 12, 13, 6, 15, 16, 15, 18, 17, 18, 21, 22, 21, 22, 25, 24, 27, 28, 21, 30, 31, 30, 33, 32, 33, 36, 37, 36, 37, 40, 39, 42, 43, 36, 45, 46, 45, 48, 47, 48, 51, 52, 51, 52, 55, 54, 57, 58, 51
Offset: 0

Views

Author

Brooke Logan, Jun 24 2016

Keywords

Crossrefs

If 4i in the definition is replaced by 2i we get A117571, and if 4i is replaced by 3i we get A273724.

Programs

  • Maple
    M:=4; # M is the multiplier (2 for A117571, 3 for A273724, 4 for the present sequence)
    ans:=[0,0];
    for n from 2 to 100 do
    h:=Array(0..n-1,0..n-1,0); ct:=0;
    for i from 1 to n-1 do j := (M*i mod n);
    if ij then if h[j,i]=0 then ct:=ct+1; h[j,i]:=1; fi;
    fi;
    od:
    ans:=[op(ans),ct];
    od:
    ans;  # N. J. A. Sloane, Jun 24 2016

Formula

We argue as in A273724. There are n-1 choices for i.
For nontrivial chords we need i != 4i mod n, which means 3i != 0 mod n, and so when n == 0 mod 3 we must subtract 2 from n-1.
A chord occurs twice (but must be counted only once) when j==4i mod n and i==4j mod n, thus when 15i==0 mod n. If n==+/- 5 mod 15 then subtract another 2, if n==0 mod 15 subtract 6.
Putting the pieces together, we obtain the g.f.
8 + x^2/(1-x)^2 - 2/(1-x^3) - 2(x^5+x^10)/(1-x^15) - 6/(1-x^15),
which can be rewritten as
x^2*(9*x^14-7*x^13+x^12+3*x^11-x^10+3*x^9+x^8-x^7+x^6+3*x^5+x^4-x^3+3*x^2-x+1)/((1-x)*(1-x^15)).

A274516 Place n equally-spaced points around a circle, labeled 0,1,2,...,n-1. For each i = 0..n-1 such that 5i != i mod n, draw an (undirected) chord from i to (5i mod n). Then a(n) is the total number of distinct chords.

Original entry on oeis.org

0, 0, 0, 1, 0, 4, 2, 6, 2, 7, 8, 10, 4, 12, 12, 13, 10, 16, 14, 18, 16, 19, 20, 22, 10, 24, 24, 25, 24, 28, 26, 30, 26, 31, 32, 34, 28, 36, 36, 37, 34, 40, 38, 42, 40, 43, 44, 46, 34, 48, 48, 49, 48, 52, 50, 54, 50, 55, 56, 58, 52, 60, 60
Offset: 0

Views

Author

Brooke Logan, Jun 25 2016

Keywords

Crossrefs

If 5i in the definition is replaced by 2i we get A117571, if 5i is replaced by 3i we get A273724, and if 5i is replaced by 4i we get A274462.

Formula

We argue as in A273724. There are n-1 choices for i.
For nontrivial chords we need i != 5i mod n, which means 4i != 0 mod n, and so when n == 0 mod 4 we must subtract 3 from n-1 and when n == 2 mod 4 we must subtract 1 from n-1.
A chord occurs twice (but must be counted only once) when j==5i mod n and i==5j mod n, thus when 24i == 0 mod n. If n == +/- 3, +/- 9 mod 24 then subtract another 1, if n == +/- 6, +/- 8 mod 24 then subtract another 2, if n==12 mod 24 subtract 4, and if n == 0 mod 24 then subtract another 10.
Putting the pieces together, we obtain the g.f.
x^2/(1-x)^2-(3+x^2)/(1-x^4)-(x^3+x^9+x^15+x^21)/(1-x^24)-2(x^6+x^8+x^16+x^18)/(1-x^24)-(4*x^12+10)/(1-x^24)+13.
The g.f. can also be written as
(14*x^25 - 12*x^24 + 2*x^23 + x^22 + 3*x^21 - 2*x^20 + 2*x^19 + 4*x^17 - x^16 + x^15 + 8*x^13 - 6*x^12 + 2*x^11 + x^10 + 3*x^9 - 2*x^8 + 2*x^7 + 4*x^5 - x^4 + x^3 + 2*x - 2) / ((1-x)*(1-x^24)).
Showing 1-3 of 3 results.