A382478 Number of palindromic binary strings of length n having no 4-runs of 1's.
1, 2, 2, 4, 3, 7, 6, 14, 12, 27, 23, 52, 44, 100, 85, 193, 164, 372, 316, 717, 609, 1382, 1174, 2664, 2263, 5135, 4362, 9898, 8408, 19079, 16207, 36776, 31240, 70888, 60217, 136641, 116072, 263384, 223736, 507689, 431265, 978602, 831290, 1886316, 1602363, 3635991, 3088654, 7008598, 5953572
Offset: 0
Links
- Vincenzo Librandi, Table of n, a(n) for n = 0..2000
- M. A. Nyblom, Counting Palindromic Binary Strings Without r-Runs of Ones, J. Int. Seq. 16 (2013) #13.8.7, P_4(n).
- Index entries for linear recurrences with constant coefficients, signature (0,1,0,1,0,1,0,1).
Crossrefs
Programs
-
Magma
m:=50; R
:=PowerSeriesRing(Integers(), m); Coefficients(R!(-(x^2+1)*(x^5+2*x+1) / (-1+x^2+x^4+x^6+x^8))); // Vincenzo Librandi, May 19 2025 -
Mathematica
LinearRecurrence[{0,1,0,1,0,1,0,1},{1,2,2,4,3,7,6,14},50] (* Vincenzo Librandi, May 19 2025 *)
Formula
G.f.: -(x^2+1)*(x^5+2*x+1)/(-1+x^2+x^4+x^6+x^8).