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.

A340326 a(n) = a(n-2) + (-1)^n*a(n-1) + n*(1-(-1)^n) with a(0) = a(1) = 1.

This page as a plain text file.
%I A340326 #24 Feb 13 2021 14:58:46
%S A340326 1,1,2,5,7,8,15,7,22,3,25,0,25,1,26,5,31,8,39,7,46,3,49,0,49,1,50,5,
%T A340326 55,8,63,7,70,3,73,0,73,1,74,5,79,8,87,7,94,3,97,0,97,1,98,5,103,8,
%U A340326 111,7,118,3,121,0,121,1,122,5,127,8,135,7,142,3,145,0,145,1,146,5,151
%N A340326 a(n) = a(n-2) + (-1)^n*a(n-1) + n*(1-(-1)^n) with a(0) = a(1) = 1.
%C A340326 If n > 0 then a(2n-1) = A021067(n).
%C A340326 a(n) = 0 if and only if n == -1 (mod 12).
%H A340326 <a href="/index/Rec#order_08">Index entries for linear recurrences with constant coefficients</a>, signature (0,3,0,-4,0,3,0,-1).
%F A340326 G.f.: -(x^6+3*x^5-5*x^4-2*x^3+x^2-x-1)/(x^8-3*x^6+4*x^4-3*x^2+1). - _Alois P. Heinz_, Feb 07 2021
%t A340326 a[0] = 1; a[1] = 1; a[n_] := a[n] =  a[n - 2] + (-1)^n a[n - 1] + n (1 - (-1)^n); Array[a,100]
%Y A340326 Cf. A030119, A065220.
%K A340326 nonn,easy
%O A340326 0,3
%A A340326 _José María Grau Ribas_, Feb 07 2021