%I #113 Jul 02 2024 14:43:21
%S 1,0,1,0,0,1,0,0,0,1,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,
%T 0,1,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,1,0,0,
%U 0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,1
%N a(n) = 1 if n is of the form m(m+3)/2, otherwise 0.
%C Can be read as table: a(n,m) = 1 if n = m >= 0, else 0 (unit matrix).
%C a(n) = number of 1's between successive 0's (see also A005614, A003589 and A007538). - _Eric Angelini_, Jul 06 2005
%C Triangle T(n,k), 0 <= k <= n, read by rows, given by A000004 DELTA A000007 where DELTA is the operator defined in A084938. - _Philippe Deléham_, Jan 03 2009
%C Sequence B is called a reverse reluctant sequence of sequence A, if B is triangle array read by rows: row number k lists first k elements of the sequence A in reverse order.
%C A023531 is reverse reluctant sequence of sequence A000007. - _Boris Putievskiy_, Jan 11 2013
%C Also the Bell transform (and the inverse Bell transform) of 0^n (A000007). For the definition of the Bell transform see A264428. - _Peter Luschny_, Jan 19 2016
%C This is the turn sequence of the triangle spiral. To form the spiral: go a unit step forward, turn left a(n)*120 degrees, and repeat. The triangle sides are the runs of a(n)=0 (no turn). The sequence can be generated by a morphism with a special symbol S for the start of the sequence: S -> S,1; 1 -> 0,1; 0->0. The expansion lengthens each existing side and inserts a new unit side at the start. See the Fractint L-system in the links to draw the spiral this way. - _Kevin Ryde_, Dec 06 2019
%H Antti Karttunen, <a href="/A023531/b023531.txt">Table of n, a(n) for n = 0..100127</a>
%H Wolfdieter Lang, <a href="http://www.cs.uwaterloo.ca/journals/JIS/VOL3/LANG/lang.html">On generalizations of Stirling number triangles</a>, J. Integer Seqs., Vol. 3 (2000), Article 00.2.4.
%H Boris Putievskiy, <a href="http://arxiv.org/abs/1212.2732">Transformations Integer Sequences And Pairing Functions</a> arXiv:1212.2732 [math.CO], 2012.
%H Franck Ramaharo, <a href="https://arxiv.org/abs/1805.10680">A generating polynomial for the pretzel knot</a>, arXiv:1805.10680 [math.CO], 2018.
%H Kevin Ryde, <a href="/A023531/a023531.l.txt">Fractint L-System drawing the spiral</a>.
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/JacobiThetaFunctions.html">Jacobi Theta Functions</a>.
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/ModifiedBesselFunctionoftheFirstKind.html">Modified Bessel Function of the First Kind</a>.
%H <a href="/index/Ch#char_fns">Index entries for characteristic functions</a>.
%F If (floor(sqrt(2*n))-(2*n/(floor(sqrt(2*n)))) = -1, 1, 0). - _Gerald Hillier_, Sep 11 2005
%F a(n) = 1 - A023532(n); a(n) = 1 - mod(floor(((10^(n+2) - 10)/9)10^(n+1 - binomial(floor((1+sqrt(9+8n))/2), 2) - (1+floor(log((10^(n+2) - 10)/9, 10))))), 10). - _Paul Barry_, May 25 2004
%F a(n) = floor((sqrt(9+8n)-1)/2) - floor((sqrt(1+8n)-1)/2). - _Paul Barry_, May 25 2004
%F a(n) = round(sqrt(2n+3)) - round(sqrt(2n+2)). - _Hieronymus Fischer_, Aug 06 2007
%F a(n) = ceiling(2*sqrt(2n+3)) - floor(2*sqrt(2n+2)) - 1. - _Hieronymus Fischer_, Aug 06 2007
%F From _Franklin T. Adams-Watters_, Jun 29 2009: (Start)
%F G.f.: (1/2 x^{-1/8}theta_2(0,x^{1/2}) - 1)/x, where theta_2 is a Jacobi theta function.
%F G.f. for triangle: Sum T(n,k) x^n y^k = 1/(1-x*y). Sum T(n,k) x^n y^k / n! = Sum T(n,k) x^n y^k / k! = exp(x*y). Sum T(n,k) x^n y^k / (n! k!) = I_0(2*sqrt(x*y)), where I is the modified Bessel function of the first kind. (End)
%F a(n) = A000007(m), where m=(t*t+3*t+4)/2-n, t=floor((-1+sqrt(8*n-7))/2). - _Boris Putievskiy_, Jan 11 2013
%F The row polynomials are p(n,x) = x^n = (-1)^n n!Lag(n,-n,x), the normalized, associated Laguerre polynomials of order -n. As the prototypical Appell sequence with e.g.f. exp(x*y), its raising operator is R = x and lowering operator, L = d/dx, i.e., R p(n,x) = p(n+1,x), and L p(n,x) = n * p(n-1,x). - _Tom Copeland_, May 10 2014
%F a(n) = A010054(n+1) if n >= 0. - _Michael Somos_, May 17 2014
%F a(n) = floor(sqrt(2*(n+1)+1/2)-1/2) - floor(sqrt(2*n+1/2)-1/2). - _Mikael Aaltonen_, Jan 18 2015
%F a(n) = A003057(n+3) - A003057(n+2). - _Robert Israel_, Jan 18 2015
%F a(A000096(n)) = 1; a(A007701(n)) = 0. - _Reinhard Zumkeller_, Feb 14 2015
%F Characteristic function of A000096. - _M. F. Hasler_, Apr 12 2018
%F Sum_{k=1..n} a(k) ~ sqrt(2*n). - _Amiram Eldar_, Jan 13 2024
%e As a triangle:
%e 1
%e 0 1
%e 0 0 1
%e 0 0 0 1
%e 0 0 0 0 1
%e 0 0 0 0 0 1
%e G.f. = 1 + x^2 + x^5 + x^9 + x^14 + x^20 + x^27 + x^35 + x^44 + x^54 + ...
%e From _Kevin Ryde_, Dec 06 2019: (Start)
%e .
%e 1 Triangular spiral: start at S;
%e / \ go a unit step forward,
%e 0 0 . turn left a(n)*120 degrees,
%e / \ . repeat.
%e 0 1 0 .
%e / / \ \ \ Each side's length is 1 greater
%e 0 0 0 0 0 than that of the previous side.
%e / / \ \ \
%e 0 0 S---1 0 0
%e / / \ \
%e 0 1---0---0---0---1 0
%e / \
%e 1---0---0---0---0---0---0---1
%e (End)
%p seq(op([0$m,1]),m=0..10); # _Robert Israel_, Jan 18 2015
%t If[IntegerQ[(Sqrt[9+8#]-3)/2],1,0]&/@Range[0,100] (* _Harvey P. Dale_, Jul 27 2011 *)
%t a[ n_] := If[ n < 0, 0, Boole @ IntegerQ @ Sqrt[ 8 n + 9]]; (* _Michael Somos_, May 17 2014 *)
%t a[ n_] := SeriesCoefficient[ (EllipticTheta[ 2, 0, x^(1/2)] / (2 x^(1/8)) - 1) / x, {x, 0, n}]; (* _Michael Somos_, May 17 2014 *)
%o (Haskell)
%o a023531 n = a023531_list !! n
%o a023531_list = concat $ iterate ([0,1] *) [1]
%o instance Num a => Num [a] where
%o fromInteger k = [fromInteger k]
%o (p:ps) + (q:qs) = p + q : ps + qs
%o ps + qs = ps ++ qs
%o (p:ps) * qs'@(q:qs) = p * q : ps * qs' + [p] * qs
%o _ * _ = []
%o -- _Reinhard Zumkeller_, Apr 02 2011
%o (Sage)
%o def A023531_row(n) :
%o if n == 0: return [1]
%o return [0] + A023531_row(n-1)
%o for n in (0..9): print(A023531_row(n)) # _Peter Luschny_, Jul 22 2012
%o (PARI) {a(n) = if( n<0, 0, issquare(8*n + 9))}; /* _Michael Somos_, May 17 2014 */
%o (PARI) A023531(n)=issquare(8*n+9) \\ _M. F. Hasler_, Apr 12 2018
%Y Cf. A000217, A003057, A010054, A000007, A023532.
%Y Cf. A000096, A007701, A024316.
%K nonn,easy,tabl,nice
%O 0,1
%A _Clark Kimberling_, Jun 14 1998
|