OFFSET
1,2
COMMENTS
Starting with offset 5 unsigned: (1, 4, 19, 110, 751, ...) = eigensequence of triangle A003991. - Gary W. Adamson, May 17 2010
LINKS
Seiichi Manyama, Table of n, a(n) for n = 1..451
FORMULA
a(n+1) = (a(n) + a(n+2))/n with a(1) = 1, a(2) = 2.
MAPLE
a[1] := 1:a[2] := 2:for n from 1 to 45 do a[n+2] := n*a[n+1]-a[n]:od:seq(a[i], i=1..45);
MATHEMATICA
a[n_]:= a[n]= If[n<3, n, (n-2)*a[n-1] -a[n-2]];
Table[a[n], {n, 50}] (* G. C. Greubel, Mar 04 2022 *)
PROG
(Magma) [n le 2 select n else (n-2)*Self(n-1) - Self(n-2): n in [1..50]]; // G. C. Greubel, Mar 04 2022
(Sage)
@CachedFunction
def a(n): return n if (n<3) else (n-2)*a(n-1) - a(n-2) # A075374
[a(n) for n in (1..50)] # G. C. Greubel, Mar 04 2022
CROSSREFS
KEYWORD
sign
AUTHOR
Amarnath Murthy, Sep 20 2002
EXTENSIONS
More terms from Sascha Kurz, Jan 30 2003
STATUS
approved