OFFSET
1,1
COMMENTS
Conjecture: n such that the characteristic polynomial of M(n) is irreducible over the rationals where M(n) is an n X n matrix with ones on the skew diagonal and below it and the skew line two positions above it and otherwise zeros; see example for one such matrix. Tested up to n=177. - Joerg Arndt, Aug 10 2011
LINKS
David Lovler, Table of n, a(n) for n = 1..1000
Melvyn B. Nathanson, On the fractional parts of roots of positive real numbers, Amer. Math. Monthly, Vol. 120, No. 5 (2013), pp. 409-429 [see p. 417].
Index entries for linear recurrences with constant coefficients, signature (1,1,-1).
FORMULA
a(n) = a(n-1) +a(n-2) -a(n-3).
a(n) = (10*n-3-(-1)^n)/4, (n>=1). [Corrected by Bruno Berselli, Sep 20 2010]
a(n) = 5*floor((n-1)/2) +3 +(-1)^n. - Gary Detlefs, Mar 02 2010
G.f.: x*(2+2*x+x^2)/((1+x)*(1-x)^2). - Paul Barry, Sep 11 2008
a(n) = 5*n-a(n-1)-4 (with a(1)=2). - Vincenzo Librandi, Nov 18 2010
a(n) = floor((5*n-1)/2). - Gary Detlefs, May 14 2011
a(n) = 2*n + floor((n-1)/2). - Arkadiusz Wesolowski, Sep 19 2012
Sum_{n>=1} (-1)^(n+1)/a(n) = sqrt(2+2/sqrt(5))*Pi/10 - sqrt(5)*log(phi)/5, where phi is the golden ratio (A001622). - Amiram Eldar, Dec 07 2021
E.g.f.: 1 + ((10*x - 3)*exp(x) - exp(-x))/4. - David Lovler, Aug 23 2022
EXAMPLE
The 7 X 7 matrix (dots for zeros):
[....1.1]
[...1.11]
[..1.111]
[.1.1111]
[1.11111]
[.111111]
[1111111]
has the characteristic polynomial x^7 - 5*x^6 - 4*x^5 + 15*x^4 + 5*x^3 - 11*x^2 - x + 1 which is irreducible over the field of rational numbers, and 7 is a term of the sequence. - Joerg Arndt, Aug 10 2011
MAPLE
seq(5*floor((n-1)/2) +3 +(-1)^n, n=1..50); # Gary Detlefs, Mar 02 2010
MATHEMATICA
Select[Range[0, 200], MemberQ[{2, 4}, Mod[#, 5]] &] (* Vladimir Joseph Stephan Orlovsky, Feb 12 2012 *)
LinearRecurrence[{1, 1, -1}, {2, 4, 7}, 80] (* Harvey P. Dale, Mar 26 2024 *)
PROG
(Haskell)
a047211 n = a047211_list !! (n-1)
a047211_list = filter ((`elem` [2, 4]) . (`mod` 5)) [1..]
-- Reinhard Zumkeller, Oct 03 2012
(Magma) [Floor((5*n-1)/2): n in [1..50]]; // Wesley Ivan Hurt, May 25 2014
(PARI) a(n)=(5*n-1)\2 \\ Charles R Greathouse IV, Sep 24 2015
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
N. J. A. Sloane, Dec 11 1999
EXTENSIONS
Conjecture corrected by John M. Campbell, Aug 25 2011
STATUS
approved