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

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}]

A325783 Reading the first row of this array, or the first column, or the successive antidiagonals is the same as reading this sequence.

Original entry on oeis.org

1, 2, 2, 2, 3, 2, 2, 4, 5, 2, 3, 6, 7, 8, 3, 2, 9, 10, 11, 12, 2, 2, 13, 14, 15, 16, 17, 2, 4, 18, 19, 20, 21, 22, 23, 4, 5, 24, 25, 26, 27, 28, 29, 30, 5, 2, 31, 32, 33, 34, 35, 36, 37, 38, 2, 3, 39, 40, 41, 42, 43, 44, 45, 46, 47, 3, 6, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 6, 7, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 7, 8, 69
Offset: 1

Views

Author

Eric Angelini, May 21 2019

Keywords

Comments

The array is always extended by its antidiagonals with the smallest term not yet present that doesn't lead to a contradiction. The sequence is thus the lexicographically earliest of its kind.
This regular pattern appears: . . . . 3 . . 4 5 . . 6 7 8 . . 9 10 11 12 . . 13 14 15 16 17 . . 18 19 20 21 22 23 . . This is the first time that these terms appear in the sequence. So it is possible to calculate the terms of this pattern. - Bernard Schott, Jun 03 2019

Examples

			Array:
  1  2  2  2  3   2   2   4   5   2   3 ...
  2  3  4  6  9  13  18  24  31  39  48 ...
  2  5  7 10 14  19  25  32  40  49  59 ...
  2  8 11 15 20  26  33  41  50  60  71 ...
  3 12 16 21 27  34  42  51  61  72  84 ...
  2 17 22 28 35  43  52  62  73  85  98 ...
  2 23 29 36 44  53  63  74  86  99 113 ...
  4 30 37 45 54  61  75  87 100 112 129 ...
  5 38 46 55 62  76  88 101 113 130 146 ...
  2 47 56 63 77  89 102 114 131 147 164 ...
  3 57 64 78 90 101 115 132 148 165 183 ...
  ...
		

Crossrefs

Cf. A325784 and A325785 where the same idea is developped, but restricted to, respectively, the first row and the first column of the arrays presented.

Formula

a(n*(n+1)/2) = a(n*(n-1)/2+1) = a(n). - Rémy Sigrist, May 21 2019
T(n+1,k+1) = A000027(n,k) + 2 if both sequences are read as square arrays. - Charlie Neder, Jun 03 2019
From Bernard Schott, Jun 03 2019: (Start)
For 2 <= q <= k:
a(k*(k+1)/2 + 2) = (k-2)*(k-1)/2 + 3.
a(k*(k+1)/2 + q) = (k-2)*(k-1)/2 + q + 1.
a(k*(k+1)/2 + k) = a(k*(k+3)/2) = (k-2)*(k-1)/2 + k + 1 = (k^2-k+4)/2. (End)

A325784 Reading the first row of this array or its successive antidiagonals is the same as reading this sequence.

Original entry on oeis.org

1, 2, 3, 3, 4, 5, 3, 6, 7, 8, 4, 9, 10, 11, 12, 5, 13, 14, 15, 16, 17, 3, 18, 19, 20, 21, 22, 23, 6, 24, 25, 26, 27, 28, 29, 30, 7, 31, 32, 33, 34, 35, 36, 37, 38, 8, 39, 40, 41, 42, 43, 44, 45, 46, 47, 4, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 9, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 10, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 11
Offset: 1

Views

Author

Eric Angelini, May 21 2019

Keywords

Comments

The array is always extended by its antidiagonals with the smallest term not yet present that doesn't lead to a contradiction. The sequence is thus the lexicographically earliest of its kind.

Examples

			Array:
   1  2  3  3   4   5   3   6   7   8   4 ...
   3  4  6  9  13  18  24  31  39  48  58 ...
   5  7 10 14  19  25  32  40  49  59  70 ...
   8 11 15 20  26  33  41  50  60  71  83 ...
  12 16 21 27  34  42  51  61  72  84  97 ...
  17 22 28 35  43  52  62  73  85  98 112 ...
  23 29 36 44  53  63  74  86  99 113 128 ...
  30 37 45 54  64  75  87 100 114 129 145 ...
  38 46 55 65  76  88 101 115 130 146 163 ...
  47 56 66 77  89 102 116 131 147 164 182 ...
  57 67 78 90 103 117 132 148 165 183 202 ...
  ...
		

Crossrefs

Cf. A325783 and A325785 where the same idea is developed.
Cf. A000124.

Formula

a(n*(n-1)/2 + 1) = a(n). - Rémy Sigrist, May 21 2019

A354371 Square array read by antidiagonals such that the sum of the digits inside any 2 X 2 square is itself a square.

Original entry on oeis.org

1, 2, 3, 4, 12, 5, 6, 7, 14, 11, 16, 8, 10, 13, 17, 19, 22, 9, 15, 20, 26, 27, 69, 31, 18, 40, 34, 32, 42, 78, 49, 21, 24, 30, 41, 43, 46, 51, 33, 23, 25, 39, 37, 44, 64, 68, 59, 54, 48, 28, 29, 38, 58, 74, 70, 72, 92, 52, 63, 36, 35, 87, 101, 98, 80, 82, 84, 177, 121, 65, 60, 45, 96, 53, 103, 76
Offset: 1

Views

Author

Eric Angelini and Carole Dubois, May 24 2022

Keywords

Comments

This is the lexicographically earliest permutation of the positive integers with this property.

Examples

			Array:
.
    1,   2,   4,   6,  16,  19,  27,  42,  46,  68,  72,  84, 120, 138, 156, ...
    3,  12,   7,   8,  22,  69,  78,  51,  59,  92, 177,  94, 134, 175, 165, ...
    5,  14,  10,   9,  31,  49,  33,  54,  52, 121, 132, 195, 166, 249, 162, ...
   11,  13,  15,  18,  21,  23,  48,  63,  65,  77,  75,  97, 131, 178, 171, ...
   17,  20,  40,  24,  25,  28,  36,  60,  55,  86,  81,  93, 169, 147, 174, ...
   26,  34,  30,  39,  29,  35,  45,  57,  62, 130,  90, 150, 200, 289, 303, ...
   32,  41,  37,  38,  87,  96,  89,  47,  50,  71, 186, 204, 146, 202, 205, ...
   43,  44,  58, 101,  53,  56, 105, 110,  61,  79,  73, 113, 149, 142, 198, ...
   64,  74,  98, 103,  83, 114,  67, 112,  66,  95, 108, 100, 140, 145, 194, ...
   70,  80,  76, 159, 123,  85, 179, 168,  99, 104, 107, 115, 129, 153, 210, ...
   82, 119, 188, 199, 117, 116, 128, 141,  91,  88, 106, 102, 158, 185, 163, ...
  109, 122, 111, 118, 137, 125, 126, 127, 136, 139, 148, 157, 213, 258, 172, ...
  124, 167, 176, 135, 222, 155, 143, 144, 133, 231, 197, 240, 164, 211, 214, ...
  151, 152, 184, 193, 161, 173, 298, 229, 160, 187, 154, 196, 201, 189, 223, ...
  170, 238, 267, 206, 232, 181, 180, 215, 224, 203, 212, 221, 183, 259, 233, ...
  ...
.
The sum of the digits inside the upper 2 X 2 squares is (1 + 2) + (3 + 1 + 2) = 9 (a square);
The sum of the digits inside the next horizontal 2 X 2 square is (2 + 4) + (1 + 2 + 7) = 16 (a square);
The sum of the digits inside the next horizontal 2 X 2 square is (4 + 6) + (7 + 8) = 25 (a square);
...
The sum of the digits inside the 2nd vertical 2 X 2 square on the left is (3 + 1 + 2) + (5 + 1 + 4) = 16 (a square);
The sum of the digits inside the next vertical 2 X 2 square on the left is (5 + 1 + 4) + (1 + 1 + 1 + 3) = 16 (a square);
...
The sum of the digits inside the lower right 2 X 2 square is (1 + 8 + 9) + (2 + 2 + 3) + (2 + 5 + 9) + (2 + 3 + 3) = 49 (a square); etc.
		

Crossrefs

Cf. A325785.
Showing 1-4 of 4 results.