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.

A276028 Number of ways to transform a sequence of n zeros and n ones to a single number by continually removing two numbers and replacing them with their sum modulo 3.

This page as a plain text file.
%I A276028 #25 Sep 07 2018 03:23:24
%S A276028 1,3,10,50,259,1540,9594,62649,422598,2960716,21030711,152470357,
%T A276028 1129502128,8434189996,63674017174,488573782216,3762932025753,
%U A276028 29178861276815,229208503750838,1803350026315019,14248236439629534,113825380196996557,909507867095014380
%N A276028 Number of ways to transform a sequence of n zeros and n ones to a single number by continually removing two numbers and replacing them with their sum modulo 3.
%C A276028 Also the number of distinct transformations when the initial state consists of n zeros and n twos.
%C A276028 Originally this entry had a reference to a paper on the arXiv by Caleb Ji, Enumerative Properties of Posets Corresponding to a Certain Class of No Strategy Games, arXiv:1608.06025 [math.CO], 2016. However, this article has since been removed from the arXiv. - _N. J. A. Sloane_, Sep 07 2018
%H A276028 Alois P. Heinz, <a href="/A276028/b276028.txt">Table of n, a(n) for n = 1..650</a>
%F A276028 a(n) = f(n, n, 0) where f(a, b, c) is the number of ways to reach one number beginning with a zeros, b ones, and c twos.
%F A276028 Then f(a, b, c) = f_1 + f_2 + f_3 + f_4 where f_1 = f(a-1, b, c) if a>=2 or a, b >=1 or a,c >=1, f_2 = f(a, b-2, c+1) if b >= 2, f_3 = f(a, b+1, c-2) if c >= 2, and f_4 = f(a+1, b-1, c-1) if b, c >= 1, and each are 0 otherwise.  Initial terms: f(a, b, c) = 1 for all 1 <= a+b+c <= 2, where a, b, c >= 0.
%p A276028 b:= proc(x, y, z) option remember;
%p A276028       `if`(x+y+z=1, 1, `if`(y>0 and z>0, b(x+1, y-1, z-1), 0)+
%p A276028       `if`(x>1 or x>0 and y>0 or x>0 and z>0, b(x-1, y, z), 0)+
%p A276028       `if`(y>1, b(x, y-2, z+1), 0)+`if`(z>1, b(x, y+1, z-2), 0))
%p A276028     end:
%p A276028 a:= n-> b(n, n, 0):
%p A276028 seq(a(n), n=1..35);  # _Alois P. Heinz_, Aug 18 2016
%t A276028 b[x_, y_, z_] := b[x, y, z] = If[x + y + z == 1, 1, If[y > 0 && z > 0, b[x + 1, y - 1, z - 1], 0] + If[x > 1 || x > 0 && y > 0 || x > 0 && z > 0, b[x - 1, y, z], 0] + If[y > 1, b[x, y - 2, z + 1], 0] + If[z > 1, b[x, y + 1, z - 2], 0]];
%t A276028 a[n_] := b[n, n, 0];
%t A276028 Table[a[n], {n, 1, 35}] (* _Jean-François Alcover_, Nov 10 2017, after _Alois P. Heinz_ *)
%Y A276028 Cf. A276027, A276029.
%K A276028 nonn
%O A276028 1,2
%A A276028 _Caleb Ji_, Aug 17 2016
%E A276028 More terms from _Alois P. Heinz_, Aug 18 2016