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-10 of 16 results. Next

A328595 Numbers whose reversed binary expansion is a necklace.

Original entry on oeis.org

1, 2, 3, 4, 6, 7, 8, 10, 12, 14, 15, 16, 20, 24, 26, 28, 30, 31, 32, 36, 40, 42, 44, 48, 52, 54, 56, 58, 60, 62, 63, 64, 72, 80, 84, 88, 92, 96, 100, 104, 106, 108, 112, 116, 118, 120, 122, 124, 126, 127, 128, 136, 144, 152, 160, 164, 168, 170, 172, 176, 180
Offset: 1

Views

Author

Gus Wiseman, Oct 22 2019

Keywords

Comments

A necklace is a finite sequence that is lexicographically minimal among all of its cyclic rotations.

Examples

			The sequence of terms together with their binary expansions and binary indices begins:
   1:      1 ~ {1}
   2:     10 ~ {2}
   3:     11 ~ {1,2}
   4:    100 ~ {3}
   6:    110 ~ {2,3}
   7:    111 ~ {1,2,3}
   8:   1000 ~ {4}
  10:   1010 ~ {2,4}
  12:   1100 ~ {3,4}
  14:   1110 ~ {2,3,4}
  15:   1111 ~ {1,2,3,4}
  16:  10000 ~ {5}
  20:  10100 ~ {3,5}
  24:  11000 ~ {4,5}
  26:  11010 ~ {2,4,5}
  28:  11100 ~ {3,4,5}
  30:  11110 ~ {2,3,4,5}
  31:  11111 ~ {1,2,3,4,5}
  32: 100000 ~ {6}
  36: 100100 ~ {3,6}
		

Crossrefs

A similar concept is A065609.
The version with the most significant digit ignored is A328607.
Lyndon words are A328596.
Aperiodic words are A328594.
Binary necklaces are A000031.
Necklace compositions are A008965.

Programs

  • Mathematica
    neckQ[q_]:=Array[OrderedQ[{q,RotateRight[q,#]}]&,Length[q]-1,1,And];
    Select[Range[100],neckQ[Reverse[IntegerDigits[#,2]]]&]
  • Python
    from itertools import count, islice
    from sympy.utilities.iterables import necklaces
    def a_gen():
        for n in count(1):
            t = []
            for i in necklaces(n,2):
                if sum(i)>0:
                    t.append(sum(2**j for j in range(len(i)) if i[j] > 0))
            yield from sorted(t)
    A328595_list = list(islice(a_gen(), 100)) # John Tyler Rascoe, May 24 2024

A065609 Positive m such that when written in binary, no rotated value of m is greater than m.

Original entry on oeis.org

1, 2, 3, 4, 6, 7, 8, 10, 12, 14, 15, 16, 20, 24, 26, 28, 30, 31, 32, 36, 40, 42, 48, 50, 52, 54, 56, 58, 60, 62, 63, 64, 72, 80, 84, 96, 98, 100, 104, 106, 108, 112, 114, 116, 118, 120, 122, 124, 126, 127, 128, 136, 144, 160, 164, 168, 170, 192, 194, 196, 200, 202
Offset: 1

Views

Author

Jonathan Ayres (jonathan.ayres(AT)btinternet.com), Nov 06 2001

Keywords

Comments

Rotated values of m are defined as the numbers which occur when m is shifted 1, 2, ... bits to the right with the last bits added to the front; e.g., the rotated values of 1011 are 1011, 1101, 1110 and 0111.
The number of k-bit binary numbers in this sequence is A008965. This gives the row lengths when the sequence is regarded as a table.
If m is in the sequence, then so is 2m. All odd terms are of the form 2^k - 1. - Ivan Neretin, Aug 04 2016
First differs from A328595 in lacking 44, with binary expansion {1, 0, 1, 1, 0, 0}, and 92, with binary expansion {1, 0, 1, 1, 1, 0, 0}. - Gus Wiseman, Oct 31 2019

Examples

			14 is included because 14 in binary is 1110. 1110 has the rotated values of 0111, 1011 and 1101 -- 7, 11 and 13 -- which are all smaller than 14.
		

Crossrefs

A similar concept is A328595.
The version with the most significant digit ignored is A328668 or A328607.
Numbers whose reversed binary expansion is a Lyndon word are A328596.
Numbers whose binary expansion is aperiodic are A328594.
Binary necklaces are A000031.
Necklace compositions are A008965.

Programs

  • Maple
    filter:= proc(n) local L, k;
      if n::odd then return evalb(n+1 = 2^ilog2(n+1)) fi;
      L:= convert(convert(n,binary),string);
      for k from 1 to length(L)-1 do
        if not lexorder(StringTools:-Rotate(L,k),L) then return false fi;
      od;
      true
    end proc:
    select(filter, [$1..1000]); # Robert Israel, Aug 05 2016
  • Mathematica
    Select[Range[200], # == Max[FromDigits[#, 2] & /@ NestList[RotateLeft, dg = IntegerDigits[#, 2], Length@dg]] &] (* Ivan Neretin, Aug 04 2016 *)
  • Python
    def ok(n):
        b = bin(n)[2:]
        return b > "0" and all(b[i:] + b[:i] <= b for i in range(1, len(b)))
    print([k for k in range(203) if ok(k)]) # Michael S. Branicky, May 26 2022

Extensions

Edited by Franklin T. Adams-Watters, Apr 09 2010

A328600 Number of necklace compositions of n with no part circularly followed by a divisor.

Original entry on oeis.org

0, 0, 0, 0, 1, 0, 2, 1, 3, 5, 5, 7, 10, 18, 20, 29, 40, 58, 78, 111, 156, 218, 304, 429, 604, 859, 1209, 1726, 2423, 3462, 4904, 7000, 9953, 14210, 20270, 28979, 41391, 59253, 84799, 121539, 174162, 249931, 358577, 515090, 739932, 1063826, 1529766, 2201382, 3168565
Offset: 1

Views

Author

Gus Wiseman, Oct 25 2019

Keywords

Comments

A necklace composition of n is a finite sequence of positive integers summing to n that is lexicographically minimal among all of its cyclic rotations.
Circularity means the last part is followed by the first.

Examples

			The a(5) = 1 through a(13) = 18 necklace compositions (empty column not shown):
  (2,3)  (2,5)  (3,5)  (2,7)    (3,7)      (2,9)    (5,7)      (4,9)
         (3,4)         (4,5)    (4,6)      (3,8)    (2,3,7)    (5,8)
                       (2,4,3)  (2,3,5)    (4,7)    (2,7,3)    (6,7)
                                (2,5,3)    (5,6)    (3,4,5)    (2,11)
                                (2,3,2,3)  (2,4,5)  (3,5,4)    (3,10)
                                                    (2,3,2,5)  (2,4,7)
                                                    (2,3,4,3)  (2,6,5)
                                                               (2,8,3)
                                                               (3,6,4)
                                                               (2,3,5,3)
		

Crossrefs

The non-necklace version is A328598.
The version with singletons is A318729.
The case forbidding multiples as well as divisors is A328601.
The non-necklace, non-circular version is A328460.
The version for co-primality (instead of divisibility) is A328602.
Necklace compositions are A008965.
Partitions with no part followed by a divisor are A328171.

Programs

  • Mathematica
    neckQ[q_]:=Array[OrderedQ[{q,RotateRight[q,#]}]&,Length[q]-1,1,And];
    Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],neckQ[#]&&And@@Not/@Divisible@@@Partition[#,2,1,1]&]],{n,10}]
  • PARI
    b(n, q, pred)={my(M=matrix(n, n)); for(k=1, n, M[k, k]=pred(q, k); for(i=1, k-1, M[i, k]=sum(j=1, k-i, if(pred(j, i), M[j, k-i], 0)))); M[q,]}
    seq(n)={my(v=sum(k=1, n, k*b(n, k, (i,j)->i%j<>0))); vector(n, n, sumdiv(n, d, eulerphi(d)*v[n/d])/n)} \\ Andrew Howroyd, Oct 26 2019

Formula

a(n) = A318729(n) - 1.

Extensions

Terms a(26) and beyond from Andrew Howroyd, Oct 26 2019

A328601 Number of necklace compositions of n with no part circularly followed by a divisor or a multiple.

Original entry on oeis.org

0, 0, 0, 0, 1, 0, 2, 1, 2, 5, 4, 7, 6, 13, 14, 20, 30, 38, 50, 68, 97, 132, 176, 253, 328, 470, 631, 901, 1229, 1709, 2369, 3269, 4590, 6383, 8897, 12428, 17251, 24229, 33782, 47404, 66253, 92859, 130141, 182468, 256261, 359675, 505230, 710058, 997952, 1404214
Offset: 1

Views

Author

Gus Wiseman, Oct 25 2019

Keywords

Comments

A necklace composition of n (A008965) is a finite sequence of positive integers summing to n that is lexicographically minimal among all of its cyclic rotations.
Circularity means the last part is followed by the first.

Examples

			The a(5) = 1 through a(13) = 6 necklace compositions (empty column not shown):
  (2,3)  (2,5)  (3,5)  (2,7)  (3,7)      (2,9)  (5,7)      (4,9)
         (3,4)         (4,5)  (4,6)      (3,8)  (2,3,7)    (5,8)
                              (2,3,5)    (4,7)  (2,7,3)    (6,7)
                              (2,5,3)    (5,6)  (3,4,5)    (2,11)
                              (2,3,2,3)         (3,5,4)    (3,10)
                                                (2,3,2,5)  (2,3,5,3)
                                                (2,3,4,3)
		

Crossrefs

The non-necklace version is A328599.
The case forbidding divisors only is A328600 or A318729 (with singletons).
The non-necklace, non-circular version is A328508.
The version for co-primality (instead of indivisibility) is A328597.

Programs

  • Mathematica
    neckQ[q_]:=Array[OrderedQ[{q,RotateRight[q,#]}]&,Length[q]-1,1,And];
    Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],neckQ[#]&&And@@Not/@Divisible@@@Partition[#,2,1,1]&&And@@Not/@Divisible@@@Reverse/@Partition[#,2,1,1]&]],{n,10}]
  • PARI
    b(n, q, pred)={my(M=matrix(n, n)); for(k=1, n, M[k, k]=pred(q, k); for(i=1, k-1, M[i, k]=sum(j=1, k-i, if(pred(j, i), M[j, k-i], 0)))); M[q,]}
    seq(n)={my(v=sum(k=1, n, k*b(n, k, (i,j)->i%j<>0 && j%i<>0))); vector(n, n, sumdiv(n, d, eulerphi(d)*v[n/d])/n)} \\ Andrew Howroyd, Oct 26 2019

Formula

a(n) = A318730(n) - 1.

Extensions

Terms a(26) and beyond from Andrew Howroyd, Oct 26 2019

A325788 Number of complete strict necklace compositions of n.

Original entry on oeis.org

1, 0, 1, 0, 0, 2, 2, 0, 0, 4, 4, 4, 4, 0, 20, 6, 16, 12, 10, 0, 84, 40, 74, 42, 66, 38, 22, 254, 238, 188, 356, 242, 272, 150, 148, 1140, 1058, 1208, 1546, 1288
Offset: 1

Views

Author

Gus Wiseman, May 22 2019

Keywords

Comments

A strict necklace composition of n is a finite sequence of distinct positive integers summing to n that is lexicographically minimal among all of its cyclic rotations. In other words, it is a strict composition of n starting with its least part (counted by A032153). A circular subsequence is a sequence of consecutive terms where the last and first parts are also considered consecutive. A necklace composition of n is complete if every positive integer from 1 to n is the sum of some circular subsequence.

Examples

			The a(1) = 1 through a(16) = 6 complete strict necklace compositions (empty columns not shown):
  (1)  (12)  (123)  (124)  (1234)  (1253)  (1245)  (1264)  (12345)  (12634)
             (132)  (142)  (1324)  (1325)  (1326)  (1327)  (12354)  (13624)
                           (1423)  (1352)  (1542)  (1462)  (12435)  (14263)
                           (1432)  (1523)  (1623)  (1723)  (12453)  (14326)
                                                           (12543)  (14362)
                                                           (13254)  (16234)
                                                           (13425)
                                                           (13452)
                                                           (13524)
                                                           (13542)
                                                           (14235)
                                                           (14253)
                                                           (14325)
                                                           (14523)
                                                           (14532)
                                                           (15234)
                                                           (15243)
                                                           (15324)
                                                           (15342)
                                                           (15432)
		

Crossrefs

Programs

  • Mathematica
    neckQ[q_]:=Array[OrderedQ[{q,RotateRight[q,#]}]&,Length[q]-1,1,And];
    subalt[q_]:=Union[ReplaceList[q,{_,s__,_}:>{s}],DeleteCases[ReplaceList[q,{t___,,u___}:>{u,t}],{}]];
    Table[Length[Select[Join@@Permutations/@Select[IntegerPartitions[n],UnsameQ@@#&],neckQ[#]&&Union[Total/@subalt[#]]==Range[n]&]],{n,30}]

A325791 Number of necklace permutations of {1..n} such that every positive integer from 1 to n * (n + 1)/2 is the sum of some circular subsequence.

Original entry on oeis.org

1, 1, 1, 2, 4, 20, 82, 252, 1074, 7912, 39552, 152680, 776094, 5550310, 30026848, 108376910
Offset: 0

Views

Author

Gus Wiseman, May 23 2019

Keywords

Comments

A necklace permutation is a permutation that is either empty or whose first part is the minimum. A circular subsequence is a sequence of consecutive terms where the last and first parts are also considered consecutive. The only circular subsequence of maximum length is the sequence itself, not any rotation of it. For example, the circular subsequences of (1,3,2) are: (), (1), (2), (3), (1,3), (2,1), (3,2), (1,3,2).

Examples

			The a(1) = 1 through a(5) = 20 permutations:
  (1)  (1,2)  (1,2,3)  (1,2,3,4)  (1,2,3,4,5)
              (1,3,2)  (1,3,2,4)  (1,2,3,5,4)
                       (1,4,2,3)  (1,2,4,3,5)
                       (1,4,3,2)  (1,2,4,5,3)
                                  (1,2,5,4,3)
                                  (1,3,2,5,4)
                                  (1,3,4,2,5)
                                  (1,3,4,5,2)
                                  (1,3,5,2,4)
                                  (1,3,5,4,2)
                                  (1,4,2,3,5)
                                  (1,4,2,5,3)
                                  (1,4,3,2,5)
                                  (1,4,5,2,3)
                                  (1,4,5,3,2)
                                  (1,5,2,3,4)
                                  (1,5,2,4,3)
                                  (1,5,3,2,4)
                                  (1,5,3,4,2)
                                  (1,5,4,3,2)
		

Crossrefs

Programs

  • Mathematica
    subalt[q_]:=Union[ReplaceList[q,{_,s__,_}:>{s}],DeleteCases[ReplaceList[q,{t___,,u___}:>{u,t}],{}]];
    Table[Length[Select[Permutations[Range[n]],#=={}||First[#]==1&&Range[n*(n+1)/2]==Union[Total/@subalt[#]]&]],{n,0,5}]

Extensions

a(11)-a(15) from Bert Dobbelaere, Nov 01 2020

A328597 Number of necklace compositions of n where every pair of adjacent parts (including the last with the first) is relatively prime.

Original entry on oeis.org

1, 1, 2, 3, 5, 8, 12, 21, 33, 57, 94, 167, 279, 491, 852, 1507, 2647, 4714, 8349, 14923, 26642, 47793, 85778, 154474, 278322, 502715, 908912, 1646205, 2984546, 5418652, 9847189, 17916000, 32625617, 59470539, 108493149, 198094482, 361965238, 661891579, 1211162270
Offset: 1

Views

Author

Gus Wiseman, Oct 23 2019

Keywords

Comments

A necklace composition of n is a finite sequence of positive integers summing to n that is lexicographically minimal among all of its cyclic rotations.

Examples

			The a(1) = 1 through a(7) = 12 necklace compositions:
  (1)  (1,1)  (1,2)    (1,3)      (1,4)        (1,5)          (1,6)
              (1,1,1)  (1,1,2)    (2,3)        (1,1,4)        (2,5)
                       (1,1,1,1)  (1,1,3)      (1,2,3)        (3,4)
                                  (1,1,1,2)    (1,3,2)        (1,1,5)
                                  (1,1,1,1,1)  (1,1,1,3)      (1,1,1,4)
                                               (1,2,1,2)      (1,1,2,3)
                                               (1,1,1,1,2)    (1,1,3,2)
                                               (1,1,1,1,1,1)  (1,2,1,3)
                                                              (1,1,1,1,3)
                                                              (1,1,2,1,2)
                                                              (1,1,1,1,1,2)
                                                              (1,1,1,1,1,1,1)
		

Crossrefs

The non-necklace version is A328609.
The non-necklace non-circular version is A167606.
The version with singletons is A318728.
The aperiodic case is A318745.
The indivisible (instead of coprime) version is A328600.
The non-coprime (instead of coprime) version is A328602.
Necklace compositions are A008965.

Programs

  • Mathematica
    neckQ[q_]:=Array[OrderedQ[{q,RotateRight[q,#]}]&,Length[q]-1,1,And];
    Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],neckQ[#]&&And@@CoprimeQ@@@Partition[#,2,1,1]&]],{n,10}]
  • PARI
    b(n, q, pred)={my(M=matrix(n, n)); for(k=1, n, M[k, k]=pred(q, k); for(i=1, k-1, M[i, k]=sum(j=1, k-i, if(pred(j, i), M[j, k-i], 0)))); M[q,]}
    seq(n)={my(v=sum(k=1, n, k*b(n, k, (i,j)->gcd(i,j)==1))); vector(n, n, sumdiv(n, d, eulerphi(d)*v[n/d])/n)} \\ Andrew Howroyd, Oct 26 2019

Formula

a(n > 1) = A318728(n) - 1.

Extensions

Terms a(21) and beyond from Andrew Howroyd, Oct 26 2019

A325790 Number of permutations of {1..n} such that every positive integer from 1 to n * (n + 1)/2 is the sum of some circular subsequence.

Original entry on oeis.org

1, 1, 2, 6, 16, 100, 492, 1764, 8592, 71208, 395520, 1679480, 9313128, 72154030, 420375872, 1625653650
Offset: 0

Views

Author

Gus Wiseman, May 23 2019

Keywords

Comments

A circular subsequence is a sequence of consecutive non-overlapping terms where the last and first parts are also considered consecutive. The only circular subsequence of maximum length is the sequence itself (not any rotation of it). For example, the circular subsequences of (2,1,3) are: (), (1), (2), (3), (1,3), (2,1), (3,2), (2,1,3).

Examples

			The a(1) = 1 through a(4) = 16 permutations:
  (1)  (1,2)  (1,2,3)  (1,2,3,4)
       (2,1)  (1,3,2)  (1,3,2,4)
              (2,1,3)  (1,4,2,3)
              (2,3,1)  (1,4,3,2)
              (3,1,2)  (2,1,4,3)
              (3,2,1)  (2,3,1,4)
                       (2,3,4,1)
                       (2,4,1,3)
                       (3,1,4,2)
                       (3,2,1,4)
                       (3,2,4,1)
                       (3,4,1,2)
                       (4,1,2,3)
                       (4,1,3,2)
                       (4,2,3,1)
                       (4,3,2,1)
		

Crossrefs

Programs

  • Mathematica
    subalt[q_]:=Union[ReplaceList[q,{_,s__,_}:>{s}],DeleteCases[ReplaceList[q,{t___,,u___}:>{u,t}],{}]];
    Table[Length[Select[Permutations[Range[n]],Range[n*(n+1)/2]==Union[Total/@subalt[#]]&]],{n,0,5}]
  • PARI
    weigh(p)={my(b=0); for(i=1, #p, my(s=0,j=i); for(k=1, #p, s+=p[j]; if(!bittest(b,s), b=bitor(b,1<Andrew Howroyd, Aug 16 2019

Extensions

a(10)-a(12) from Andrew Howroyd, Aug 18 2019
a(13)-a(15) from Bert Dobbelaere, Nov 01 2020

A328602 Number of necklace compositions of n where no pair of circularly adjacent parts is relatively prime.

Original entry on oeis.org

0, 1, 1, 2, 1, 4, 1, 5, 3, 8, 1, 16, 1, 20, 9, 35, 2, 69, 3, 111, 24, 190, 13, 384, 31, 646, 102, 1212, 113, 2348, 227, 4254, 613, 7993, 976, 15459, 1915, 28825, 4357, 54988, 7868, 105826, 15760, 201115, 33376, 385590, 63974, 744446, 128224, 1428047, 262914, 2754037
Offset: 1

Views

Author

Gus Wiseman, Oct 25 2019

Keywords

Comments

A necklace composition of n (A008965) is a finite sequence of positive integers summing to n that is lexicographically minimal among all of its cyclic rotations.
Circularity means the last part is followed by the first.

Examples

			The a(2) = 1 through a(10) = 8 necklace compositions:
  (2)  (3)  (4)    (5)  (6)      (7)  (8)        (9)      (10)
            (2,2)       (2,4)         (2,6)      (3,6)    (2,8)
                        (3,3)         (4,4)      (3,3,3)  (4,6)
                        (2,2,2)       (2,2,4)             (5,5)
                                      (2,2,2,2)           (2,2,6)
                                                          (2,4,4)
                                                          (2,2,2,4)
                                                          (2,2,2,2,2)
The a(19) = 3 necklace compositions are: (19), (3,6,4,6), (2,2,6,3,6).
		

Crossrefs

The non-necklace, non-circular version is A178470.
The version for indivisibility (rather than co-primality) is A328600.
The circularly coprime (as opposed to anti-coprime) version is A328597.
Partitions with no consecutive parts relatively prime are A328187.

Programs

  • Mathematica
    neckQ[q_]:=Array[OrderedQ[{q,RotateRight[q,#]}]&,Length[q]-1,1,And];
    Table[Length[Select[Join@@Permutations/@IntegerPartitions[n],neckQ[#]&&And@@Not/@CoprimeQ@@@Partition[#,2,1,1]&]],{n,10}]
  • PARI
    b(n, q, pred)={my(M=matrix(n, n)); for(k=1, n, M[k, k]=pred(q, k); for(i=1, k-1, M[i, k]=sum(j=1, k-i, if(pred(j, i), M[j, k-i], 0)))); M[q,]}
    seq(n)={my(v=sum(k=1, n, k*b(n, k, (i,j)->gcd(i,j)<>1))); vector(n, n, sumdiv(n, d, eulerphi(d)*v[n/d])/n)} \\ Andrew Howroyd, Oct 26 2019

Extensions

Terms a(26) and beyond from Andrew Howroyd, Oct 26 2019

A325787 Number of perfect strict necklace compositions of n.

Original entry on oeis.org

1, 0, 1, 0, 0, 0, 2, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
Offset: 1

Views

Author

Gus Wiseman, May 22 2019

Keywords

Comments

A strict necklace composition of n is a finite sequence of distinct positive integers summing to n that is lexicographically minimal among all of its cyclic rotations. In other words, it is a strict composition of n starting with its least part. A circular subsequence is a sequence of consecutive terms where the last and first parts are also considered consecutive. A necklace composition of n is perfect if every positive integer from 1 to n is the sum of exactly one distinct circular subsequence. For example, the composition (1,2,6,4) is perfect because it has the following circular subsequences and sums:
1: (1)
2: (2)
3: (1,2)
4: (4)
5: (4,1)
6: (6)
7: (4,1,2)
8: (2,6)
9: (1,2,6)
10: (6,4)
11: (6,4,1)
12: (2,6,4)
13: (1,2,6,4)
a(n) > 0 iff n = A002061(k) = A004136(k) for some k. - Bert Dobbelaere, Nov 11 2020

Examples

			The a(1) = 1 through a(31) = 10 perfect strict necklace compositions (empty columns not shown):
  (1)  (1,2)  (1,2,4)  (1,2,6,4)  (1,3,10,2,5)  (1,10,8,7,2,3)
              (1,4,2)  (1,3,2,7)  (1,5,2,10,3)  (1,13,6,4,5,2)
                       (1,4,6,2)                (1,14,4,2,3,7)
                       (1,7,2,3)                (1,14,5,2,6,3)
                                                (1,2,5,4,6,13)
                                                (1,2,7,4,12,5)
                                                (1,3,2,7,8,10)
                                                (1,3,6,2,5,14)
                                                (1,5,12,4,7,2)
                                                (1,7,3,2,4,14)
From _Bert Dobbelaere_, Nov 11 2020: (Start)
Compositions matching nonzero terms from a(57) to a(273), up to symmetry.
a(57) = 12:
  (1,2,10,19,4,7,9,5)
  (1,3,5,11,2,12,17,6)
  (1,3,8,2,16,7,15,5)
  (1,4,2,10,18,3,11,8)
  (1,4,22,7,3,6,2,12)
  (1,6,12,4,21,3,2,8)
a(73) = 8:
  (1,2,4,8,16,5,18,9,10)
  (1,4,7,6,3,28,2,8,14)
  (1,6,4,24,13,3,2,12,8)
  (1,11,8,6,4,3,2,22,16)
a(91) = 12:
  (1,2,6,18,22,7,5,16,4,10)
  (1,3,9,11,6,8,2,5,28,18)
  (1,4,2,20,8,9,23,10,3,11)
  (1,4,3,10,2,9,14,16,6,26)
  (1,5,4,13,3,8,7,12,2,36)
  (1,6,9,11,29,4,8,2,3,18)
a(133) = 36:
  (1,2,9,8,14,4,43,7,6,10,5,24)
  (1,2,12,31,25,4,9,10,7,11,16,5)
  (1,2,14,4,37,7,8,27,5,6,13,9)
  (1,2,14,12,32,19,6,5,4,18,13,7)
  (1,3,8,9,5,19,23,16,13,2,28,6)
  (1,3,12,34,21,2,8,9,5,6,7,25)
  (1,3,23,24,6,22,10,11,18,2,5,8)
  (1,4,7,3,16,2,6,17,20,9,13,35)
  (1,4,16,3,15,10,12,14,17,33,2,6)
  (1,4,19,20,27,3,6,25,7,8,2,11)
  (1,4,20,3,40,10,9,2,15,16,6,7)
  (1,5,12,21,29,11,3,16,4,22,2,7)
  (1,7,13,12,3,11,5,18,4,2,48,9)
  (1,8,10,5,7,21,4,2,11,3,26,35)
  (1,14,3,2,4,7,21,8,25,10,12,26)
  (1,14,10,20,7,6,3,2,17,4,8,41)
  (1,15,5,3,25,2,7,4,6,12,14,39)
  (1,22,14,20,5,13,8,3,4,2,10,31)
a(183) = 40:
  (1,2,13,7,5,14,34,6,4,33,18,17,21,8)
  (1,2,21,17,11,5,9,4,26,6,47,15,12,7)
  (1,2,28,14,5,6,9,12,48,18,4,13,16,7)
  (1,3,5,6,25,32,23,10,18,2,17,7,22,12)
  (1,3,12,7,20,14,44,6,5,24,2,28,8,9)
  (1,3,24,6,12,14,11,55,7,2,8,5,16,19)
  (1,4,6,31,3,13,2,7,14,12,17,46,8,19)
  (1,4,8,52,3,25,18,2,9,24,6,10,7,14)
  (1,4,20,2,12,3,6,7,33,11,8,10,35,31)
  (1,5,2,24,15,29,14,21,13,4,33,3,9,10)
  (1,5,23,27,42,3,4,11,2,19,12,10,16,8)
  (1,6,8,22,4,5,33,21,3,20,32,16,2,10)
  (1,8,3,10,23,5,56,4,2,14,15,17,7,18)
  (1,8,21,45,6,7,11,17,3,2,10,4,23,25)
  (1,9,5,40,3,4,21,35,16,18,2,6,11,12)
  (1,9,14,26,4,2,11,5,3,12,27,34,7,28)
  (1,9,21,25,3,4,8,5,6,16,2,36,14,33)
  (1,10,22,34,27,12,3,4,2,14,24,5,8,17)
  (1,10,48,9,19,4,8,6,7,17,3,2,34,15)
  (1,12,48,6,2,38,3,22,7,10,11,5,4,14)
a(273) = 12:
  (1,2,4,8,16,32,27,26,11,9,45,13,10,29,5,17,18)
  (1,3,12,10,31,7,27,2,6,5,19,20,62,14,9,28,17)
  (1,7,3,15,33,5,24,68,2,14,6,17,4,9,19,12,34)
  (1,7,12,44,25,41,9,17,4,6,22,33,13,2,3,11,23)
  (1,7,31,2,11,3,9,36,17,4,22,6,18,72,5,10,19)
  (1,21,11,50,39,13,6,4,14,16,25,26,3,2,7,8,27)
(End)
		

Crossrefs

Programs

  • Mathematica
    neckQ[q_]:=Array[OrderedQ[{q,RotateRight[q,#]}]&,Length[q]-1,1,And];
    subalt[q_]:=Union[ReplaceList[q,{_,s__,_}:>{s}],DeleteCases[ReplaceList[q,{t___,,u___}:>{u,t}],{}]];
    Table[Length[Select[Join@@Permutations/@Select[IntegerPartitions[n],UnsameQ@@#&],neckQ[#]&&Sort[Total/@subalt[#]]==Range[n]&]],{n,30}]

Extensions

More terms from Bert Dobbelaere, Nov 11 2020
Showing 1-10 of 16 results. Next