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.

A293004 Expansion of 2*x^2 / (x^3 + x^2 - 3x + 1).

This page as a plain text file.
%I A293004 #44 Sep 08 2022 08:46:19
%S A293004 0,0,2,6,16,40,98,238,576,1392,3362,8118,19600,47320,114242,275806,
%T A293004 665856,1607520,3880898,9369318,22619536,54608392,131836322,318281038,
%U A293004 768398400,1855077840,4478554082,10812186006,26102926096,63018038200,152139002498
%N A293004 Expansion of 2*x^2 / (x^3 + x^2 - 3x + 1).
%C A293004 Number of weak orderings R on {1,...,n} that are weakly single-peaked w.r.t. the total ordering 1 < ... < n and for which {1,...,n} has exactly one maximal element for the weak ordering R.
%H A293004 Colin Barker, <a href="/A293004/b293004.txt">Table of n, a(n) for n = 0..1000</a>
%H A293004 Andrei Asinowski, Cyril Banderier, Sara Billey, Benjamin Hackl, Svante Linusson, <a href="http://www.iam.fmph.uniba.sk/amuc/ojs/index.php/amuc/article/view/1307">Pop-stack sorting and its image: permutations with overlapping runs</a>, Eurocomb, Acta Math. Univ. Comenianae (2019), 1-8.
%H A293004 M. Couceiro, J. Devillet, and J.-L. Marichal, <a href="http://arxiv.org/abs/1709.09162">Quasitrivial semigroups: characterizations and enumerations</a>, arXiv:1709.09162 [math.RA], 2017.
%H A293004 <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (3,-1,-1).
%F A293004 G.f.: 2*x^2 / (x^3 + x^2 - 3x + 1).
%F A293004 a(n) = 2*A048739(n-2), a(0) = a(1) = 0.
%F A293004 From _Colin Barker_, Sep 28 2017: (Start)
%F A293004 a(n) = 3*a(n-1) - a(n-2) - a(n-3) for n > 2.
%F A293004 a(n) = (-2 + (1-sqrt(2))^n + (1+sqrt(2))^n) / 2. (End)
%F A293004 a(n) = A265278(n) for n != 1. - _Joerg Arndt_, Oct 01 2017
%p A293004 A293004:=gfun:-rectoproc({a(n)=3*a(n-1) -a(n-2)-a(n-3),a(0)=0,a(1)=0,a(2)=2},a(n),remember):  map(A293004, [$0..10^3]);  # _Muniru A Asiru_, Oct 09 2017
%t A293004 CoefficientList[Series[2 x^2/(x^3 + x^2 - 3 x + 1), {x, 0, 30}], x] (* _Michael De Vlieger_, Oct 06 2017 *)
%t A293004 RecurrenceTable[{a[1]==a[2]==0, a[3]==2, a[n]==3a[n-1] - a[n-2] - a[n-3]}, a, {n, 40}] (* _Vincenzo Librandi_, Oct 09 2017 *)
%o A293004 (PARI) concat(vector(2), Vec(2*x^2 / (x^3+x^2-3*x+1) + O(x^40))) \\ _Colin Barker_, Sep 28 2017
%o A293004 (Magma) I:=[0,0,2]; [n le 3 select I[n] else 3*Self(n-1)-Self(n-2)-Self(n-3): n in [1..40]]; // _Vincenzo Librandi_, Oct 09 2017
%Y A293004 Cf. A000129, A048739.
%Y A293004 Essentially the same as A265278.
%K A293004 nonn,easy
%O A293004 0,3
%A A293004 _J. Devillet_, Sep 28 2017