%I #11 Dec 07 2021 02:57:03
%S 0,1,4,12,34,92,242,628,1616,4138,10570,26970,68798,175545,448176,
%T 1145058,2927924,7493021,19191836,49195806,126205062,324000494,
%U 832371414,2139802870,5504256592,14166936063,36483006046,94000206216
%N Number of peaks at even level in all Dyck paths of semilength n with no UUU's and no DDD's, (U=(1,1), D=(1,-1)). These Dyck paths are counted by the secondary structure numbers (A004148).
%H G. C. Greubel, <a href="/A166294/b166294.txt">Table of n, a(n) for n = 1..1000</a>
%F a(n) = Sum_{k=0..n-1} k*A166293(n,k).
%F G.f.: G=z[z - 1 + (1 - z + z^2)g(z)]/[(1 - z - z^2)(1 - z - z^2 - 2z^3*g(z)], where g=g(z) satisfies g = 1 + zg + z^2*g + z^3*g^2.
%F a(n) ~ sqrt(55 + 123/sqrt(5)) * (3+sqrt(5))^n / (sqrt(Pi*n) * 2^(n+5/2)). - _Vaclav Kotesovec_, Mar 20 2014
%F Equivalently, a(n) ~ phi^(2*n + 5) / (4 * 5^(1/4) * sqrt(Pi*n)), where phi = A001622 is the golden ratio. - _Vaclav Kotesovec_, Dec 07 2021
%e a(3)=4 because the paths UDUDUD, UDU(UD)D, U(UD)DUD, and U(UD)(UD)D have 0 + 1 + 1 + 2 = 4 peaks at even level (shown between parentheses).
%p g := ((1-z-z^2-sqrt(1-2*z-z^2-2*z^3+z^4))*1/2)/z^3: G := z*(z-1+(1-z+z^2)*g)/((1-z-z^2)*(1-z-z^2-2*z^3*g)): Gser := series(G, z = 0, 35): seq(coeff(Gser, z, n), n = 1 .. 30);
%t Rest[CoefficientList[Series[x*(x-1+(1-x+x^2)*((1-x-x^2-Sqrt[1-2*x-x^2-2*x^3+x^4])*1/2)/x^3)/((1-x-x^2)*(1-x-x^2-2*x^3*((1-x-x^2-Sqrt[1-2*x-x^2-2*x^3+x^4])*1/2)/x^3)), {x, 0, 20}], x]] (* _Vaclav Kotesovec_, Mar 20 2014 *)
%Y Cf. A004148, A166291, A166292, A166293.
%K nonn
%O 1,3
%A _Emeric Deutsch_, Oct 12 2009
|