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.

A373554 Number of ternary length-2 squarefree words of length n not containing the subwords 021 or 10.

Original entry on oeis.org

1, 3, 5, 7, 11, 16, 24, 36, 53, 80, 118, 177, 263, 392, 585, 870, 1299, 1933, 2883, 4295, 6400, 9540, 14212, 21185, 31564, 47042, 70101, 104463, 155680, 231985, 345722, 515187, 767749, 1144111, 1704963, 2540784, 3786288, 5642420, 8408397
Offset: 0

Views

Author

Miquel A. Fiol, Jun 09 2024

Keywords

Examples

			For n=3 the a(3)=7 solutions are  012, 020, 120, 121, 201, 202, 212.
		

Formula

a(n) = 2*a(n-2) + a(n-3) - a(n-4).
G.f.: ((1+x)*(1+2*x+x^2-x^3))/(1-2*x^2-x^3+x^4).