editing
approved
editing
approved
LinearRecurrence[{1, 1, -1}, {3, 11, 11}, 80] (* Harvey P. Dale, Oct 05 2022 *)
approved
editing
(MAGMAMagma) [3+8*Floor(n/2): n in [1..70]]; // Vincenzo Librandi, Sep 18 2013
reviewed
approved
proposed
reviewed
editing
proposed
a(n) = 3 + 8*floor(n/2).
More generally, the sequences generated by the recursive relation b(n) = h*n - b(n-1) + k, with b(1)=c and h, k, c, prefixed integers, have the closed form b(n) = (2*h*n + (3*h + 2*k - 4*c)*(-1)^n + h + 2*k)/4. Also, if 2*c = h+k, then b(n) = c + h*floor(n/2); if 2*c = 2*h+k, then b(n) = c + h*floor((n-1)/2); if 2*c = k, b(n) = c + h*floor((n+1)/2). [_- _Bruno Berselli_, Sep 18 2013]
<a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (1,1,-1).
a(n) = 8*n - a(n-1) - 2, with n>1, a(1)=3.
G.f.: x*(3 + 8*x - 3*x^2)/((1+x)*(x-1)^2). - Vincenzo Librandi, Sep 18 2013
a(n) = 4*n + 2*(-1)^n + 1. [_- _Bruno Berselli_, Sep 18 2013]
a(n) = A168381(n) + 1 = A168398(n) - 1. [_- _Bruno Berselli_, Sep 18 2013]
E.g.f.: (4*x + 3)*cosh(x) + (4*x - 1)*sinh(x) - 3. - G. C. Greubel, Jul 19 2016
approved
editing
<a href="/index/Rec">Index to sequences with entries for linear recurrences with constant coefficients</a>, signature (1,1,-1).
<a href="/index/Rea#recLCCRec">Index to sequences with linear recurrences with constant coefficients</a>, signature (1,1,-1).
proposed
approved