%I #28 Feb 24 2021 02:48:18
%S 0,1,3,5,7,11,17,21,23,27,33,39,47,61,77,85,87,91,97,103,111,125,141,
%T 151,159,173,191,211,241,285,325,341,343,347,353,359,367,381,397,407,
%U 415,429,447,467,497,541,581,599,607,621,639
%N Toothpick sequence on the semi-infinite square grid.
%C Contribution from Omar E. Pol, Oct 01 2011 (Start):
%C On the semi-infinite square grid, at stage 0, we start from a vertical half toothpick at [(0,0),(0,1)]. This half toothpick represents one of the two components of the first toothpick placed in the toothpick structure of A139250. Consider only the toothpicks of length 2, so a(0) = 0.
%C At stage 1, we place an orthogonal toothpick of length 2 centered at the end, so a(1) = 1.
%C In each subsequent stage, for every exposed toothpick end, place an orthogonal toothpick centered at that end.
%C The sequence gives the number of toothpicks after n stages. A152968 (the first differences) gives the number of toothpicks added to the structure at n-th stage.
%C For more information see A139250. (End)
%H Seiichi Manyama, <a href="/A152998/b152998.txt">Table of n, a(n) for n = 0..8191</a>
%H David Applegate, Omar E. Pol and N. J. A. Sloane, <a href="/A000695/a000695_1.pdf">The Toothpick Sequence and Other Sequences from Cellular Automata</a>, Congressus Numerantium, Vol. 206 (2010), 157-191. [There is a typo in Theorem 6: (13) should read u(n) = 4.3^(wt(n-1)-1) for n >= 2.]
%H N. J. A. Sloane, <a href="/wiki/Catalog_of_Toothpick_and_CA_Sequences_in_OEIS">Catalog of Toothpick and Cellular Automata Sequences in the OEIS</a>
%H <a href="/index/To#toothpick">Index entries for sequences related to toothpick sequences</a>
%F a(n) = (A139250(n+1)-1)/2.
%F From _Omar E. Pol_, Oct 01 2011: (Start)
%F a(n) = A139250(n+1) - A153003(n) + A153000(n-1) - 1, if n >= 1.
%F a(n) = A153003(n) - A153000(n-1), if n >= 1.
%F a(n) = 2*A153000(n-1) + 1, if n >= 1.
%F (End)
%F a(n) = (A187220(n+2) - 3)/4. - _Omar E. Pol_, Feb 18 2013
%Y Cf. A139250, A139251, A152968.
%Y Cf. A153000, A152978.
%K nonn
%O 0,3
%A _Omar E. Pol_, Dec 19 2008, Dec 23 2008, Jan 02 2008