A274651 Triangle read by rows: T(n,k), (1<=k<=n), in which each term is the least positive integer such that no row, column, diagonal, or antidiagonal contains a repeated term.
1, 2, 3, 4, 1, 2, 3, 5, 4, 6, 6, 2, 1, 3, 4, 5, 4, 6, 2, 7, 8, 7, 8, 3, 1, 6, 5, 9, 9, 6, 10, 5, 8, 3, 11, 7, 8, 11, 9, 4, 1, 7, 10, 6, 5, 12, 7, 13, 8, 2, 9, 4, 11, 10, 14, 10, 9, 5, 12, 3, 1, 2, 13, 7, 8, 11, 11, 12, 8, 13, 5, 4, 3, 10, 9, 15, 14, 16, 13, 10, 11, 7, 9, 2, 1, 12, 8, 5, 17, 15, 18
Offset: 1
Examples
Triangle begins: 1; 2, 3; 4, 1, 2; 3, 5, 4, 6; 6, 2, 1, 3, 4; 5, 4, 6, 2, 7, 8; 7, 8, 3, 1, 6, 5, 9; 9, 6, 10, 5, 8, 3, 11, 7; 8, 11, 9, 4, 1, 7, 10, 6, 5; 12, 7, 13, 8, 2, 9, 4, 11, 10, 14; 10, 9, 5, 12, 3, 1, 2, 13, 7, 8, 11; 11, 12, 8, 13, 5, 4, 3, 10, 9, 15, 14, 16; 13, 10, 11, 7, 9, 2, 1, 12, 8, 5, 17, 15, 18; ... From _Omar E. Pol_, Jun 07 2017: (Start) The triangle may be reformatted as an isosceles triangle so that the all 1's sequence (A000012) appears in the central column (but note that this is NOT the way the triangle is constructed!): . . 1; . 2, 3; . 4, 1, 2; . 3, 5, 4, 6; . 6, 2, 1, 3, 4; . 5, 4, 6, 2, 7, 8; . 7, 8, 3, 1, 6, 5, 9; . 9, 6, 10, 5, 8, 3, 11, 7; . 8, 11, 9, 4, 1, 7, 10, 6, 5; ... (End)
Links
- Michel Marcus, Table of n, a(n) for n = 1..20100
- F. Michel Dekking, Jeffrey Shallit, and N. J. A. Sloane, Queens in exile: non-attacking queens on infinite chess boards, Electronic J. Combin., 27:1 (2020), #P1.52.
- N. J. A. Sloane, Notes on A274650 and Proof by Non-Attacking Queens
Crossrefs
Cf. A001844 (indices of the 1's).
Cf. A000012 (middle diagonal).
Every diagonal and every column of the right triangle is a permutation of A000027.
Cf. A274650 is the same triangle but with every entry minus 1.
Programs
-
Mathematica
f[1,1] = 1; (* for 1 < n and 1 <= k <= n *) f[n_,k_] := f[n,k] = Module[{vals=Sort[Join[Map[f[n, #]&, Range[1, k-1]], Map[f[#, k]&, Range[k, n-1]], Map[f[n-k+#, #]&, Range[1, k-1]], Map[f[n-#, k+#]&, Range[1, Floor[(n-k)/2]]]]], c}, c=Complement[Range[1, Last[vals]], vals]; If[c=={}, Last[vals]+1, First[c]]] (* computation of rows 1 ... n of triangle *) a274651[n_] := Prepend[Table[f[i, j], {i, 2, n}, {j, 1, i}], {1}] Flatten[a274651[13]] (* data *) TableForm[a274651[13]] (* triangle *) (* Hartmut F. W. Hoft, Jun 12 2017 *)
Formula
T(n,k) = A274650(n-1,k-1) + 1.
Comments