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.

A334771 a(n) = smallest m that generates a rotationally symmetrical XOR-triangle T(m) with a central triangle of zeros with side length n.

Original entry on oeis.org

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

Views

Author

Michael De Vlieger, May 10 2020

Keywords

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".

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
		

Crossrefs

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