A334771 a(n) = smallest m that generates a rotationally symmetrical XOR-triangle T(m) with a central triangle of zeros with side length n.
543, 151, 2359, 599, 8607, 2391, 37687, 9559, 137631, 38231, 602935, 152919, 2202015, 611671, 9646903, 2446679, 35232159, 9786711, 154350391, 39146839, 563714463, 156587351, 2469606199, 626349399, 9019431327, 2505397591, 39513699127, 10021590359
Offset: 1
Examples
First 4 terms shown below, replacing 0 with “.” for clarity: a(1) = 543; T(543): 1 . . . . 1 1 1 1 1 1 . . . 1 . . . . 1 . . 1 1 . . . 1 . 1 . 1 . . 1 1 1 1 1 . . . . . 1 . . . 1 . . 1 . 1 1 a(2) = 151; T(151): 1 . . 1 . 1 1 1 1 . 1 1 1 . . 1 1 . . 1 . . 1 . 1 1 1 1 1 . . . 1 . 1 1 a(3) = 2359; T(2359): 1 . . 1 . . 1 1 . 1 1 1 1 . 1 1 . 1 . 1 1 . . 1 1 . 1 1 1 1 . 1 . . 1 1 . . . 1 1 1 1 . 1 . . 1 . . 1 1 1 . 1 1 . . . 1 1 . 1 . 1 . 1 1 1 1 1 . . . 1 . 1 1 a(4) = 599; T(599): 1 . . 1 . 1 . 1 1 1 1 . 1 1 1 1 1 . . 1 1 . . . . 1 . . 1 . . . 1 1 1 1 . . 1 . . 1 . 1 1 1 1 1 . . . 1 . 1 1
Links
- Michael De Vlieger, Table of n, a(n) for n = 1..3314
- Michael De Vlieger, Central zero-triangles in rotationally symmetrical XOR-Triangles, 2020.
- Michael De Vlieger, Diagram montage of XOR-triangles of the first 64 terms.
- Michael De Vlieger, Correlation of A334771, A334769, A334556, and A333624.
- Index entries for sequences related to binary expansion of n
- Index entries for sequences related to XOR-triangles
- Index entries for linear recurrences with constant coefficients, signature (0,0,0,17,0,0,0,-16).
Programs
-
Mathematica
Block[{f, s = Rest[Import["https://oeis.org/A334556/b334556.txt", "Data"][[All, -1]] ], t, u}, f[n_] := NestWhileList[Map[BitXor @@ # &, Partition[#, 2, 1]] &, IntegerDigits[n, 2], Length@ # > 1 &]; Set[{t, u}, Transpose@ Array[Block[{n = s[[#]]}, If[# == 0, Nothing, {n, #}] &@ FirstCase[MapIndexed[If[2 #2 > #3 + 1, Nothing, #1[[#2 ;; -#2]]] & @@ {#1, First[#2], Length@ #1} &, f[n][[1 ;; Ceiling[IntegerLength[#, 2]/(2 Sqrt[3])] + 3]] ], r_List /; FreeQ[r, 1] :> Length@ r] /. k_ /; MissingQ@ k -> 0] &, Length@ s - 1, 2]]; Array[If[! IntegerQ@ #, 0, t[[#]] ] &@ FirstPosition[u, #][[1]] &, Max@ u] ] (* Second, more efficient program: *) LinearRecurrence[{0, 0, 0, 17, 0, 0, 0, -16}, {543, 151, 2359, 599, 8607, 2391, 37687, 9559}, 28] (* Michael De Vlieger, May 20 2020 *)
-
PARI
Vec(x*(543 + 151*x + 2359*x^2 + 599*x^3 - 624*x^4 - 176*x^5 - 2416*x^6 - 624*x^7) / ((1 - x)*(1 + x)*(1 - 2*x)*(1 + 2*x)*(1 + x^2)*(1 + 4*x^2)) + O(x^30)) \\ Colin Barker, May 21 2020
Formula
a(n) = 17*a(n-4) - 16*a(n-8), starting with a(1) = 543, a(2) = 151, a(3) = 2359, a(4) = 599, a(5) = 8607, a(6) = 2391, a(7) = 37687, and a(8) = 9559.
G.f.: x*(543 + 151*x + 2359*x^2 + 599*x^3 - 624*x^4 - 176*x^5 - 2416*x^6 - 624*x^7) / ((1 - x)*(1 + x)*(1 - 2*x)*(1 + 2*x)*(1 + x^2)*(1 + 4*x^2)). - Colin Barker, May 21 2020
Comments