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.

A316384 Number of ways to stack n triangles symmetrically in a valley (pointing upwards or downwards depending on row parity).

This page as a plain text file.
%I A316384 #123 Jul 29 2023 05:04:21
%S A316384 1,1,1,0,1,0,1,1,2,1,2,1,2,1,3,1,4,2,5,2,5,2,6,3,8,4,9,4,10,4,12,6,15,
%T A316384 7,17,7,19,8,22,10,26,12,30,13,33,14,38,17,45,21,51,22,56,24,64,29,74,
%U A316384 33,83,36,92,40,104,46,119,53,133,58,147,63,165,73,187,83,208,90
%N A316384 Number of ways to stack n triangles symmetrically in a valley (pointing upwards or downwards depending on row parity).
%C A316384            *
%C A316384           / \
%C A316384        *-*-*-*-*
%C A316384         \ / \ /
%C A316384          *---*
%C A316384           \ /
%C A316384            *
%C A316384 Such a way to stack is not allowed.
%C A316384 From _George Beck_, Jul 28 2023: (Start)
%C A316384 Equivalently, a(n) is the number of partitions of n such that the 2-modular Ferrers diagram is symmetric.
%C A316384 The first example for n = 16 below corresponds to the partition 9 + 2 + 2 + 2 + 1 with 2-modular Ferrers diagram:
%C A316384    2 2 2 2 1
%C A316384    2
%C A316384    2
%C A316384    2
%C A316384    1
%C A316384 (End)
%H A316384 Seiichi Manyama, <a href="/A316384/b316384.txt">Table of n, a(n) for n = 0..10000</a>
%F A316384 a(2n+1) = A036015(n).
%F A316384 a(2n  ) = A036016(n).
%F A316384 a(n) = |A029838(n)| = |A082303(n)|.
%F A316384 Euler transform of period 16 sequence [1, 0, -1, 1, -1, 1, 1, -1, 1, 1, -1, 1, -1, 0, 1, 0, ...].
%F A316384 a(n) ~ sqrt(sqrt(2) + (-1)^n) * exp(Pi*sqrt(n)/2^(3/2)) / (4*n^(3/4)). - _Vaclav Kotesovec_, Feb 08 2023
%F A316384 G.f.: Product_{k>=1} 1/((1 - x^(16*k-2))*(1 - x^(16*k-8))*(1 - x^(16*k-14))) + x*Product_{k>=1} 1/((1 - x^(16*k-6))*(1 - x^(16*k-8))*(1 - x^(16*k-10))). - _Vaclav Kotesovec_, Feb 08 2023
%e A316384 a(16) = 4.
%e A316384                                  *   *
%e A316384                                 / \ / \
%e A316384      *---*---*---*---*         *---*---*
%e A316384       \ / \ / \ / \ /         / \ / \ / \
%e A316384        *---*---*---*         *---*---*---*
%e A316384         \ / \ / \ /           \ / \ / \ /
%e A316384          *---*---*             *---*---*
%e A316384           \ / \ /               \ / \ /
%e A316384            *---*                 *---*
%e A316384             \ /                   \ /
%e A316384              *                     *
%e A316384    *---*           *---*     *           *
%e A316384     \ / \         / \ /     / \         / \
%e A316384      *---*       *---*     *---*   *   *---*
%e A316384       \ / \     / \ /       \ / \ / \ / \ /
%e A316384        *---*   *---*         *---*---*---*
%e A316384         \ / \ / \ /           \ / \ / \ /
%e A316384          *---*---*             *---*---*
%e A316384           \ / \ /               \ / \ /
%e A316384            *---*                 *---*
%e A316384             \ /                   \ /
%e A316384              *                     *
%e A316384 a(17) = 2.
%e A316384            *---*         *---*           *---*
%e A316384           / \ / \         \ / \         / \ /
%e A316384          *---*---*         *---*       *---*
%e A316384         / \ / \ / \         \ / \     / \ /
%e A316384        *---*---*---*         *---*---*---*
%e A316384         \ / \ / \ /           \ / \ / \ /
%e A316384          *---*---*             *---*---*
%e A316384           \ / \ /               \ / \ /
%e A316384            *---*                 *---*
%e A316384             \ /                   \ /
%e A316384              *                     *
%t A316384 nmax = 100; CoefficientList[Series[(QPochhammer[x^6, x^16]*QPochhammer[x^10, x^16] + x*QPochhammer[x^2, x^16]*QPochhammer[x^14, x^16])/(QPochhammer[x^2, x^4] * QPochhammer[x^8, x^16]), {x, 0, nmax}], x] (* _Vaclav Kotesovec_, Feb 08 2023 *)
%o A316384 (Ruby)
%o A316384 def s(k, n)
%o A316384   s = 0
%o A316384   (1..n).each{|i| s += i if n % i == 0 && i % k == 0}
%o A316384   s
%o A316384 end
%o A316384 def A(ary, n)
%o A316384   a_ary = [1]
%o A316384   a = [0] + (1..n).map{|i| ary.inject(0){|s, j| s + j[1] * s(j[0], i)}}
%o A316384   (1..n).each{|i| a_ary << (1..i).inject(0){|s, j| s - a[j] * a_ary[-j]} / i}
%o A316384   a_ary
%o A316384 end
%o A316384 def A316384(n)
%o A316384   A([[1, 1], [4, -1]], n).map{|i| i.abs}
%o A316384 end
%o A316384 p A316384(100)
%Y A316384 Cf. A000700 (number of symmetric Ferrers graphs with n nodes), A006950 (number of ways to stack n triangles in a valley), A029838, A036015, A036016, A082303.
%K A316384 nonn
%O A316384 0,9
%A A316384 _Seiichi Manyama_, Jun 30 2018