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.

A224704 Number of stacks of n triangles, pointing upwards or downwards depending on row parity.

This page as a plain text file.
%I A224704 #36 Jul 14 2019 16:49:05
%S A224704 1,1,1,2,4,7,13,24,45,84,156,291,543,1013,1889,3524,6575,12266,22883,
%T A224704 42691,79647,148593,277221,517197,964911,1800189,3358526,6265846,
%U A224704 11689902,21809313,40688632,75910917,141623529,264220545,492944193,919663462,1715774125
%N A224704 Number of stacks of n triangles, pointing upwards or downwards depending on row parity.
%C A224704 A stack is formed by starting with a row of triangles pointing upwards, and then additional triangles pointing downwards can be inserted between adjacent triangles pointing upwards, and additional triangles pointing upwards can be put on top of triangles pointing downwards.
%C A224704 Number of compositions of n with a(1) = 1 and a(i+1) <= a(i) + 1 + mod(a(i),2).
%C A224704 From _Peter Bala_, Jul 12 2019: (Start)
%C A224704 These triangle stacks may be defined using Schröder paths. A Schröder path is a lattice path in the plane starting and ending on the x-axis, never going below the x-axis, using the steps (1,1) rise, (1,-1) fall or (2,0) flat. A small Schröder path is a Schröder path with no flat steps on the x-axis.
%C A224704 The area between a small Schröder path and the x-axis may be decomposed into a stack of unit area triangles of two types - up triangles with vertices at the lattice points (x, y), (x+1, y+1) and (x+2, y) and down triangles with vertices at the lattice points (x, y), (x-1, y+1) and (x+1, y+1). (End)
%H A224704 Seiichi Manyama, <a href="/A224704/b224704.txt">Table of n, a(n) for n = 0..3694</a> (terms 0..500 from Paul Tek)
%H A224704 P. Bala, <a href="/A224704/a224704.pdf">The area beneath small Schröder paths: Notes on A224704, A326453 and A326454</a>
%H A224704 Paul Tek, <a href="/A224704/a224704.png">Illustration of the first terms</a>
%F A224704 From _Peter Bala_, Jul 03 2019: (Start)
%F A224704 O.g.f. as a continued fraction: A(q) = 1/(1 - q/(1 - q^2 - q^3/(1 - q^4 - q^5/(1 - q^6 - q^7/( ... ) )))). Also,
%F A224704 A(q) = 1/(1 - q/(1 - (q^2 + q^3)/(1 - q^5/(1 - (q^4 + q^7)/(1 - q^9/(1 - (q^6 + q^11)/(1 - q^13/( ... ) ))))))) and
%F A224704 A(q) = 1/(2 - (1 + q)/(2 - (1 + q^3)/(2 - (1 + q^5)/(2 - (1 + q^7)/( ... ) )))).
%F A224704 O.g.f. as a ratio of q-series: A(q) =  N(q)/D(q), where N(q) = Sum_{n >= 0} (-1)^n*q^(2*n^2+n)/( (1-q^2)*(1-q^4)*...*(1-q^(2*n)) )^2 and D(q) = Sum_{n >= 0} (-1)^n*q^(2*n^2-n)/( (1-q^2)*(1-q^4)*...*(1-q^(2*n)) )^2.
%F A224704 D(q) has its least (simple) real zero at x = 0.53600 49695 29708 61653 44946 12214 97438 08884 63471 33627....
%F A224704 a(n) ~ c*x^(-n) where c = 0.30516 69461 42293 61432 58334 29163 22891 57284 39056 20388 ... = - N(x)/(x*D'(x)) and the prime indicates differentiation w.r.t. q. (End)
%t A224704 a[ n_] := SeriesCoefficient[ 1/(1 + ContinuedFractionK[ - q^(2 k - 1), 1 - q^(2 k), {k, Ceiling @ Sqrt[n]}]), {q, 0, n}]; (* _Michael Somos_, Jul 14 2019 *)
%o A224704 (Perl)
%o A224704 use bigint;
%o A224704 my $max = 100;
%o A224704 my @d = ( [1] );
%o A224704 foreach my $n (0..$max) {
%o A224704     my $a = 0;
%o A224704     foreach my $h (0..$#{$d[$n]}) {
%o A224704         $a += $d[$n][$h];
%o A224704         my $maxh = ($h % 2) ? ($h+2) : ($h+1);
%o A224704         foreach my $newh (1..$maxh) {
%o A224704             $d[$n+$newh][$newh] += $d[$n][$h];
%o A224704         }
%o A224704     }
%o A224704     print "$a,";
%o A224704 }
%Y A224704 Column 1 of A316354 (except a(0)).
%Y A224704 Cf. A005169, A001524.
%K A224704 nonn
%O A224704 0,4
%A A224704 _Paul Tek_, Apr 16 2013