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.

A385312 a(n) is the number of ternary strings of length n with at least one 0, at least two 1's and at least three 2's.

This page as a plain text file.
%I A385312 #13 Jun 28 2025 19:46:49
%S A385312 0,0,0,0,0,0,60,455,2268,9366,34800,121077,403392,1304732,4133220,
%T A385312 12900771,39837684,122064930,371891592,1128317489,3412864056,
%U A385312 10299925992,31033986588,93394501983,280818931020,843832511150,2534467085280,7609793357805,22843103816688,68558705110836
%N A385312 a(n) is the number of ternary strings of length n with at least one 0, at least two 1's and at least three 2's.
%H A385312 <a href="/index/Rec#order_08">Index entries for linear recurrences with constant coefficients</a>, signature (13,-72,222,-417,489,-350,140,-24).
%F A385312 a(n) = 3^n - 2^(n-2)*(binomial(n,2) + 4*n + 12) + 3*binomial(n,3) + 4*binomial(n,2) + 4*n + 3 for n>=4.
%F A385312 E.g.f.: (exp(x) - x^2/2 - x - 1)*(exp(x) - x - 1)*(exp(x) - 1).
%F A385312 G.f.: x^6*(60 - 325*x +673*x^2 - 678*x^3 + 348*x^4 - 72*x^5)/((1 - x)^4*(1 - 2*x)^3*(1 - 3*x)). - _Stefano Spezia_, Jun 25 2025
%e A385312 a(6) = 60 since the strings are the 60 permutations of 011222.
%e A385312 a(7) = 455 since the strings are the 210 permutations of 0011222, the 140 permutations of 0111222 and the 105 permutations of 0112222.
%t A385312 LinearRecurrence[{13, -72, 222, -417, 489, -350, 140, -24}, {0, 0, 0, 0, 0, 0, 60, 455, 2268, 9366, 34800, 121077}, 30] (* _Amiram Eldar_, Jun 28 2025 *)
%Y A385312 Cf. A000453, A000478, A358341.
%K A385312 nonn,easy
%O A385312 0,7
%A A385312 _Enrique Navarrete_, Jun 25 2025