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.

A334796 a(n) = (A070939(A334769(n)) - A334770(n))/3.

Original entry on oeis.org

2, 2, 3, 2, 2, 3, 3, 3, 3, 3, 3, 2, 2, 3, 3, 2, 4, 4, 4, 4, 2, 3, 3, 4, 4, 3, 3, 4, 4, 3, 5, 5, 5, 5, 3, 2, 4, 4, 4, 4, 2, 3, 5, 5, 5, 5, 5, 3, 5, 2, 5, 4, 5, 4, 4, 5, 4, 5, 2, 5, 3, 5, 6, 6, 6, 6, 3, 4, 5, 5, 4, 3, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 5, 5, 3, 4, 5
Offset: 1

Views

Author

Michael De Vlieger, May 12 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, listed in A334769, a subset of A334556. CZTs have side length k = A334770(n), surrounded on all sides by a layer of 1 bits, and generally j > 1 bits of any parity.
This sequence describes the "frame width" j.
Smallest n with a given value of j appears in A334836. - Michael De Vlieger, May 20 2020

Examples

			a(4) pertains to T(599), with A334770(4) = 4.
(1 + A070939(599) - 4)/3 = (1 + 9 - 4)/3 = 6/3 = 2, thus a(4) = 2.
(Diagram, replacing 0 with “.”):
  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(11) pertains to T(2359), with A334770(11) = 3.
(1 + A070939(2359) - 4)/3 = (1 + 11 - 3)/3 = 9/3 = 3, thus a(11) = 3.
(Diagram):
  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
From _Michael De Vlieger_, May 14 2020: (Start)
Linear recurrences that produce XOR-triangles with frame length j (table may not be exhaustive):
j   LR          Lower               Upper
-----------------------------------------------------
2   (5, -4)     {39, 151}           {57, 223}
3   (17, -16)   {543, 8607}         {993, 15969}
                {1379, 22115}       {1589, 25397}
                {1483, 23755}       {1693, 27037}
                {2359, 37687}       {3785, 60617}
4   (17, -16)   {22243, 356067}     {25525, 408501}
                {39047, 624775}     {57625, 921881}
                {40679, 650983}     {59257, 948089}
                {171475, 2743763}   {208613, 3337957}
                {356067, 5697251}   {408501, 6536117}
... (End)
		

Crossrefs

Programs

  • Mathematica
    Block[{f, s = Rest[Import["https://oeis.org/A334556/b334556.txt", "Data"][[All, -1]] ]}, f[n_] := NestWhileList[Map[BitXor @@ # &, Partition[#, 2, 1]] &, IntegerDigits[n, 2], Length@ # > 1 &]; Array[Block[{n = s[[#]]}, If[# == 0, Nothing, (1 + Floor@ Log2[n] - #)/3] &@ 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] ]