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 41-50 of 50 results.

A263768 Number of necklaces with n beads colored white or red, where the number of white beads is odd and at least three and turning over is allowed.

Original entry on oeis.org

1, 1, 3, 4, 8, 11, 22, 33, 62, 101, 189, 324, 611, 1087, 2055, 3770, 7154, 13363, 25481, 48174, 92204, 175791, 337593, 647325, 1246862, 2400841, 4636389, 8956059, 17334800, 33570815, 65108061, 126355335, 245492243, 477284181, 928772649, 1808538354, 3524337979, 6872209823
Offset: 3

Views

Author

David Eppstein, Oct 25 2015

Keywords

Comments

a(n) is also the number of non-isomorphic n-vertex undirected graphs forming an odd cycle with any number of degree-1 vertices attached to each cycle vertex. To transform a necklace into a graph of this type, create a cycle vertex for each white bead and a pendant vertex for each red bead, with each pendant vertex attached to the next clockwise cycle vertex. Since these are exactly the graphs of the n-vertex and n-edge linear thrackles, a(n) is also the number of non-isomorphic linear thrackles.
For any n there is a unique n-bead necklace where the number of white beads is 1. Hence this sequence is one less than the number of n-bead (0,1) bracelets with an odd number of 0's. - Andrew Howroyd, Feb 28 2017

Examples

			For n=5 the a(5)=3 solutions are: five white beads (a 5-cycle), three white beads and two red beads with the two red beads adjacent (a triangle with two pendant vertices attached at one triangle vertex), and three white beads and two red beads with the two red beads separated (a triangle with two of its vertices having a single pendant vertex attached).
		

Crossrefs

Programs

Formula

a(n) = (A000016(n) + A016116(n-1)) / 2 - 1. - Andrew Howroyd, Feb 28 2017
a(n) = A007147(n) - 1. - Bernd Mulansky, Mar 08 2023

Extensions

a(21)-a(40) from Andrew Howroyd, Feb 28 2017

A361655 Number of even-length integer partitions of 2n with integer mean.

Original entry on oeis.org

0, 1, 3, 4, 10, 6, 33, 8, 65, 68, 117, 12, 583, 14, 319, 1078, 1416, 18, 3341, 20, 8035, 5799, 1657, 24, 36708, 16954, 3496, 24553, 68528, 30, 192180, 32, 178802, 91561, 14625, 485598, 955142, 38, 29223, 316085, 2622697, 42, 3528870, 44, 2443527, 5740043
Offset: 0

Views

Author

Gus Wiseman, Mar 23 2023

Keywords

Examples

			The a(0) = 0 through a(5) = 6 partitions:
  .  (11)  (22)    (33)      (44)        (55)
           (31)    (42)      (53)        (64)
           (1111)  (51)      (62)        (73)
                   (111111)  (71)        (82)
                             (2222)      (91)
                             (3221)      (1111111111)
                             (3311)
                             (4211)
                             (5111)
                             (11111111)
For example, the partition (4,2,1,1) has length 4 and mean 2, so is counted under a(4).
		

Crossrefs

Even-length partitions are counted by A027187, bisection A236913.
Including odd-length partitions gives A067538 bisected, ranks A316413.
For median instead of mean we have A361653.
The odd-length version is counted by A361656.
A000041 counts integer partitions, strict A000009.
A051293 counts subsets with integer mean, median A000975.
A058398 counts partitions by mean, see also A008284, A327482.
A325347 counts partitions with integer median, complement A307683.
A326567/A326568 gives mean of prime indices.
A326622 counts factorizations with integer mean.

Programs

  • Mathematica
    Table[Length[Select[IntegerPartitions[2n], EvenQ[Length[#]]&&IntegerQ[Mean[#]]&]],{n,0,15}]
  • PARI
    a(n)=if(n==0, 0, sumdiv(n, d, polcoef(1/prod(k=1, 2*d, 1 - x^k + O(x*x^(2*(n-d)))), 2*(n-d)))) \\ Andrew Howroyd, Mar 24 2023

Extensions

Terms a(36) and beyond from Andrew Howroyd, Mar 24 2023

A363525 Number of integer partitions of n with weighted sum divisible by reverse-weighted sum.

Original entry on oeis.org

1, 2, 2, 3, 2, 4, 2, 4, 5, 5, 3, 10, 4, 7, 13, 10, 8, 29, 10, 18, 39, 20, 20, 70, 29, 40, 105, 65, 55, 166, 73, 132, 242, 141, 129, 476, 183, 248, 580, 487, 312, 984, 422, 868, 1345, 825, 724, 2709, 949, 1505, 2756, 2902, 1611, 4664, 2289, 4942, 5828, 4278
Offset: 1

Views

Author

Gus Wiseman, Jun 10 2023

Keywords

Comments

The (one-based) weighted sum of a sequence (y_1,...,y_k) is Sum_{i=1..k} i*y_i. This is also the sum of partial sums of the reverse.

Examples

			The partition (6,5,4,3,2,1,1,1,1) has weighted sum 80, reverse 160, so is counted under a(24).
The a(n) partitions for n = 1, 2, 4, 6, 9, 12, 14 (A..E = 10-14):
  1  2   4     6       9          C             E
     11  22    33      333        66            77
         1111  222     711        444           65111
               111111  6111       921           73211
                       111111111  3333          2222222
                                  7311          71111111
                                  63111         11111111111111
                                  222222
                                  621111
                                  111111111111
		

Crossrefs

The case of equality (and reciprocal version) is A000005.
The strict case is A363528.
A000041 counts integer partitions, strict A000009.
A053632 counts compositions by weighted sum, rank statistic A029931/A359042.
A264034 counts partitions by weighted sum, reverse A358194.
A304818 gives weighted sum of prime indices, row-sums of A359361.
A318283 gives weighted sum of reversed prime indices, row-sums of A358136.
A320387 counts multisets by weighted sum, zero-based A359678.
A363526 = partitions with weighted sum 3n, ranks A363530, reverse A363531.

Programs

  • Mathematica
    Table[Length[Select[IntegerPartitions[n], Divisible[Total[Accumulate[#]], Total[Accumulate[Reverse[#]]]]&]],{n,30}]

A057591 Maximal size of binary code of length n that corrects 2 deletions.

Original entry on oeis.org

1, 1, 2, 2, 2, 4, 5, 7, 11, 16, 24
Offset: 1

Views

Author

N. J. A. Sloane, Oct 05 2000

Keywords

Comments

Comments from Pablo San Segundo, Dec 04 2015 (Start): The search for a maximal clique in the graph 2dc.2048 has now finished. The answer is 24 (which was already known to be a lower bound).
The total time was 16.4 days using a 20-core XEON with 128Gb. 18 cores out of the 20 were in fact used.
The solution was found by a strong heuristic algorithm during pre-processing (about 5s). The actual search time was used "only" to prove optimality. The actual maximum clique algorithm is our most recent variant based on infra-chromatic BBMCX, described here, but as yet unpublished: https://www.researchgate.net/profile/Pablo_San_Segundo
The project was carried out by Pablo San Segundo and Jorge Artieda, Polytechnic University of Madrid (UPM), Center of Automation and Robotics (CAR). Supported by National Grant DPI 2014-53525-C3-1-R (End)

Crossrefs

Extensions

Guenter Stertenbrink (Sterten(AT)aol.com) found a(9) = 11 and a(10) >= 16, Apr 28 2001
James B. Shearer (jbs(AT)pkmfgvm4.vnet.ibm.com) proved that a(10) = 16, Sep 20 2003
Pablo San Segundo and Jorge Artieda showed that a(11) = 24, Dec 04 2015

A361656 Number of odd-length integer partitions of n with integer mean.

Original entry on oeis.org

0, 1, 1, 2, 1, 2, 4, 2, 1, 9, 8, 2, 13, 2, 16, 51, 1, 2, 58, 2, 85, 144, 57, 2, 49, 194, 102, 381, 437, 2, 629, 2, 1, 956, 298, 2043, 1954, 2, 491, 2293, 1116, 2, 4479, 2, 6752, 14671, 1256, 2, 193, 8035, 4570, 11614, 22143, 2, 28585, 39810, 16476, 24691, 4566
Offset: 0

Views

Author

Gus Wiseman, Mar 24 2023

Keywords

Comments

These are partitions of n whose length is an odd divisor of n.

Examples

			The a(1) = 1 through a(10) = 8 partitions (A = 10):
  1   2   3     4   5       6     7         8   9           A
          111       11111   222   1111111       333         22222
                            321                 432         32221
                            411                 441         33211
                                                522         42211
                                                531         43111
                                                621         52111
                                                711         61111
                                                111111111
For example, the partition (3,3,2,1,1) has length 5 and mean 2, so is counted under a(10).
		

Crossrefs

Odd-length partitions are counted by A027193, bisection A236559.
Including even-length gives A067538 bisected, strict A102627, ranks A316413.
The even-length version is counted by A361655.
A000041 counts integer partitions, strict A000009.
A027187 counts even-length partitions, bisection A236913.
A051293 counts subsets with integer mean, median A000975.
A058398 counts partitions by mean, see also A008284, A327482.
A325347 counts partitions with integer median, complement A307683.
A326567/A326568 gives mean of prime indices.
A326622 counts factorizations with integer mean.

Programs

  • Mathematica
    Table[Length[Select[IntegerPartitions[n], OddQ[Length[#]]&&IntegerQ[Mean[#]]&]],{n,0,30}]
  • PARI
    a(n)=if(n==0, 0, sumdiv(n, d, if(d%2, polcoef(1/prod(k=1, d, 1 - x^k + O(x^(n-d+1))), n-d)))) \\ Andrew Howroyd, Mar 24 2023

A059736 A class of polytopal spheres.

Original entry on oeis.org

0, 0, 1, 0, 1, 1, 4, 6, 16, 25, 52, 89, 175, 308, 593, 1066, 2031, 3743, 7124, 13330, 25445, 48134, 92160, 175743, 337541, 647269, 1246802, 2400776, 4636319, 8955984, 17334720, 33570730, 65107971, 126355239, 245492141, 477284073
Offset: 1

Views

Author

N. J. A. Sloane, Feb 09 2001

Keywords

Programs

  • Maple
    A016116 := n->2^floor(n/2):with(numtheory): A000016 := proc(n) local d,t1: if n = 0 then RETURN(1) else t1 := 0; for d from 1 to n do if n mod d = 0 and d mod 2 = 1 then t1 := t1+phi(d)*2^(n/ d)/(2*n); fi; od; RETURN(t1); fi; end: A007147 := n->1/2*(A016116(n-1)+A000016(n)): A059736 := n->A007147(n) - floor(n^2/12) - 1: for j from 1 to 100 do printf(`%d,`, A059736(j)) od:
  • Mathematica
    a[n_] := (1/2)*(2^Quotient[n - 1, 2] + Total[(Mod[#, 2]*EulerPhi[#]*2^(n/#) &) /@ Divisors[n]]/(2*n)) - Floor[n^2/12] - 1;
    Array[a, 36] (* Jean-François Alcover, Aug 30 2019 *)

Formula

a(n) = A007147(n) - [n^2/12] - 1.

Extensions

More terms from James Sellers, Feb 20 2001

A054200 Number of binary vectors (x_1,...x_n) satisfying Sum_{i=1..n} i*x_i = 3 (mod n+1) = size of Varshamov-Tenengolts code VT_3(n).

Original entry on oeis.org

1, 1, 2, 2, 3, 6, 9, 16, 29, 51, 93, 172, 315, 585, 1094, 2048, 3855, 7285, 13797, 26214, 49938, 95325, 182361, 349536, 671088, 1290555, 2485532, 4793490, 9256395, 17895730, 34636833, 67108864, 130150586, 252645135, 490853403
Offset: 0

Views

Author

N. J. A. Sloane, Apr 29 2000

Keywords

Examples

			From _Seiichi Manyama_, Sep 02 2023: (Start)
1 + 2 == 3 mod 6,
3 == 3 mod 6,
1 + 3 + 5 == 3 mod 6,
2 + 3 + 4 == 3 mod 6,
4 + 5 == 3 mod 6,
1 + 2 + 3 + 4 + 5 == 3 mod 6.
So a(5) = 6. (End)
		

References

  • N. J. A. Sloane, On single-deletion-correcting codes, in Codes and Designs (Columbus, OH, 2000), 273-291, Ohio State Univ. Math. Res. Inst. Publ., 10, de Gruyter, Berlin, 2002.

Crossrefs

For the codes VT_0(n), VT_1(n), VT_2(n) see resp. A000016, A000048, A000048 (again).

Programs

  • PARI
    a(n, k=3) = sumdiv(n+1, d, (d%2)*eulerphi(d)*moebius(d/gcd(d, k))/eulerphi(d/gcd(d, k))*2^((n+1)/d))/(2*(n+1)); \\ Seiichi Manyama, Sep 02 2023

Extensions

Offset changed to 0 by Seiichi Manyama, Sep 02 2023

A096010 Number of different cycles computed with the generalized 3x+1 problem using C=2, B=Cn+m, A=C^m.

Original entry on oeis.org

2, 2, 3, 3, 5, 7, 11, 17, 31, 53, 95, 173, 317, 587, 1097, 2049, 3857, 7287, 13799, 26217
Offset: 1

Views

Author

Peter Lengler (PeterLengler(AT)t-online.de), Jul 20 2004

Keywords

Examples

			a(9)=59
		

Crossrefs

A008965 is the same sequence as this with A = -C^m.

Formula

Generalize the 3x+1-Problem from S:= S / 2 if S is even, S:= (S * 3) + 1 if S is odd to S:= S / C if C | S S:= (S * B) + A otherwise. For B=Cn+A, A=C^m the number of different cycles z are computed. Every S leads to a cycle, so it can be conjectured that the number of cycles is infinite. But the number of different cycles seems to be finite. It is conjectured that the last new cycle occurs at the starting number S = B. This was tested with A=1; B=3; C=2 up to S=100000000.
a(n) = A000016(n)+1. - Vladeta Jovovic, Feb 14 2006

A114702 Number of binary vectors (x_1,...x_(n-1)) satisfying Sum_{i=1..n-1} (-1)^i*i*x_i = 0 (mod n).

Original entry on oeis.org

1, 1, 2, 3, 6, 9, 16, 28, 52, 93, 172, 315, 586, 1091, 2048, 3855, 7286, 13797, 26216, 49929, 95326, 182361, 349536, 671088, 1290556, 2485504, 4793492, 9256395, 17895736, 34636833, 67108864, 130150493, 252645136, 490853403, 954437292
Offset: 2

Views

Author

Vladeta Jovovic, Feb 18 2006

Keywords

Formula

a(2*n-1) = A000048(2*n-1), a(2*n) = A000016(2*n).

Extensions

More terms from R. J. Mathar, Jan 24 2008

A337442 Number of output sequences from the linear feedback shift register whose feedback polynomial coefficients (excluding the constant term) correspond to the binary representation of n.

Original entry on oeis.org

1, 2, 3, 2, 4, 2, 2, 4, 6, 2, 4, 4, 2, 6, 4, 4, 8, 4, 2, 6, 2, 4, 8, 2, 4, 8, 4, 2, 6, 2, 2, 8, 14, 2, 6, 4, 8, 8, 4, 6, 6, 8, 12, 4, 4, 2, 8, 6, 2, 12, 8, 2, 8, 8, 2, 4, 4, 2, 4, 12, 6, 4, 6, 10, 20, 2, 4, 8, 2, 12, 6, 2, 2, 6, 4, 8, 16, 8, 2, 8, 4, 4, 16, 2
Offset: 0

Views

Author

Michael Schwartz, Aug 27 2020

Keywords

Comments

a(n) > 1 for n > 0.
It appears that every term after a(2) is even.
It appears that a(2^n) is greater than each preceding term and is greater than or equal to each term up to a(2^(n+1)).
If a(n) = 2, then the nonzero shift register sequence is an m-sequence.

Examples

			For n = 3 = 11 in binary, the polynomial is 1+x+x^2 and the 2 shift register sequences are {00..., 01101...}.
For n = 4 = 100 in binary, the polynomial is 1+x^3 and the 4 shift register sequences are {000..., 001001..., 011011..., 111...}.
For n = 6 = 110 in binary, the polynomial is 1+x^2+x^3 and the 2 shift register sequences are {000..., 0010111001...}.
For n = 10 = 1010 in binary, the polynomial is 1+x^2+x^4 and the 4 shift register sequences are {0000..., 0001010001..., 0011110011..., 0110110...}.
For n = 11 = 1011 in binary, the polynomial in 1+x+x^2+x^4. Using a Fibonacci LSFR, if the current state of the register is 0001, the next input bit is 0+0+1=1, and the next state is 0011. If the current state is 0100, the next input bit is 0+0+0=0, and the next state is 1000. The 4 shift register sequences are {0000..., 00011010001..., 00101110010..., 1111...}.
		

Crossrefs

a(2^n) = A000031(n+1).
A011260 counts how many 2's are in the interval [2^(n-1),(2^n)-1].
a(n) = 2 if and only if 2n+1 is in A091250.
Cf. A100447, A001037, A000016, A000013 (definition 2), A000020, A058947.
Cf. A011655..A011751 for examples of binary m-sequences.
Previous Showing 41-50 of 50 results.