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.

A122657 a(n) = if n mod 2 = 1 then (n^2-1)*n^3/4 else n^5/4.

This page as a plain text file.
%I A122657 #21 Feb 16 2025 08:33:02
%S A122657 0,0,8,54,256,750,1944,4116,8192,14580,25000,39930,62208,92274,134456,
%T A122657 189000,262144,353736,472392,617310,800000,1018710,1288408,1606044,
%U A122657 1990656,2437500,2970344,3582306,4302592,5121690,6075000,7149840,8388608,9774864,11358856
%N A122657 a(n) = if n mod 2 = 1 then (n^2-1)*n^3/4 else n^5/4.
%C A122657 Wiener index of product of two cycles of length n.
%H A122657 Harvey P. Dale, <a href="/A122657/b122657.txt">Table of n, a(n) for n = 0..1000</a>
%H A122657 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/TorusGridGraph.html">Torus Grid Graph</a>
%H A122657 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/WienerIndex.html">Wiener Index</a>
%H A122657 J. Zerovnik, <a href="http://dx.doi.org/10.1021/ja01193a005">Szeged index of symmetric graphs</a>, J. Chem. Inf. Comput. Sci., 39 (1999), 77-80.
%H A122657 <a href="/index/Rec#order_10">Index entries for linear recurrences with constant coefficients</a>, signature (2,3,-8,-2,12,-2,-8,3,2,-1).
%F A122657 G.f.: 2*x^2*(4*x^6+19*x^5+62*x^4+70*x^3+62*x^2+19*x+4) /((x+1)^4*(x-1)^6). - Maksym Voznyy (voznyy(AT)mail.ru), Jul 28 2009
%t A122657 Table[If[Mod[n, 2] == 0, n^5, (n^2 - 1) n^3]/4, {n, 0, 20}] (* _Eric W. Weisstein_, May 10 2017 *)
%t A122657 LinearRecurrence[{2, 3, -8, -2, 12, -2, -8, 3, 2, -1}, {0, 8, 54, 256,
%t A122657    750, 1944, 4116, 8192, 14580, 25000}, {0, 20}] (* _Eric W. Weisstein_, May 10 2017 *)
%t A122657 CoefficientList[Series[2 x^2 (4 x^6 + 19 x^5 + 62 x^4 + 70 x^3 + 62 x^2 + 19 x + 4)/((x + 1)^4 (x - 1)^6), {x, 0, 20}], x] (* _Eric W. Weisstein_, Sep 08 2017 *)
%t A122657 If[OddQ[#],((#^2-1)#^3)/4,#^5/4]&/@Range[0,40] (* _Harvey P. Dale_, Jul 03 2021 *)
%Y A122657 Cf. A034828, A122658.
%K A122657 nonn
%O A122657 0,3
%A A122657 _N. J. A. Sloane_, Sep 22 2006