OFFSET
1,1
COMMENTS
An XOR-triangle T(m) is an inverted 0-1 triangle formed by choosing a top row the binary rendition of n and having each entry in subsequent rows be the XOR of the two values above it, i.e., A038554(m) applied recursively until we reach a single bit.
A334556 is the sequence of rotationally symmetrical T(m).
A central zero-triangle (CZT) is a field of contiguous 0-bits with side length n in T(m) surrounded on all sides by a layer of 1 bits, and generally k > 1 bits of any parity. Alternatively, these might be referred to as "central bubbles".
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 linear recurrences with constant coefficients, signature (0,0,0,17,0,0,0,-16).
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
EXAMPLE
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
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 *)
PROG
(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
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Michael De Vlieger, May 10 2020
STATUS
approved