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.
%I A307469 #19 Feb 20 2023 09:47:24 %S A307469 1,5,16,62,220,812,2944,10760,39184,142928,520960,1899488,6924736, %T A307469 25246400,92041216,335560832,1223368960,4460102912,16260419584, %U A307469 59281456640,216125430784,787939601408,2872631787520,10472901183488,38181593092096,139200593285120 %N A307469 a(n) = 2*a(n-1) + 6*a(n-2) for n >= 2, a(0) = 1, a(1) = 5. %C A307469 a(n) is the number of words of length n over alphabet {1,2,3,4,5} such that no odd letter is followed by an odd letter. %H A307469 <a href="/index/Rec#order_02">Index entries for linear recurrences with constant coefficients</a>, signature (2,6). %F A307469 a(n) = (-(2/7)*sqrt(7)+1/2)*(1-sqrt(7))^n+((2/7)*sqrt(7)+1/2)*(1+sqrt(7))^n. %F A307469 G.f.: (1+3*x)/(1-2*x-6*x^2). %F A307469 a(n) = 3*A083099(n) + A083099(n+1). - _R. J. Mathar_, Jan 27 2020 %e A307469 For n=2 the a(2)=16 solutions are: 12, 14, 21, 22, 23, 24, 25, 32, 34, 41, 42, 43, 44, 45, 52, 54. %p A307469 aseq:=proc(n) option remember; %p A307469 if n<0 then return "seq not defined for negative indices"; %p A307469 elif n=0 then return 1; %p A307469 elif n=1 then return 5; %p A307469 else 2*aseq(n-1)+6*aseq(n-2); %p A307469 end if; %p A307469 end proc: %p A307469 seq(aseq(n),n=0..26); %t A307469 a[0] = 1; a[1] = 5; %t A307469 a[n_] := a[n] = 2*a[n - 1] + 6*a[n - 2]; %t A307469 Table[a[n], {n, 0, 26}] %t A307469 LinearRecurrence[{2,6},{1,5},30] (* _Harvey P. Dale_, Feb 20 2023 *) %Y A307469 The same over alphabet {1,2,3} gives A001045(n+2). %K A307469 nonn,easy %O A307469 0,2 %A A307469 _Armend Shabani_, Apr 09 2019