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.

A357291 a(n) = number of subsets S of {1,2,...,n} having more than 2 elements such that (sum of least two elements of S) < difference between greatest two elements of S.

This page as a plain text file.
%I A357291 #12 Oct 13 2022 13:09:01
%S A357291 0,0,0,0,0,0,1,3,8,19,42,89,185,378,766,1544,3102,6220,12459,24939,
%T A357291 49902,99831,199692,399417,798871,1597782,3195608,6391264,12782580,
%U A357291 25565216,51130493,102261051,204522172,409044419,818088918,1636177921,3272355933
%N A357291 a(n) = number of subsets S of {1,2,...,n} having more than 2 elements such that (sum of least two elements of S) < difference between greatest two elements of S.
%H A357291 <a href="/index/Rec#order_07">Index entries for linear recurrences with constant coefficients</a>, signature (3,-1,-2,-1,1,3,-2).
%F A357291 a(n) = 3*a(n-1) - a(n-2) - 2*a(n-3) - a(n-4) + a(n-5) + 3*a(n-6) - 2*a(n-7).
%F A357291 G.f.: x^6/((-1 + x)^3 (1 + x) (-1 + 2 x) (1 + x + x^2)).
%F A357291 a(n) ~ A021025*2^n. - _Stefano Spezia_, Oct 03 2022
%F A357291 a(n) = 2^n/21 - n^2/12 + n/6 + O(1). Conjecture: a(n) = round(2^n/21 - n^2/12 + n/6). - _Charles R Greathouse IV_, Oct 11 2022
%e A357291 The 3 relevant subsets of {1,2,3,4,5,6,7} are {1, 2, 6}, {1, 2, 7}, {1, 2, 3, 7}.
%t A357291 s[n_] := s[n] = Select[Subsets[Range[n]], Length[#] >= 3 &];
%t A357291 a[n_] := Select[s[n], #[[1]] + #[[2]] < #[[-1]] - #[[-2]] &]
%t A357291 Table[Length[a[n]], {n, 0, 15}]
%Y A357291 Cf. A357290, A357292.
%Y A357291 Cf. A021025.
%K A357291 nonn,easy
%O A357291 0,8
%A A357291 _Clark Kimberling_, Oct 02 2022